Create fillable document templates from PDF or DOCX with GPT-4o and Google Drive

πŸ“„Template Creator

How it works This workflow accepts any uploaded document (PDF or DOCX) via webhook and automatically converts it into a reusable fill-in-the-blank template.

Step 1 β€” Identify: GPT-4o first reads the document and determines the document type (e.g., Employment Contract, Invoice, NDA, Lease Agreement, Project Proposal) and the specific variable fields that type of document typically contains.

Step 2 β€” Templatize: A second AI pass uses the identified document type and field list to replace all variable content with clearly labeled [BRACKET] placeholders while preserving all static boilerplate and structure verbatim.

Step 3 β€” Deliver: The cleaned template is rendered to PDF via Gotenberg, uploaded to Google Drive, made publicly accessible, and a JSON response with file URLs is returned to the caller.

Setup Configure the Webhook path if needed (default: general-template-creator) Set your OpenAI credential on both LLM nodes Set your Google Drive credential and confirm the target folder ID in the Upload node Confirm the Gotenberg URL matches your self-hosted instance Install the community node n8n-nodes-word2text (see ⚠️ warning sticky)

Customization Swap GPT-4o for GPT-4.1 or GPT-4.1-mini on the Identify node to reduce cost on the lighter classification task Add a Switch node after identification to route different document types to type-specific prompts Modify the Drive folder ID to sort templates into subfolders by document type

Document accepts input from a form such as the one found here: Sample Form

0
Downloads
0
Views
8.31
Quality Score
beginner
Complexity
Author:AI Solutions(View Original β†’)
Created:4/16/2026
Updated:4/23/2026

πŸ”’ Please log in to import templates to n8n and favorite templates

Workflow Visualization

Loading...

Preparing workflow renderer

Comments (0)

Login to post comments