Skip to main content
GET
/
v1
/
pay
/
wallet
/
total_balance
Query total balance of personal account
curl --request GET \
  --url https://openplatform.gateapi.io/v1/pay/wallet/total_balance \
  --header 'X-GatePay-Certificate-ClientId: <x-gatepay-certificate-clientid>' \
  --header 'X-GatePay-Nonce: <x-gatepay-nonce>' \
  --header 'X-GatePay-Signature: <x-gatepay-signature>' \
  --header 'X-GatePay-Timestamp: <x-gatepay-timestamp>'
{
  "details": {
    "cross_margin": {
      "amount": "0",
      "currency": "USDT"
    },
    "spot": {
      "currency": "USDT",
      "amount": "42264489969935775.5160259954878034182418"
    },
    "finance": {
      "amount": "662714381.70310327810191647181",
      "currency": "USDT"
    },
    "margin": {
      "amount": "1259175.664137668554329559",
      "currency": "USDT",
      "borrowed": "0.00"
    },
    "quant": {
      "amount": "591702859674467879.6488202650892478553852",
      "currency": "USDT"
    },
    "futures": {
      "amount": "2384175.5606114082065",
      "currency": "USDT",
      "unrealised_pnl": "0.00"
    },
    "delivery": {
      "currency": "USDT",
      "amount": "1519804.9756702",
      "unrealised_pnl": "0.00"
    },
    "warrant": {
      "amount": "0",
      "currency": "USDT"
    },
    "cbbc": {
      "currency": "USDT",
      "amount": "0"
    }
  },
  "total": {
    "currency": "USDT",
    "amount": "633967350312281193.068368815439797304437",
    "unrealised_pnl": "0.00",
    "borrowed": "0.00"
  }
}

Headers

X-GatePay-Certificate-ClientId
string
required

The clientId assigned when the merchant registers an application in the Gate merchant console.

Example:

"4186d0c6-6a35-55a9-8dc6-5312769dbff8"

X-GatePay-Signature
string
required

Request signature. GatePay uses this signature to verify whether the request is valid.

X-GatePay-Timestamp
string
required

UTC timestamp in milliseconds when the request is generated. GatePay will not process requests where the difference from the receive time exceeds 10 seconds.

Example:

"1672905655498"

X-GatePay-Nonce
string
required

Random string. Must comply with HTTP header rules; recommended length is within 32 characters, composed of digits and letters.

Example:

"9578"

Query Parameters

currency
string
required

Specify currency name.

Response

200 - application/json

Total balance and details

Response body for querying total balance of personal account.

total
object

Total account balance converted to target currency.

details
object

Account type details. key is Account type.