Skip to content

Credits, usage and prices

GET /v1/credits

Team-wide credentials return the team balance and recent ledger:

{
"balance_micro": 366800000,
"balance": 366.8,
"granted_micro": 500000000,
"spent_last_24h_micro": 0,
"my_spent_30d_micro": 48210000,
"next_expiry": { "expires_at": 1809638400, "amount_micro": 366800000 },
"ledger": [
{ "id": "led_…", "kind": "grant", "amount_micro": 500000000, "note": "Opening credits", "created_at": 1794000000, "expires_at": 1809638400, "remaining_micro": 366800000 }
]
}
  • granted_micro: total non-usage credits added to the balance (net of adjustments and expiries).
  • my_spent_30d_micro: the caller’s posted Box usage over the last 30 days in micro-credits; included only for signed-in user sessions (via: "session") and omitted for team-wide API keys.
  • next_expiry: the next expiry date (Unix seconds, UTC) and the unused amount expiring on that UTC day; null if no unused credits have an expiry date.
  • ledger: recent non-usage entries (grant, adjustment, and expiry). Grants include expires_at (null for permanent credits) and remaining_micro. Other entries have remaining_micro: null. An expired grant has zero spendable remaining credits. Positive expiry entries correct an earlier expiry when pre-expiry usage is reported late.
  • balance_micro excludes expired funds immediately, even before the expiry entry is posted.

A project-scoped API key returns only its project ID and 24-hour spend:

{ "project_id": "prj_…", "spent_last_24h_micro": 127500 }
GET /v1/usage?days=30&group_by=day
Query Default Meaning
days 30 Lookback window (1 to 366)
group_by day day (UTC YYYY-MM-DD), sku (resource), or project
project all Filter to one project by slug

A project-scoped key sees only its own project’s usage across all grouping options. With group_by=project, archived projects include "archived": true.

{
"from": 1792108800,
"to": 1794700800,
"group_by": "day",
"total_micro": 133200000,
"items": [
{ "key": "2026-11-14", "seconds": 7200, "cost_micro": 7440000 }
]
}

seconds is Box running time and may be fractional (for example, 1.25). cost_micro is the posted charge in integer micro-credits. Under group_by=sku, a GPU Box’s full cost (including vCPUs, memory, and disk) is reported under its GPU SKU.

GET /v1/prices

Add optional ?project=<slug> to query GPU availability for a specific project (defaults to the key’s bound project, or default; unknown slugs return 404 not_found).

{
"currency": "USD",
"credits_per_usd": 1,
"items": [
{ "sku": "vcpu", "kind": "compute", "label": "vCPU", "unit": "vCPU", "micro_per_hour": 50000 },
{ "sku": "gpu.rtx5090", "kind": "gpu", "label": "Nvidia RTX 5090", "unit": "GPU", "micro_per_hour": 1490000, "availability": "mid" }
]
}

For GPU SKUs, availability indicates free capacity right now: low (under 30% free), mid (30%–70%), high (over 70%), or null when unknown. To request a GPU, pass the suffix after gpu. as the model name.