What is CapitalFlow AI?

Small businesses often have to piece together invoices, payment confirmations, and follow-up priorities across separate tools. CapitalFlow AI brings those receivables workflows into one private workspace: create an invoice, collect through PayPal, reconcile confirmed payments, and ask an AI analyst what needs attention.

What you can do

  • Create and track invoices. Create customer invoices with an amount and due date, then review pending, paid, overdue, and refunded records.
  • Collect with PayPal Sandbox. PayPal Checkout creates Orders v2 orders on the server. The server retrieves the saved invoice amount rather than trusting an amount sent by the browser.
  • Verify payment before updating the ledger. The capture flow checks PayPal's completed status, invoice reference, currency, and amount. PayPal webhooks are signature-verified and duplicate events are handled safely.
  • Ask the AI financial operations analyst. Ask questions such as “What invoices are overdue?”, “How much is outstanding?”, or “What should I follow up on first?” The analyst uses Vercel AI Gateway with OpenAI GPT-5.5 and receives the signed-in user's latest 100 invoice records plus computed receivables totals.
  • Keep workspaces private. Supabase email authentication identifies the user; invoice queries are scoped to that account. Service-role and PayPal secrets stay on the server.

How PayPal and AI work together

PayPal is the payment rail, not just a button in the interface. CapitalFlow AI creates and captures PayPal Sandbox orders, validates the authoritative invoice amount, and reconciles verified webhook events into the invoice ledger.

The AI analyst turns that verified ledger into useful operational answers. It distinguishes confirmed receipts from pending and overdue receivables, explains its calculations, and avoids inventing bank balances, expenses, profit, or forecasts that the app does not have.

Built with

Next.js 15, React 19, TypeScript, Supabase Auth and Postgres, PayPal REST Orders v2, PayPal JavaScript SDK, Vercel, Vercel AI Gateway, and OpenAI GPT-5.5.

Demo and scope

The hosted application is configured for PayPal Sandbox test transactions only; it does not move live money. The analyst currently works from invoice and payment records, not bank feeds, payroll, expenses, or a full accounting ledger.

Built With

Share this project:

Updates