Today we have introduced 5 new endpoints to provide documents in PDF format:
/api/orders/{code}/pdf
/api/invoices/{code}/pdf
/api/proforma-invoices/{code}/pdf
/api/credit-notes/{code}/pdf
/api/delivery-notes/{code}/pdf
The endpoints are slightly different to the others – in case the call is successfull (200 OK), the response is the PDF file in binary format (Content-type: application/octet-stream
). In case of an error, the response is a common JSON response with an error description.
Before calling this endpoint, the document must already exist – it means it has been already generated via a status change or manually.