Library / Files & Cloud Storage
Files & Cloud Storage
Generate invoice PDFs from forms with APITemplate.io, Google Drive, Gmail and Slack
When a form is submitted, it manages files using APITemplate.io, Gmail, Google Drive, Slack.
What it does
# Auto Document Generator from Forms Workflow ## How it works: This workflow converts n8n form submissions into professional PDF invoices. It captures form data, validates key fields, prepares invoice items and document ID, generates the PDF via APITemplate.io, uploads it to Google Drive, emails it to customers via Gmail, and notifies the team via Slack with all links. The complete process requires no manual document editing. ## Setup Steps: 1. Trigger Workflow Open the imported workflow and ensure it is inactive while configuring. The process is triggered by the TRG – Invoice Request Form node when someone submits the hosted form URL. 2. Configure Form Fields In the form node, confirm fields exist for fullName, address_bill_to, company, website, email, company_bill_to, invoice_no, invoice_date, and invoice_due_date. Adjust labels if needed but keep the field names aligned with the rest of the workflow. 3. Wrap and Validate Data The SET – Wrap Form Data node stores the entire incoming JSON as form_data. The IF – Check Required Fields node checks that form_data.fullName, form_data.email, and form_data.invoice_no are not empty. No configuration change is required unless you want to add more validation rules. 4. Prepare Items and Document ID In SET – Items & Document ID, review or edit the hardcoded items array that represents invoice line items and the expression that generates document_id. You can update the sample items to match your typical services, while keeping property names item_name, unit_price, unit, and total. 5. Build Template Payload and Generate PDF The SET – Template Payload node combines form_data, items, and a computed outputFileName. In PDF Generate From Template, attach your APITemplate.io credentials, confirm the template ID matches your invoice template, and ensure each property key has the correct value expression pointing to form_data or items. 6. Store, Email, and Notify Verify PDF Status and upload to Google Drive. Configure Gmail to email invoice to customer and Slack to notify internal team with links and details. Activate and test end-to-end.
The steps
- PDF Generate From Template
- TRG – Invoice Request Form
- SET – Wrap Form Data
- SET – Template Payload
- SET – Items & Document ID
- IF – Check Required Fields
- IF – PDF Generation OK
- GDrive – Upload Invoice
- EMAIL – Send Invoice to Customer
- SLACK – Notify New Invoice
Similar automations
Finance, Invoices & AccountingCreate PDF Invoices in Telegram with APITemplate.io6 stepsFinance, Invoices & AccountingCreate Invoices from Typeform Submissions with APITemplate.io2 stepsDocuments, PDF & OCRCreate Documents from Typeform Submissions with APITemplate.io3 stepsImage, Video & AudioCreate Social Images from Text Templates with APITemplate.io7 steps