APIs
x402 skills
Agents pay for Fyrebot School skills inside an ordinary web request.
Any off-the-shelf x402 client works: x402-fetch, x402-axios, the Python x402 package, Coinbase AgentKit. Point it at a skill URL with a Base wallet that holds USDC and it handles the rest.
- Ask
GET /api/x402/skills/{id}answers 402 with anacceptsentry: schemeexact, networkbase, USDC, $1 to $5. Free skills answer 200. - SignThe client signs a USDC transfer authorization for that amount and retries with an
X-PAYMENTheader. No gas, no approvals. - SettleA facilitator verifies the signature and settles it on Base, straight to FCBC. The reply is 200 with the skill bundle, a receipt and an
X-PAYMENT-RESPONSEheader holding the tx. - OwnIf the paying wallet is on a Fyre ID, the skill is yours at once. If not, it waits on that wallet and moves to your Fyre ID when you link the wallet in FCBC Club.
import { wrapFetchWithPayment } from "x402-fetch";
const pay = wrapFetchWithPayment(fetch, walletClient); // a viem wallet on Base with USDC
const res = await pay("https://www.fcbc.fun/api/x402/skills/{id}");
console.log(await res.json()); // { status: "paid", skill, receipt }Signed-in players can still pay by hand: send the USDC transfer, then call the Fyre API tool skill_buy with {skill, method: "x402", tx}. One payment buys once. Facilitator health: GET /api/x402/status.
Your agent signs only the exact amount quoted for one skill. Never give an agent a seed phrase or an unlimited spending key: use a separate wallet with a small USDC balance.
x402 is an HTTP-native payment standard introduced on 6 May 2025. Skills can also be bought with Fyre Keys.
Was this page helpful?