{"product_id":"gmail-supplier-invoice-ocr-with-openai-google-sheets-checks","title":"Gmail Supplier Invoice OCR with OpenAI + Google Sheets Checks","description":"\u003ch3\u003eAutomatically extract supplier invoice data from Gmail PDFs and validate it against your Google Sheets ledger\u003c\/h3\u003e\n\u003cp\u003eThis n8n workflow monitors a Gmail label for supplier invoice PDFs, uses \u003cstrong\u003eOpenAI\u003c\/strong\u003e to extract structured invoice fields, then runs validation checks in \u003cstrong\u003eGoogle Sheets\u003c\/strong\u003e—posting approved invoices to the ledger, routing large invoices to \u003cstrong\u003eSlack\u003c\/strong\u003e for sign-off, and returning failures to the supplier.\u003c\/p\u003e\n\n\u003ch3\u003eWhat this workflow does\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003eGmail-triggered invoice intake:\u003c\/strong\u003e Watches a specified Gmail label for new emails with attachments.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003ePDF filtering + text extraction:\u003c\/strong\u003e Keeps only PDF attachments and extracts the PDF text.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eOpenAI-powered OCR to structured fields:\u003c\/strong\u003e Converts invoice text into structured data such as supplier, invoice number, PO number, dates, currency, totals, and line items.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eGoogle Sheets checks (8 validations):\u003c\/strong\u003e Loads supplier records, open purchase orders, and already-posted invoices from Google Sheets, then checks for issues including duplicates, totals\/tax validity, PO matching, and invoice date sanity.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eLedger posting or escalation:\u003c\/strong\u003e\n    \u003cul\u003e\n      \u003cli\u003eIf all checks pass and the invoice amount is within the approval limit, it appends the record to the \u003cstrong\u003eGoogle Sheets Ledger\u003c\/strong\u003e.\u003c\/li\u003e\n      \u003cli\u003eIf checks pass but the amount exceeds the approval limit, it posts a \u003cstrong\u003eSlack\u003c\/strong\u003e message requesting human sign-off.\u003c\/li\u003e\n    \u003c\/ul\u003e\n  \u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eFailure handling:\u003c\/strong\u003e If any check fails, it appends the invoice to the \u003cstrong\u003eGoogle Sheets Exceptions\u003c\/strong\u003e sheet and emails the supplier with a numbered list of issues.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eUse cases\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003eAutomating supplier invoice OCR and validation for AP teams using Gmail + Google Sheets.\u003c\/li\u003e\n  \u003cli\u003ePreventing duplicate invoice postings by comparing invoice data against already-posted ledger entries.\u003c\/li\u003e\n  \u003cli\u003eEnsuring purchase order (PO) alignment and invoice date reasonableness before recording expenses.\u003c\/li\u003e\n\u003c\/ul\u003e\n\n\u003ch3\u003eTechnical details\u003c\/h3\u003e\n\u003cul\u003e\n  \u003cli\u003e\n\u003cstrong\u003en8n nodes\/integrations:\u003c\/strong\u003e Gmail, OpenAI (extraction), Google Sheets (ledger, open POs, suppliers, exceptions), Slack (approval escalation).\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eLogic controls:\u003c\/strong\u003e Uses nodes such as \u003cem\u003eif\u003c\/em\u003e, \u003cem\u003ecode\u003c\/em\u003e, \u003cem\u003efilter\u003c\/em\u003e, and \u003cem\u003esticky note\u003c\/em\u003e for conditional routing and processing.\u003c\/li\u003e\n  \u003cli\u003e\n\u003cstrong\u003eSetup:\u003c\/strong\u003e Configure Gmail label ID (with attachments enabled), add OpenAI credentials, and provide the Google Sheets spreadsheet URL and sheet names for the ledger and exception handling.\u003c\/li\u003e\n\u003c\/ul\u003e","brand":"N8N Commerce","offers":[{"title":"Default Title","offer_id":46029406863539,"sku":"N8N-19597","price":60.99,"currency_code":"GBP","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0749\/6279\/6723\/files\/y_LDgSkd6aVLEW5cpFoYB_eJSwNPll.png?v=1789463499","url":"https:\/\/buyflowscripts.com\/products\/gmail-supplier-invoice-ocr-with-openai-google-sheets-checks","provider":"N8N Commerce","version":"1.0","type":"link"}