402MCP
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MCP_402_OFFLINE | No | Set to 1 to use the bundled registry snapshot and never fetch. |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| decode_402_challengeA | Call this whenever an HTTP response has status 402, or carries a WWW-Authenticate (L402, LSAT or Payment) or PAYMENT-REQUIRED header. Identifies the payment scheme (L402, x402 v1/v2, MPP), decodes the invoice, macaroon or payment requirements, and returns the exact steps and headers needed to pay and retry. Pass either |
| recommend_payment_railA | Choose an HTTP 402 payment solution from requirements rather than from rank. Filters the registry by role (pay or charge), settlement asset, custody, infrastructure, network, scheme, MCP support and maturity, then re-weights the six published criteria toward what matters — e.g. sub-cent amounts weight settlement cost heavily. Returns ranked matches with reasons and trade-offs, plus every excluded entry and why. |
| search_402_solutionsA | Search the 402MCP.org registry of HTTP 402 payment solutions (L402, x402, MPP). Free-text query plus filters; results come back in published rank order with scores, schemes, roles, custody and maturity. Call with no arguments to list the whole registry. |
| get_solutionA | Return one solution in full: summary, advantages and trade-offs, the six criterion scores with rationale, install commands, verified code samples, sources, maturity and the date its claims were last verified. |
| get_scheme_referenceA | Protocol reference for L402, x402 or MPP: challenge, credential and receipt headers, encodings, the request/response flow, an example, and links to the specifications. Use when implementing a client or server. |
| probe_402_supportA | Make one GET (or HEAD) request to a public URL and report whether it answers with an HTTP 402 payment challenge, which scheme, and the decoded terms. Redirects are reported, not followed. Private and local addresses are refused. Never pays anything. |
| get_best_payment_solutionA | Return whichever solution currently holds rank 1 on 402MCP.org, with its full breakdown, install commands and code. Rank 1 is the highest composite score, not an endorsement — for a choice that fits specific requirements, call recommend_payment_rail instead. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| choose_payment_rail | Compare indexed 402 solutions against a project's requirements and recommend one, with trade-offs. |
| handle_402_response | Decode a 402 response and work out exactly how to pay and retry — safely. |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| registry | Every indexed HTTP 402 solution with scores, schemes, roles, maturity, sources and code. |
| methodology | How solutions are scored and ranked, and what each maturity label means. |
| scheme-l402 | Challenge, credential and receipt format for L402. |
| scheme-x402 | Challenge, credential and receipt format for x402. |
| scheme-mpp | Challenge, credential and receipt format for MPP. |
| lightning-labs-wavelength | Self-custodial Bitcoin and Lightning wallet toolkit with native MCP support, zero node/channel operational overhead, and unilateral on-chain exit guarantees. |
| x402-protocol | Open HTTP 402 standard for stablecoin payments on EVM chains and Solana, with TypeScript, Python and Go reference implementations. |
| alby-mcp | Alby's official MCP server connects a Lightning wallet to agents over Nostr Wallet Connect, with invoice, payment and L402 tools. |
| cloudflare-agents-x402 | Cloudflare's Agents SDK adds x402 pricing to MCP tools with paidTool, so free and paid tools coexist on one server. |
| coinbase-payments-mcp | Coinbase's MCP server and companion wallet give agents an embedded wallet, an onramp and automatic x402 payments, installed with one npx command. |
| machine-payments-protocol | Open, method-agnostic HTTP 402 scheme co-authored by Tempo and Stripe, using WWW-Authenticate: Payment challenges and Payment-Receipt receipts. |
| thirdweb-x402 | thirdweb's hosted x402 facilitator settles payments on 170+ EVM chains, with a client fetch wrapper and a hosted endpoint agents can pay through. |
| payai-x402-facilitator | Solana-first x402 facilitator that verifies and settles payments, sponsors settlement gas, and offers batch settlement for high-frequency micropayments. |
| vercel-402-mcp-middleware | Library for charging per MCP tool call with x402, wrapping mcp-handler, plus a client helper that pays 402 challenges automatically. |
| crossmint-agent-wallets | Smart-contract wallets for agents with an owner key and a scoped agent signer, paying x402 endpoints in USDC on Base. |
| stripe-machine-payments | Stripe's machine payments let businesses accept agent payments over MPP (cards and stablecoins) and x402 (USDC), settling to a Stripe account. |
| lightning-labs-lnget | Command-line HTTP client that pays L402 invoices automatically and caches the token, backed by lnd, Lightning Node Connect or an embedded wallet. |
| lightning-labs-aperture | Lightning Labs' open-source HTTP 402 reverse proxy that puts L402 — and optionally MPP — payment checks in front of HTTP and gRPC backends. |
| fewsats-l402 | Hosted L402 payment platform with an MCP server that lets agents check balances and pay L402 offers through an API key. |
TDQS
Scored across 7 tools
Each tool targets a distinct action within the HTTP 402 workflow: decoding a challenge, probing a URL, fetching protocol reference, searching the registry, getting a specific solution, getting the top-ranked solution, and recommending by requirements. The solution-retrieval tools are differentiated by input and purpose, so an agent can select appropriately.
All seven names use snake_case with a clear verb_noun pattern (decode_402_challenge, get_solution, search_402_solutions, etc.). The numeric token 402 is consistently placed, making the set predictable.
Seven tools is well within the ideal 3-15 range for a focused decision-support server. Each tool has a clear role in the 402 workflow, with no redundant or filler entries.
The surface covers challenge decoding, probing, scheme reference, solution search, top-solution retrieval, targeted recommendation, and detailed solution retrieval, which is strong coverage for decision support. Minor gaps remain around payment execution, receipt or credential verification after payment, and registry mutation, but these may be intentionally out of scope.