Extract structured data from medical documents with Google Gemini AI
Ready for 3.0What this workflow does
This workflow has 10 nodes and runs when an HTTP POST request hits its webhook URL. It uses only n8n's built-in nodes. It also calls generativelanguage.googleapis.com over HTTP.
How it runs
Trigger: When an HTTP POST request hits its webhook URL.
- Parse Input (Edit Fields (Set)): sets 3 fields: image_url, expected_type, language_hint
- Download Image (HTTP Request): calls an HTTP API
- Extract to Base (Extract from File): extracts data from a file (binary to propery)
- Prepare for AI (Edit Fields (Set)): sets 1 field: mime_type
- Gemini Classify Extract (HTTP Request): calls generativelanguage.googleapis.com (POST)
- Parse AI Results (Edit Fields (Set)): sets 1 field: classification_output
- Gemini Structure Data (HTTP Request): calls generativelanguage.googleapis.com (POST)
- Finalize Track (Edit Fields (Set)): sets 3 fields: final_result, token_usage, processing_metadata
- API Response (Respond to Webhook): sends the response back to the webhook caller
HTTP calls to: generativelanguage.googleapis.com
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.
Nodes used (5)
- Webhook
n8n-nodes-base.webhook - Edit Fields (Set)
n8n-nodes-base.set - HTTP Request
n8n-nodes-base.httpRequest - Extract from File
n8n-nodes-base.extractFromFile - Respond to Webhook
n8n-nodes-base.respondToWebhook
From the author
How it works Transform medical documents into structured data using Google Gemini AI with enterprise-grade accuracy. Classifies document types (receipts, prescriptions, lab reports, clinical notes) - Extracts text with 95%+ accuracy using advanced OCR -…