PDF Generator API icon

PDF Generator API

Generate PDFs, manage templates, convert HTML/URLs to PDF, and perform PDF operations like watermarking, encryption, and optimization

Document → Generate (Batch)

AI-generated

Summary

Generates a batch of documents from one or more templates, sending each template ID and its JSON data to PDF Generator API. Choose PDF or HTML and a response format; optional fields set the document name and enable testing mode, which adds a PREVIEW stamp.

Inputs

  • Templates (required) — Add one or more template entries. For each, select a template from the list or enter its numeric ID, then provide the required JSON data to merge with that template.
  • Format — Choose PDF (default) or HTML for the generated documents.
  • Output — Choose Base64 (default), File, URL, or Viewer. File is returned inline as binary data; URL and Viewer store the document for 30 days.
  • Additional Fields — Optionally set an output name and enable testing mode. Testing mode does not count generation but adds a large PREVIEW stamp.

Output shape

A single n8n item per input item, containing JSON response data or binary document data, depending on the output format.

For File, the binary property is named from the output name or batch-documents, with the selected format extension; JSON includes success, filename, format, and file size. For Base64, JSON includes success, filename, format, and the API response fields. URL and Viewer return the API response as JSON. Errors stop execution unless Continue On Fail is enabled, in which case an error field is returned for that input item.

Links

Discussion