Agentic Payments with FX402
FX402 was designed with autonomous agents and AI services in mind.
Agents can rent access to APIs, datasets, or models using x402-compatible microtransactions — no UI required.
🤖 1. Concept
In an agent-to-agent economy, bots can:
- Discover resources via metadata
- Parse
402 Payment Requiredresponses - Automatically pay for short-term access
- Cache receipts for re-use
This enables machine-level commerce — dynamic, automated, and verifiable.
⚙️ 2. Agent Flow
| Step | Action |
|---|---|
| 1️⃣ | Agent requests data from API |
| 2️⃣ | Receives R402 payload (pricing, tiers) |
| 3️⃣ | Selects optimal tier automatically |
| 4️⃣ | Pays and submits proof |
| 5️⃣ | Receives JWT receipt and continues ops |
🧩 3. Example: Agent R402 Request
{
"agent": "bot:market-analyzer",
"action": "fetch-market-data",
"r402": {
"tiers": [
{ "id": "hour", "price": "0.01", "currency": "USDC" },
{ "id": "day", "price": "0.05", "currency": "USDC" }
],
"modes": ["read"]
}
}The agent can automatically select the cheapest tier for its operation window.
🔒 4. Rate Limits & Fairness
Facilitators can enforce agent-level rate limits such as:
- Requests per second
- Receipt reuse detection
- Blacklisting expired receipts
Agents can also implement caching policies for efficient micro-purchases.
💡 5. Example Use Cases
| Agent | Purpose |
|---|---|
| Data Crawlers | Rent access to premium APIs temporarily |
| AI Models | Pay for inference windows (e.g., 1h access to weights) |
| Indexers | Stream data from blockchain providers under hourly plans |
| Automation Bots | Rent digital collectibles for short campaigns |
🧭 6. Key Design Principles
- Payments remain honor-system unless facilitator enforced.
- No blockchain RPC calls needed — pure HTTP flow.
- Works with Solana USDC, but can extend to Base or ETH.
📚 Next Steps
Last updated on