Build monthly mileage reimbursement reports from Google Calendar with OpenAI and Dropbox
Ready for 3.0What this workflow does
This AI workflow has 38 nodes and runs on a schedule (every month at 07:00) (plus 2 other triggers). Along the way it connects Gmail, Dropbox and OpenAI Chat Model. It also calls nominatim.openstreetmap.org over HTTP.
How it runs
Trigger: On a schedule (every month at 07:00) (plus 2 other triggers).
- Settings (Edit Fields (Set)): sets 18 fields: monthOverride, timezone, mode…
- Did the workflow stop? (If): checks a condition and branches into true / false
- Email me: workflow stopped (Gmail): send (message)
- Month to process (Edit Fields (Set)): sets 1 field: month
- Read the month from Google Calendar (HTTP Request): calls an HTTP API (GET)
- Parse the trips (Code): runs custom JavaScript code
- Any event to read with AI? (If): checks a condition and branches into true / false
- Events for the AI (Code): runs custom JavaScript code
- Trips of the month (Code): runs custom JavaScript code
- Read the trip with AI (Basic LLM Chain): sends a prompt to an LLM, with model: OpenAI Chat Model; output parser: Trip structure
…plus 23 more steps. See the full node list below.
Services it uses
Other OpenAI + Gmail templates (1,623) · Other OpenAI + Dropbox templates (6) · Other Dropbox + Gmail templates (5)
HTTP calls to: nominatim.openstreetmap.org
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
- Code node: the task timeout drops from 300s to 60s. Test with a realistic data volume.
Nodes used (15)
- Schedule Trigger
n8n-nodes-base.scheduleTrigger - Edit Fields (Set)
n8n-nodes-base.set - Manual Trigger
n8n-nodes-base.manualTrigger - Error Trigger
n8n-nodes-base.errorTrigger - If
n8n-nodes-base.if - Gmail
n8n-nodes-base.gmail - HTTP Request
n8n-nodes-base.httpRequest - Code
n8n-nodes-base.code - Basic LLM Chain
@n8n/n8n-nodes-langchain.chainLlm - Dropbox
n8n-nodes-base.dropbox - Convert to File
n8n-nodes-base.convertToFile - Filter
n8n-nodes-base.filter - Data table
n8n-nodes-base.dataTable - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Structured Output Parser
@n8n/n8n-nodes-langchain.outputParserStructured
From the author
Quick overview This workflow runs monthly to turn Google Calendar trip events into a mileage reimbursement Excel, using OpenAI to parse free-text events and OpenStreetMap/OSRM to calculate driving distances, then uploads the file to Dropbox and (in live mode)…