Skip to content

Query Account Balance

Use this API to query the merchant's account balances across currencies. It returns balances for all opened account currencies in one call, with optional currency filtering.

Request

  • Method: POST
  • Path: /api/v1/account/merchant/balanceQuery
  • Content-Type: application/json
  • Auth: Include the required auth headers and signature as described in Authentication

Request Body

ParameterTypeRequiredDescription
currencystringNoCurrency code (e.g. RUB). When provided, only that currency's balance is returned; otherwise all currencies are returned

Request example

json
{
  "currency": "RUB"
}

Or query all currencies:

json
{}

Response

Response body has a unified structure: result for request outcome, data for balance data.

result object

FieldTypeDescription
codestringResponse code (success/failure)
msgstringMessage

data object

FieldTypeAlways returnedDescription
balancesarrayYesList of per-currency balances, see table below. Empty array when no account exists or the filter matches nothing

data.balances object

FieldTypeAlways returnedDescription
currencystringYesCurrency code
availableBalancestringYesAvailable balance (string, 2 decimal places, e.g. "1000.00")
pendingBalancestringYesPending settlement balance (successful pay-in amount in the current settlement week)
frozenBalancestringYesFrozen balance (amount frozen for in-flight payouts)

Response example

json
{
  "result": {
    "code": "S0000",
    "msg": "Success"
  },
  "data": {
    "balances": [
      {
        "currency": "RUB",
        "availableBalance": "1000.00",
        "pendingBalance": "500.00",
        "frozenBalance": "200.00"
      }
    ]
  }
}

Notes

  • Only currencies with opened channel accounts are returned; a currency without any channel account will not appear in the list
  • Amounts are returned as strings with 2 decimal places. Parse them with a high-precision decimal library to avoid floating-point issues

See also