Which method do I need?
| I want to… | Method |
|---|
| Use API keys to call providers | Stripe top-up (credits) |
| Give my agent its own autonomous wallet | On-chain USDC deposit (X402) |
Most developers use Stripe top-up — it’s the fastest way to get started. No crypto wallet required.
Method 1: Stripe Top-Up (Recommended)
Fund your account with USD using any major credit/debit card, Apple Pay, Google Pay, or Link. Credits are added within seconds.
Minimum: $5 · Accepted: Visa, Mastercard, Amex, Apple Pay, Google Pay, Link
From the Dashboard
- Go to app.acn.exchange and sign in
- Navigate to Billing in the sidebar
- Select a preset amount or enter a custom amount (minimum $5)
- Click Add Credits — you’ll be redirected to Stripe Checkout
- Complete payment and return to the dashboard
- Your balance updates automatically within a few seconds
Via the API
# Step 1: Create a Stripe Checkout session
curl -X POST https://api.acn.exchange/v1/billing/checkout \
-H "Authorization: Bearer acn_sk_your_key" \
-H "Content-Type: application/json" \
-d '{
"amountUsdCents": 1000,
"successUrl": "https://yourapp.com/billing?status=success",
"cancelUrl": "https://yourapp.com/billing?status=cancelled"
}'
{
"checkoutUrl": "https://checkout.stripe.com/c/pay/cs_live_...",
"sessionId": "cs_live_...",
"creditsToReceive": "10000000"
}
Redirect your user to checkoutUrl. After payment, Stripe redirects them back to successUrl.
Checking Your Balance After Top-Up
curl https://api.acn.exchange/v1/billing/balance \
-H "Authorization: Bearer acn_sk_your_key"
{
"balanceCredits": "10000000",
"balanceUsdc": "10.000000",
"dailySpentCredits": "0",
"dailySpentUsdc": "0.000000"
}
Credit conversion: 1 USD = 1,000,000 credits = 1 USDC equivalent. Credits never expire and balances carry over indefinitely.
Method 2: On-Chain USDC Deposit (Agent Wallets / X402)
Use this if you’re setting up an agent with its own wallet to pay for calls autonomously via the X402 protocol.
If you’re using API keys to make calls, you don’t need this. Use Stripe top-up instead.
Prerequisites
- USDC on Base (Ethereum L2)
- A wallet with the USDC (MetaMask, Coinbase Wallet, or programmatic wallet)
Getting USDC on Base
| Method | Best For |
|---|
| Bridge from Ethereum | Moving existing USDC from Ethereum mainnet |
| Exchange withdrawal | Buying USDC and withdrawing directly to Base |
| Base Sepolia faucet | Testing on devnet |
Depositing
- Go to app.acn.exchange
- Navigate to Wallet → Deposit
- Copy the ACN platform wallet address shown
- Send USDC to that address on the Base network
- Submit the transaction hash to confirm:
curl -X POST https://api.acn.exchange/v1/wallet/deposit \
-H "Authorization: Bearer acn_sk_your_key" \
-H "Content-Type: application/json" \
-d '{
"tx_hash": "0xYourTransactionHash"
}'
{
"deposit_id": "dep_abc123",
"amount_usdc": "10.00",
"status": "confirmed",
"new_balance_usdc": "10.00"
}
Always send on the Base network. Sending on Ethereum mainnet or other chains will result in lost funds.
For Fully Autonomous Agents
Agents can deposit and manage their own balance without human intervention. See Equip an Agent with a Wallet for setup with the ACN CLI and AgentKit.
Viewing Transaction History
Credits (Stripe / API key path)
curl "https://api.acn.exchange/v1/billing/transactions?limit=20" \
-H "Authorization: Bearer acn_sk_your_key"
{
"transactions": [
{
"id": "txn_abc123",
"type": "deposit",
"amountCredits": "10000000",
"amountUsdc": "10.000000",
"description": "Credit top-up: $10.00",
"createdAt": "2026-03-19T10:00:00Z"
},
{
"id": "txn_abc124",
"type": "debit",
"amountCredits": "-2000",
"amountUsdc": "-0.002000",
"description": "API call: text-summarizer",
"createdAt": "2026-03-19T10:05:00Z"
}
],
"pagination": { "page": 1, "limit": 20, "total": 2 }
}
On-chain wallet history
curl "https://api.acn.exchange/v1/wallet/history?limit=10" \
-H "Authorization: Bearer acn_sk_your_key"
Low Balance
When your credit balance is too low to cover a call, you’ll get a clear error:
{
"statusCode": 402,
"code": "ACN-CREDIT-001",
"error": "Insufficient Credits",
"details": {
"requiredCredits": "2000",
"currentBalance": "500",
"priceUsdc": "0.002000",
"topUpUrl": "https://app.acn.com/billing"
}
}
You can set up email alerts before this happens — see Notifications & Alerts.