Skip to content
Back to search

fusebox

Your agent pays. Circuits decide. TapeOut circuit fuses for AI agent wallets on X Layer.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/0xdopewilly--fusebox/badge.svg)](/listings/0xdopewilly--fusebox)

HTML

<a href="/listings/0xdopewilly--fusebox"><img src="/api/listings/0xdopewilly--fusebox/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 138 lines
  1. # Fusebox
  2. **Your agent pays. Circuits decide.**
  3. Fusebox wires an AI agent's wallet through small logic circuits taped out on [TapeOut](https://tapeout.net) on X Layer. A payment reaches the payee only if every fuse on the line holds, and every fuse that checks a payment pays its designer, the no's included.
  4. ## For judges (X Layer TapeOut Accelerate)
  5. | | |
  6. |---|---|
  7. | **Demo video (2:30)** | https://youtu.be/vcopkuNdhkc |
  8. | **Live app** | https://fusebox-xlayer.vercel.app/app · try it with no wallet: [/app/try](https://fusebox-xlayer.vercel.app/app/try) |
  9. | **On DeWEB** | https://15-2-272.tapekit.org/ (`15.2.272.tape`, stored in circuit #15's container, served by TapeKit) |
  10. | **TapeOut processor** | `0x57F319CF056F72F48cF1dbb670F2A3DB007Aa355` (OrderGuard, X Layer chain 196) |
  11. | **Circuit IDs** | 15, 16, 17, 18, 21 (fuses 1–5) · 22, 23, 24, 25 (rival fuses 6–9) |
  12. | **TapeOut features used** | Circuits: every payment calls the processor's `eval`/`step` on X Layer, in the same transaction. **DeWEB + TapeKit**: the on-chain edition. **TapeSend**: every stopped payment is posted to the wallet's inbox from circuit #15. |
  13. | **Business** | [docs/BUSINESS.md](docs/BUSINESS.md): who it's for, how we reach them, how it earns (90% of every check fee to the circuit's designer), why they keep paying |
  14. | **Usage, live** | [/app/status](https://fusebox-xlayer.vercel.app/app/status) (Usage on mainnet): wallets, payments checked, circuit evaluations, fees paid to designers, on-chain alerts |
  15. | **Assurance** | Contracts verified on Sourcify; invariant suite, mutation tests and a complete Payee Guard proof in [docs/ASSURANCE.md](docs/ASSURANCE.md) |
  16. | **Built during the event** | First commit 2026-11-13; all of Fusebox is event work |
  17. | **Follow** | [@fuseboxhq](https://x.com/fuseboxhq) |
  18. - **Live site:** https://fusebox-xlayer.vercel.app
  19. - **Live app:** https://fusebox-xlayer.vercel.app/app (Atlas, a real agent wallet on X Layer mainnet)
  20. - **On X:** [@fuseboxhq](https://x.com/fuseboxhq)
  21. - **For agents:** `claude mcp add fusebox -- npx -y fusebox-mcp` ([npm](https://www.npmjs.com/package/fusebox-mcp)), the TypeScript SDK `npm install fusebox-sdk viem` ([npm](https://www.npmjs.com/package/fusebox-sdk), [source](sdk)) for check, pay (checked first), pay-per-call, approve, freeze, watch and history, or ready-made tools for the Vercel AI SDK, LangChain and ElizaOS: `npm install fusebox-tools` ([source](tools)). Not on a Fusebox wallet yet? Pre-flight runs any payment through TapeOut circuits before your agent signs it from any wallet (`preflight()` in the SDK, `fusebox_preflight` in the MCP)
  22. - **Pay per call (x402):** agents pay for APIs over HTTP 402, and the price goes through the wallet's fuses first. Two [live demo sellers](https://fusebox-xlayer.vercel.app/app/x402) (an honest price sheet and a scam), a seller helper in the SDK and a hosted verifier for the `fusebox` scheme.
  23. - **Plain-English guardrails:** describe your agent in the wizard and get a proposed line of fuses with reasons and test payments, checked on TapeOut's circuits before you sign.
  24. - **Rob the agent:** https://fusebox-xlayer.vercel.app/app/rob. Write the scam; an AI payables agent reads it and decides, and whatever it tries to pay goes through Atlas's real fuses, read-only.
  25. - **Try to scam it:** https://fusebox-xlayer.vercel.app/app/try. Write the payment an agent might be tricked into; the app runs the real `check()` of Atlas's v2 wallet on X Layer (Atlas's limits plus the Repeat Guard, five fuses). It's free, needs no wallet, and nothing moves. The same invoice sent twice is stopped: that wallet really paid it, and the Repeat Guard remembers.
  26. - **For approvers:** [Approvals](https://fusebox-xlayer.vercel.app/app/approve) is an inbox of every payment waiting on your signature, across all the wallets where you hold a seat, with a feed you can subscribe to. Install Fusebox as an app and turn on alerts: when an agent hits the approval threshold, your phone buzzes with that exact payment.
  27. - **For owners:** [My wallets](https://fusebox-xlayer.vercel.app/app/mine) is a fleet view (fees left, blown fuses, today's stops, freeze every agent); the wizard starts from tested lines (invoice agent, procurement bot, refund desk, small allowance); every wallet page has an owner console (fuses, payees, agents, approvers, money, ownership), spending analytics (paid vs stopped per day, top payees, what each fuse stopped), an Atom feed of its decisions, a full CSV export and browser alerts for stopped payments. The [line simulator](https://fusebox-xlayer.vercel.app/app/simulate) runs any line of fuses on a sequence of payments with TapeOut's own `eval`/`step`, and matches a real wallet fuse for fuse.
  28. - **For designers:** [Fuse Studio](https://fusebox-xlayer.vercel.app/app/studio) builds a fuse from rules (or from 13 ready-made ones), compiles it to NAND gates, proves the bytes on every input in the browser (all 2^33 for Payee Guard, by BDD equivalence), then mints, tapes out and lists it from your wallet. All five live fuses come out of it byte-identical (circuits #15, #16, #17, #18 and #21). Every fuse has its own page (e.g. [/app/fuse/1](https://fusebox-xlayer.vercel.app/app/fuse/1)), installs from the market in one signature, and describes itself on-chain (`fusebox-fuse/1` metadata as a data URI).
  29. ## New to Fusebox?
  30. AI agents now hold wallets and send real money, and one convincing message can make an agent pay a scammer. Fusebox gives the agent a wallet where every payment must pass a few small circuits called **fuses** (a daily limit, known payees only, two signers for big payments). If any fuse says no, nothing moves.
  31. **Atlas** is the live demo wallet: an AI agent pays a supplier from it on X Layer mainnet, through four fuses. Start by trying to trick it in *Try to scam it*: free, no wallet, nothing moves. First-time visitors get a three-card intro that ends there, and every screen has an **i** button and tap-to-explain terms (the full glossary is in the docs).
  32. - **Phones** get an app layout: a dock (Wallet, Try, Market, Sell, your account), one job per screen, details in bottom sheets, and the wizard as one step per screen.
  33. - **Connecting:** any browser wallet (EIP-6963 or injected), the **OKX Wallet app** over OKX Connect (a QR code on desktop, a hand-off on phones), or reopen Fusebox inside OKX Wallet, MetaMask, Trust Wallet or Bitget Wallet. Fusebox adds and switches to X Layer itself.
  34. - **Genuine use, in minutes:** Wire up can make your agent's key in the browser, send it gas, and finish with a ready setup for Claude Code, Claude Desktop, Cursor or the SDK. A first-payment guide then has your agent pay a saved payee for real and shows a stranger being stopped (read-only).
  35. - **The Fusebox assistant:** pay by chatting ("pay Kano Cotton 2"). It only proposes; your wallet's fuses check each payment on X Layer, you tap Pay, and the agent key in your browser signs. It only pays saved payees or addresses you type, and never sees a key on the server.
  36. - **Before you wire up** a wallet you need: a wallet on X Layer (the owner), an agent key (the address your agent signs with), USD₮0 on X Layer for fees and payments, and a little OKB for gas. The wizard's first step checks these.
  37. ## Live on X Layer mainnet (chain 196)
  38. | What | Address / id |
  39. |---|---|
  40. | TapeOut processor (OrderGuard) | [`0x57F319CF056F72F48cF1dbb670F2A3DB007Aa355`](https://www.oklink.com/xlayer/address/0x57F319CF056F72F48cF1dbb670F2A3DB007Aa355) |
  41. | Circuits | **#15** Daily Cap · **#16** Payee Guard · **#17** Breaker · **#18** Two of Three · **#21** Repeat Guard |
  42. | FuseRegistry v2 (new wallets, the fuse market) | [`0x2583928546a614A2fD993B5C106ED9aD0E781AB6`](https://www.oklink.com/xlayer/address/0x2583928546a614A2fD993B5C106ED9aD0E781AB6) |
  43. | FuseboxFactory v2 | [`0xdFc9b1d715efB2bCDAd8f848A5E3b4e2c243EE9B`](https://www.oklink.com/xlayer/address/0xdFc9b1d715efB2bCDAd8f848A5E3b4e2c243EE9B) |
  44. | FuseboxSetup (a whole wallet in one transaction) | [`0x3B31e35bf9157413Bb50884009c415b27e3a6DA9`](https://www.oklink.com/xlayer/address/0x3B31e35bf9157413Bb50884009c415b27e3a6DA9) |
  45. | FuseboxHerald (holds circuit #15; posts fuse alerts over TapeSend) | [`0xBf385a2A9368cC08EA234FF1965B6a486a6b0b81`](https://www.oklink.com/xlayer/address/0xBf385a2A9368cC08EA234FF1965B6a486a6b0b81) |
  46. | FuseRegistry v1 (Atlas and the first wallets) | [`0x852a278322667BB86A2665a38CbC5Bfd551B20d7`](https://www.oklink.com/xlayer/address/0x852a278322667BB86A2665a38CbC5Bfd551B20d7) |
  47. | FuseboxFactory v1 | [`0x192C099a18ed42612b6e74f243f8dF1EE0E3E7a5`](https://www.oklink.com/xlayer/address/0x192C099a18ed42612b6e74f243f8dF1EE0E3E7a5) |
  48. | Atlas (demo wallet) | [`0x0Db0457715a6445D8a65F820d717a6B39Be66800`](https://www.oklink.com/xlayer/address/0x0Db0457715a6445D8a65F820d717a6B39Be66800) |
  49. | Fees | USDT0 [`0x779Ded0c9e1022225f8E0630b35a9b54bE713736`](https://www.oklink.com/xlayer/address/0x779Ded0c9e1022225f8E0630b35a9b54bE713736) |
  50. Every address is in [`deployments/xlayer-mainnet.json`](deployments/xlayer-mainnet.json). **Setting up a wallet takes three taps:** a free USD₮0 permit signature, one `FuseboxSetup.setUpWallet` transaction that creates the wallet, splices in its fuses, saves payees, seats approvers, prepays fees, funds it and sends the agent gas, then `acceptOwnership()`. The first one on mainnet, [`0x63d5…48fa`](https://fusebox-xlayer.vercel.app/app/w/0x63d5033569101B320A088680629cF0E10b3E48fa), took 5.02M gas (about 0.0001 OKB) for all five fuses. **Telegram alerts:** follow any wallet through [@FuseboxAlertsBot](https://t.me/FuseboxAlertsBot) and every payment its agent tries arrives as a message, paid or stopped and why. v2 (Nov 20) stores socket pinouts as data and adds the Repeat Guard; v1 (Nov 15) keeps running Atlas unchanged. See [docs/V2-REPEAT-GUARD.md](docs/V2-REPEAT-GUARD.md). The first v2 wallet, [`0x6292…577c`](https://fusebox-xlayer.vercel.app/app/w/0x6292Ea57a1d50c74A5E918CfDC4Dc1Dbf87a577c), had its agent send the same invoice twice on mainnet: the first payment went through and the Repeat Guard [stopped the second](https://www.oklink.com/xlayer/tx/0x502bd9f3fe577c7a74f0c43696003559f95d2cff3929f45a5e88ec678baf22ad).
  51. ## The five fuses
  52. | Fuse | Circuit | What it does | Fee / check |
  53. |---|---|---|---|
  54. | Daily Cap | 24 inputs · 108 NAND | No more than the owner's cap in a UTC day, however the agent is asked. | 0.001 USDT0 |
  55. | Payee Guard | 33 inputs · 79 NAND | Saved payees only; a new payee gets a small trial amount until its cooling-off ends. | 0.001 USDT0 |
  56. | Breaker | 4 inputs · 10 NAND + 1 LATCH | Trips on a payment to a stranger and stays blown until the owner resets it. | 0.0005 USDT0 |
  57. | Two of Three | 19 inputs · 46 NAND | Above a threshold, two of three approvers must sign that exact payment. | 0.002 USDT0 |
  58. | Repeat Guard (v2) | 2 inputs · 2 NAND | The same invoice sent twice gets paid once: the same amount to the same payee inside the owner's window is stopped, unless the owner clears one repeat. | 0.0005 USDT0 |
  59. ## How a payment works
  60. 1. **The agent asks to pay.** It sends the payee, the amount and a one-line memo. That's all it gets to say, and the fuses never read the memo.
  61. 2. **Every fuse checks it on X Layer, in the same call.** `FuseboxWallet.pay()` builds each fuse's inputs from the wallet's own state, then calls `eval` (or `step` for latches) on TapeOut's processor.
  62. 3. **One no stops the payment.** The decision is recorded either way, along with which fuse blew. The Breaker's latch state lives in the wallet.
  63. 4. **Designers are paid.** `FuseRegistry.charge()` takes each fuse's fee from the wallet's prepaid USDT0 balance. 90% goes to whoever owns the circuit NFT, and the protocol keeps 10% (capped at 20%).
  64. ## Built on TapeOut
  65. - **Every fuse is a TapeOut circuit.** All nine (circuits #15–18, #21 and the rivals #22–25) live on TapeOut's OrderGuard processor `0x57F319CF056F72F48cF1dbb670F2A3DB007Aa355`, and every payment calls the processor's `eval` or `step` on X Layer.
  66. - **TAP-02 toolchain.** [`circuits/`](circuits) builds, encodes and simulates TAP-02 netlists, and its tests pass TapeOut's official test vectors.
  67. - **Netlist integrity in the app.** The [fuse market](https://fusebox-xlayer.vercel.app/app/market) reads each fuse's netlist straight from its TapeOut processor and checks it against the hash the registry pinned when the fuse was listed. Fuses without a hand-drawn schematic get their real wiring drawn from those bytes.
  68. - **DeWEB and TapeKit.** [`deweb/`](deweb) is a version of Fusebox stored on X Layer in circuit #15's container and opened through TapeKit: **[https://15-2-272.tapekit.org/](https://15-2-272.tapekit.org/)** (`15.2.272.tape`). It has no off-chain references, and your browser reads every number, including a live "scam Atlas" `check()`, from X Layer.
  69. - Published on mainnet 2026-11-21: the container was opened (0.08 OKB to TapeOut), all 7 chunks stored and the name bound, and the SHA-256 read back from the chain matched (`0xdd038cb2…41ae`). The same file is also previewed at [/onchain](https://fusebox-xlayer.vercel.app/onchain).
  70. - **TapeSend alerts.** Every payment a Fusebox wallet's fuses stop is posted, once, to that wallet's TapeSend inbox on X Layer (endpoint `uint32(0) ‖ uint64(196) ‖ wallet` on the DeWEB hub `0xe61A…25ee`), as a public TapeSend message from circuit #15's container. The wallet page reads the inbox back from the hub and checks each message against its on-chain digest; messages from any other sender are never shown as Fusebox's.
  71. - TapeSend only lets a circuit's holder send, so circuit #15 sits in [`FuseboxHerald`](contracts/src/FuseboxHerald.sol) (Sourcify-verified). The server holds only the herald's *crier* key, which can post and nothing else; the admin (a cold key) claims the fuse's designer fees, runs the DeWEB site and can take the circuit back. A leaked crier key costs spam, not the circuit. 10 fork tests against the live hub ([`HeraldFork.t.sol`](contracts/test/fork/HeraldFork.t.sol)).
  72. - Posted right after a payment (the app, SDK and MCP call `/api/telegram/notify`), and by a sweep every 10 minutes for agents that pay some other way. At most 6 posts per wallet per hour; each costs about 0.000004 OKB of gas.
  73. ## Repository
  74. | Folder | What's in it |
  75. |---|---|
  76. | [`circuits/`](circuits) | The TAP-02 netlist toolchain (builder, encoder, simulator), the four shipped fuses and four rival designs for the same sockets ([`src/rivals.ts`](circuits/src/rivals.ts)), all with exhaustive tests. `scripts/publish-rivals.mjs` tapes the rivals out and lists them (rehearsed on a fork; `--dry` prices it). |
  77. | [`contracts/`](contracts) | `FuseRegistry`, `FuseboxWallet` and `FuseboxFactory` (Foundry), the unit and fuzz tests, the X Layer fork tests, and the launch scripts. |
  78. | [`sdk/`](sdk) | [`fusebox-sdk`](sdk/README.md): a typed client for agents and services (viem). Tested against a mainnet fork. |
  79. | [`mcp/`](mcp) | [`fusebox-mcp`](https://www.npmjs.com/package/fusebox-mcp): `fusebox_check`, `fusebox_pay`, `fusebox_status` and `fusebox_fetch` (x402) for any MCP agent (`npx -y fusebox-mcp`). |
  80. | [`tools/`](tools) | [`fusebox-tools`](tools/README.md): the same four tools for the Vercel AI SDK, LangChain and ElizaOS, or framework-free. |
  81. | [`web/`](web) | The site and app (Next.js, GSAP, three.js, viem). They read X Layer mainnet directly. |
  82. | [`deweb/`](deweb) | The DeWEB edition: one self-contained page with no backend, built for circuit #15's container (`15.2.272.tape`, served by TapeKit), plus a resumable publisher. |
  83. | [`deployments/`](deployments) | Deployed addresses. |
  84. | [`docs/`](docs) | [`ARCHITECTURE.md`](docs/ARCHITECTURE.md) (sockets, circuits, fee flow, threat model, gas), [`BUSINESS.md`](docs/BUSINESS.md) (who it's for, how it earns, milestones), [`STATUS.md`](docs/STATUS.md) and [`tapeout-ecosystem-research.md`](docs/tapeout-ecosystem-research.md). |
  85. | [`design/`](design) | Design directions and the landing mock. |
  86. ## Run it
  87. ```bash
  88. git clone --recursive https://github.com/0xdopewilly/fusebox.git && cd fusebox
  89. # circuits: build the netlists and run the exhaustive tests
  90. (cd circuits && npm ci && npm test)
  91. # contracts: unit, fuzz, invariant and X Layer mainnet-fork tests, then the mutation check
  92. (cd contracts && forge test && forge test --match-path test/fork/XLayerFork.t.sol --fork-url https://rpc.xlayer.tech)
  93. (cd contracts && python3 test/invariant/mutation.py)
  94. # rehearse the whole launch on a local fork of X Layer mainnet (no keys or funds: it makes throwaway keys)
  95. anvil --fork-url https://rpc.xlayer.tech --port 8547 --chain-id 196 --auto-impersonate &
  96. RPC=http://127.0.0.1:8547 contracts/script/launch.sh
  97. # web: reads X Layer mainnet by default
  98. (cd web && pnpm install && pnpm dev) # http://localhost:3120
  99. # DeWEB edition: build the self-contained page; it fails on any off-chain reference
  100. (cd deweb && npm ci && npm run build) # deweb/dist/index.html, same SHA-256 on every build
  101. ```
  102. X Layer's public RPCs cap `eth_getLogs` ranges (1,000 blocks on tapeout.net, about 100 on rpc.xlayer.tech and drpc), and tapeout.net sometimes hangs. The app therefore reads event history from a small block index ([`web/lib/deployments/mainnet-index.json`](web/lib/deployments/mainnet-index.json)), scans forward from there in cached windows, and races the three RPCs when one is slow. Refresh the index with `node web/scripts/index-logs.mjs`.
  103. ## Status
  104. The contracts are deployed and working on X Layer mainnet. They have no third-party audit yet. What stands in for one is in [docs/ASSURANCE.md](docs/ASSURANCE.md): 12 invariants checked over 786,432 random calls from every role, long walks that must reach every path, a mutation check that catches all 14 planted bugs, a review of the web app, SDK and MCP server with every finding fixed, and a Slither triage. Atlas is a public demo wallet with small balances.
  105. ## License
  106. MIT

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.