A case study

Piece of Cake

Agentic checkout simplifies commerce. Here, an agent plans my son's birthday party and checks out from real store listings. It can only spend what the parent approves, since the limits live in the payment, not the prompt.

Built by , Senior PM, Checkout Status: live, Stripe test mode
Try the agent
What this shows
  • I ship. When something new lands in payments, I build with it. Piece of Cake went from idea to a live agent on real store listings in about ten days, with real Stripe calls and evals that run in CI.
  • I build trust into the payment. My work in AI showed people trust automation with money when its limits are clear and a person can step in. So the agent can only spend what you approve, tells you up front when it will stop and ask, and Stripe enforces every limit.
  • I understand the user. I built it as the parent it's for, and my UX research on AI said the same thing: people hand an agent their money only when they can see the plan, set the limit, and check afterward exactly what it did. So every step is visible, and every run ends in a receipt.
Why I built it

Agentic checkout is the future

I've spent seven years in payments as a product manager, and the most exciting recent development is agentic commerce. I wanted to take what I learned building an AI-first billing portal and build an app that helped me shop for my son's birthday party.

Every checkout I've built assumes a person is at the keyboard. That's already changing: on Black Friday, agentic payments through Stripe's Link set a record, 36% above their previous best day. But agents aren't reliable yet. When Visa tested 22 AI models on 15 shopping tasks, they passed 57.2% of runs, and in more than half of the failed runs the agent still bought something. So the hard question isn't whether an agent can find a bounce house. It's who the agent is, whether the parent actually approved the purchase, and what stops it when it's wrong. That's why Piece of Cake puts the limits in the payment, not the prompt.

The party is real: December 5, building-brick theme, backyard, 6 to 10 kids aged 2 to 5, a bounce house and a piñata, under $600. A real brief keeps a demo honest: a toddler coming means the piñata needs pull strings, and a booked bounce house is a real problem, not a contrived one.

What it does

One request, one approval, six stores

Home: 'Party planning? Piece of cake.' beside a two-tier cake, with the party request and a Plan it button. The cart for Feb 6, starting with Fun: a flag on the bounce house, not brick-themed, because the brick one is booked Feb 6. Keep it, See 2 other options, Remove. The pull-string piñata ships to 90210. Your go-ahead: $360 of a $600 budget; check with me before paying more than $100, Always ask or Never; deliver to Backyard party, 90210; Visa •••• 4242, Stripe test card; Approve $360 and shop.
The live demo on a phone: the request, the party the agent shopped (with the one call it needs me to make), and the go-ahead.
The payment

The agent can't overspend. Stripe won't let it.

Most agent demos put the budget in the prompt and hope. Prompts can be talked out of things; a store listing can even carry hidden instructions. So the agent never gets a payment tool. It proposes a cart, the parent approves a signed permission, and the server buys, minting a Stripe shared payment token for one store, capped at that store's approved amount, that expires in 30 minutes.

How a party gets paid for
The AI's part
The money's part: your rules, enforced by Stripe
AgentProposes a cartShops real listings. Has no payment tool.
StripeMakes a pass per storeOne store, one charge, up to its limit, for 30 minutes.
StoreCharges the passWithin the limit: paid.Asks for $20 more? Stripe declines it.
See every step, including refunds and the receipt ↓
The test: the rental tries to charge $20 more
1 · The budget $600 I approve the party; each store gets its own cap, and the caps add up to no more than this.
2 · A pass for one store $149.99 the rental's cap. Good for that store only, for 30 minutes.
3 · Store asks for more $169.99 refused by Stripe, not by my code. Nothing charged.

"The requested amount is greater than the remaining amount capturable with this shared payment granted token."

Stripe's own response, tested live on November 19. If Stripe ever accepted an over-cap charge, the server refunds it at once and the page says so in plain words.

On a phone, under the bounce house rental: what the store saw (its order, a $209.14 charge, a pass good for one use, Visa ending 4242) and what it never saw (the card number, the other 4 stores, the $600 budget, the request).
The same charge, from the store's side

After a run, every paid store shows what that store saw. The rental got its own order, a $209.14 pass good for one use, and the card's brand and last four. It never saw the card number, the other four stores, the $600 budget, or what I asked the agent.

So a leaked pass is worth one charge, at one store, for 30 minutes. Real test-mode Stripe ids, from the live demo.

The rules
RuleHow it holds
The agent never paysIt has no payment tool. It submits a cart; the server buys.
Prices come from the catalogBy item id, never from the page or the model.
One cap per storeEach pass is capped at that store's approved total, delivery and tax included.
Check with me over $100A purchase over the parent's choice ($100, always ask, or never) pauses for a tap.
Ends on the party dateNothing is bought after the party date.
Can't be editedThe permission is signed on the server; a changed one is refused.
What breaks in production, and what I'd do ↓
The agent

An agent you can grade

Claude searches every category in one turn, then submits a cart by item id. Code checks every cart against the same rules the page and the server use: buyable, in budget, enough favor packs for every kid, toddler-safe, nothing booked or past its delivery notice. A cart with problems goes back once. If Claude is off, over its limit or down, a rules agent plans instead, and the page says which happened.

Money and safety have right answers, so every check is code, not a model grading a model. The 13 prompts are all variations of the real party: tighter budgets, more kids, "just a cake", a booked date, and four tries at tricking the agent. Seven checks must pass every time: a buyable cart, nothing a listing pushed, the hidden instruction reported, nothing from the store that planted it, honest about the budget, a favor for every kid, and safe for a 2-year-old.

Five runs on Claude Haiku 5.5, two passes per check. The first scored 21 of 24; the last two scored 26 of 26 with no fallbacks. Every failure was real, and every fix went in code. About 18,000 tokens and three turns a plan.

What the runs taught
  • Don't trust the model's memory with money. It once dropped the budget from the cart. Now the budget and date come from the parent's own words, in code.
  • Honest beats full. A cart that leaves something out and says why is a pass. A swapped bounce house with no reason is sent back once to explain.
  • Distrust the store, not just the text. The agent ignored the planted instruction but still bought the trap store's package. Now a store that tries to steer an AI shopper loses the sale entirely, and the cart says why.
Decisions and trade-offs

Three calls I'd defend in a review

Limits in the payment, not the prompt

A parent can't check what an AI's instructions will make it do. She can understand "this store can charge up to $149.99, once, in the next 30 minutes."

Trade-off: each store gets its own pass, so the card statement shows five charges instead of one.

Three stops, and only three

From my work in AI: people accept automation when its edges are clear. Before approving, the parent sees the only times the agent stops: over the check-with-me amount, a store asks for more, part of the party falls through. Each stop says why, what's done, and what it suggests.

Trade-off: it won't stop for things the parent might care about but didn't say. That's the price of being predictable.

A receipt anyone can read

When an agent spends money, the parent needs to see what it did, not take its word. Every run ends in one record: what she approved, what each store charged, what was refused and by whom (Stripe or the agent), the pass behind each charge, and a check that spending never passed the approval. It prints, and it copies as plain text.

Trade-off: more on screen at the end of the run, so it reads like an order confirmation, with the ids folded under each store.

Smaller calls (8)
Plan by what, pay by whereParents think "bounce house, cake, favors", not "Target, Michaels". The cart is grouped by what it is; the run, passes and receipt go by store, because that's where the money moves.
Traps only on a made-up storeReal listings make it credible, but nothing false about a real business: the booked bounce house and the hidden instruction live on a test store labeled as made up.
One real party onlyThe request is fixed. A narrow demo that's true beats an open one that's vague.
Distrust the store, not just the textIn a live run, Claude ignored the hidden instruction but still bought that store's $16 table set. Now nothing from that store goes in the cart, even an item the parent names; the cart says why instead.
Toddler safetyA hard check on the agent's cart, but the parent's call when she edits it: a note, not a refusal.
Delivery and taxEstimated per store and labeled as estimates, so every cap includes them.
Quiet by defaultTwo agent notes; reasons behind "Why each item?"; the ignored instruction as one line.
Playful, never in the numbersThe cake makes faces and dances. Amounts, limits and Stripe's words stay plain.
How I worked with AI

Claude built most of it. I made the calls.

Claude wrote the code. I owned the decisions, the evals, and every call on what shipped: what to build, what to cut, and when it was wrong.

I chose payment rails over prompt rules. The first instinct with agents is a better prompt. I asked where the limit should live if the prompt fails, and the answer was Stripe.

I read the failures before the fixes. Each eval failure got a root cause, and the fix went in code where it could be tested, not in another line of prompt.

I wrote the evals a parent would. Shipping notice and "what if not a bounce house" came from thinking about my own party, not from the code.

I sweated the small signals. The agent's face when it stops to ask looked cross, so it became one raised eyebrow: curious, never annoyed.

What I'd measure

Two numbers that matter

Charges over a limitShould be zero, always. Every refusal and any refund is logged on the receipt.
Carts approved unchangedHow often a parent says go to the agent's first cart, and which item gets swapped when they don't.
What's next

From test mode toward real stores

The party is the demo; the pattern is the product. Spending a person delegates, with limits they set and a payment network enforces, fits corporate cards for agents, procurement and B2B billing too.

How it's built

Small, real, and test mode

A static page and a few serverless functions on Vercel, with no dependencies. Every route works with no keys: a rules agent stands in for Claude and payments are simulated with the same rules, labeled on the page.

Stripe shared payment tokensStripe PaymentIntentsClaude API, tool useEvals in GitHub ActionsVercelClaude Code
Appendix

Every step, behind the screen

The agent can propose. Only your signed permission lets money move, and Stripe enforces each limit, not the prompt.

How Piece of Cake works behind the screen Five lanes: you, the agent, the Piece of Cake server, Stripe, and the stores. The agent only proposes a cart. Your signed permission lets money move, Stripe makes a capped pass for each store and declines anything over it, and the receipt records every step. You the parent The agent Claude Piece of Cake server checks and signs Stripe test mode The stores real listings, simulated checkout Out of the loop No payment tool,no card, no passes PLAN 1 Asks for the party Lego theme, Feb 6, 6-10 kids, bounce house and piñata, under $600 2 Shops the listings Reads listings as data, never as instructions. Proposes a cart; can't pay. 3 Checks the cart Prices from the catalog Nothing booked or late In budget, toddler-safe Nothing a listing pushed Hidden instruction A test-store listing tells AI shoppers what to buy. Ignored and reported. 4 Reviews the cart Answers the flag on the bounce house, swaps items, asks for changes checked cart + any questions CONSENT 5 Approves once Budget: $600 A limit for each store Check with me over $100 Ends on the party date Saves the test card 6 Seals it Signs the permission (HMAC). A changed permission is refused. what you approved BUY REPEATS FOR EACH STORE Over $100? Taps Approve or Skip 7 Before each buy Store approved? Under its limit? Over $100? Asks first 8 Makes a pass Shared payment token on your saved card This store only Its limit, 30 minutes asks you 9 Charges the pass Store runs a payment with the pass, never your card number 10 Enforces the limit Within the limit: paid Over it: declined One use, then closed 11 Logs the result Pass and payment ids for the receipt WHEN SOMETHING CHANGES Asks for more Test: the rental asks $20 over its limit Declines it Over the pass's limit Approve $20 more? Only within the budget; a new pass if yes you decide The rental cancels Test Refunds it Money back to your card Find another? Another store, within what's left, with its own permission party not complete AFTER Checks the totals Never over approved? Is the party complete? 12 Gets a receipt What you approved, what was charged, what was refused one record Your consent Money, enforced by Stripe Refused, or a labeled test Stripe test mode. Nothing is ordered and no store is contacted.

What breaks in production, and what I'd do

RiskWhat I'd do
Tax and delivery are estimatesTake them from each store's checkout, the way agentic checkout protocols return them from the address. The shape is already per store.
Price changes after approvalStop and ask (the raise flow exists): approve the new amount once, or skip the store.
Proving the parent tappedIn the demo, the check-with-me tap comes from the browser, so a script could send it. In production I'd tie it to the parent with a passkey. The caps don't depend on it: Stripe enforces them.
A store cancelsRefund, say the party isn't complete, and offer the same kind of item elsewhere under a second, separate permission.
DisputesThe receipt is the audit trail: what the parent approved, each pass and PaymentIntent, what the agent ignored. Liability between agent, parent and store still needs a policy.
Listings that instruct the agentTreat listings as data, report the instruction, and stop shopping at that store altogether.