Skip to navigation

Get Workspace Balance

Beta

Where the workspace’s money stands, readable with an API key: the credit new work can spend (available_usd), credit a past-due invoice holds back (held_usd), the auto-recharge rule that tops the balance up, and this calendar month’s spend against the workspace budget, in the same monthly_spend, monthly_budget, monthly_budget_status and monthly_budget_remaining fields a project reports. Poll it to show a balance in your own app or to warn before a 402; the workspace.spend_budget.* webhooks push the budget crossings. Every amount is in US dollars, to the micro-dollar. To see what the spend went on, by model, project or API key, read GET /v1/workspaces/current/usage: its default window totals to this monthly_spend.

Requires an API key granted billing:read (or an unrestricted key). A key pinned to a project is refused with 403, as on every workspace-level read, and so is a key whose owner may not view the workspace’s usage. A workspace with no billing account reads a zero balance.

Authentication

AuthorizationBearer

Enter your API key with the Bearer prefix, e.g. ‘Bearer sk_…’.

Headers

Speechify-VersionstringOptional

Response headers

Speechify-Request-IdstringOptional

Unique identifier for this request, present on every response (2xx and non-2xx alike). If the caller sends a Speechify-Request-Id request header the server echoes it back (sanitized and length-capped) so one logical request can be traced end-to-end; otherwise the server generates a fresh value. Log it on every response and quote it in support requests

  • it is the stable handle that ties your observation to Speechify’s server-side logs, and it matches the request_id field in the error envelope.

The legacy alias X-Request-ID carries the same value and is still accepted on requests, until 2027-07-24. Prefer the un-prefixed name (RFC 6648).

Response

The workspace's balance and this month's spend.
available_usddouble>=0

Credit new work can spend now, in US dollars to the micro-dollar: purchased credit plus the plan’s included credit, less held_usd. It is the balance synthesis and calls are admitted on, so at 0 new billable work is refused with 402 payment_required until the workspace tops up.

held_usddouble>=0

Plan-included credit still in the balance that cannot be spent while a subscription invoice is past due, in US dollars to the micro-dollar. Paying the invoice releases it; 0 when nothing is held.

as_ofdatetime
When the balance was last read from the billing ledger. Usage is metered just after each request, so the balance trails live traffic by up to a few minutes.
auto_rechargeobjectOptional

The rule that tops the balance up when it falls to a threshold, the same shape GET /v1/workspaces/current/auto-recharge returns. Present whenever the billing plane answered.

monthly_spenddoubleOptional>=0

The workspace’s billed month-to-date spend in US dollars: every project’s monthly_spend plus the Default project’s, read from the same meter. The month is the calendar month (UTC). Present whenever the billing plane answered.

monthly_budgetdoubleOptional

The workspace’s monthly spend budget in US dollars, present only when one is set. New billable work is refused with the coded 402 spend_budget_exceeded once monthly_spend reaches it.

monthly_budget_statusenumOptional

Where monthly_spend stands against monthly_budget, present only when both are: warning from 80% of the budget, reached once new billable work is refused, ok below 80%. The workspace.spend_budget.warning and workspace.spend_budget.reached webhook events fire at the same thresholds.

Allowed values:
monthly_budget_remainingdoubleOptional

monthly_budget minus monthly_spend in US dollars, present only when both are. Negative by the amount work already under way carried the workspace past its budget.

Errors

401
Unauthorized Error
403
Forbidden Error
409
Conflict Error
429
Too Many Requests Error
500
Internal Server Error
502
Bad Gateway Error