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

Overview

This node integrates with a PDF generation and management API, enabling users to create, update, and manage PDF templates programmatically. Specifically, the Template - Create operation allows users to create new PDF templates by providing a complete template configuration in JSON format.

Use cases include:

  • Automating the creation of reusable PDF templates for invoices, reports, labels, or certificates.
  • Managing document layouts and data bindings centrally via API.
  • Integrating dynamic PDF template creation into workflows where templates need to be generated or updated on the fly.

Example scenario: A business wants to automate invoice generation. They can define an invoice template JSON with layout, pages, and data settings, then use this node to create that template in the PDF service. Later, documents can be generated from this template with specific data.

Properties

Name Meaning
Template Configuration JSON The full JSON object defining the template configuration. This must include keys such as name, layout, pages (an array), dataSettings, and editor. The JSON defines page size, orientation, margins, components, and other template details. Example structure is provided in the property description.

Output

The output JSON contains the response from the PDF Generator API after creating the template. Typically, it includes details about the newly created template such as its ID, name, and metadata confirming successful creation.

The node does not output binary data for this operation; it returns JSON describing the created template.

Dependencies

  • Requires an API key credential for the PDF Generator API service.
  • The node makes authenticated HTTP requests to the PDF Generator API endpoint (default base URL: https://us1.pdfgeneratorapi.com/api/v4).
  • Proper network access to the API endpoint is necessary.

Troubleshooting

  • Invalid JSON Error: If the "Template Configuration JSON" is malformed or missing required fields (name, layout, pages, etc.), the API will reject the request. Ensure the JSON is valid and matches the expected schema.
  • Authentication Errors: Missing or invalid API credentials will cause authentication failures. Verify that the API key credential is correctly configured.
  • API Endpoint Unreachable: Network issues or incorrect base URL configuration may prevent communication with the API.
  • Operation Not Supported: If the resource or operation parameters are incorrect, the node throws an error indicating unsupported operations.
  • Large Payloads: Very large template configurations might cause timeouts or errors; consider validating and minimizing the JSON payload.

Links and References


This summary focuses on the Template resource's Create operation as requested, based on static analysis of the provided source code and input properties.

Discussion