Ecosystem

Where MPP fits in
the Web3 SDLC.

HTTP 402 is a protocol. Solana is the settlement rail. mpp-test-sdk is the developer interface. Understanding all three layers is how you build production-ready pay-per-request systems.

L0·Protocol

HTTP 402 - the forgotten standard

HTTP 402 Payment Required has existed in the spec since RFC 2616 (1999). It was reserved for a future where machines could pay machines. That future arrived with programmable blockchains. MPP implements the protocol as it was always intended: stateless, RESTful, and composable.

MPP Role

MPP Test Kit defines and implements the header schema, making HTTP 402 concrete for the first time.

Specifications
Status Code
402 Payment Required
Request Header
Payment-Request: solana; amount=…; recipient=…; network=…
Receipt Header
Payment-Receipt: solana; signature=…; network=…
Standard
RFC 7231 compatible
Transport
Pure HTTP - no WebSocket, no streaming
Architecture

The full stack, visualized

Five layers from foundation to application - click any layer to explore it.

Players

Who's in the ecosystem

The full HTTP 402 ecosystem is multi-stakeholder. Here's how each participant fits.

Protocol Authors
MPP Test Kit

Define the HTTP 402 header schema and reference implementation

Blockchain Layer
Solana Foundation

Fast, cheap settlement + devnet/testnet infrastructure

API Providers
Any developer

Add mpp.charge() to any Express route - instant monetization

API Consumers
AI agents, scripts, services

Call mppFetch() - payment handled invisibly

Infrastructure
Solana RPC providers

QuickNode, Helius, public endpoints - pluggable

Tooling
Test runners, CI systems

Real on-chain tests at zero cost on devnet

Comparison

HTTP 402 vs. traditional API billing

This is not a marginal improvement. It is a different model entirely.

Aspect
Traditional billing
HTTP 402 + Solana
Billing setup
Stripe account, webhook endpoint, subscription tiers, dunning logic
Zero - server wallet auto-generated on createTestServer()
Client auth
API key stored in env vars, rotation schedule, key leakage risk
Ephemeral keypair per session - no stored secrets
Payment granularity
Monthly subscriptions or prepaid credit bundles
Per-request - pay exactly for what you use
Settlement time
T+1 to T+3 days (card networks)
~800ms (Solana finality)
Testing
Mocked Stripe webhooks - production surprises
Real on-chain transactions on devnet - free, <3s
Machine-to-machine
Not designed for it - requires human billing relationship
Native - designed for autonomous agent workflows
Positioning

Where MPP Test Kit sits in your SDLC

Development
  • mppFetch() replaces fetch - zero refactor
  • createTestServer() on localhost
  • Devnet faucet airdrops are instant + free
  • onStep callbacks for full visibility
Testing / CI
  • Real on-chain tests in GitHub Actions
  • Devnet = $0 per test run
  • No mocked payment paths - real receipts
  • Vitest / Jest compatible
Production
  • network: "mainnet" - one config change
  • Bring your own funded keypair
  • Same SDK, same middleware
  • Real SOL settlements, real receipts
Start Building

The infrastructure is ready. You just need to ship.

The protocol is defined. The SDK is published. The blockchain is live. Everything you need to build pay-per-request APIs is already here.

npm i mpp-test-sdk