GenAiHub

Last checked 23 October 2026 — responded normally.

Extract and validate invoice data with OpenAI, Google Sheets, and Gmail

Quick overview

Live
Open / InstallLast updated October 23, 2026

Description

Quick overview This workflow receives uploaded invoice files via a webhook, uses OpenAI to extract structured invoice fields, checks and logs invoices in Google Sheets, and emails status updates via Gmail, optionally posting clean invoices to your accounting system through a configurable HTTP request. How it works Receives an invoice file upload via a webhook endpoint. Validates the uploaded file type and extracts text from the PDF content. Uses OpenAI to extract invoice fields (vendor, invoice number/dates, totals, currency, and line items) from the extracted text. Reads the existing “Invoices” tab in Google Sheets to detect duplicates by vendor name and invoice number, and emails you via Gmail if a duplicate is found. Validates line-item totals against the extracted invoice total and flags low-confidence extractions, sending a Gmail review email when manual review is needed. Posts non-flagged invoices to your accounting software via an HTTP request, appends the invoice record with status to Google Sheets, and responds to the webhook with a JSON “received” message. Runs daily at 8:00 AM to read the Google Sheets log, filter invoices still marked “review,” and emails you a reminder list via Gmail. Setup Add credentials for OpenAI, Google Sheets OAuth2, and Gmail OAuth2. Update both CONFIG nodes with your owner email address and the Google Sheets document ID, and create a sheet tab named “Invoices” with columns for at least date, status, vendor_name, invoice_number, total_amount, and currency. Configure the “Post to Accounting - HTTP” request with your QuickBooks/Xero (or other accounting system) endpoint and authentication method. Copy the production webhook URL for the invoice upload webhook and configure your upload form or upstream system to POST the invoice file to it. Requirements An OpenAI API key, a Google account (Sheets + Gmail), and a QuickBooks or Xero account (or any accounting API you can reach over HTTP). Customization Extend the extractor schema with extra fields (PO number, tax rate, cost center), tighten or loosen the duplicate/totals rules in the Code nodes, swap the Sheets log for your ERP, or add a Slack notification alongside the Gmail alerts. Additional info Who's it for: Bookkeepers, accountants, and small businesses drowning in supplier invoices — anyone who still types invoice data into accounting software by hand — plus agencies that want an AP automation service to sell. An n8n automation workflow template by AI Automation Playbook.

Community Metrics

Views
0
Avg Rating
N/A
Ratings
0
Likes
0
Comments
—

Author

AI Automation Playbook

Platform

web

Pricing model

free

Categories

  • Automation
  • AI

Tags

  • n8n
  • workflow
  • google-sheets
  • http-request
  • gmail
  • code
  • openai-chat-model
  • information-extractor

Capabilities

  • 6 nodes

Information

TypeWorkflow
Sourcen8n
AddedOctober 14, 2026

Comments

?

Others in the same category, ranked by how often they are opened.