Merchants
Merchant Overview
For Merchants (API Sellers)
ChainPe lets you monetize any HTTP API per-call in USDC without API keys, subscriptions, or credit card integrations. Your backend receives no code changes — the x402 proxy sits in front and handles all payment gating.
How it works
Client request
│
▼
┌─────────────────────────────┐
│ ChainPe x402 Proxy │ ← chainpe start
│ (Express + x402-express) │
│ port 4402 (default) │
└──────────┬──────────────────┘
│ payment verified
▼
┌─────────────────────────────┐
│ Your backend │ ← http://localhost:3000
│ (any HTTP server) │
└─────────────────────────────┘The proxy:
- Returns
402 Payment Requiredwith your USDC address and price - Waits for
X-PAYMENTheader with a signed USDC authorization - Calls the facilitator to settle on Avalanche (~1-2s)
- Forwards the request to your backend
- Returns the response to the client
Quick start for merchants
# Install
npm install -g @chainpeavax/cli
# Interactive setup
chainpe init
# Start the proxy
chainpe start
# Register on-chain (makes your service discoverable)
chainpe registerSections in this guide
- Registration — how to register your service on ChainPeRegistry
- Policy Configuration — set up PolicyVault for buyers
- Receiving Payments — USDC settlement and earnings