Add Form Fields To PDF using n8n action
PDF4me Add Form Fields To PDF converts static PDF documents into interactive, fillable forms through n8n automation workflows. Process PDFs via n8n triggers, binary data, base64 strings, or public URLs to add form fields (text boxes, checkboxes) with customizable positioning, field names, default values, size control, page-specific targeting, and flexible alignment options. This solution is ideal for form template creation, interactive document generation, data collection forms, survey creation, and automated form design workflows that require professional form field creation with precise positioning and seamless integration.
Setup
Add the PDF4me "Add Form Fields To PDF" node to your n8n workflow and configure the required parameters. For initial setup instructions, see our n8n Integration Guide.
Prerequisites:
- PDF4me API credentials
- n8n workflow access
Configuration:
- Add PDF4me node to workflow
- Select "Add Form Fields To PDF" action
- Configure input parameters (see below)

Parameters
Complete list of parameters for the Add Form Fields To PDF action. Configure these parameters to control form field addition.
Important: Parameters marked with an asterisk (***) are required and must be provided for the action to function correctly.
| Parameter | Type | Description | Example |
|---|---|---|---|
| Input Data Type*** | String | PDF Input Format Selection • Choose the format of your PDF document input • PDF4me supports multiple input types • Options: Binary Data, Base64 String, or URL | Binary Data |
| Input Binary Field | Binary | Binary PDF File Input (Required if Binary Data) • Reference PDF file from previous n8n node or file upload • Works with any PDF document for form field addition • Required when Input Data Type is "Binary Data" | {{ $binary.data }} |
| Base64 PDF Content | String | Base64 Encoded PDF Input (Required if Base64 String) • Provide PDF content as base64 encoded string • Supports various PDF formats for form enhancement • Required when Input Data Type is "Base64 String" | JVBERi... |
| PDF URL | String | Public PDF URL Input (Required if URL) • Provide a public/open permission URL to the PDF file • Downloads and processes the document for form field addition • Required when Input Data Type is "URL" | https://abc.com/doc.pdf |
| Initial Value*** | String | Form Field Default Value • Set the initial or default text value for the form field • Text appears in the field when PDF is opened • Provides guidance or pre-filled information for users | input text |
| Position X*** | Number | Horizontal Field Position • Define the horizontal position (X coordinate) for the form field • Works with alignment settings (Left, Right, Center) • Default value is 0 | 300 |
| Position Y*** | Number | Vertical Field Position • Define the vertical position (Y coordinate) for the form field • Works with alignment settings (Top, Bottom, Middle) • Default value is 0 | 300 |
| Field Name*** | String | Form Field Identifier • Specify a unique name for the form field • Used to identify field in form data extraction and processing • Use descriptive names for better form management | Input Field Name |
| Size*** | Number | Form Field Size • Define the size or font size for the form field • Controls appearance and usability of the form field • Default value is 0 | 4 |
| Pages*** | String | Target Page Specification • Specify page indices as comma-separated values or ranges • Examples: "0,1,2-" or "1,2,3-7" • Default processes all pages if not specified | 1 |
| Form Field Type*** | String | Field Type Selection • Choose the type of form field to add • Options: TextBox (text input), CheckBox (checkbox field) • Different types provide different functionality | TextBox |
| Output File Name*** | String | Output Filename • Specify the name for the generated PDF file with form fields • Must include .pdf extension • PDF4me ensures unique naming and format validation | form_fields_output.pdf |
| Output Binary Field Name*** | String | Binary Data Mapping • Define the variable name for accessing generated PDF binary data • Used in subsequent workflow actions • Essential for workflow data flow | data |
| Async | Boolean | Asynchronous Processing • Enable or disable asynchronous processing • When enabled, operation runs in background for better performance • Recommended for enterprise workflows and high-volume processing | true |
Output
Output Parameters
| Parameter | Type | Description | Example |
|---|---|---|---|
| fileName | String | PDF4me generated filename - The complete filename of the successfully processed PDF document with form fields with proper extension. PDF4me ensures unique naming and validates file format compliance for seamless integration with downstream processes | form_fields_output.pdf |
| mimeType | String | PDF4me MIME type identifier - The standardized MIME type for the generated PDF file, always set to application/pdf by PDF4me's processing engine. This ensures proper file handling and recognition across all systems and applications | application/pdf |
| fileSize | Number | PDF4me file size in bytes - The exact size of the generated PDF file in bytes, provided for storage planning, bandwidth optimization, and file transfer monitoring. Essential for enterprise document management and workflow automation | 121883 |
| success | Boolean | PDF4me form field addition status indicator - Boolean flag indicating the success or failure of the form field addition process. Returns true for successful operations and false for any errors, enabling robust error handling in automated workflows | true |
| message | String | PDF4me form field addition status message - Descriptive message indicating the result of the form field addition process. Provides clear status messages for successful operations and detailed error information for troubleshooting purposes | Form fields added to PDF successfully |
| fieldName | String | PDF4me form field identifier - The name of the form field that was added to the PDF document. This identifier matches the Field Name parameter used during field creation and is essential for form data extraction and field management | Test Box |
| formFieldType | String | PDF4me field type confirmation - The type of form field that was successfully added to the PDF document. Confirms the field type (TextBox, Checkbox, Radio Button, Combo Box) that was created during the operation | TextBox |
| initialValue | String | PDF4me field default value - The initial or default text value that was set for the form field. This value appears in the field when the PDF is opened and provides guidance or pre-filled information for users | input |
| position | Object | PDF4me field position coordinates - The exact position where the form field was placed on the page, containing X and Y coordinates measured in points from the page edges | {"x": 200, "y": 200} |
| size | Number | PDF4me field size confirmation - The size or font size that was applied to the form field. This confirms the field dimensions and appearance settings that were configured during field creation | 3 |
| pages | String | PDF4me target page confirmation - The page number where the form field was successfully added. Confirms the specific page within the document where the field was placed | "1" |
N8N Action Response
The PDF4me Add Form Fields To PDF API returns a response that can be viewed in multiple formats. Choose the view that best fits your needs:
- JSON
- Table
- Schema
- Binary
JSON Response Format
The raw JSON response from the API:
[
{
"success": true,
"message": "Form fields added to PDF successfully",
"fileName": "form_fields_output.pdf",
"mimeType": "application/pdf",
"fileSize": 121883,
"fieldName": "Test Box",
"formFieldType": "TextBox",
"initialValue": "input ",
"position": {
"x": 200,
"y": 200
},
"size": 3,
"pages": "1"
}
]
Table View
Response data in a structured table format:
| Parameter | Value |
|---|---|
| success | true |
| message | Form fields added to PDF successfully |
| fileName | form_fields_output.pdf |
| mimeType | application/pdf |
| fileSize | 121883 |
| fieldName | Test Box |
| formFieldType | TextBox |
| initialValue | input |
| position | {"x": 200, "y": 200} |
| size | 3 |
| pages | "1" |
Schema View
The data structure and types of the response:
success: ✓ true
message: AB Form fields added to PDF successfully
fileName: AB form_fields_output.pdf
mimeType: AB application/pdf
fileSize: # 121883
fieldName: AB Test Box
formFieldType: AB TextBox
initialValue: AB input
position: {} {"x": 200, "y": 200}
size: # 3
pages: AB "1"
Type Indicators:
AB= String#= Number✓= Boolean{}= Object
Binary Data View
The actual PDF file data and metadata:
data
─────────────────────────────────────────
File Name: form_fields_output.pdf
File Extension: pdf
Mime Type: application/pdf
File Size: 119.0 KB
Use Cases
Digital Form Creation and Conversion**
- Convert paper forms into interactive digital PDF forms with fillable fields
- Add form fields to existing documents for data collection and user input
- Create custom form templates for surveys, applications, and feedback collection
Document Enhancement and Interactivity
- Enhance static documents with interactive elements for better user engagement
- Add data collection capabilities to existing PDF documents and reports
- Transform documents into fillable forms for automated data processing
Workflow Automation and Data Collection
- Automate form creation for standardized data collection processes
- Integrate form field addition into document processing workflows
- Create dynamic forms for various business processes and applications