Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.monkepay.xyz/llms.txt

Use this file to discover all available pages before exploring further.

How it works

Agent → GET /api/data
← 402 Payment Required { amount: "0.001 USDC", network: "base-sepolia" }

Agent → GET /api/data (X-Payment: ...)
← 200 OK  +  X-Payment-Response: ...  (settlement proof)
One middleware on your server. The agent handles the rest.

What you need

As an API owner:
  • A MonkePay account — monkepay.xyz
  • Your API key ID and secret from the dashboard
  • One of: Express, Hono, Fastify, or Next.js (App Router)
As an agent developer:
  • A wallet with USDC on Base Sepolia (testnet) or Base (mainnet)
  • x402-fetch — wraps the standard fetch API with automatic payment handling

The stack

MonkePay is built on three open standards: x402 — an open payment protocol that revives the HTTP 402 status code. When a server returns 402, the client pays and retries. The spec is maintained by Coinbase and is framework and chain agnostic. Base — Coinbase’s L2 on Ethereum. ~1 second finality, near-zero gas fees. A 0.001paymentcostslessthan0.001 payment costs less than 0.0001 in gas. USDC — a dollar-pegged stablecoin issued by Circle. 1 USDC = $1. No volatility, no FX risk, instant settlement.

Pricing

MonkePay takes 1% of every transaction. No monthly fee, no per-endpoint charges, no seat licences. You only pay when you get paid.
  • Quick Start — gate your first endpoint in 5 minutes
  • Dashboard — manage API keys, view transactions, configure payouts
  • GitHub — SDK source
  • npm@monkepay/sdk