Skip to content

Get the account balance

GET
/v1/Accounts/{auth_id}/Balance
curl --request GET \
--url https://api.siprtc.io/v1/Accounts/example/Balance \
--header 'Authorization: Basic <credentials>'

Returns the prepaid balance of the account in the path, in US dollars. Calls, messages, numbers and other paid usage are debited from this balance as they happen, so it can go below zero. A sub-account that belongs to the same company as its parent account (for example a portal user) is billed to the parent: its usage is debited from the parent’s balance, not from its own. Call it with your own Auth ID, or as a parent account with a direct sub-account’s Auth ID in the path. The same response is served at /Accounts/{auth_id}/Balances.

auth_id
required
string

Auth ID of the account (yours, or a direct sub-account’s)

The account and its balance

Media type application/json
object
auth_id
required

Auth ID of the account the balance belongs to.

string
balance
required

Prepaid balance in US dollars. Negative when usage has exceeded the credit.

number

Example

{
"auth_id": "AC000000000000000000",
"balance": 42.75
}

Missing or wrong credentials, or the path account is neither yours nor a direct sub-account’s (body: "Authentication failed")

Media type application/json
string

Example generated

example

No account with this Auth ID (body: {})

Media type application/json
object

Example generated

{}