Skip to main content
GET
Get credit balance
Example response:
Credit balances can be fractional. The key determines which account or organization balance is returned; there is no user or organization request parameter. Use this for budgeting before generation. A balance check does not reserve credits, and specification costs vary. For browser submissions, also check your queue and in-flight limit. In Node, call client.getCreditsBalance(). In Python, client.get_credits_balance() returns a CreditsBalanceResponse object, so read balance.creditsRemaining. This is an exception to the Python SDK’s dictionary-shaped specification and browser responses.

Errors

Each status has an example body in the response examples. See errors and retries.

Authorizations

Authorization
string
header
required

Your pre.dev workspace API key (pdk_...) from Integrations, Built-in tab: https://pre.dev/projects/integrations?tab=built-in

Response

Credit balance.

success
boolean
required

Whether the request was successful

creditsRemaining
number | null
required

Remaining credits. null on plans without a credit limit.