Lessons from building an MCP server whose tools cost real money
eminbudak · reddit · 2026-11-08
A Wiro AI developer shares lessons from building an MCP server whose tools spend real money (running image/video models, starting workflows, deploying agents). Since the caller is a model — and models retry, guess, and misread replies — their rules:
- Paid tools quote first: without confirm: true, the tool only returns a price and a nextAction with the exact call to make; the model shows the price, waits for a yes, then repeats with confirm: true.
- Re-price on confirm: if the price moved, nothing is charged and a fresh quote returns.
- Write money rules into server instructions: the key one — a yes given before the user saw the price doesn't count (users constantly say "just upgrade me," and models take it as consent).
- Irreversible actions (delete, cancel, replace) use the same two-step call.
- Long jobs don't block: waiting tools return after 45 seconds with job state plus a nextAction; timeout means "unknown," not "failed" — retrying the original call is the easiest way to pay twice.
Open source at github.com/wiroai/Wiro-MCP.
More from coding & agent
- Stanford's Memorilla compresses LLM memory to 16 tokens, 4212x fewer and 27x faster — _AustinCalvert_ · 2026-11-08
- 13 free open-source repos that turn your notes into an agent-ready second brain — nikola_mr64990 · 2026-11-08
- Dev updates Lamport build and mulls fine-tuning a game-dev model — R4nsack · 2026-11-08
- Coinbase CEO Brian Armstrong details his multi-agent workflow with lead agents and one prioritized queue — dair_ai · 2026-11-08
- Together triples Step 3 serving throughput with 8 stacked inference optimizations — togethercompute · 2026-11-08
- Game dev workflow: build a placeholder-art gameplay gym first, sub-agents make assets — chongdashu · 2026-11-08