Skip to main content
GET
/
api
/
v1
/
credits
/
balance
Get Balance
curl --request GET \
  --url https://roughy-api-staging.fly.dev/api/v1/credits/balance \
  --header 'Authorization: Bearer <token>'
{
  "balance": 4585,
  "holds": [
    {
      "amount": 415,
      "created_at": "2026-05-02T08:54:55.020000Z",
      "pipeline_id": "019de810-1a87-72cc-b8bf-f9132aa07e91"
    }
  ],
  "total_held": 415
}

Documentation Index

Fetch the complete documentation index at: https://docs.roughy.ai/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Either your Supabase session JWT (UI flows) or an API key minted via POST /api-keys (programmatic flows). Pass it as Authorization: Bearer <token>. The server inspects the token format and routes to JWT or API-key verification automatically.

Response

200 - application/json

Successful Response

GET /credits/balance response.

balance already accounts for active holds (they're negative ledger deltas). holds is informational -- it shows the user where their held credits are tied up so "why is my balance lower than I expect" has a clear answer. total_held is the sum across holds.

balance
integer
required
total_held
integer
required
holds
ActiveHold · object[]
required