Generate a PDF by rendering a named template with provided context data
templateName (string, required): The name of your custom template created in the dashboardx-api-key (string, required): Your API key for authenticationContent-Type: application/jsonpreviewUrl as the src for an iframe (or <object> tag) when you want to render a read-only preview directly in your UI. The URL is short-lived and expires alongside the download link.
Error (400/401/404):
contextJson object structure depends entirely on your template design. Common patterns include:
Certificate Template:
TEMPLATE_NOT_FOUND: Template with specified name doesn’t existINVALID_API_KEY: API key is invalid or expiredMISSING_TEMPLATE_DATA: Required template fields are missingQUOTA_EXCEEDED: Account has exceeded PDF generation limitsURL-encoded name of the template to use for PDF generation
PDF generated successfully
Whether the PDF generation was successful
true
Signed URL to download the generated PDF (expires in 1 hour)
Signed URL to preview the generated PDF in an iframe (expires in 1 hour)
Name of the generated PDF file
Size of the generated PDF in bytes
ID of the template used for generation
Name of the template used for generation