Skip to content
OpenRelay is in early access, and the /v1 API is stable. New capabilities ship in the changelog.
Skip to Content
API ReferenceBilling and usageUsage

Get current-month usage

Returns the cents and hours used so far this month by GPU model and tier, plus the live burn per hour and the projected hours until the auto-stop floor.

Required permission

Requires the usage.read permission. See Permissions for the roles and API key permissions that include it.

Command line

The orl CLI wraps this endpoint:

Guided workflow: orl balance

orl balance
orl usage current get
GET
/v1/orgs/{orgId}/usage/current

Authorization

apiKey
headerAuthorizationBearer <token>

OpenRelay API key. Send it as Authorization: Bearer or_… (legacy vl_… keys still work).

Path Parameters

orgId*string

Response Body

OK

application/json
  1. response
usageCents*integer
usageHours*number
breakdown*array<>
burnPerHourCents?integer

sum of the locked rates of every open usage record in the org (live burn per hour)

projectedRunwayHours?number

hours until available balance hits the auto-stop floor at the current burn: (available - autoStopFloorCents) / burnPerHourCents; null when burn is 0 or the organization is balance-exempt (it is never auto-stopped), clamped to 0 when already at or below the floor

Formatdouble
autoStopFloorCents?integer

available-balance floor (cents) below which the org is auto-stopped

Example Request
curl -X GET 'https://api.openrelay.inc/v1/orgs/string/usage/current'
Example Response
{  "usageCents": 0,  "usageHours": 0,  "breakdown": [    {      "key": "string",      "hours": 0,      "cents": 0    }  ],  "burnPerHourCents": 0,  "projectedRunwayHours": 0.1,  "autoStopFloorCents": 0}