How to integrate PDF Generator API with n8n
From Data to Document in 5 Minutes: Your First n8n - PDF Generator API Workflow.
The true power of automation platforms like n8n is unlocked when you connect them to specialised external services like PDF Generator API. If you've ever needed to dynamically create invoices, reports, or certificates, the PDF Generator API is an excellent tool for the job. In this tutorial, we will build a simple but practical n8n workflow that authenticates and calls the PDF Generator API Generate document action, allowing you to create custom documents automatically.
Prerequisites
- An active n8n instance.
- An active PDF Generator API account (free SANDBOX account is great for getting started).
- API Credentials: Workspace Identifier, API Key and Secret in the PDF Generator API "Settings".
- A basic understanding of n8n concepts (workflows, nodes, expressions).
The Easiest Way to Create PDFs in n8n with the Official PDF Generator API Node
Step 1: Downloading the PDF Generator API Node
First, we need to add the official node to your n8n instance.
- Once at your n8n canvas, add a new node by navigating to "+" button.
- Search for "PDF Generator API" on the right side of the canvas.
- Select the node and click the install icon. The PDF Generator API node will be available in few seconds and ready to use.
Step 2: Set Your Credentials
Next, securely connect your PDF Generator API account.
- Double-click the PDF Generator API node you just downloaded, select the Credentials to connect with
- Select + Create new credentials
- Fill in the fields with your API Key, Secret and Workspace Identifier which you can find in your PDF Generator API account settings.
- Click Save.
Step 3: Configure the "Generate Document" Action
With your PDF Generator API module added to the workflow, it's time to tell it exactly what to create. This step involves selecting your template and providing the data to populate it.
As shown in the image, you will configure the following parameters:
- Credential to connect with: Ensure the PDF Generator account you connected in the previous step is selected here.
- Resource: Set this to
Document
. - Document Operations: Choose the
Generate
option. - Template: Select the specific template you want to use from your PDF Generator API account. In the example, a template named "Certificate (ID: 1458495)" is chosen.
- Data: This is the most critical part. You need to provide the dynamic content for your document in JSON format.
In this example, the following JSON data is used:
JSON
{
"name": "John",
"id": "123456",
"role": "Developer"
}
- Format: Select
PDF
as the output file format. - Output: Choose
File
to ensure the final output of this step is a usable file for the next steps in your automation (like sending an email or saving to a drive).
key
(e.g., "name") must match the placeholder name in your PDF template (e.g., {name}
). The value
(e.g., "John") is the information that will replace that placeholder.Related articles you may find helpful
- How is the monthly usage calculated (merges)
- How to share templates with other workspaces?
- What is Expression Language?
Updated on: 08/10/2025
Thank you!