Templates / Extract invoice data from Google Drive to Sheets with Mistral OCR and Gemini

Extract invoice data from Google Drive to Sheets with Mistral OCR and Gemini

Needs changes

by Ysqander · 16,885 views · created 2025-06-11 · Invoice Processing, AI Summarization

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: AI Agent v1 (old agent modes). 1 breaking item(s) found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 20 nodes and runs manually, when you click “Execute workflow” (plus 1 other trigger). Along the way it connects Google Drive, Google Sheets and Google Gemini Chat Model. It also calls api.mistral.ai over HTTP.

How it runs

Trigger: Manually, when you click “Execute workflow” (plus 1 other trigger).

  1. Load files from Google Drive folder (Google Drive): work with file folder
  2. Get Fields Schema (Google Sheets): uses Google Sheets
  3. Filter processed files (Merge): merges the data from its input branches
  4. extract schema (Code): runs custom JavaScript code
  5. Download file for OCR (Google Drive): download
  6. Get already processed rows from Sheets (Google Sheets): uses Google Sheets
  7. If: checks a condition and branches into true / false
  8. Mistral Upload (HTTP Request): calls api.mistral.ai (POST)
  9. Mistral Upload (HTTP Request): calls api.mistral.ai (POST)
  10. Mistral Signed URL (HTTP Request): calls an HTTP API

…plus 7 more steps. See the full node list below.

Services it uses

Google DriveGoogle SheetsGoogle Gemini Chat Model

HTTP calls to: api.mistral.ai

Before you upgrade to n8n 3.0

1 thing in this workflow is removed in n8n 3.0. Fix it before you upgrade:

  • AI Agent v1 (old agent modes) in Field Extractor (v1.8): replace with Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.
Removed in 3.0Replace with
AI Agent v1 (old agent modes)
Field Extractor (v1.8)
Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.

Nodes used (10)

From the author

Extract data from any PDF or image invoice dropped in Google Drive directly into Google Sheets – powered by AI OCR. Free, fully modifiable n8n workflow. Optional add-ons for pro features. 🚀 What this template does Stop typing invoice data by hand. Drop a PDF…

Excerpt from Ysqander's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.