WhatsApp API Platform
Account

Get an agent's wallet balance

GET
/api/v1/wallet/agents/{id}

Returns the spending allotment, spend-to-date, and remaining balance for one of your agents.

This is not the account wallet. Agents do not hold their own wallet — they spend against the account balance up to a per-agent cap, and this endpoint reports that cap and what is left of it. For the account balance itself, use the account overview endpoint.

Amounts are the raw fixed-point integer used throughout the billing API: divide by 10,000 for the major-currency value (e.g. 5000000000 is ₹500,000.00).

allotment and remaining are null when the agent is uncapped — they spend against the account balance with no per-agent ceiling. spend_since marks the start of the current spend window; spent counts only ledger activity after it, so resetting the window resets spent without touching the cap.

An agent-scoped API key may only read its own agent; any other agent id returns 403.

Authorization

ApiKeyAuth
X-API-Key<token>

API key from your dashboard (Settings > API Keys)

In: header

Path Parameters

id*string

Agent id (User cuid2)

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://loading/api/v1/wallet/agents/string"
{
  "success": true,
  "data": {
    "allotment": 5000000000,
    "spent": 1234000000,
    "remaining": 3766000000,
    "spend_since": "2026-08-01T00:00:00Z"
  }
}
{
  "success": false,
  "message": "user not authenticated"
}
{
  "success": false,
  "message": "not your agent"
}
{
  "success": false,
  "message": "agent not found"
}
{
  "success": false,
  "message": "internal server error"
}

Get your account overview GET

One call for everything that describes the calling account: profile details, the active plan and subscription, the default WhatsApp number (including its last-synced Meta business profile), and the wallet balance. Useful as a startup call — it saves fanning out to the plan, WABA, and wallet endpoints separately. `wallet.balance` is in **major currency units** (rupees, not paise) — unlike the agent wallet endpoint, which reports the raw fixed-point integer. `active_plan`, `active_subscription`, and `default_waba` are omitted when the account has none.

Issue an access token POST

OAuth 2.0 **client-credentials** token endpoint. Exchanges the API key you are already calling with for a bearer token that authenticates as the **same account** — use it to sign that account into the dashboard, or to call any endpoint that expects `Authorization: Bearer` instead of an API key. Your API key is the client credential, so there is nothing to send: the account is whichever one the `X-API-Key` header resolves to. An agent-scoped API key returns a token for the account that owns the agent. The body is optional. If you send one — as JSON or as `application/x-www-form-urlencoded`, both are accepted — `grant_type` must be `client_credentials`; any other value returns `400`. There is no authorization-code flow: this endpoint never issues a token for an account other than the caller's. `expires_in` is always `null`: **the token does not expire**, and no `refresh_token` is issued because there is nothing to refresh. Treat it as a long-lived credential and store it like a password. The only way to invalidate it is to block or deactivate the account. Because the token carries exactly the authority the API key already had, any active account can call this — there is no extra permission to hold.