Secure Word Document using n8n action
PDF4me Secure Word Document enables adding password protection and security restrictions to Word documents through n8n automation workflows with comprehensive security controls and editing restrictions. This powerful document security feature supports open password protection, document editing restrictions, read-only protection, comment-only access, form field editing, and revision tracking with full control over security levels and password requirements, perfect for confidential documents, collaborative editing, and document access control workflows.
Setup
Add the PDF4me "Secure Word Document" 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 "Secure Word Document" action
- Configure input parameters (see below)

Parameters
Complete list of parameters for the Secure Word Document action. Configure these parameters to control document security behavior.
Important: Parameters marked with an asterisk (***) are required. Password parameters are required when their corresponding security options are enabled.
| Parameter | Type | Description | Example |
|---|---|---|---|
| Input Data Type*** | String | Word Document Input Format Selection • Choose the format of your Word document data input • PDF4me supports multiple input types • Options: Binary Data, Base64 String, or URL | Binary Data |
| Input Binary Field*** | Binary | Binary Word File Input (Required if Binary Data) • Reference Word file (.docx, .doc) from previous n8n node or file upload • PDF4me processes binary Word files with automatic format detection • Required when Input Data Type is "Binary Data" | {{ $binary.data }} |
| Base64 Word Content*** | String | Base64 Encoded Word Input (Required if Base64 String) • Provide Word content (.docx, .doc) as base64 encoded string for secure transmission • PDF4me automatically decodes and processes the Word content • Required when Input Data Type is "Base64 String" | UEsDBBQABgAI... |
| Word Document URL*** | String | Public Word Document URL Input (Required if URL) • Provide a public/open permission URL to the Word file (.docx, .doc) to be processed • PDF4me downloads and processes the Word file from the provided URL • Required when Input Data Type is "URL" | https://abc.com/document.docx |
| Word Document Name*** | String | Word Document Input Filename • Specify the name of the input Word file with proper extension (.docx, .doc) • PDF4me uses this for format detection and processing optimization | document.docx |
| Secure On Open | Boolean | Enable Password Protection • Yes - Requires password to open the document • No - No password required to open (default) • Uses Word's built-in password protection | Yes |
| Open Password | String | Password to Open Document • Password required to open the document • Required when Secure On Open is Yes • Should be strong password (8+ characters) • Case-sensitive password | "SecurePass123!" |
| Security Options Protection Type | String | Document Protection Type • No Protection - No editing restrictions (default) • Read Only - Document cannot be edited, only viewed • Allow Comments - Only comments can be added/modified • Allow Form Fields - Only form fields can be edited • Allow Revisions - Only tracked changes/revisions allowed | "Read Only" |
| Security Options Protection Password | String | Password for Document Protection • Password to remove document protection • Required when Protection Type is not "No Protection" • Should be different from Open Password • Case-sensitive password | "EditPass456!" |
Output
Output Parameters
| Parameter | Type | Description | Example |
|---|---|---|---|
| fileName | String | Secured Word document filename - The name of the output secured Word document file | secured_document.docx |
| fileSize | Number | File size in bytes - The size of the secured Word document in bytes | 13793 |
| success | Boolean | PDF4me operation status - Boolean flag indicating the success or failure of the security application operation. PDF4me returns true for successful operations and false for any errors | true |
| originalFileName | String | Original Word document filename - The name of the input Word document file | document.docx |
| secureOnOpen | Boolean | Password protection status - Indicates whether password protection is enabled for opening the document. true if password is required to open, false otherwise | true |
| protectionType | String | Document protection type - The type of editing protection applied to the document. Values: "ReadOnly", "AllowComments", "AllowFormFields", "AllowRevisions", or empty string if no protection | ReadOnly |
| message | String | Operation message - Descriptive message indicating the result of the security operation | Word document secured successfully |
N8N Action Response
The PDF4me Secure Word Document 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:
[
{
"fileName": "secured_document.docx",
"fileSize": 13793,
"success": true,
"originalFileName": "document.docx",
"secureOnOpen": true,
"protectionType": "ReadOnly",
"message": "Word document secured successfully"
}
]
Table View
Response data in a structured table format:
| Parameter | Value |
|---|---|
| fileName | secured_document.docx |
| fileSize | 13793 |
| success | true |
| originalFileName | document.docx |
| secureOnOpen | true |
| protectionType | ReadOnly |
| message | Word document secured successfully |
Schema View
The data structure and types of the response:
1 item
fileName: T secured_document.docx
fileSize: # 13793
success: ☑ true
originalFileName: T document.docx
secureOnOpen: ☑ true
protectionType: T ReadOnly
message: T Word document secured successfully
Type Indicators:
T= String (Text)#= Number☑= Boolean[]= Array
Binary Data View
The actual Word document file data and metadata:
data
─────────────────────────────
File Name: secured_document.docx
File Extension: docx
Mime Type: application/vnd.openxmlformats-officedocument.wordprocessingml.document
File Size: 13.8 kB
Binary Data Access:
- n8n Binary Object:
$binary.data.data - Base64 Content: Available for direct use
- File Operations: Ready for download, email, or storage
Use Cases
Enterprise Document Automation
- Document Distribution: Send password-protected documents to authorized recipients
- Collaborative Editing: Apply comment-only or revision-only protection for team collaboration
- Form Distribution: Apply form field protection for fillable documents
- Archive Storage: Store read-only documents in secure archives
AI-Powered Document Processing
- Multi-Format Support: Process Word documents in .docx and .doc formats
- Multi-Language Processing: Support for different languages and regions
- Intelligent Security: Automatic application of appropriate security levels
Business Intelligence and Analytics
- Document Security: Ensure documents meet security requirements
- Compliance Monitoring: Apply security controls for regulatory compliance
- Performance Metrics: Track processing accuracy and efficiency