Gas Pools
A gas pool holds USDC that agents spend on payments. The pool is linked to an API key and tracks balance, daily cap, and status ( healthy, low, critical, empty).
Create
POST/gas-poolJWT
| Field | Type | |
|---|---|---|
| apiKeyId | string (uuid) | required |
| dailyCapCents | integer | required — 0 = no cap |
| alertThresholdUsdc | string (integer) | required — microUSDC string |
POST /gas-pool
{
"apiKeyId": "uuid",
"dailyCapCents": 10000,
"alertThresholdUsdc": "5000000"
}Balance
GET/gas-pool/:apiKeyId/balanceJWT
{
"id": "uuid",
"balanceUsdc": "50000000",
"status": "healthy",
"dailyCapCents": 10000
}Top Up
Send USDC on-chain to the PaymentProcessor address first, then record the txnId here to credit the pool.
POST/gas-pool/:apiKeyId/topupJWT
| Field | Type | |
|---|---|---|
| amountUsdc | string (integer) | required |
| txnId | string | required — Algorand txn ID |
PATCH/gas-pool/:apiKeyId/settingsJWT
| Field | Type | |
|---|---|---|
| dailyCapCents | integer | optional |
| alertThresholdUsdc | string (integer) | optional |