xPay is the discovery and payment layer for agentic commerce. Find and pay 21,000+ services across Solana and Base — multi-network wallet, x402 rails, and spending guardrails in a single SDK.
npm install @xona-labs/xpayRead the docs →$ npm install -g @xona-labs/xpay $ xpay init✔ Solana 7RB7frd…6qkpf5ph✔ EVM 0xA5D9…1023dfa $ xpay discover "short video" $0.5000 solana api.xona-agent.com $ xpay pay api.xona-agent.com/video/…✔ Paid $0.5000 on solana · 1.2sYour agent handles reasoning. xPay handles the money — finding the right service, enforcing your spending rules, and settling payment over x402, all in three calls the agent never has to think about.
“Make a short video of a cat astronaut”
Needs a video-generation service it doesn’t have
Searches 21,000+ services → api.xona-agent.com · $0.50
$0.50 ≤ $1.00 per-tx cap — approved before signing
Signs USDC on Solana · x402 settled in 1.2s
Receives payment, generates the short video
Video returned to the agent → back to the user
Search the entire x402 ecosystem via PayAI and other catalogs. Ranked, cached, one call.
Pay any compatible endpoint — catalog or wild — with automatic network routing and retries.
One BIP-39 seed derives both. USDC balances and transfers unified across chains.
Per-tx and per-day limits enforced before signing — a hallucinating agent can't slip past.
Keys live in an encrypted keystore on the agent's machine. No vendor, no popups, no lock-in.
Every payment is a public USDC transfer. Read activity straight from the chain, no backend.
Type-safe TypeScript with one entry point. createXPay gives you discover, pay, transfer, balance, and history — plus tool exporters for Claude, OpenAI, and Gemini so your agent can spend in four lines.
import { createXPay, loadProfile } from "@xona-labs/xpay" const xpay = createXPay({ profile: await loadProfile({ passphrase }),}); // pay any x402 endpoint, get the resultconst video = await xpay.useByUrl( "https://api.xona-agent.com/video/short-generation", { body: { prompt: "a cat astronaut" } });Install once, init a local encrypted keystore, and you're transacting. No browser, no popups, no vendor — perfect for scripts, cron jobs, and headless agents.
$ npm install -g @xona-labs/xpay $ xpay init✔ Solana 7RB7frd…6qkpf5ph✔ EVM 0xA5D9…1023dfa $ xpay discover "short video" $0.5000 solana api.xona-agent.com $ xpay pay api.xona-agent.com/video/…✔ Paid $0.5000 on solana · 1.2sPaste one block into your MCP host config and your agent gets seven payment tools — discover, pay, do, transfer, balance, history, guardrail — reading the same profile you created with the CLI.
// claude_desktop_config.json{ "mcpServers": { "xpay": { "command": "npx", "args": ["-y", "@xona-labs/xpay", "mcp"], "env": { "XPAY_PASSPHRASE": "•••" } } }} › "pay api.xona-agent.com to make a short video"Install the SDK, run xpay init, and your agent can discover and pay 21,000+ services across Solana and Base.