
Peaje
The payment rail for AI agents: your site charges them, your agents buy for you.
Demo
About
Peaje is the cash register of the agent economy: it lets any business charge AI agents per request, and lets any person run a buyer agent that spends from the same balance, with no payment code and no crypto knowledge required. Selling side: a business registers with an email and a URL, sets prices on links or API routes (or imports its sitemap), and gets a hosted gateway that answers HTTP 402 payment challenges via MPP, the machine-to-machine payment standard from Tempo and Stripe. Agents pay on their own in stablecoin (pathUSD on Tempo, USDC on Arc) and the gateway proxies the paid request to the original site. Peaje also makes the site discoverable to agents: agents.md, llms.txt, ard.json, an enriched openapi.json, an api-catalog, JSON-LD, Link headers and a paid-tools MCP server, all generated from the database and anchored at the business's own domain. The demo site's agent-readiness score (Ora) went from 40 to 73 after installing Peaje with a single prompt. The gateway also speaks the emerging agent-commerce protocols: UCP profile, ACP checkout sessions, and AP2 cart mandates signed with ES256. Buying side: every account gets one buyer agent with its own wallet. You type what you need in plain language ("this week's weather in Bogotá, three lines"), the agent searches roughly 15,000 real paid services across three sources (Peaje's own directory, Coinbase's x402 Bazaar, and the ERC-8004 identity registry via The Graph) and shows you what it would buy, at what price, and why, before spending a cent. A language-model veto rejects services that would not answer the request: buying nothing beats buying garbage. On approval it pays (MPP on Tempo/Arc, x402 with real USDC on Base mainnet), translates your request into the service's actual query parameters, reads what it bought, and returns a short human-readable answer with the on-chain receipt behind it. The agent's wallet balance is its budget: it physically cannot overspend. Peaje takes a 2% fee per transaction on the selling side. The full loop is live: an external agent paid for content on the demo business, that revenue funded the owner's buyer agent, and the buyer agent purchased real weather data and returned a three-line answer, every step with an on-chain receipt.
How it's made
Monorepo with three pieces: a multi-tenant Hono gateway (Railway) that does the charging, proxying, discovery generation and the whole buyer-agent engine; a Next.js dashboard (Vercel) with email-only onboarding; and a shared db package over Supabase. Wallets for businesses and agents are Privy server wallets, created invisibly at signup, exposed to code as viem accounts. Charging uses mppx (MPP's reference implementation): the gateway issues 402 challenges offering two rails per request, Tempo (pathUSD) and Arc (USDC via EIP-3009 transferWithAuthorization), verifies receipts, credits a per-tenant ledger net of the 2% fee, and proxies to the origin. Discovery files are not static: they are generated per tenant from the database and served through the business's own domain via a reverse-proxy kit installed by pasting one prompt into any coding assistant, so the docs self-name at the business domain and agents never get pointed at our infrastructure. The buyer agent composes three discovery sources: our own directory, the full Coinbase x402 Bazaar index (~15 pages of 1,000 services, cached an hour: with the default 100 the agent only ever saw 0.7% of the market and bought junk), and ERC-8004 identity plus reputation read from Agent0 subgraphs on The Graph, which feeds on-chain reputation into every scoring decision. Deterministic keyword scoring picks a shortlist; Claude then acts as a veto gate ("does this service actually deliver the requested data?"), fills the winning API's query string (city coordinates, forecast variables, date ranges) and synthesizes the purchased content into a plain-language answer. Purchases pay via mppx on Tempo/Arc and via x402-fetch with real USDC on Base mainnet, from the same Privy account. Notable hacky bits: the agent's spend cap is not an accounting entry, it is the wallet's literal balance, so no bug can overspend; structured outputs silently reject open JSON schemas, so the query-builder had to move from a record type to closed key/value pairs (before that fix every purchase went out with an empty query and we paid for weather APIs that returned nothing); sweeping a Tempo wallet needs a fee buffer because gas is paid in the same token you are sweeping; and pending withdrawals are reconciled lazily against chain receipts from the scheduler tick, so the ledger heals itself.