Automating Invoice Processing with n8n, PDF.co, and Airtable
What You'll Build
By the end of this tutorial, you’ll have a fully automated workflow that:
- Monitors your email inbox for new invoice attachments.
- Downloads invoice files automatically.
- Uploads invoices to PDF.co for secure AI-based parsing.
- Extracts invoice details (vendor, customer, line items, totals, etc.).
- Creates a new record in Airtable with the parsed data.
This automation eliminates manual invoice entry and ensures your data flows directly into your system.
Prerequisites
Before you begin, make sure you have:
- A PDF.co API Key → Get yours here
- An email inbox with IMAP access (e.g., Gmail, Outlook, or custom domain)
- An Airtable account + personal access token (for API authentication)
- An n8n instance (cloud or self-hosted)
Quick Start Options
Option A: Import and Run Immediately
- Import the provided workflow template + sample invoice file.
- Connect your IMAP (email), Airtable, and PDF.co credentials.
- Test with the included sample document.
- Activate the workflow.
Option B: Build It Step-by-Step
Follow the steps below to build this workflow from scratch.
Automation Overview
Here’s what the finished workflow does:
- Monitors your inbox for new invoice emails.
- Downloads invoice attachments automatically.
- Uploads the invoice to PDF.co.
- Parses invoice data using PDF.co’s AI Invoice Parser.
- Creates a record in Airtable with extracted details.
Step 1: Trigger Invoice Collection
Node: Email Trigger (IMAP)
Settings:
- Mailbox Name:
INBOX
- Action:
Mark as Read
- Download Attachments:
True
- Custom Email Rules:
["UNSEEN", ["SUBJECT", "Sales Invoice"]]
Success looks like: When a new/unread email with subject “Sales Invoice” arrives, the workflow is triggered and attachments are pulled in.
Step 2: Upload Documents to PDF.co
Node: PDF.co API → Upload File
Settings:
- Binary File:
True
- Input Binary Field:
attachment_0
Success looks like: The invoice file is uploaded securely to PDF.co and returns a file URL for parsing.
Step 3: Parse Invoice with AI
Node: PDF.co API → AI Invoice Parser
Settings:
- Action:
AI Invoice Parser
- URL:
={{ $json.url }}
(from Step 2)
Success looks like: A structured JSON with invoice details is returned. Example output:
{
"vendor": { "name": "ABC Company", "contactInformation": { "email": "contact@abccompany.com" } },
"customer": { "billTo": { "name": "John Doe", "contactInformation": { "email": "johndoe@email.com" } } },
"invoice": { "invoiceNo": "INV-1001", "invoiceDate": "2025-09-21" },
"paymentDetails": { "dueDate": "2025-10-05", "total": "$1,980.00" },
"lineItems": [
{ "description": "Web Design Services", "qty": "1", "unit_price": "$1,000.00", "total": "$1,000.00" }
]
}
Step 4: Create a Record in Airtable
Node: Airtable (Create a Record)
Settings:
- Credentials: Airtable Personal Access Token
- Resource:
Record
- Operation:
Create
- Base:
Invoice Record
(select from list) - Table:
Invoice
(select from list) - Mapping Mode:
Map Each Column Manually
Fields to Map:
- Customer’s Name →
{{$json.body.customer.billTo.name}}
- Customer’s Email →
{{$json.body.customer.billTo.contactInformation.email}}
- Vendor’s Name →
{{$json.body.vendor.name}}
- Vendor’s Email →
{{$json.body.vendor.contactInformation.email}}
- Invoice Date →
{{$json.body.invoice.invoiceDate}}
- Invoice Number →
{{$json.body.invoice.invoiceNo}}
- Payment Due Date →
{{$json.body.paymentDetails.dueDate}}
- Total Amount →
{{$json.body.paymentDetails.total}}
Success looks like: A new record is created in Airtable under your Invoice table, containing parsed invoice details.
Step 5: Final End-to-End Test
- Send an invoice as an attachment to your inbox (or use the sample PDF).
- Execute the workflow in n8n.
- Check Airtable → A new invoice record should appear.
Congratulations!
You’ve successfully automated invoice processing. Your workflow now:
- Captures invoices from email.
- Parses them with AI.
- Logs them into Airtable for tracking.
This setup scales easily—from startup use cases to enterprise-level automation.
Built something cool with this workflow? Share it with us @pdfdotco
Related Tutorials



