v52

latestOpenAPI 3.0.1AGPL-3.0raw.githubusercontent.com2026-08-01255473862.7 KB
Wallets

Get wallet balance

Use when displaying or checking current wallet balance (e.g. before charging or in a portal). Supports optional expand for credits breakdown and from_cache.

get/wallets/{id}/balance/real-time

Path parameters

idstring required

Wallet ID

Query parameters

expandstring

Expand fields (e.g., credits_available_breakdown)

Response

OK

alert_state'ok' | 'info' | 'warning' | 'in_alarm'
balancestring
balance_updated_atstring date-time
conversion_ratestring

amount in the currency = number of credits * conversion_rate ex if conversion_rate is 1, then 1 USD = 1 credit ex if conversion_rate is 2, then 1 USD = 0.5 credits ex if conversion_rate is 0.5, then 1 USD = 2 credits

created_atstring date-time
created_bystring
credit_balancestring
currencystring
current_period_usagestring
customer_idstring
descriptionstring
environment_idstring
idstring
is_cached_fallbackboolean

IsCachedFallback is true whenever the response is sourced from cache: either an explicit cache request, or fallback after a real-time failure. Clients should treat the absence of this field as if it were true and only trust freshness when the server explicitly emits false.

metadataTypesMetadata
namestring
real_time_balancestring
real_time_credit_balancestring
status'published' | 'deleted' | 'archived'
tenant_idstring
topup_conversion_ratestring

topup_conversion_rate is the conversion rate for the topup to the currency ex if topup_conversion_rate is 1, then 1 USD = 1 credit ex if topup_conversion_rate is 2, then 1 USD = 0.5 credits ex if topup_conversion_rate is 0.5, then 1 USD = 2 credits

unpaid_invoices_amountstring
updated_atstring date-time
updated_bystring
wallet_status'active' | 'frozen' | 'closed'
wallet_type'PRE_PAID' | 'POST_PAID'