v0.1{ pay per call · stop at the budget · never twice }{ pay per call · never twice }

Let agents pay.Don't let them overpay.

Sellers price an API or MCP tool in one line. Agents get a budget per task, a cap per day and a ledger that never pays twice. Built on x402, paid in USDC, straight to the seller.

Run the demo
  • search$0.002/call
  • weather$0.001/call
  • data$0.001/call
  • inference$0.01/call

{ 402 → policy ok → paid $0.001 → 200 }

agent.log — research-botdemo
  1. GET /v1/fact
  2. 402payment required$0.001
  3. policy okbudget · seller · once
  4. paid $0.0010x8f3c…a91e
  5. 200 OK182 ms

402 → policy ok → paid $0.001 → 200

guard · policyactive

task: research

spent of $0.50
  • per_call ≤ $0.01ok
  • domain_list3 sellers
  • not_paid_beforeon

run the demo

Watch one paid request, end to end.

A demo agent with a $0.005 task budget calls a $0.001 endpoint. Guard checks the policy, the agent pays, the API answers. Run it five times and the sixth gets blocked.

GET /v1/fact$0.001
@coinslot/guardtask · demo
GET/v1/fact$0.001
  • budget ok
  • seller allowed
  • not paid before
task budget/ $0.005
Receipt$0.001
Amount
—
Network
—
Trace ID
—
Transaction
—
guard.log
  1. $Run → GET /v1/fact

SimulationThis run plays in your browser using the same events Guard emits. No USDC moves and there is no transaction to link. The live mainnet demo is coming: $0.001 per call, a demo agent with a hard $1-a-day cap.

two lanes

Pick your side of the 402.

I sell an API

Price your API in one line.

Put the middleware in front of any route or MCP tool. Agents get a 402 with your price, pay in USDC and get the response. The money settles to your wallet through the facilitator you choose.

server.ts
import { paywall } from "@coinslot/paywall/hono"
app.use("/v1/*", paywall({ price: "$0.002", payTo: env.WALLET }))
// 402 → paid → 200. USDC lands in your wallet, not ours.
  • Hono, Express, Next.js and MCP tools
  • Any facilitator: Coinbase CDP, PayAI, thirdweb
  • A retry with the same payment never charges twice
Sell your API

I run an agent

Give it a wallet. And a budget.

Guard wraps your x402 client and fetch. Every 402 goes through your policy before anything is signed: budget per task, cap per call and per day, sellers you allow, addresses you pinned.

agent.ts
const guard = createGuard({ signer, daily: "$5" })
const research = guard.task("research", { budget: "$0.50" })
await research.fetch("https://api.example.com/v1/fact")
  • Task budgets, per-call caps, a daily cap
  • Allow-lists and payTo pinning
  • Keys never leave your machine
Guard your agent

what guard catches

Four ways an agent drains a wallet.

None of them need a hacker. They need a loop, a timeout, a new link or a busy day. Guard stops each one with a rule and a reason you can read.

01 budget

The runaway loop

A tool keeps failing and the agent keeps retrying. A $0.01 per-call cap happily approves call 1,000, and call 1,001.

  1. call 498 · $0.001 · paid
  2. call 499 · $0.001 · paid
  3. call 500 · $0.001 · paid · $0.000 left
  4. call 501 · blocked · budget

Guard counts every cent against the task budget and refuses the first call that would cross it. The loop ends at $0.50, not at your balance.

{ stop at the budget }

02 not_paid_before

Paid, then timed out

The payment settles, the response never arrives, your HTTP client retries and signs a second payment for the same request.

  1. POST /v1/report · 402 · $0.01
  2. paid $0.01 · ledger written
  3. timeout 30s · retrying
  4. same payment re-sent · not charged
  5. 200 OK · replayed

Guard writes every payment to a local ledger before sending it. The retry re-sends the same payment, which can only settle once. You get the answer, not a second charge.

{ never twice }

03 payto_pinned

The swapped address

Your agent follows a link to an API it has never paid. Or a known API's 402 suddenly asks to be paid at a different address.

  1. 402 · api.example.com · $0.002
  2. payTo 0x9a…c3
  3. pinned 0x4b…7e · mismatch
  4. blocked · payto_pinned

New sellers wait for your ok, a Telegram button works. Known sellers are pinned to the payTo you approved. If it changes, Guard refuses and says why.

{ ask first }

04 daily

Fine per task, too much per day

Every task stays inside its $0.50 budget. Then a cron job starts a new task every ten minutes, all day.

  1. task 9 · $0.50 · done · day $4.50
  2. task 10 · $0.50 · done · day $5.00
  3. task 11 · GET /v1/fact · $0.001
  4. blocked · daily · $5.00 of $5.00

A daily cap sits above every task budget. When the day is spent, every task stops paying until the window resets, or until you raise the cap.

{ one cap for the day }

how it works

Seven steps. Two are ours.

x402 does the paying. Coinslot decides whether to pay at all, and remembers that you did.

  1. 01agent

    Request

    The agent calls a paid endpoint like any other URL.

  2. 02seller

    402 Payment Required

    The seller answers HTTP 402 with a PAYMENT-REQUIRED header: price, asset, network and the payTo address.

  3. 03guard

    Policy check

    Guard decides whether to pay: task budget, per-call cap, daily cap, allowed sellers, pinned payTo, not paid before. One no means no payment.

    Coinslot
  4. 04agent

    Sign

    The agent's signer signs the payment locally and retries with a PAYMENT-SIGNATURE header. The key never leaves the machine.

  5. 05facilitator

    Verify & settle

    The facilitator checks the signature and settles USDC on-chain, from the agent's wallet to the seller's.

  6. 06seller

    200 + receipt

    The seller returns 200 with the data and a PAYMENT-RESPONSE header that carries the settlement.

  7. 07guard

    Receipt to dashboard

    Guard ties the payment to the task, the step, the trace id and the transaction. Locally, in your OpenTelemetry, or in the hosted dashboard.

    Coinslot
  8. Steps 1, 2 and 4–6 are plain x402 V2. Steps 3 and 7 are Coinslot. The money goes agent → facilitator → seller and never touches us.

example endpoints · not live listings

  • GET /v1/fact$0.001base
  • POST /v1/search$0.01base
  • GET /weather/now$0.001base
  • mcp · web.search$0.002solana
  • POST /v1/embed$0.002base
  • GET /v1/price/sol$0.001solana
  • POST /v1/summarize$0.005base
  • mcp · pdf.extract$0.003base
  • GET /v1/geocode$0.001solana
  • POST /v1/ocr$0.004base

open source · MIT

Yours to read. Free to self-host.

Paywall, Guard and the CLI are MIT-licensed and run without our server. Everything that touches a wallet is code you can read. The hosted dashboard is optional.

01

@coinslot/paywall

Middleware for Hono, Express, Next.js and MCP tools. Price per route, any facilitator, idempotent, rate-limited per payer.

npm i @coinslot/paywall
02

@coinslot/guard

Wraps your x402 client and fetch. Task budgets, caps, allow-lists, payTo pinning, an anti-double-pay ledger, OpenTelemetry.

npm i @coinslot/guard
03

@coinslot/cli

init wires Paywall or Guard into your project. test makes one paid request on Base Sepolia.

npx @coinslot/cli init

packages land on npm with v0.1 — until then install from the repo

faq

Fair questions.

{ never twice }

No. Payments go from the agent's wallet to the seller's wallet through the facilitator you configure. Coinslot never receives, routes or holds USDC, and never sees a private key.

An open standard that puts HTTP 402 Payment Required to work. The server answers with a price, the client pays in USDC and retries with a signature, the server returns 200. No accounts, no cards, no minimums.

Base and Solana, plus Base Sepolia and Solana devnet for testing. Coinbase CDP is the default facilitator; PayAI, thirdweb or any facilitator URL work too.

The SDKs and CLI are free and MIT-licensed, with no limits. The hosted dashboard has a free tier. There is no fee on agent payments, ever.

Guard writes the payment to its ledger before sending. A retry re-sends that same payment instead of signing a new one, and a signed payment can only settle once. If the seller runs Coinslot Paywall, the retry gets the stored response. Either way, you pay once.

Same open standard, different job. Coinslot works with any x402 facilitator in any country (Cloudflare's Monetization Gateway opened on October 1, 2026 as a private beta for US accounts). And Guard adds the agent-side controls a paywall alone doesn't: task budgets, anti-double-pay, payTo pinning, a kill switch.

No. Coinslot is experimental and has not been audited. Start on Base Sepolia, keep agent wallets small, and read the code: it's all on GitHub.

A paywall for your API. A budget for your agent.

Two installs, one standard. Try it on testnet first: npx @coinslot/cli test <url> makes one paid request on Base Sepolia.

{ pay per call }