Skip to main content
POST
/
sdk
/
{environmentId}
/
balances
Get account balances for multiple addresses
curl --request POST \
  --url https://app.dynamicauth.com/api/v0/sdk/{environmentId}/balances \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "balanceRequests": [
    {
      "address": "<string>",
      "chain": "ETH",
      "networkIds": [
        123
      ],
      "whitelistedContracts": [
        "<string>"
      ]
    }
  ],
  "filterSpamTokens": true
}
'
{
  "chainBalances": [
    {
      "walletAddress": "<string>",
      "chain": "ETH",
      "networks": [
        {
          "networkId": 123,
          "balances": [
            {
              "address": "0xbF394748301603f18d953C90F0b087CBEC0E1834",
              "name": "<string>",
              "symbol": "<string>",
              "decimals": 123,
              "logoURI": "<string>",
              "balance": 123,
              "rawBalance": 123,
              "networkId": 123,
              "price": 123,
              "marketValue": 123,
              "liquidityPoolSizeUsd": 123,
              "totalSupply": "<string>",
              "isNative": true
            }
          ]
        }
      ]
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

environmentId
string
required

ID of the environment

Required string length: 36
Example:

"95b11417-f18f-457f-8804-68e361f9164f"

Body

application/json

Array of account addresses with chains and network IDs

balanceRequests
object[]
required
Required array length: 1 - 5 elements
filterSpamTokens
boolean
default:true

If false, the balance requests will not be filtered for spam tokens

Response

Token balances organized by chain and network

chainBalances
object[]
required