TokenLab

Management

Get Workspace Balance

Get the balance, top-ups, and usage spend for the current Workspace.

GEThttps://api.tokenlab.sh/v1/management/balance

Overview

Return the balance, total top-ups, and total usage spend for the Workspace associated with the management token.

Notes

  • Monetary fields are USD-only.

  • Amounts are returned in USD. Use balance_decimal, total_recharge_decimal, and total_used_decimal for exact calculations.

Example

Request

cURL
curl -X GET "https://api.tokenlab.sh/v1/management/balance" \
  -H "Authorization: Bearer mt-your-management-token"

Request / Response

This page provides the OpenAPI schema and copyable request examples. Send management requests from your terminal or client with a Management Token; direct sending is not available on this page.

Response example

Response

200 OK
{
  "object": "organization_balance",
  "organization_id": "org_123",
  "balance": 42.5,
  "balance_decimal": "42.50",
  "total_recharge": 100,
  "total_recharge_decimal": "100",
  "total_used": 57.5,
  "total_used_decimal": "57.50"
}

Important fields

objectstring
Always organization_balance.
organization_idstring
Organization associated with the current management token.
balancenumber
Current organization balance in USD as a JSON number for display.
balance_decimalstring
Exact current organization balance in USD as a decimal string for reconciliation.
total_rechargenumber
Total successful organization recharge amount in USD as a JSON number for display.
total_recharge_decimalstring
Exact total successful organization recharge amount in USD as a decimal string for reconciliation.
total_usednumber
Total organization usage spend in USD as a JSON number for display.
total_used_decimalstring
Exact total organization usage spend in USD as a decimal string for reconciliation.

Authorization

ManagementTokenAuth
AuthorizationBearer <token>

Management token authentication. Create or manage Management Tokens in Dashboard > API > Management Tokens.

In: header

Response

application/json

application/json

application/json

application/json