Payments
Execute on-chain payments from your Axiomatic smart wallet — pay bills, send transfers, and track payment intents.
Overview
The Payments module lets you execute on-chain token transfers directly from your entity's Axiomatic smart wallet. Payments are submitted as ERC-4337 UserOperations, with gas fees sponsored by the Axiomatic paymaster — no ETH balance required.
Smart Wallet Architecture
Each entity in Axiomatic has a smart contract wallet deployed on-chain using the Diamond pattern (EIP-2535). The wallet is managed server-side — the platform constructs UserOperations, a paymaster sponsors gas, and a bundler submits the transaction to the network.
sequenceDiagram
participant User
participant PayPage as /pay Page
participant API as /api/pay/execute
participant Bundler
participant Paymaster
participant Wallet as Entity Smart Wallet
participant Token as ERC-20 Contract
User->>PayPage: Confirm payment details
PayPage->>API: POST (entityId, token, amount, recipient)
API->>API: Build UserOp calldata
API->>Bundler: eth_sendUserOperation
Bundler->>Paymaster: Validate + sponsor gas
Bundler->>Wallet: Execute UserOp
Wallet->>Token: transfer(recipient, amount)
API-->>PayPage: userOpHash
PayPage-->>User: Transaction submittedPayment Types
The platform supports several payment intent types:
| Type | Description |
|---|---|
AP_PAYMENT | Pay a vendor bill |
AR_COLLECTION | Collect payment on an invoice |
DISTRIBUTION | Distribute to investors or stakeholders |
CAPITAL_CALL | Request and collect capital |
TRANSFER | Freeform token transfer |
Payment Intent Lifecycle
Payment intents track the full lifecycle of an on-chain payment:
stateDiagram-v2
[*] --> PENDING: Intent created
PENDING --> SUBMITTED: UserOp sent to bundler
SUBMITTED --> CONFIRMED: Transaction mined
SUBMITTED --> FAILED: Transaction reverted
PENDING --> EXPIRED: TTL exceeded (24h)Using the Pay Page
Entry Points
The /pay page can be accessed in three ways:
| URL | Behavior |
|---|---|
/pay | Opens the payment type selector |
/pay?intent=<id> | Loads a payment intent and skips to confirmation |
/pay?bill=<id> | Pre-selects a bill and skips to confirmation |
Three-Step Flow
Step 1 — Select payment type:
- Pay a bill — choose from open bills with
payCryptoenabled - Upload a bill — upload a received invoice and enter vendor details
- Send a transfer — enter recipient address, amount, token, and chain
Step 2 — Confirm details:
Review recipient, amount, token, chain, and gas sponsorship before submitting.
Step 3 — Execute:
The payment is submitted to the bundler. You receive a UserOp hash for tracking.
From the AP Page
When you click Pay on a bill in the Payables page, it creates a payment intent and navigates to /pay?intent=<id>. The Pay page loads the intent details and presents the confirmation step.
Supported Tokens
| Chain | Token | Address |
|---|---|---|
| Base | USDC | 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 |
| Base | ETH | Native |
| Base Sepolia | USDC | 0x036CbD53842c5426634e7929541eC2318f3dCF7e |
| Base Sepolia | ETH | Native |
API Reference
Execute Payment
POST /api/pay/executeExecute a token transfer from the entity's smart wallet.
Request body:
{
"entityId": "uuid",
"token": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
"amount": "1000000",
"recipient": "0x...",
"chain": "base",
"paymentIntentId": "uuid (optional)"
}amountis in the token's smallest unit (e.g. 1 USDC =1000000with 6 decimals)tokenset to0x0000000000000000000000000000000000000000for native ETHpaymentIntentIdlinks the payment to an existing intent and updates its status
Response:
{
"success": true,
"userOpHash": "0x...",
"chain": "base",
"from": "0x...",
"to": "0x...",
"token": "0x...",
"amount": "1000000"
}Error codes:
| Status | Meaning |
|---|---|
| 400 | Missing fields, invalid intent status, or bundler rejection |
| 401 | Unauthorized |
| 404 | Payment intent not found |
| 409 | Intent already submitted/confirmed |
| 502 | Bundler submission failed |
| 503 | Wallet or bundler not configured for chain |
Payment Intents
GET /api/payment-intents?entityId=<uuid>
POST /api/payment-intents
PATCH /api/payment-intentsSee the AR & AP documentation for the full payment intent API.