Let your agentslive off your Bitcoin.

BanQor turns a Mezo trove into a credit line for AI agents. Your BTC stays locked as collateral. Agents borrow MUSD against it just in time, inside caps they can't break, and pay any x402 API.

Testnet only. Unaudited. Contracts verified on Sourcify.

Extends Mezo's own stack
Mezotroves MUSDstablecoin x402exact Permit2EIP-2612 Sourcifyverified Foundrytested viemSDK

The problem

Agents need money.They can't hold it safely.

AI agents now pay for APIs per request over x402. Someone has to fund them. Today a BTC holder has three bad options.

Fund a big hot walletOne bug or leaked key and the balance is gone.
Drained
Fund a small oneThe agent stalls when it runs dry, so a human babysits it.
Stalled
Sell BTC for stablecoinsDefeats the point of holding Bitcoin on Mezo.
Sold
Give it a BanQor credit lineBTC stays put. The agent borrows small amounts on demand, inside on-chain caps.
Funded

The line

One trove, many agents.Every draw on the record.

Collateral health. Agents can only borrow while the trove stays above your floor. Mezo liquidates at 110%; the default floor is 200%.

281%ICR on the demo vault
110% liquidation 200% floor 281% now 400%
Collateral
0.07 BTC
Debt
2,007.81 MUSD
Draws stop below
$57,366 / BTC

Breaches blocked. The breach demo, run on testnet against the live vault.

4/4
DrawTooLargeDailyCapExceededPausedNotAgent

The worst case is small. An agent key can't touch the BTC or call owner functions. If one leaks, the most it can take is:

float it holds+rest of today's cap=≤ 2 + 20 MUSD

With the demo policy, until the owner presses pause. Then every draw reverts.

How it works

From BTC to a paid API call.Five steps, one of them yours.

1 · owner

Open a line

Deposit BTC. The vault opens a Mezo trove in its own name and keeps the minted MUSD.

2 · owner

Set the rules

Per agent: daily cap, max float, max single draw, expiry. Plus an ICR floor for the trove.

3 · agent

Draw just in time

When its float runs low the SDK calls draw(). If the vault is short, it borrows against the BTC.

4 · agent

Pay per request

The agent pays x402 APIs in MUSD with a signed permit. No gas, no custom protocol.

5 · owner

Stay in control

Pause, change rules, repay, add BTC or close. Anyone can rebalance a trove near its floor.

For agent developers, explained for everyone

Swap one line.Your agent can pay.

  1. 1

    Bring in BanQor

    Your AI agent adds the BanQor helper. That's the only new piece it needs.

    One import from @banqor/sdk.

  2. 2

    Connect it to your credit line

    The agent gets its own key and is pointed at your vault, the credit line backed by your Bitcoin on Mezo.

    Agent key, vault address, network and RPC.

  3. 3

    Keep a little pocket money

    When the agent has less than 0.20 MUSD on hand, it borrows 1 more from your vault by itself. Nobody tops it up.

    minFloat and topUp drive automatic draw() calls.

  4. 4

    Set a price limit

    Anything that costs more than 0.10 MUSD is refused before any money moves. Your own on-chain caps still apply on top.

    maxPricePerCall, checked before signing. Refusals come back as typed errors.

  5. 5

    Use the internet as usual

    The agent asks an API for data. If the API wants to be paid, the agent pays it in MUSD and gets the answer. No forms, no cards.

    A fetch-compatible function that handles x402 payments.

agent.ts
import { createBanQorFetch } from "@banqor/sdk";const fetchPaid = createBanQorFetch({  agentKey: process.env.AGENT_KEY,  vault: "0xcDa3Cb64aEd90C2A77981434d66AD3F3197fC791",  network: "eip155:31611",  rpcUrl: "https://rpc.test.mezo.org",  minFloat: "0.20",        // draw below this  topUp: "1.00",           // MUSD per draw  maxPricePerCall: "0.10",  // refuse pricier calls});const res = await fetchPaid("https://api.example.com/price");

Proof

Running on Mezo testnet.Real trove, real payments.

152

paid x402 calls settled on-chain through the x402 facilitator

4.03

MUSD paid out in micro-payments of 0.01–0.05

5

automatic draws, one of them borrowed against BTC

0

manual top-ups

Snapshot from the demo vault on Oct 24, 2026. Factory on Sourcify · Vault on Sourcify · Vault on the explorer

Who gains

Everyone on the line gains.Nobody sells Bitcoin.

PartyBeforeWith BanQor
BTC holderowns the vault Sells BTC, or tops up agent hot wallets by hand. BTC stays on Mezo. Agents get spending power on their own, inside limits the contract enforces.
Agent developerwrites the agent Writes custom wallet top-up logic and handles running dry. One line. createBanQorFetch() replaces fetch, and paying just works.
API sellerscharge over x402 Few buyers with funded wallets. Buyers that can always pay, in MUSD, per request.
Mezothe network MUSD demand from people only. A new kind of borrower that never sleeps. More MUSD minted against BTC, and real x402 volume.
Collateral sold0 BTC

Give your agent a credit line.Keep your Bitcoin.