API basics
Plans and credits
Agent runs spend credits from the key owner's plan. When they run out, runs return 402; see Errors.
| Method | URL | Returns | Auth |
|---|---|---|---|
GET | /api/v1/billing/subscription/ | The owner's plan: tier_slug, tier_name, status, expires_at, and quotas with limit, used and blocked per metric | Key or bearer |
GET | /api/v1/billing/plans/ | The plans on sale: slug, name, audience (personal or organization), credits, unit_amount in cents, currency, interval | Key or bearer |
GET /api/v1/billing/plans/exists only where self-serve billing is on; elsewhere it returns404.- Buying a plan, changing seats and billing details need a signed-in user in the web app.
curl "$CENTRAL_HUB_URL/api/v1/billing/subscription/" \
-H "X-API-Key: $ALO_API_KEY" \
-H "X-Space-Slug: $WORKSPACE_SLUG"{
"tier_slug": "free_trial",
"tier_name": "Free trial",
"status": "active",
"expires_at": "2026-10-27T13:56:02.968809Z",
"quotas": [{"scope": "total", "metric": "credits", "limit": "2000.0000", "used": "0", "blocked": false}]
}