beel_get_invoice_preview
Generates a temporary pre-signed URL to an invoice WebP preview for inline rendering; returns 202 while the invoice PDF is still being generated.
Instructions
Returns a temporary pre-signed URL to a preview image (WebP) of the invoice, suitable for
inline rendering. The image is generated and cached on first request, so a later call
returns the cached image. The URL expires in five minutes and only allows GET.
The image of an issued invoice is taken from its stored PDF, the one delivered. While that
PDF does not exist yet — right after issuing (whether or not the invoice goes through
VeriFactu, since the PDF is generated asynchronously) or, for a VeriFactu invoice
specifically, while it waits for the QR of its registration — the answer is 202, as for
the PDF download.
Endpoint: GET /v1/companies/{company_id}/invoices/{invoice_id}/preview
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| company_id | Yes | Unique identifier (UUID) of the company the operation acts on — its identifier, not its NIF. It is the only source of context: the account that owns it is derived from it, and the `BeeL-Active-Company` header plays no part. A company you do not reach answers `403`, and so does a company that does not exist, so the existence of a company in another account is never disclosed. | |
| invoice_id | Yes | Invoice ID |