Automation library · Money admin

Extract Amazon invoice data with Airtop and OpenAI

Started by a clock, and works across Google Drive and Google Sheets. It hands the judgement calls to OpenAI. 25 steps, 1 branch, 3 loops or waits: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAI

25 stepsLarge: read it before trusting it with anything live
1Branch: places the flow splits
3Loops or waits
2Services it connects to

The flow

Starts it 1Model 5Logic 9Service 10

The steps in the order they run, from what starts it.

  1. 1Output Parser - Invoice fieldsOutput Parser StructuredModel
  2. 2Chat modelLm Chat Open AiModel
  3. 3Run every nightSchedule triggerStarts it
  4. 4Auto-fixing Output ParserOutput Parser AutofixingModel
  5. 5Read the invoice imageAgentModel
  6. 6Structure the invoice dataAgentModel
  7. 7Get invoice links from sheetGoogle SheetsService
  8. 8Add invoice data to sheetGoogle SheetsService
  9. 9Keep only today's rowsFilterLogic
  10. 10Close browser sessionAirtopService
  11. 11Loop over invoicesSplit In BatchesLogic
  12. 12Start browser sessionAirtopService
  13. 13Open the invoice pageAirtopService
  14. 14Wait for page to loadWaitLogic
  15. 15Zoom out to fit the pageAirtopService
  16. 16Wait for zoom to applyWaitLogic
  17. 17Screenshot the invoiceAirtopService
  18. 18Is it a PDF or an image?IfLogic
  19. 19Combine file and folderMergeLogic
  20. 20Find this month folder in DriveGoogle DriveService
  21. 21Upload invoice to DriveGoogle DriveService
  22. 22Pick the month folderCodeLogic
  23. 23Download invoice backGoogle DriveService
  24. 24Combine file and linksMergeLogic
  25. 25Build Drive linksCodeLogic

How it's built

Starts on
A clock
Steps
25, with 1 branch, 3 loops or waits
Size
Large: read it before trusting it with anything live
Connects to
Google Drive, Google Sheets
Model
OpenAI

Questions

What does it need to run?

An n8n account, plus your own Google Drive and Google Sheets accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on a clock.

Does it use AI?

Yes. It calls OpenAI. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 25 steps it is large: read it before trusting it with anything live.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

Before you run it

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 25 steps before you point it at anything that matters.