BUYER AGENT

thebuyside-x4-agent

An MCP gateway that gives your AI agent three new tools: discover paid APIs, fetch and pay automatically, check wallet status. Works with Claude Code, Claude Desktop, and Cursor. Your agent never sees the wallet or a private key.

Node 20+MCPClaude CodeClaude DesktopCursorBase USDCSolana USDC

Three tools, one install

pay.fetch
Fetch a URL. If it returns 402, jaypay pays automatically and returns the response. x402 and MPP both supported.
pay.discover
Search the directory plus CDP Bazaar, agentic.market, and x402watch for paid APIs. Deduped, tagged, ready to call.
pay.wallet_status
Show wallet addresses, today's spend, daily cap remaining, and which chains you have keys for.

Install

1
Fund a wallet with USDC

You need USDC on at least one chain. The buyer wallet only needs USDC — not SOL or ETH for gas. Sellers' facilitators cover network fees.

# For Base / EVM:
export X402_PAYER_PRIVATE_KEY=0x... # 64 hex chars
# For Solana / SVM:
export X402_PAYER_SOLANA_KEY=<base58> # Phantom export
# USDC mint on Solana:
# EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v
2
Register with your MCP client
# Claude Code:
claude mcp add x402-pay -- npx -y thebuyside-x4-agent
# Verify:
/mcp
✓ x402-pay connected · 3 tools available

For Claude Desktop, see the full install docs. For Cursor, add to your MCP config JSON.

3
Try it
Ask your agent:
"Use pay.discover to find news APIs."
"Use pay.fetch to get https://news-ep.com/api/v1/stories?market=houston"
"Use pay.wallet_status to show my balance."

Spend controls

Safe defaults are built in. Override via environment variables if needed.

VariableDefaultWhat it does
X402_DAILY_LIMIT$1.00Max USDC per rolling 24h window
X402_PER_CALL_LIMIT$0.05Max USDC per single call
X402_REQUIRE_CONFIRMalwaysAsk before paying: always · never · $threshold
X402_ALLOWLISTseed hostsComma-separated allowed hostnames
X402_ALLOW_UNVERIFIEDoffSet to 1 for dev — allows any host
Browse paid APIs →