Inspiration
Supplora Pay grows out of Supplora, an AI tool already used every day by a restaurant in Spain. Supplora reads supplier delivery notes (albaranes) at the kitchen door and pushes them into the restaurant's ERP: 715 delivery notes processed and €1,876 in supplier price increases caught so far. The owner's obvious next question was: "if you already know what arrived and what it should cost, why am I still paying invoices by hand?" Supplora Pay closes that loop: read, verify, plan, approve, pay, follow up.
What it does
- Inbox — Supplier invoices arrive (6 realistic samples ship with the app; upload a phone photo or PDF for more).
- AI review — Claude (vision) transcribes each document and maps the supplier and every line to the restaurant's directory. Deterministic checks then compare it with price history, the signed delivery note and payment history, and recommend pay in full / pay partial / hold, each finding citing the exact numbers.
- Payment run — A Claude agent builds the week's plan (due dates first, early-payment discounts captured, held invoices excluded, the owner's cash cap respected). Nothing is paid until the owner approves. Approved payments go out as one PayPal Payouts batch, polled live until final.
- Disputes — For held or partial invoices Claude drafts a polite credit-note request in the supplier's language, with the evidence.
- Agentic reorder — A purchasing agent checks stock against par, reads the suppliers' store catalogs and creates PayPal Orders v2 checkouts within a spending limit. It cannot pay: on approval the order is confirmed with the card on file (a PayPal Vault token) and captured.
- Ledger — Paid, held and disputed amounts, money saved, and an audit log of every agent decision and every PayPal API call.
What it catches on the six sample invoices
| Supplier | Issue in the document | Outcome |
|---|---|---|
| Huerta del Guadalhorce (produce) | 6 kg x €4.20 printed as €28.20 | Pay partial, withhold €3.12 |
| Pescados Bahia (fish) | Hake €13.80/kg vs €11.90 on the last 3 invoices | Pay partial, withhold €29.26 |
| Carnicas Hermanos Sanz (meat) | 12 kg invoiced, 10 kg on signed delivery note | Pay partial, withhold €40.70 |
| Green Valley Dairy | Payment reminder that copies an invoice already paid | Hold €274.71 (duplicate) |
| Atlantic Wine & Spirits | 2/10 net 30 terms | Pay €1,134.34 by 24 Oct, save €23.15 |
| CleanPro | none | Pay in full |
How we built it
- Stack: Next.js 16, React 19, Tailwind 4, TypeScript, Zod. Local JSON state store with atomic writes.
- Claude (claude-opus-5-5 via the official @anthropic-ai/sdk): vision extraction with structured output; two tool-runner agents for the payment run and the restock, streaming progress to the UI as NDJSON; structured generation for the dispute emails.
- Verification is NOT Claude: deterministic rules in integer cents (arithmetic, price vs history with 2% tolerance, quantity vs signed delivery note, duplicates, unknown supplier, changed payment details, discounts, due dates), covered by unit tests.
- PayPal (server-side REST, OAuth token cached, every write idempotency-keyed, every call audited): Payouts to pay suppliers, Orders v2 for agent checkouts, Vault v3 to keep the card on file without storing card data.
How PayPal is used (the agentic-commerce split)
The agent can create a checkout (a real PayPal order in CREATED state, visible to the owner with its id) but has no tool that confirms or captures it. Money only moves through the owner's approval route: Payouts for suppliers, and confirm-payment-source plus capture with the vault token for restock. Autonomy, with a hard stop before money moves.
Accomplishments that we're proud of
A real sandbox run end to end, with verifiable PayPal ids (16 Oct 2026): Payout batches RKYHUPDKCFCKC and 2E9W84LASKJY6 (SUCCESS); an agent checkout at CleanPro (order 9YE76279V08301647, capture 7H155397J75490001, COMPLETED); an owner checkout at Atlantic Wine (order 2H720218XA6665054, capture 4J328721C0427440T, COMPLETED). Built on a product a real restaurant already uses. Invoice-fraud defense built in: payment destinations come from the supplier directory, never from the document.
Challenges we ran into
Keeping the model away from money (amounts are always computed in code and re-validated at approval against the cash cap). Reading messy real documents (we instruct Claude to transcribe exactly what is printed, including errors, so the rules engine can catch them). Sandbox payout receivers (documented, with an override to settle items in a real sandbox account).
What we learned
Agentic commerce isn't "let the agent pay." It is drawing the line precisely: the agent does the tedious, high-judgment reading and planning; the rails (PayPal) move the money; the human approves. The trust comes from making that boundary unbypassable in code.
What's next
Onboard suppliers' own PayPal accounts, a real database with auth and roles, and feed delivery notes, price history and inventory from Supplora's live ERP. The bigger picture: Supplora Pay is one organ of an AI operations layer for independent restaurants, and a natural next step is exposing it as an MCP server so any AI assistant can pay a restaurant's suppliers through PayPal, always behind human approval.
Built With
- anthropic
- claude
- next.js
- paypal
- react
- typescript
Log in or sign up for Devpost to join the conversation.