DocuPotion - Generate PDF Documents icon

DocuPotion - Generate PDF Documents

Automatically create PDFs from a reusable template. Use our AI-powered document editor to create your template in minutes and generate error-free PDFs at scale.

Create Document

AI-generated

Summary

Generate a PDF document based on a specified DocuPotion template and dynamic template data, returning the document as a file, URL, or Base64 string according to user preference.

Inputs

  • Template ID (required) — The ID of the DocuPotion template to use for generating the document.
  • Output (required) — Choose how to receive the generated document: as a binary file, a URL link, or a Base64-encoded string.
  • File Name — Specifies the name of the output file when 'File' output is selected; defaults to 'document.pdf'.
  • URL Expiration (Minutes) — Sets the validity duration for the URL in minutes when 'URL' output is selected; must be between 1 and 10080 (default 60).
  • Template Data (required) — JSON object containing dynamic variables that populate the template fields for document generation.

Output shape

A list of items matching input length. Each item contains JSON with success status and format for file outputs plus the binary PDF data, or JSON with response data for URL or Base64 outputs.

When output is 'File', the node produces the PDF as binary data with metadata including the filename. When output is 'URL', the response includes a URL valid for the specified expiration. When output is 'Base64', the response includes the Base64-encoded PDF string. Invalid JSON in 'Template Data' causes operation failure unless 'Continue On Fail' is enabled.

Examples

Example 1: Generate a PDF file from a template with dynamic data and use it in subsequent workflow steps as binary data.

Set 'Template ID' to a valid template identifier, 'Output' to 'File', provide 'File Name' if desired, and supply JSON in 'Template Data' matching template variables.

Example 2: Create a PDF document and receive a temporary URL to access it.

Set 'Output' to 'URL', specify 'URL Expiration (Minutes)' for how long the URL remains active, and provide required template parameters.

Links

Discussion