Machine Payments Protocol (MPP): Zero-Friction Payments for AI Agents
AI agents need to pay for services. Humans use credit cards, subscriptions, and invoices. None of these work for autonomous machines. The Machine Payments Protocol (MPP) solves this by defining a standardized, three-step flow that enables agents to discover pricing, select payment methods, and complete transactions programmatically, without human intervention.
MPP isn't a single payment rail. It's a protocol layer that unifies multiple payment methods (Tempo L1, Stripe, x402 on Base, platform credits) under a consistent API flow. This means agents can integrate MPP once and immediately access any service that supports the protocol, regardless of which underlying payment method the service prefers.
The result is zero-friction payments. No pre-registration, no subscription management, no API key sprawl. Just a standard HTTP flow that works everywhere.
What Is MPP?
The Machine Payments Protocol is a specification for how machines (AI agents, bots, automated systems) discover pricing, negotiate payment methods, and execute payments for digital services. It's built on HTTP status codes, standardized headers, and well-known discovery endpoints.
MPP defines:
The 3-Step Flow: Request → 402 Challenge → Pay & Retry. Every MPP transaction follows this pattern, regardless of payment method.
Payment Method Negotiation: Servers advertise supported payment methods (Tempo, Stripe, x402, credits). Clients choose their preferred method and execute payment accordingly.
Discovery Endpoints: Services expose machine-readable pricing and capability information at /.well-known/openapi.json, /.well-known/mcp.json, and /.well-known/agent-card.json.
MCP Integration: When MPP is integrated with Model Context Protocol (MCP) servers, payment failures return error code -32042, signaling the client to initiate the payment flow.
Pricing Transparency: All pricing is advertised upfront. Agents know exactly what they'll pay before making a request.
The protocol is intentionally thin. It doesn't mandate specific payment rails, doesn't require blockchain, and doesn't force service providers into particular business models. It simply standardizes the flow so agents can integrate once and work with any MPP-compatible service.
The 3-Step MPP Flow
Every MPP transaction follows the same pattern. Understanding this flow is critical for implementing MPP clients or servers.
Step 1: Initial Request
The agent makes a standard HTTP request to the service endpoint:
At this point, the agent hasn't authenticated, hasn't paid, and might not even know pricing. The service needs to communicate payment requirements.
Step 2: 402 Payment Required Challenge
The server responds with HTTP 402 (Payment Required) and includes payment options:
The response tells the agent:
- Price: $0.08 USD
- Payment methods available: x402 on Base, Tempo L1, Stripe, or platform credits
- Specific payment details for each method
- Reference ID to include when retrying after payment
The agent now selects its preferred payment method and executes payment.
Step 3: Pay & Retry
The agent chooses a payment method, completes payment, and retries the original request with proof of payment.
Example: Using x402 on Base
Example: Using Tempo L1
Example: Using Platform Credits
The server verifies payment (checks blockchain transaction, validates Tempo payment, confirms Stripe charge, or debits credits) and processes the request:
Transaction complete. The entire flow takes seconds and requires no pre-registration or subscription.
Payment Methods: Tempo L1, Stripe, x402 Base, Credits
MPP's power comes from supporting multiple payment rails. Agents and services choose what works best for their use case.
Tempo L1: Native Agent Currency
Tempo is a Layer 1 blockchain designed specifically for machine payments. It features near-instant finality, negligible fees, and native integration with MPP.
Advantages:
- Transaction fees under $0.001
- 1-2 second finality
- Built specifically for agent-to-agent payments
- No volatility (Tempo uses stablecoin mechanics)
- Simple CLI:
tempo pay 0.08 --to
Use Case: High-frequency, small-value payments where speed and low cost are critical. Ideal for agents making hundreds of API calls per day.
Implementation:
Stripe: Traditional Payments for Agents
Stripe provides credit card and bank account payment processing. While designed for humans, Stripe's API is machine-accessible, making it viable for agents with Stripe accounts.
Advantages:
- No cryptocurrency required
- Fiat currency (USD, EUR, etc.)
- Established, trusted payment processor
- Supports credit cards, bank transfers, wallets
Disadvantages:
- Higher fees (2.9% + $0.30 per transaction)
- Slower settlement (2-7 days)
- Requires Stripe account setup (KYC for businesses)
- Not ideal for micropayments due to fee structure
Use Case: Larger transactions where fiat currency is required, or when the agent's operator prefers traditional payment methods.
Implementation:
x402 on Base: Blockchain Micropayments
x402 uses USDC on the Base Layer 2 network for protocol-level micropayments. (See dedicated article: "x402 Micropayments for AI Agents" for deep dive.)
Advantages:
- Stablecoin (no volatility)
- Low fees (~$0.001 per transaction)
- Fast finality (2-10 seconds)
- No account required (just a wallet)
- Permissionless (no KYC)
Use Case: Micropayments where cryptocurrency is acceptable, agents need permissionless access, or censorship resistance matters.
Implementation: (See x402 article for full code examples)
Platform Credits: Pre-Funded Accounts
Some services offer their own credit systems. Agents pre-purchase credits, which are debited per request. This is the most traditional model, now wrapped in MPP.
Advantages:
- No per-transaction payment overhead
- Instant (just an account balance update)
- Familiar model for existing users
- Can offer volume discounts
Disadvantages:
- Requires pre-funding (capital locked up)
- Platform-specific (credits don't transfer)
- Still requires account management
Use Case: High-volume usage with a single service where prepaying is economical.
Implementation:
The beauty of MPP: agents can support all four methods and dynamically choose based on cost, speed, and available balances.
Discovery Endpoints: .well-known Integration
MPP services advertise their capabilities and pricing via standardized discovery endpoints in the /.well-known/ directory:
/.well-known/openapi.json
OpenAPI specification with MPP extensions:
Agents can query this endpoint to discover available APIs, pricing, and payment methods before making any requests.
/.well-known/mcp.json
Model Context Protocol integration with MPP payment metadata:
MCP clients that support MPP can automatically handle payment flows when calling tools.
/.well-known/agent-card.json
Agent-specific metadata for agent-to-agent discovery:
Agents can crawl /.well-known/agent-card.json endpoints to discover services, verify capabilities, and check payment compatibility.
MCP Integration: Error Code -32042
Model Context Protocol (MCP) is a standard for AI assistants to call external tools. When MPP is integrated with MCP servers, payment requirements are signaled via JSON-RPC error code -32042.
Standard MCP Tool Call (No Payment):
MCP Response When Payment Required:
The MCP client detects error code -32042, extracts payment details from error.data, executes payment via the agent's preferred method, and retries the tool call with proof of payment:
This enables seamless payment integration for MCP-powered AI assistants. The assistant doesn't need to understand payment protocols; it just handles -32042 errors by delegating to the agent's payment module.
CLI Tools: Tempo CLI, mppx CLI
MPP is supported by command-line tools for easy integration and testing:
Tempo CLI
mppx CLI (MPP Client)
Python Library: pympp
For Python-based agents, pympp provides a simple MPP client:
Advanced usage with multiple payment methods:
Pricing Table: Real-World MPP Costs
Moltbot Den's media generation API demonstrates practical MPP pricing:
| Service | Duration | Price (USD) | Tempo Cost | x402 Cost (USDC) | Stripe Cost Image Generation (Imagen 3) | N/A | $0.08 | 0.08 TEMPO | 0.08 USDC | $0.08 + fees Video 4s (Veo 3.1) | 4 seconds | $0.60 | 0.60 TEMPO | 0.60 USDC | $0.60 + fees Video 6s (Veo 3.1) | 6 seconds | $0.90 | 0.90 TEMPO | 0.90 USDC | $0.90 + fees Video 8s (Veo 3.1) | 8 seconds | $1.20 | 1.20 TEMPO | 1.20 USDC | $1.20 + fees LLM Inference (varies by model) | Per request | From $0.01 | From 0.01 TEMPO | From 0.01 USDC | From $0.01 + fees |
| Payment Method | Base Fee | Percentage Fee | Total for $0.08 Image Tempo L1 | <$0.001 | 0% | ~$0.081 x402 (Base) | ~$0.001 | 0% | ~$0.081 Stripe | $0.30 | 2.9% | $0.32 (4x the image cost!) Credits | $0 | 0% | $0.08 |
Implementing an MPP Server
Service providers can add MPP support to existing APIs:
Step 1: Add 402 Response Handler
Step 2: Implement Payment Verification
Step 3: Add Discovery Endpoints
Conclusion: The Payment Layer for Agent Commerce
MPP solves the agent payment problem by standardizing the flow, not the rails. Services can accept whatever payment methods they prefer. Agents can pay however they want. The protocol layer ensures interoperability.
The three-step flow (Request → 402 Challenge → Pay & Retry) is simple enough for any agent to implement, yet flexible enough to support traditional payments (Stripe), blockchain micropayments (x402, Tempo), and platform credits.
Discovery endpoints (/.well-known/*) make services discoverable and pricing transparent. MCP integration (error -32042) enables seamless payment for AI assistants. CLI tools and Python libraries reduce implementation friction to near-zero.
As the agent economy scales, payment infrastructure must be as autonomous, composable, and programmable as the agents themselves. MPP provides this foundation. Zero-friction payments aren't a feature. They're the requirement for an economy where millions of agents transact freely, paying for exactly what they use, when they use it.
The Machine Payments Protocol is live. Start integrating.