PICKED FROM N8N.IO · DOCUMENTS & DATA ENTRY
Watches a Gmail inbox for supplier emails with PDF invoices, sends each PDF to LlamaParse to turn tables into text, then asks OpenAI to pull out the invoice fields. The results are added to a Google Sheet and the email is labelled so it is not processed twice.
Template by Jimleuk · 46.7k views on n8n.io · listed there as “Invoice data extraction with LlamaParse and OpenAI”
- DIFFICULTY
- Advanced
- NODES
- 17
- USES AI
- Yes
- PUBLISHED
- July 2024
001 / WHAT HAPPENS
- 01
The Gmail trigger picks up emails with PDF attachments that do not yet carry the 'invoice synced' label.
- 02
The PDF is uploaded to LlamaParse, and the workflow waits and checks until the job is ready.
- 03
The parsed invoice text is fetched back from LlamaParse.
- 04
OpenAI extracts the fields you define into structured data.
- 05
The data is appended to a Google Sheet and the email gets the 'invoice synced' label.
WHO IT SUITS
Suits bookkeepers and small businesses that receive many supplier invoices by email and want them listed in a sheet before keying into accounting software.
CONNECTS
- Gmail
- LlamaParse
- OpenAI
- Google Sheets
002 / BEFORE YOU USE IT HERE
- !Invoices go to LlamaParse and OpenAI, both overseas services, which is a cross-border disclosure under APP 8 of the Privacy Act if they hold personal information, so say so in your privacy policy.
- !Create the 'invoice synced' Gmail label first, and replace the sender filter, Google Sheet URL, sheet name and extracted fields with your own.
- !Needs a LlamaCloud account and a paid OpenAI API key. Check extracted amounts, ABN and GST against the original invoice before relying on them.
- !This template uses older AI nodes, so test it on your current n8n version first.
LOCAL SWAP
Swap the Google Sheets node for the Xero node to create bills there, or for Microsoft Excel 365 if you use Excel.
Need n8n and the AI hosted in Australia? →003 / MORE FOR DOCUMENTS & DATA ENTRY
- 16 NODESAI
DOCUMENTS & DATA ENTRY
Save matching PDF email attachments from Gmail to Google Drive
GmailOpenAIGoogle DriveIntermediateby n8n Team22.1k views - 36 NODESAI
DOCUMENTS & DATA ENTRY
Parse emailed documents with LlamaParse, AI and Telegram alerts
GmailLlamaParseOpenAIGoogle DriveAdvancedby Joseph LePage19.8k views - 5 NODESAI
DOCUMENTS & DATA ENTRY
Generate Google Slides proposals from a form with OpenAI
Google SlidesGoogle DriveGmailOpenAIBeginnerby Gerald Denor14.4k views
004 / QUESTIONS
Anything else is quicker to answer on a call. Thirty minutes, free, with the people who would build it.
Yes. Every template on this list is free on n8n.io. You need an n8n account (n8n Cloud or self-hosted) and accounts for the apps it connects to, some of which charge for API use.
We adapt templates to your systems, add approval steps where customers are involved, host n8n in Australia when the data calls for it and hand it over documented.
Book a free call→