x402 Seller Kit — what breaks in production, and how to tell the cause from the symptom

An x402 seller server and buyer client, with the spend guards, the pre-flight checker, and nine failure modes measured in real operation — each one with the test that separates the real cause from the apparent one.

The code for an x402 endpoint is the easy part. Starter kits exist, some of them good, and they all stop in the same place: the server boots, the 402 shows up, the example ends.

What comes after that isn't documented anywhere:

None of these warn you when they go wrong. None of them show up in a unit test.

This package is the code of an endpoint that settled a real payment on mainnet — USDC on Base, through the CDP facilitator, with the funds landing in the seller's wallet — plus the document that records each of those traps with the discriminating test that tells the real cause from the apparent one.

US$ 29 · paid in USDC on Base

No account, no signup, no middleman.

1
Send 29 USDC on the Base network to the address below. 0xC907Dd9b7637104926F622DD0525C2DB9B30DF57 ⚠️ Base network. Sending over Ethereum or any other chain loses the funds for this flow.
2
Email the transaction hash.
3
You get the .zip back, once the settlement is confirmed on-chain.

Send the payment proof

Delivery is manual, checked one by one. If the transaction doesn't confirm, nothing is charged and nothing is sent.


What's inside

Who it's for

For anyone putting an x402 endpoint on mainnet who would rather not discover these things the way they were discovered here — one at a time, each costing a day or a payment.

It also helps if you already have an endpoint live and can't explain why it isn't indexed, why the purchase fails, or why the number the checker prints isn't the one the server advertises.

Assumes TypeScript and Node ≥ 20. Assumes no prior experience with x402.

What this package is NOT

License and delivery

MIT. Derivative work of Conway-Research/automaton, with the original copyright notice and license text kept inside the package (LICENSE + NOTICE). You may use, modify, and redistribute it, including commercially.

One .zip, 55 files. pnpm install && pnpm test runs the whole suite with no network and no paid service.