n8n-nodes-pdfgenstudio
v1.0.6
Published
n8n node for PDF Gen Studio - Generate PDFs and images from templates, JSON, or HTML
Maintainers
Readme
n8n-nodes-pdfgenstudio
This is an n8n community node for PDF Gen Studio - a powerful document generation API that lets you create PDFs and images from templates, JSON designs, or HTML.
Features
- Template Renderer: Render saved templates with dynamic data injection
- JSON Renderer: Render raw JSON design documents to PDF/PNG/JPG/HTML
- HTML Renderer: Convert HTML content to PDF or images
Installation
In n8n Desktop/Self-hosted
- Go to Settings > Community Nodes
- Select Install
- Enter
n8n-nodes-pdfgenstudioand click Install
Using npm
npm install n8n-nodes-pdfgenstudioCredentials
To use this node, you need a PDF Gen Studio API key:
- Sign up at PDF Gen Studio
- Go to your Dashboard > API Keys
- Create a new API key
- In n8n, create new credentials for "PDF Gen Studio API"
- Enter your API key and base URL
Credential Properties
| Property | Description |
|----------|-------------|
| API Key | Your PDF Gen Studio API key |
| Base URL | API base URL (default: https://api.pdfgenstudio.com) |
Node Operations
Template Renderer
Render saved templates with dynamic data.
Parameters: | Parameter | Description | |-----------|-------------| | Template | Select from your saved templates or enter ID directly | | Dynamic Data | JSON data to inject into template placeholders | | Output Format | PDF, PNG, or JPG | | Response Type | Binary (file) or Base64 (encoded string) |
Options:
- Text Overflow: How to handle text exceeding boundaries (truncate, wrap, scale, none)
- Table Pagination: Auto-paginate tables exceeding page height
- Table Header on New Page: Repeat headers on new pages
- Pixel Ratio: Image quality multiplier (1-4)
- Quality: JPG quality (0.1-1)
- Page Index: Render specific page only
JSON Renderer
Render raw JSON design documents.
Parameters: | Parameter | Description | |-----------|-------------| | JSON Document | The JSON design document structure | | Output Format | PDF, PNG, JPG, or HTML | | Response Type | Binary, Base64, or Preview (HTML only) | | Validate Only | Only validate without rendering |
Options:
- Scale, Quality, Print Background
- Header/Footer templates
- Timeout, Full Page, Omit Background, Raw output
HTML Renderer
Convert HTML content to PDF or images.
Parameters: | Parameter | Description | |-----------|-------------| | HTML Content | Complete HTML document | | Output Format | PDF, PNG, or JPG | | Response Type | Binary or Base64 |
PDF Options:
- Page Format: A4, A3, A5, Letter, Legal, Tabloid
- Orientation: Portrait or Landscape
- Margins, Scale, Print Background
- Header/Footer templates, Page Ranges
- Custom Width/Height, Timeout
Image Options:
- Quality (1-100)
- Full Page, Omit Background, Timeout
Example Workflows
Generate Invoice PDF from Template
- Trigger: Webhook or Schedule
- Set Node: Prepare invoice data
- PDF Gen Studio: Template Renderer
- Select invoice template
- Pass dynamic data with customer info, items, totals
Convert HTML Report to PDF
- HTTP Request: Fetch HTML report
- PDF Gen Studio: HTML Renderer
- Pass HTML content
- Set format to PDF
- Configure page options
Generate Document from JSON
- Function: Build JSON document structure
- PDF Gen Studio: JSON Renderer
- Pass document JSON
- Choose output format
API Reference
This node connects to the following PDF Gen Studio API endpoints:
| Endpoint | Method | Description |
|----------|--------|-------------|
| /api/v1/templates | GET | List all templates |
| /api/v1/templates/:id | GET | Get template by ID |
| /api/v1/renderer/templates/:id | POST | Render template |
| /api/v1/renderer/json | POST | Render JSON document |
| /api/v1/renderer/html | POST | Render HTML |
All render endpoints support query parameters for options (e.g., ?format=pdf&response=binary).
Support
- Documentation: docs.pdfgenstudio.com
- Issues: GitHub Issues
- Email: [email protected]
License
MIT License - see LICENSE.md
