Inspiration

AI agents are starting to spend money, and paying for AI work today means paying whether or not the result is any good. For a small business, giving a bot a card is a leap of faith. PayPal's authorize-then-capture flow already separates a promise to pay from the payment itself. We wondered what would happen if the capture depended on an inspection of the work.

Who it's for. A small business that wants an agent to handle routine AI work, like translating and voicing customer messages, without trusting it with a card. Today it pays for every API call, good or bad, and finds the bad ones later, if at all. With Agent Desk the buyer sets a per-job and a total limit once, the agent buys on its own, and money only moves for work that passed a check. (Agents send text today; audio and image jobs, like transcribing calls or cleaning up product photos, run from the web page.)

What it does

Agent Desk is a shop for AI work where payment depends on delivery: an inspection, not the seller, decides what PayPal captures. It sells voice-overs, transcription, translation, grammar checks and background removal.

  1. A person (web page) or an agent (MCP) asks for a job in plain words.
  2. NVIDIA Nemotron turns the request into a plan. Code validates every step and prices it from a fixed table; the model never sets a price or moves money.
  3. PayPal places a hold for the quote. A person approves it with the PayPal button. An agent uses a wallet the buyer saved once through Vault, with no popup, within a per-job and a total limit.
  4. The work runs, and every output is inspected. Speech is transcribed back and compared with the text. Translations are translated back, then Nemotron checks numbers, negatives and meaning phrase by phrase.
  5. PayPal captures only the steps that passed, with a final capture that releases the rest. If nothing passes, the authorization is voided. Results are delivered only after PayPal settles.

Designed so the buyer never has to trust a black box. The quote lists every step, its price and exactly how it will be checked before anything is held. During the job, each step shows its verdict and the evidence: the word error rate of a voice-over, or the inspector's score and reason for a translation. Underneath, a ledger shows every hold, capture and release with its PayPal ID, for people and agents alike. An agent's owner sees what is left of its budget and can cut it off with one click (Revoke).

In a real test, a customer message was voiced and translated to Vietnamese. "Table for four" came back as "Bàn 4", which means table number 4. The inspector scored it 2/5 and named the error. The voice-over's 10¢ was captured and the translation's 5¢ was released.

How we built it

  • PayPal: JS SDK buttons with intent=authorize; Orders v2 (create, authorize); Payments v2 (partial capture with final_capture, void); Vault v3 (setup tokens, payment tokens, stored_credential) for agent purchases. PayPal-Request-Id on every money call, in the sandbox.
  • AI: NVIDIA Nemotron 3 Ultra plans and inspects; Nemotron 3.5 Lightning pre-checks every request and attachment. The work itself runs on self-hosted open models (whisper.cpp, Kokoro, OPUS-MT, u2netp, LanguageTool) through our existing Fixlark tools API.
  • Agents: an MCP server (Streamable HTTP) with list_services, quote_job, buy_job and job_status. Agent keys are stored as hashes.
  • AG Grid: the ledger, with every hold, capture and release, the buyer (a person or a named agent) and the PayPal ID, plus filtering, totals and CSV export.
  • Stack: TypeScript, Hono, SQLite, Docker, behind Cloudflare and Caddy. Written with Claude Code as a coding assistant.

Challenges we ran into

  • The inspector had to be inspected. In a live purchase it passed "table for four" as "table 4" with 5/5. We built a labelled test set, rewrote the prompt, switched on reasoning for that check, and measured again: 12/12 and 11/12 on two runs, catching that error both times. It's still a model's judgement. Borderline sentences can score differently between runs, and the README says so.
  • A spending limit that could be raced. Our own abuse review found that purchases started at the same moment could all pass a limit, because a hold is only recorded after PayPal answers. We proved it with a failing test (3 purchases on a budget for 1), then counted money in flight against the limit.
  • Requested voices were ignored. A "British voice" request silently used an American one, because the planner had never been told the voice names. We only noticed by reading a quote closely while filming.
  • Agents are untrusted input too. We ran 25 attack prompts against the live pre-check. All 23 real attacks were blocked, and 12 of 12 normal requests went through. (The other two prompts ask for translation, which is what the shop sells. The offered pair passes the pre-check; English to French isn't offered, so it's refused by the pre-check or the planner.)

Accomplishments that we're proud of

Every money path has run on real PayPal sandbox APIs and been confirmed on PayPal's side: full capture, partial capture and void, by a person with the popup and by an agent with a saved wallet.

What we learned

Authorize-then-capture fits agentic commerce very well. It gives you a natural place to put a quality check, and it fails in the buyer's favour: if a check can't run, the step simply isn't charged.

It works for both sides. Buyers stop paying for bad output and can see why each cent was or wasn't charged. Sellers who deliver good work get paid automatically, with a PayPal record for every step. The same pattern could sit in front of any AI service an agent buys, not just ours.

What's next for Agent Desk

A refund and dispute flow for when a buyer disagrees with the inspector, audio and image attachments over MCP, more languages, and letting other sellers offer their own services behind the same inspection.

Built With

Share this project:

Updates

Submission history