Email Automation
Reconcile bank payments with GPT-4o-mini, Google Sheets, Gmail and Telegram
On a schedule, it handles email with OpenAI / ChatGPT using Gmail, Google Sheets, Telegram.
What it does
## Reconcile bank payments with open invoices using GPT-4o-mini, Google Sheets, Gmail and Telegram ### How it works Every morning the workflow reads new payments from a "Bank" tab (paste your bank export there) and the open invoices from an "Invoices" tab. A Merge node joins them on the invoice number found in the payment description, so clean payments are matched without AI. The rest go to GPT-4o-mini with the list of open invoices; it names the best candidate with a confidence score and only matches at 80% or more are applied. A Switch classifies each match as Paid, Partial or Overpaid, updates both sheets, logs the decision and pings Telegram about anything that is not a clean full payment. Doubtful or failed AI calls land in a review queue instead of touching your books. Every Monday an aging report of overdue invoices goes out by Gmail. ### Setup steps - Create a Google Sheet with the tabs Invoices, Bank and Log (columns in the section notes) and paste its ID into the Sheets nodes. - Connect Google Sheets, Gmail, OpenAI and Telegram; set your chat ID and finance email. - If your invoice numbers do not look like INV-1042, edit the regex in "Set Payment Fields". ### Customization Change the 80% threshold in the IF node, the Paid tolerance in the Switch, or swap Telegram for Slack.
The steps
- When Day Starts at 7am
- Read Transactions in Sheets
- Set Payment Fields
- Filter Incoming Payments
- Read Invoices in Sheets
- Set Invoice Fields
- Filter Open Invoices
- Merge Payment and Invoice
- If Reference Matched
- Set Match Attributes
- Aggregate Open Invoices
- Merge Invoices with Unmatched Payments
- AI Match Payment Evaluation
- OpenAI GPT-4o-mini
36 steps in total.
Similar automations
Finance, Invoices & AccountingReconcile bank payments to invoices and ERP using Postgres and Claude33 stepsFinance, Invoices & AccountingReconcile bank payments with ERP invoices, Google Sheets, and Slack20 stepsForms & SurveysReconcile invoice payments from bank statements using n8n Forms6 stepsFinance, Invoices & AccountingReconcile Rent Payments with an Excel Sheet and OpenAI11 steps