Why x402r?
Standard x402 payments are immediate and irreversible. x402r adds:- Escrow deposits — Funds held in smart contracts until conditions are met
- Refund windows — Configurable time periods for buyers to request refunds
- Dispute resolution — Arbiter system for handling contested transactions
How It Works
Who Is This For?
Clients (Payers)
Request refunds, freeze suspicious payments, and track payment state.
Merchants (Receivers)
Release funds, process refunds, and manage escrow periods.
Arbiters
Resolve disputes and approve/deny refund requests.
Get Started
Protocol Overview
Understand how x402r extends the x402 protocol.
Smart Contracts
Explore the escrow and payment operator contracts.
SDK Quickstart
Start building with the TypeScript SDK.
Deploy an Operator
Deploy your own PaymentOperator on Base.
Architecture
x402r consists of these core components:| Component | Purpose |
|---|---|
| PaymentOperator | Manages payment authorization, release, charge, and refunds with pluggable conditions |
| AuthCaptureEscrow | Holds ERC-20 tokens during the payment lifecycle (from commerce-payments) |
| Conditions & Recorders | Pluggable authorization checks (before action) and state updates (after action) |
| EscrowPeriod & Freeze | Time-based release and freeze policies for buyer protection |
| RefundRequest | Handles refund request lifecycle and approvals |
Supported Networks
| Network | Chain ID | Status |
|---|---|---|
| Base | 8453 | Supported |
| Ethereum | 1 | Supported |
| Polygon | 137 | Supported |
| Arbitrum One | 42161 | Supported |
| Optimism | 10 | Supported |
| Celo | 42220 | Supported |
| Avalanche C-Chain | 43114 | Supported |
| Monad | 143 | Supported |
| Linea | 59144 | Supported |
| Base Sepolia | 84532 | Testnet |
| Ethereum Sepolia | 11155111 | Testnet |
Resources
GitHub
Source code and examples.
SDK Reference
SDK documentation and API reference.
Support
Get help with integration.
