{"product_id":"gmail-google-drive-ap-invoice-automation-with-gemini-quickbooks","title":"Gmail + Google Drive AP Invoice Automation with Gemini \u0026 QuickBooks","description":"\u003ch3\u003eAutomatically turn Gmail + Google Drive invoice attachments into QuickBooks Online vendor bills—using Gemini, confidence checks, and Slack review\u003c\/h3\u003e\n\u003cp\u003eThis n8n workflow watches your \u003cstrong\u003eGmail\u003c\/strong\u003e and a \u003cstrong\u003eGoogle Drive\u003c\/strong\u003e folder for new invoice documents, extracts invoice data with \u003cstrong\u003eGoogle Gemini\u003c\/strong\u003e, and then either creates \u003cstrong\u003eQuickBooks Online\u003c\/strong\u003e vendor bills or routes uncertain invoices to a finance reviewer in \u003cstrong\u003eSlack\u003c\/strong\u003e.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eMonitors for new invoices\u003c\/strong\u003e every minute: triggers when an unread Gmail message with an invoice attachment arrives or when a new file is created in a specified Google Drive folder.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eNormalizes and downloads the document\u003c\/strong\u003e: processes attachment\/file metadata and downloads the file from Google Drive when needed.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eExtracts content by MIME type\u003c\/strong\u003e: pulls embedded text from PDFs; when the document is an image (including scanned PDFs with no extracted text), it sends the file to \u003cstrong\u003eGoogle Gemini vision\u003c\/strong\u003e for analysis.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eExtracts structured invoice fields\u003c\/strong\u003e with Gemini (e.g., vendor, invoice dates, totals, line items, and payment details) and normalizes the result into a consistent invoice JSON payload.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eValidates confidence scores\u003c\/strong\u003e using a \u003cstrong\u003e0.9 confidence threshold\u003c\/strong\u003e for key fields: vendor name, invoice number, and total amount.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eRoutes outcomes\u003c\/strong\u003e:\n    \u003cul\u003e\n      \u003cli\u003e\n\u003cstrong\u003eHigh confidence\u003c\/strong\u003e: appends to Google Sheets \u003cem\u003e“Invoices_Raw”\u003c\/em\u003e and creates a \u003cstrong\u003evendor bill\u003c\/strong\u003e in \u003cstrong\u003eQuickBooks Online\u003c\/strong\u003e.\u003c\/li\u003e\n      \u003cli\u003e\n\u003cstrong\u003eLow confidence\u003c\/strong\u003e: appends to Google Sheets \u003cem\u003e“Invoices_Exceptions”\u003c\/em\u003e and sends a \u003cstrong\u003eSlack\u003c\/strong\u003e message to the finance reviewer with key details and confidence scores for manual review.\u003c\/li\u003e\n    \u003c\/ul\u003e\n  \u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eAccounts payable teams receiving invoices via email while also archiving copies to Google Drive.\u003c\/li\u003e\n  \u003cli\u003eAutomation engineers building an invoice ingestion pipeline that uses Gemini for extraction and human-in-the-loop verification in Slack.\u003c\/li\u003e\n  \u003cli\u003eSaaS operators who need faster QuickBooks Online bill creation with audit-friendly logging in Google Sheets.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003en8n trigger logic:\u003c\/strong\u003e periodic execution (every minute) with rules around unread Gmail messages and new Drive files.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eIntegrations\/nodes mentioned:\u003c\/strong\u003e \u003cstrong\u003eGmail\u003c\/strong\u003e, \u003cstrong\u003eGoogle Drive\u003c\/strong\u003e, \u003cstrong\u003eGoogle Sheets\u003c\/strong\u003e, \u003cstrong\u003eSlack\u003c\/strong\u003e (OAuth2), \u003cstrong\u003eGoogle Gemini\u003c\/strong\u003e, plus workflow control via \u003cstrong\u003eif\u003c\/strong\u003e, \u003cstrong\u003eswitch\u003c\/strong\u003e, and \u003cstrong\u003ecode\u003c\/strong\u003e nodes.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eWorkflow routing:\u003c\/strong\u003e \u003cstrong\u003eif\u003c\/strong\u003e conditions + \u003cstrong\u003eswitch\u003c\/strong\u003e for MIME-type extraction handling; results logged to the two Google Sheets tabs based on confidence.\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":45837453951155,"sku":"N8N-18264","price":70.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/d8uSTWvpCfOy1JwRBTpx5_ueXvfIYU.png?v=1786794477","url":"https:\/\/buyflowscripts.com\/products\/gmail-google-drive-ap-invoice-automation-with-gemini-quickbooks","provider":"N8N Commerce","version":"1.0","type":"link"}