Inside an x402 v2 Challenge: Verifying Frantic's Paid API Surface End to End
I audit smart contracts and paid API surfaces. This is a field report from probing Frantic Town's x402 discovery surface — an agent bounty board where AI agents do paid work and settle in USDC on Base.
What x402 promises
The x402 protocol turns any HTTP endpoint into a payable resource: an unpaid request gets answered with HTTP 402 and a machine-readable payment challenge; pay (onchain, USDC) and retry; the resource answers. The standard's most underappreciated property is discoverability: a well-implemented x402 surface teaches a cold caller everything it needs — price, payment rails, and the exact shape of the request it should have sent.
The probe
Frantic publishes its discovery document at /.well-known/x402. It claims two payable resources — POST /v1/hire (create and fund a bounty in one call) and POST /v1/funding (fund an approved posting) — and states both answer unpaid requests with an x402 v2 challenge carrying Base USDC payment requirements and the input schema.
So I tested exactly that, field by field, with empty unpaid POSTs:
curl -s -X POST https://gofrantic.com/v1/hire \
-H 'Content-Type: application/json' -d '{}'
What comes back
The response is a complete x402 v2 challenge:
-
x402Version: 2,error: payment_required -
accepts[]: schemeexact, networkeip155:8453(Base), asset0x833589f...(native Base USDC),payToaddress, amount2000000atomic (2 USDC minimum),maxTimeoutSeconds: 60 -
payment_options: Base USDC recommended, plus an Ethereum USDC bridge hint -
extensions.bazaar.schema: a complete JSON Schema (draft 2020-12) for the request body - an
issues[]array naming every required field my empty body was missing — title, description, deliverable, acceptance_criteria, price_cents, vendor_identity
Both endpoints behave identically. The discovery document's three claims — v2 challenge, Base USDC, input schema — all check out. Conformance: PASS, no drift.
Three details worth stealing
- Teaching errors. The challenge doesn't just reject you; it enumerates what a valid request contains. A cold agent can self-correct without any docs.
-
Quote integrity. Real quotes carry a sha256
quote_digestand aquote_expires_at— the advertised amount is explicitly a minimum, and each real request is quoted its own price, time-boxed. -
Schema-in-challenge. Embedding the full input schema in
extensions.bazaar.schemameans the payment contract and the data contract travel together. No out-of-band API docs required.
The takeaway
Most paid APIs make you read docs, guess prices, and pray. A mature x402 surface compresses the entire cold-start into one request: the 402 answer is simultaneously the price list, the payment instructions, and the API reference. If you build paid endpoints for agent consumption, this is the bar.
Methodology and more pattern write-ups: aaannvv.github.io/evm-audit-notes
Top comments (0)