Skip to main content
ARouter supports the x402 payment protocol, the open standard for HTTP-native payments. AI agents with crypto wallets can authenticate, pay for credits, and make LLM requests — all without registering an account or logging into a dashboard.

Three Entry Points

ARouter provides three ways for agents to get started. API key users and wallet users now follow separate long-term paths:
Standard x402 mode works with any x402-compatible tool@x402/fetch, awal, MCP wallets, Chrome extensions. No ARouter SDK required.

How It Works

Standard x402 (Any x402 Client)

The simplest entry point. Any wallet with USDC can make LLM requests immediately:
  1. Send a request with no API key — the gateway returns HTTP 402 with payment options.
  2. The x402 client signs a USDC payment (gasless via EIP-3009).
  3. Retry the request with the PAYMENT-SIGNATURE header.
  4. The gateway verifies, settles, creates your account, and returns the response.
  5. The PAYMENT-RESPONSE header contains a jwt extension for future wallet-authenticated requests.

SIWx Authentication (Wallet Sign-In)

Prove wallet ownership to get a wallet JWT without paying first: SIWx follows the CAIP-122 standard — the same protocol used by QuickNode and other x402-enabled services.

API Key Users

Existing API key users continue to use the standard ARouter API key flow:

Supported Networks

Wallet Compatibility

All wallets work — no private key export required:

SDK Usage

Standard x402 (No ARouter SDK Needed)

Use Coinbase’s official @x402/fetch directly:

SIWx Authentication (Get Wallet JWT)

Node.js SDK

Go SDK

Go SDK — EVM (Base)

WithX402CoinbasePayment sets up wallet x402 payment with JWT caching:
  • first successful payment returns a wallet JWT inside PAYMENT-RESPONSE
  • subsequent requests use Bearer <jwt>
  • 401 triggers SIWx re-authentication
  • 402 triggers x402 payment

Go SDK — Solana

Node.js SDK — EVM (Base)

Node.js SDK — Dual-Chain (EVM + Solana)

GET Endpoint for CLI Tools

For x402 CLI tools like awal that cannot send POST bodies:

Payment Headers

How Credits Work

  • x402 payments are deposited as credits into your tenant balance — the same pool used by Stripe and Helio payments.
  • All x402 transactions appear in the Billing page under transaction history with the x402_topup reference type.
  • The gateway deducts credits per-request as usual after the balance is topped up.
  • Wallet users are billed by tenant, authenticated by wallet JWT, and can re-authenticate via SIWx without exposing raw API keys.

Security

  • Standard x402 protocol: Uses Coinbase’s official x402 SDK for verification and settlement.
  • Facilitator verification: Payments are cryptographically verified via the x402 Facilitator before credits are granted.
  • Gasless payments: EIP-3009 (TransferWithAuthorization) — users sign, the Facilitator submits on-chain.
  • Amount cap: Single payments are capped to prevent unexpectedly large charges.
  • Idempotency: Each payment payload has a unique nonce — the same signature cannot be replayed.
  • SIWx standard: Authentication follows CAIP-122 with EIP-4361 (EVM) and SIWS (Solana) message formats.
  • Audit trail: All x402 top-ups are recorded in transaction history alongside Stripe/Helio payments.
  • Non-custodial: USDC goes directly to the receiving wallet. The Facilitator never holds funds.