BotsRated

Learn

How paying a bot works

A bot pays the way a browser loads a page: ask, get a price, pay, ask again.

The steps

  1. Ask. The agent calls the seller's endpoint.
  2. Get a price. The seller answers 402 Payment Required with its terms: amount, token, network and the payTo address.
  3. Decide. The agent's wallet or payment library compares the terms with its own limits.
  4. Pay. If the terms are OK, the agent signs a payment and sends the request again with it attached.
  5. Settle. The seller, or its facilitator, checks the payment and settles it.
  6. Get the answer. The seller sends the response, often with a settlement or receipt header.

What to check before signing

The MPP spec says clients must check four things before they authorize a payment, and the same list works for x402:

It also warns not to trust the seller's description text. A misleading description can sit next to a payment request for a different amount.

Set a per-payment cap. Common x402 clients cap single payments by default (for example, @x402/fetch's maxAmountPerPayment), so the agent stops instead of paying an unexpected price.

Why checking first matters

Many x402 stablecoin payments settle as on-chain transfers, which usually cannot be reversed the way a card chargeback can. Some x402 schemes authorize first and settle later (see Payment Headers in V2 / batch settlement). If a seller sends money back, that is a separate payment. Stripe machine payments are different: refunds go through Stripe's Refunds API (Stripe docs). Either way, the cheapest mistake is the one you avoid before you sign.

What can go wrong

BotsRated records the first, second and fourth on every unpaid check. Our capped test purchases record the third. How to check a seller.

For bots

  • Before paying, free: GET https://botsrated.com/v1/preflight?url=<host> (1000 per client IP per UTC day). MCP tool preflight with {"url":"<host>"}.
  • In code: Guard, createPaymentGuard in npm @botsrated/x402-preflight or PaymentGuard in PyPI botsrated (docs). It compares the 402 you got with what we last measured.
  • Compare latest_probe.live_amount, live_payTo, live_asset and live_network with the 402 in front of you, and read freshness.stale.

Full field list: /llms.txt · /openapi.json · MCP endpoint POST https://botsrated.com/mcp (Streamable HTTP, no login).

Sources

Educational information about how payments and measurements work, not legal, tax or financial advice.

Next: How to check a seller before paying · All lessons · Guides · Docs