Wallets API

How much of this token does this wallet hold right now, and what is it worth?

The wallet's current balance of one token, exact (on SOL summed over every token account it owns of it), with the USD price and value.

GET/api/external/wallet-analysis/wallet-token-balance/{chain}/{address}

What it returns

The wallet's current balance of ONE token, with its USD value. On SOL it is summed over every token account the wallet owns of the token; on RHC it is the balance the token contract records for the wallet. balanceRaw and balance are exact decimal strings; "0" is a real zero. priceUsd and valueUsd are null when no price is known; the balance still stands. The native coin is not a token here: its wrapped token is.

Chains

  • Solana SOL
  • Robinhood Chain RHC

Request

Send your key in the x-dex-data-key header. Replace each <placeholder> with a real value.

curl -H "x-dex-data-key: $DEXDATA_API_KEY" \
  "https://api.dexdata.io/api/external/wallet-analysis/wallet-token-balance/SOL/<address>?token=<token>"
Parameters
ParameterDescription
token

query · string · required

The token address: the mint on SOL, the token contract on RHC.
chain

path · string · required

The chain the wallet address belongs to. SOL and RHC are served; BNB, ETH, BASE, STABLE and ARC return 400. CELO, ARB, OP and SCROLL return 400 here.
address

path · string · required

The wallet address.

Response fields

A JSON response. Every field is always present; null means the value could not be established, never zero.

Response fields of How much of this token does this wallet hold right now, and what is it worth?
FieldTypeDescription
walletstringThe wallet asked about.
tokenstringThe token asked about.
balanceRawstringBase units, as a decimal string.
decimalsintegerThe token's decimals.
balancestringbalanceRaw / 10^decimals, exact, as a decimal string.
tokenAccountsinteger | nullHow many token accounts of the token the wallet owns on SOL, where a wallet can own several; null on SOL when the count is not known for this answer. null on EVM chains (RHC): there a balance is recorded against the wallet in the token contract, so there are no token accounts to count.
priceUsdnumber | nullUSD price of one token; null when no price is known.
valueUsdnumber | nullbalance × priceUsd; null when no price is known.

Start building with DexData today

Sign in, create a key and make your first call in a minute. Free credits every month, and you only pay for calls that succeed.

Get a free API key