The x402 Ecosystem: Every Tool That Lets AI Agents Pay Each Other

August 1, 2026 · 7 min read · by Iris

Something new is happening on the web. For the first time since HTTP 402 was reserved in 1997, AI agents are actually paying for API access — not with credit cards, not with monthly subscriptions, but with on-chain USDC micropayments, settled in seconds, with no human in the loop.

This is the x402 ecosystem — a stack of tools that together make machine-to-machine payments work. Here's a map of every piece, who builds what, and how they fit together.

The 30-Second Map

Middleware (wayleave, Centinel) protects your API → Agent SDKs (level42) let agents pay → Marketplaces (minia2a) let agents discover services.
Each layer solves a different problem. Together they make the agent economy work.

The Three Layers of the x402 Stack

Think of it like the web payments stack. Stripe, PayPal, and Visa operate at different layers — one doesn't replace the other. The x402 ecosystem has the same structure:

LayerWhat It DoesWho Builds It
🛡️ Gateway / MiddlewareSits in front of your API. Detects agents, enforces payment, returns HTTP 402wayleave, Centinel
💰 Agent Payment SDKLives inside the agent. Detects 402 responses, pays, retrieslevel42
🏪 Marketplace / DiscoveryWhere agents find paid services and developers list their endpointsminia2a.uk

Layer 1: The Gateways — Protecting Your API

Before an agent can pay you, your API needs to tell them payment is required. That's the gateway layer — middleware that inspects every request, classifies the caller, and returns 402 Payment Required when a priced route is hit.

wayleave Node.jsExpress

A zero-dependency middleware that classifies every request into four lanes: verified_agent (valid Ed25519 signature), declared_agent (self-identified bot), suspected_bot (automation fingerprints), and human (browser-shaped traffic).

On priced routes, it returns 402 Payment Required with a challenge containing the price and receiving address. A developer-supplied verifyPayment callback confirms settlement before the request gets a 200.

Key insight: wayleave delegates settlement to an external "x402 facilitator." It screens and prices, but doesn't custody funds. The developer picks their own payment rail.

github.com/gibrancorbin11-hub/wayleave · 0 dependencies · MIT-ish

Centinel Node.jsExpressNext.js

A low-code middleware framework that implements the x402 protocol with multi-chain support. Accepts SOL, ETH, and USDC on Solana and Base.

Config lives in a single centinel.config.json file — pricing rules, path wildcards, wallet addresses, session durations. Ships with Express and Next.js adapters, a CLI scaffolder, and signed webhooks for payment events.

Key insight: Centinel verifies payments on-chain directly — it checks transaction hashes against the blockchain. Two-layer replay protection (age verification + in-memory dedup) prevents double-spends.

github.com/blaqjeff/Centinel · Multi-chain · x402 protocol

Gateway Comparison

wayleaveCentinel
LanguageNode.js (Express)Node.js (Express, Next.js)
Agent Detection4-lane classification + Ed25519 sigsHeader-based (X-Payment-Signature)
Payment VerificationDelegated to developer callbackOn-chain, built-in
ChainsAny (via facilitator)Solana, Base
Session ModelRate-limit windowsJWT session tokens (per_session billing)
Best ForCustom settlement logic, key-based authQuick setup, multi-chain, managed verification

Layer 2: The Agent SDK — Paying From the Client Side

Gateways return 402. Someone needs to respond to that 402 — detect it, authorize payment, pay, and retry. That's the agent SDK layer.

level42 PythonBase L2USDC

The x402-Agent Framework. When an agent built with level42 encounters an HTTP 402 response, it automatically processes the payment and continues with the task. No human approval. No popup. No OAuth.

Key features:

from level42 import Level42Agent

agent = Level42Agent(
    llm=my_llm,
    wallet_key="your_base_private_key"
)
agent.register_tool("web-scrape", "https://api.example.com/scrape", "...")
result = agent.run("Scrape the top 10 HN posts and summarize")

Key insight: level42 handles the entire payment flow on the agent side. The developer sets a budget; the agent stays within it. Payments happen in the background while the task continues.

github.com/tjelz/level42 · pip install level42 · USDC on Base

Layer 3: The Marketplace — Where Services Are Discovered

Gateways protect APIs. Agent SDKs pay for them. But how does an agent find the right paid service in the first place?

That's the marketplace layer — and it's where minia2a.uk sits.

minia2a.uk Marketplace173+ Servicesx402

minia2a.uk is the discovery layer for the x402 ecosystem. It lists 173+ paid API endpoints across categories like web scraping, DeFi data, DNS, crypto security, email verification, and more. Agents browse, find the service they need, and call it — all through the x402 protocol.

For developers: list your API endpoint, set your price in USDC, and get discovered by agents that need your service. minia2a handles the authorization envelope — spending limits are enforced server-side.

For agents: one API key gives access to 173+ services. Free credits to start. Pay-as-you-go beyond that. No per-service signup. No credit card per endpoint.

Current stats (live from /api/stats): 173 services · 34 registered agents · 309K+ total requests · 2,798 free trials used.

minia2a.uk · USDC on Base · 500 free credits on signup

How They Fit Together: A Real Request Flow

Here's the full path of an agent paying for an API call, with every layer involved:

1. AGENT (level42)
   "I need to scrape news.ycombinator.com"
   → Looks up available services on minia2a.uk
   → Finds /x402/web-scrape at $0.01/call

2. AGENT → API GATEWAY (Centinel)
   GET /api/scrape?url=news.ycombinator.com

3. GATEWAY → AGENT
   HTTP 402 Payment Required
   {"price":"0.01","currency":"USDC","chain":"base","address":"0x..."}

4. AGENT (level42 auto-pay)
   Detects 402 → checks budget ($0.05 max/call, $1.00/day)
   → $0.01 is within limits → signs USDC transfer on Base
   → Attaches payment proof header → retries

5. GATEWAY (Centinel verify)
   Checks transaction hash on-chain → confirmed
   → Returns 200 OK with scraped data

6. MARKETPLACE (minia2a)
   Records the transaction → updates usage stats
   → Enforces developer's pricing and agent's spending limits

Total time from 402 to 200: ~2-4 seconds on Base L2. The agent never stops — payment happens inline, mid-task.

What's Missing: The Gaps in the Ecosystem

This stack is real and working, but it's early. Here's what still needs to be built:

GapWhy It Matters
Universal agent identitywayleave uses Ed25519 keys; Centinel uses payment signatures. No standard way for an agent to say "I am agent-X" across gateways.
Cross-gateway discoveryAn agent using level42 + minia2a can discover minia2a-listed services, but not services behind a standalone wayleave instance. Standardized service registries needed.
Reputation / ratingsNo way for agents to rate services or for gateways to rate agents. A reputation layer would help agents decide which services are reliable.
Multi-facilitator settlementwayleave delegates to an external facilitator. Centinel verifies on-chain. No standard facilitator interface means each gateway picks its own settlement path.
TypeScript/Python agent SDKslevel42 covers Python. No equivalent SDK for TypeScript/Node.js agents yet.

Where to Start

If you're an API developer who wants to charge AI agents:

  1. Pick a gateway — Centinel for quick multi-chain setup, wayleave for custom settlement logic
  2. List your endpoint on minia2a.uk so agents can discover it
  3. Set your price in USDC. minia2a enforces authorization; your gateway enforces payment.

If you're building AI agents that need to call paid APIs:

  1. Use level42 (Python) for automatic 402 detection and payment
  2. Browse minia2a.uk/services to find the APIs your agent needs (or read the 3-step integration guide)
  3. Start with 500 free credits. Pay as you go. Your agent never exceeds the budget you set. See the full tutorial: Build Your First x402-Powered AI Agent.

The Bottom Line

HTTP 402 sat unused for 28 years. In 2026, it's waking up — not for humans, but for the agents that act on their behalf. The stack is small but real: wayleave + Centinel protect the door, level42 pays at the door, and minia2a tells agents which doors exist.

All of this is open-source. All of it uses real USDC on real blockchains. None of it requires KYC, credit cards, or bank accounts. This is the agent economy — and it's being built right now.

Tags: x402, HTTP 402, agent payments, micropayments, USDC, Base L2, wayleave, Centinel, level42, minia2a, agent economy, M2M payments