🧾 Automated trip expense claim form with OpenAI agent & Google Drive

771 views · 🧾 Invoice Processing

Description

🧾 Automated Trip Expense Claim Form With OpenAI Agent & Google Drive

Watch the demo video below:

Watch the video > This workflow is designed for employees who need to submit expense claims for business trips. It automates the process of extracting data from receipts/invoices, logging it to a Google Sheet, and notifying the finance team via email.

👤 Who’s it for

Ideal users:

⚙️ How it works / What it does

  1. Employee submits a form with trip information (name, department, purpose, dates) and uploads one or more receipts/invoices (PDF).
  2. Uploaded files are saved to Google Drive for record-keeping.
  3. Each PDF is passed to a DocClaim Assistant agent, which uses GPT-4o and a structured parser to extract structured invoice data.
  4. The data is transformed and formatted into a standard JSON structure.
  5. Two parallel paths are followed:
    • Invoice records are appended to a Google Sheet for centralized tracking.
    • A detailed HTML email summarizing the trip and expenses is generated and sent to the finance department for claim processing.

🛠 How to set up

  1. Create a form to capture:

    • Employee Name
    • Department
    • Trip Purpose
    • From Date / To Date
    • Receipt/Invoice File Upload (multiple PDFs)
  2. Configure file upload node to store files in a specific Google Drive folder.

  3. Set up DocClaim Agent using:

    • GPT-4o or any LLM with document analysis capability
    • Output parser for standardizing extracted receipt data (e.g., vendor, total, tax, date)
  4. Transform extracted data into a structured claim record (Code Node).

  5. Path 1: Save records to a Google Sheet (one row per expense).

  6. Path 2:

    • Format the employee + claim data into a dynamic HTML email
    • Use Send Email node to notify the finance department (e.g., finance@yourcompany.com)

✅ Requirements

🧩 How to customize the workflow

🔗 Nodes Used

Send Email, Google Sheets, Google Drive, AI Agent, OpenAI Chat Model, Structured Output Parser

📥 Import

Download workflow.json and import into n8n: Workflow menu → Import from File

📖 Importing guide · 🔑 Credential setup