Skip to content

Print invoice

POST/documents/invoices/{id}/pdf

Costs 2 rate-limit points · Rate limits

Renders the invoice PDF (or reuses the stored one when nothing changed) and returns a signed download URL valid for one week, the file name and when it was generated. Records a download in the invoice history. To only get the link, read the invoice instead (pdf.url); use this for a fresh render or when no PDF is stored yet.

Rendering a new PDF counts against a free plan invoice limit; reusing a stored one does not. To only get the link, read GET /documents/invoices/:id first: pdf.url is the signed link whenever pdf.available is true. Call this when it is false or the merchant wants a fresh render.

Also searched asdownload invoice pdfget invoice pdfprint invoiceregenerate invoice pdfinvoice pdf linkrender invoice

Path parameters

  • idstringRequired

Request body

  • regenerateboolean

    true renders the PDF again even when the stored one is current (default false).

  • template_idinteger

    Template to render with. Default: the shop default for this document type.

Returns

  • idinteger
    Example: 980191015
  • urlstring, nullable
  • filenamestring, nullable
  • generated_atstring, nullable

Errors

401

Missing or unknown X-Auth-Token, or the shop uninstalled the app.

403

v3_required: the shop still runs the previous dashboard. paid_plan_required: API access needs a paid plan.

404

The resource does not exist for this shop, or no action is registered at this path.

422

The request failed validation. Nothing was saved.

429

Rate limited: cost-weighted per key (reads cost less than writes). Wait Retry-After seconds; see X-RateLimit-* headers.

Every error has the same shape: see Errors.

POST/documents/invoices/{id}/pdf
curl -X POST "https://app.invoicefalcon.com/api/v3/external/documents/invoices/980191059/pdf" \
  -H "X-Auth-Token: $INVOICE_FALCON_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
Response
{
  "id": 980191015,
  "url": null,
  "filename": null,
  "generated_at": null
}