Automation library · Money admin

Extract and log Outlook invoices to OneDrive Excel with OpenAI

Started by a clock, and works across Excel and Outlook. It hands the judgement calls to OpenAI. 24 steps, 2 branches: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAI

24 stepsLarge: read it before trusting it with anything live
2Branches: places the flow splits
0Loops or waits
2Services it connects to

The flow

Starts it 1Model 2Logic 13Service 8

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

  1. 1Schedule, Daily TriggerSchedule triggerStarts it
  2. 2OpenAI, GPT-4.1-mini ModelLm Chat Open AiModel
  3. 3Outlook, Get Unread EmailsMicrosoft OutlookService
  4. 4AI, Extract Invoice FieldsChain LlmModel
  5. 5Code, Prepare Invoice TextCodeLogic
  6. 6Code, Parse Invoice JSONCodeLogic
  7. 7Set, Format Excel RowSetLogic
  8. 8IF, Has Attachment?IfLogic
  9. 9HTTP, Get AttachmentsHttp RequestService
  10. 10Code, No Attachment Pass-ThroughCodeLogic
  11. 11Code, Build Upload PathCodeLogic
  12. 12Merge, Rejoin Attachment BranchesMergeLogic
  13. 13HTTP, Check Folder ExistsHttp RequestService
  14. 14Outlook, Mark as ReadMicrosoft OutlookService
  15. 15Excel, Append Invoice RowMicrosoft ExcelService
  16. 16IF, Folder Exists?IfLogic
  17. 17Filter, Has Invoice DataFilterLogic
  18. 18Merge, After Folder CheckMergeLogic
  19. 19HTTP, Create FolderHttp RequestService
  20. 20Code, Build Digest EmailCodeLogic
  21. 21Code, Decode PDF BinaryCodeLogic
  22. 22Outlook, Send Daily DigestMicrosoft OutlookService
  23. 23HTTP, Upload PDFHttp RequestService
  24. 24Code, Capture PDF LinkCodeLogic

How it's built

Starts on
A clock
Steps
24, with 2 branches
Size
Large: read it before trusting it with anything live
Connects to
Excel, Outlook
Model
OpenAI

Questions

What does it need to run?

An n8n account, plus your own Excel and Outlook 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 24 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 24 steps before you point it at anything that matters.