🧾 Flag duplicate and risky AP invoices with Gmail, OpenAI and Supabase

⚑ 50 views · 🧾 Invoice Processing

Description

πŸš€ How it works

Monitors your AP inbox for incoming invoices, extracts structured data with AI, runs duplicate and vendor history checks against Supabase, then scores each invoice for fraud risk β€” routing suspicious ones to Slack and your AP team before any payment is processed.

πŸ› οΈ Set up steps

Estimated setup time: ~20 minutes

  1. Gmail Trigger β€” connect Gmail OAuth2; point it at your AP inbox
  2. OpenAI β€” connect OpenAI API credential (used by both AI Agent nodes)
  3. Supabase β€” connect Supabase API credential; create two tables: invoices (invoice_number, vendor_name, amount, status, risk_level, created_at) and vendors (vendor_name, avg_amount, total_invoices, flagged)
  4. Slack β€” connect Slack OAuth2; update the channel name #invoice-alerts
  5. Gmail (Send) β€” connect Gmail OAuth2; replace ap-manager@example.com
  6. Follow the sticky notes inside the workflow for per-node guidance

πŸ“‹ Prerequisites

Custom Workflow Request with Personal Dashboard

kumar@smartflowcraft.com

https://www.smartflowcraft.com/contact

More free templates

https://www.smartflowcraft.com/n8n-templates

πŸ”— Nodes Used

Slack, Gmail, Supabase, Gmail Trigger, AI Agent, OpenAI Chat Model

πŸ“₯ Import

Download workflow.json and import into n8n: Workflow menu β†’ Import from File

πŸ“– Importing guide Β· πŸ”‘ Credential setup