Render a PDF from a template and data

Renders a PDF document by merging `data` into a template. Provide either `templateId` (referring to a stored template owned by the calling organization or a system template) or `template` (an inline BlockTemplate). Returns the binary PDF as `application/pdf`. Optional `attachments` are embedded after the render (visible in the Acrobat Attachments pane).

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Request

This endpoint expects an object.
datamap from strings to anyRequired

Data object that is merged into the template placeholders. Shape is template-specific — keys must match the placeholders the template expects.

templateIdstringOptionalformat: "uuid"

UUID of a stored template (system or organization-owned). Mutually exclusive with template.

templatemap from strings to anyOptional

Inline template definition. Mutually exclusive with templateId.

attachmentslist of objectsOptional

Optional file attachments to embed into the rendered PDF (visible in the Acrobat Attachments pane; same mechanism as ZUGFeRD/Factur-X embedding).

Response

PDF document

Errors

400
Generate PDF Request Bad Request Error
401
Generate PDF Request Unauthorized Error
403
Generate PDF Request Forbidden Error
404
Generate PDF Request Not Found Error
429
Generate PDF Request Too Many Requests Error
500
Generate PDF Request Internal Server Error