Your agent pays for APIs from a fuse you set on Solana. One payment over the line and it blows, and nothing else gets through until you put in a new one.
An agent that pays is usually handed a wallet with money in it. Whoever ends up with its key ends up with the whole balance, and nothing in that wallet can tell a thief from a bug.
The money sits in an account the agent does not own. A leaked key, or an agent stuck in a retry loop at 3 a.m., can spend what is left of today’s rating. The rest of the account was never on the circuit.
Solana’s token program checks every payment against what is left of the rating. Be the agent: pay until it blows. Then be the owner and put a new one in.
It behaves like fetch. When a service answers 402 Payment Required, it checks the price against the fuse, pays from it and asks again. Services change nothing: a fuse payment is a standard x402 payment.
import { fuse } from 'https://fuseagent.vercel.app/lib/fuse.js' const agent = fuse({ budget, key }) const res = await agent.fetch(url)
Pulling a fuse revokes the agent key in one transaction, and it holds from the next slot. Every fuse can be pulled on its own, and the fusebox has a main for all of them.