Extract invoice data to Excel using Google Gemini, OCR, and Telegram
🚀 1. HOW IT WORKS This workflow automatically extracts structured data from invoices sent via Telegram (PDF or image) and saves it to Excel. 1. A user sends an invoice (PDF or image) to a Telegram bot 2. The workflow...
Template notes
🚀 1. HOW IT WORKS This workflow automatically extracts structured data from invoices sent via Telegram (PDF or image) and saves it to Excel.
1. A user sends an invoice (PDF or image) to a Telegram bot 2. The workflow detects the file type (PDF or image) 3. For PDF: - Extracts text directly from the file - Falls back to OCR if needed 4. For images: - Uses OCR to extract text 5. The extracted text is cleaned and processed 6. AI (Google Gemini) converts the raw text into structured JSON data 7. The data is validated and formatted 8. Valid data is saved to Excel (Microsoft Excel or Google Sheets) 9. A confirmation message is sent back via Telegram
This eliminates manual data entry and speeds up invoice processing.
⚙️ 2. SETUP INSTRUCTIONS Prerequisites:
1. Telegram Bot - Create a bot using BotFather - Copy the Bot Token
2. Google Gemini API Key - Get API key from Google AI Studio
3. Excel / Google Sheets - Prepare a sheet with columns: invoicenumber, date, vendor, total, tax, items
Setup Steps: