Event search and on-sale checks over Ticketmaster Discovery. An agent pays $0.003 to find real events with venues, dates and price ranges, or $0.002 to poll whether a specific event has gone on sale — and gets the answer in the same response.
git clone https://github.com/nirholas/x402-events
cd x402-events && npm install
npm run dev
| Route | Price | Returns |
|---|---|---|
GET /search | $0.003 | Events with venue, local and UTC start times, status, genre, price ranges and a ticket link |
GET /onsale-check/:eventId | $0.002 | A complete on-sale snapshot — state, public and presale windows, price ranges, ticket link, and a fresh cursor — plus the field-by-field delta since the cursor you sent |
GET /, GET /health, GET /.well-known/x402 |
free | Service info, liveness, discovery manifest |
Every paid route returns the purchased artifact in the 200 response body.
The 402 challenge advertises both. Your client picks whichever it can sign.
base-sepolia · base on mainnetsolana · solana-devnet on devnetimport { wrapFetchWithPayment, createSigner } from "x402-fetch";
const signer = await createSigner("base-sepolia", process.env.PRIVATE_KEY!);
const payFetch = wrapFetchWithPayment(fetch, signer);
const res = await payFetch(
"http://localhost:4023/search?keyword=jazz&city=Chicago&countryCode=US&size=2"
);
const artifact = await res.json(); // purchased artifact, in-response