Document → Generate
AI-generatedSummary
Generate a PDF from an Eledo document template.
Inputs
- templateScope (required) — Whether to load templates from your private library or from the public gallery.
- templateId (required) — Select the document template to use. Templates are loaded from the selected scope. Choose from the list, or specify an ID using an expression.
- useTemplateVersion — Whether to use a specific template version instead of the latest one.
- templateVersion — Specific version of the template (integer >= 1).
- inputMode (required) — Choose how to provide input data for the selected template. Guided Fields are recommended for most use cases.
- textAndNumberFields — Add template fields and map values (you can use expressions).
- booleanFields — Add template fields and map values (you can use expressions).
- dateFields — Add template fields and map values (you can use expressions).
- payloadJson — Paste the JSON payload for the selected template. You can copy the exact payload structure from the template’s API page in Eledo.
- outputType (required) — Choose how the generated PDF should be returned.
Output shape
The generated PDF is returned as part of the workflow item. The exact shape depends on the outputType setting:
Based on the executeDocumentGenerate implementation: the item always includes json with the original item data. If outputType is 'file', the item includes binary.document with the prepared PDF binary data. If outputType is 'base64', the item includes json.pdfBase64 with the Base64-encoded PDF string, along with json.filename and json.mimeType set to 'application/pdf'. API errors (JSON content-type responses) are thrown as NodeApiError with the API's error message.