Use this powerful n8n workflow to automate bulk PDF generation from Google Sheets data, saving documents to Google Drive, and emailing them via Gmail. Perfect for contracts and invoices.
Download this n8n workflow template and start using it instantly.
Generating personalized business documents—like job proposals, contracts, or invoices—from structured data often becomes a repetitive and time-consuming manual task. This expert n8n workflow provides a complete solution, transforming raw data from Google Sheets into polished, legally compliant PDF documents. By utilizing CraftMyPDF for generation, the workflow ensures dynamic field mapping and high-quality output. Every step is automated: data extraction, document creation, secure archiving in Google Drive, and immediate distribution using a dedicated Gmail n8n node. This specific n8n workflow greatly enhances operational efficiency, making it one of the most valuable n8n templates for data-to-document tasks.
The entire process is initiated using a manual n8n trigger, designed for batch processing. The workflow begins by utilizing the Google Sheets n8n node (Get employees) to query a specified spreadsheet, retrieving all rows that have not yet been marked as processed. The Split In Batches n8n node then ensures that each document request is handled sequentially.
For each item, the CraftMyPDF n8n node (Create agreement) maps the Google Sheets data (names, addresses, positions) to a predefined PDF template ID, generating a unique document. An If n8n node (Success?) verifies the successful creation of the PDF. If successful, an HTTP Request n8n node (Get agreement) downloads the newly created PDF file into the n8n workflow memory.
Next, the file is simultaneously handled by two n8n nodes: the Google Drive n8n node (Upload agreement) archives the file with a dynamically generated filename, and the Gmail n8n node (Send email with PDF) sends the document as an attachment to the corresponding email address listed in the original sheet data. Finally, a second Google Sheets n8n node (Update row) marks the processed row as 'DONE', ensuring this robust n8n workflow does not duplicate efforts upon subsequent executions of the n8n trigger.
When clicking ‘Execute workflow’ (Manual Trigger): This n8n trigger manually initiates the flow for batch processing.
Get employees (Google Sheets n8n node): Function: Reads data from the target Google Sheet, filtered to only retrieve rows that have not been marked as 'DONE'. Key Configuration: Read operation, filtering enabled on the 'DONE' column.
Create agreement (CraftMyPDF n8n node): Function: Generates the PDF document by dynamically injecting data from Google Sheets (names, addresses, position) into the configured template. Key Configuration: Requires a predefined Template ID.
Success? (If n8n node): Function: Directs the flow only if the document generation step returns a 'success' status, ensuring no failed documents are processed further.
Get agreement (HTTP Request n8n node): Function: Downloads the PDF file content using the temporary URL provided by the CraftMyPDF n8n node, converting the file into binary data for subsequent steps.
Upload agreement (Google Drive n8n node): Function: Archives the generated PDF into a designated folder. Key Configuration: File name dynamically constructed using the 'FIRST NAME' and 'LAST NAME' fields from the sheet data.
Send email with PDF (Gmail n8n node): Function: Composes and sends a personalized email, attaching the PDF downloaded by the HTTP Request n8n node. Key Configuration: Send To field is dynamically set using the 'EMAIL' column from the sheet.
Update row (Google Sheets n8n node): Function: Marks the row in the source spreadsheet as processed ('x') using the row number, preventing reprocessing by this effective n8n workflow.
Use this powerful n8n workflow to generate personalized, high-value business automation opportunity reports complete with detailed ROI calculations using chained Anthropic Claude AI agents. Leverage the n8n node structure to automate lead nurturing and qualification.

Automate branded DOCX document creation using an n8n workflow integrating Claude AI and Json2Doc. This robust n8n template manages complex styling, AI prompting, and job polling to deliver professional documents.

Use this powerful n8n workflow to automatically generate high-quality, branded article images using GPT-4o for prompting and FAL Flux for creation, then save them directly to Google Drive.

Use this advanced n8n workflow to automatically monitor Reddit for AI and business automation opportunities. AI agents classify posts and generate full social media content strategies for LinkedIn and Twitter, delivered instantly via Telegram.

Use this powerful n8n workflow to monitor Reddit for pain points, classify them using DeepSeek AI (via OpenRouter), generate innovative business ideas, and store the results in Google Sheets. Get started with n8n templates.

Full-stack Web Developer based in Italy specialising in Marketing & AI-powered automations. For business enquiries, send me an email at [email protected] or add me on Linkedin.com/in/davideboizza







































