Generate Documents in Make
What this module does
PDF4me – Generate Documents merges JSON or XML data into a Word or HTML template and returns the result as a finished PDF, Word document, or Excel file — ready to email, store, or continue processing. Place {'{{fieldName}}'} placeholders in your template, supply matching key-value data, and the module performs the substitution entirely server-side. It is the legacy document generation module — for new scenarios with complex conditional logic or loop structures, use Generate Document Single instead, which supports the full PDF4me LINQ template syntax.
Authenticating Your API Request
Every PDF4me module in Make requires a valid Connection. Create or select one that holds your PDF4me API key so the scenario can authenticate document generation requests securely.
Important Facts You Should Not Miss
invoice_template.docx), mapped from the File Name output of your Dropbox, Google Drive, or OneDrive download step. It is not a template ID from the PDF4me dashboard — the actual template binary is supplied separately via Document Data File.
Set Template File Type and Output Type first, then wire Template Name and Document Data File from the step that downloaded the template. Supply merge data via Document Data Text or Document Data File.
Parameters
Required: Connection, Template File Type, Output Type, Template Name, and Document DataType. Set File to Map first to reveal Template Name and Document Data File.
| Parameter | Required | What it does | Example |
|---|---|---|---|
| Connection | Yes | PDF4me API connection. Click Add and paste your API key to create one. | [email protected] |
| Template File Type | Yes | Format of the template file. Options: Word (DOCX) or html. Has a Map toggle for dynamic scenarios. Hint: "Select Template file type." | Word |
| Output Type | Yes | Format of the generated output. Options: Pdf, Word, or Excel. Has a Map toggle. Choose based on the recipient's needs. | Pdf |
| File | No | How the template is supplied. Choose Map to wire Template Name and Document Data File from a prior module. Choose Dropbox – Download a File for a direct Dropbox trigger. | Map |
| Template Name | Yes | Filename of the template including extension (e.g. invoice_template.docx). Hint: "Template file name." Map from the File Name output of your download step. | 7. File Name |
| Document Data File | No | Binary content of a JSON or XML data file from a storage module. Hint: "Map source document file content from the previous action." If both this and Document Data Text are supplied, this file takes precedence. | 7. Data |
| Document DataType | Yes | Format of the data source. Options: Json or Xml. Has a Map toggle. Hint: "Choose Document Data Type." | Json |
| Document Data Text | No | JSON or XML data as a text string — paste a literal payload or map from a prior module output. Hint: "Input Data text to generate document." Example: [{"name":"John"},{"name":"Jane"}] | [{"name":"John"}] |
| Meta Data Json | No | Optional JSON for field formatting. Use FieldType 2 for date fields, FieldType 0 for checkboxes, FieldType 1 for HTML content. Hint: "MetaData for Fields." | {"FieldsMetaData":[...]} |
Output Fields
| Field | Type | What it contains |
|---|---|---|
Name | String | Filename of the generated document. Map into the file name field of your storage upload or email step. |
Doc Data | Buffer | Binary content of the generated PDF, Word, or Excel file. Wire directly into a Create file action in SharePoint, Google Drive, Dropbox, or OneDrive, or attach it to a Gmail send action. |
Quick Setup
- Add PDF4me → Generate Documents to your Make scenario.
- Select Connection (or click Add to create one with your API key).
- Set Template File Type to Word or html to match your template format.
- Set Output Type to Pdf, Word, or Excel for the desired output.
- Set File to Map, then wire Template Name to the filename output and Document Data File to the binary content of your template download step.
- Set Document DataType to Json or Xml. Enter or map your data in Document Data Text, or leave it empty if the data is already wired via Document Data File.
- Save and click Run once. The Doc Data output holds the finished document — wire it into a storage upload or email step.
Workflow Examples
Workflow ExamplesCommon Make scenario patterns using Generate Documents.
- A webhook fires when a new order is confirmed in Shopify or WooCommerce.
- Google Drive downloads the
invoice_template.docxstored in the team drive. - Generate Documents merges the order payload (customer name, line items, total, due date) into the template with Template File Type set to Word and Output Type set to Pdf.
- The Doc Data PDF is attached to a Gmail message sent to the customer immediately.
- A second Gmail uploads a copy to a "Invoices/2026" folder in Google Drive for accounting records.
- A scheduled scenario triggers every Monday morning and queries Google Sheets for last week's KPI data.
- A Make text module assembles the sheet data into a JSON object with fields matching the report template placeholders.
- Generate Documents merges the JSON into the Word report template with Output Type set to Word.
- The Doc Data Word document is emailed to the management team as an editable attachment before the 9 AM standup.
- A Typeform training completion form triggers the scenario with participant name, course, and date.
- Dropbox downloads the HTML certificate template stored in the team account.
- Generate Documents merges the participant data into the HTML template with Template File Type set to html and Output Type set to Pdf.
- The certificate PDF is emailed to the participant and uploaded to a SharePoint "Certificates" library for compliance records.