GET
https://api.sim.dune.com
/
v1
/
evm
/
balances
/
{uri}
curl --request GET \
  --url https://api.sim.dune.com/v1/evm/balances/{uri} \
  --header 'X-Sim-Api-Key: <x-sim-api-key>'
{
  "balances": [
    {
      "address": "native",
      "amount": "605371497350928252303",
      "chain": "ethereum",
      "decimals": 18,
      "price_usd": 3042.816964922323,
      "symbol": "ETH",
      "value_usd": 1842034.6622198338
    }
  ],
  "next_offset": "dKMBWDLqM7vlyn5OMEXsLWp0nI4AAAABA5JLazNO7x4poVGqUwsgxgqvvIg",
  "request_time": "2023-11-07T05:31:56Z",
  "response_time": "2023-11-07T05:31:56Z",
  "wallet_address": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045"
}

The Token Balances API provides accurate and fast real time balances of the native and ERC20 tokens of accounts on supported EVM blockchains.

The Balances API only returns balances for certain low latency chains by default. To fetch balances for all supported chains, use the ?chains_ids=all query parameter.

Token Prices

Sim looks up prices onchain. We use the most liquid onchain pair to determine a USD price. We return the available liquidity in pool_size as part of the response, and show a warning low_liquidity: true if this value is less than $10k.

Spam Tokens

The Balances API provides the ?exclude_spam_tokens query parameter. You can use it filter out potential spam tokens based on various criteria, including a minimum liquidity threshold of $100.

We also include the pool_size field in all responses, allowing you to implement custom filtering logic based on your specific requirements. For a detailed explanation of our spam filtering approach, see our Spam Token Filtering guide.

Pagination

This endpoint is using cursor based pagination. You can use the limit query parameter to define the maximum page size. Results might at times be less than the maximum page size. The next_offset value is passed back by the initial response and can be used to fetch the next page of results, by passing it as the offet query parameter in the next request.

You can only use the value from next_offset to set the offset query parameter of the next page of results.

Headers

X-Sim-Api-Key
string
required

API key to access the service

Path Parameters

uri
string
required

Wallet to get balances for

Query Parameters

chain_ids
string | null

A comma separated list of chain_ids or tags for blockchains to get balances for. Examples: chain_ids=1,8453,10, chain_ids=mainnet,testnet. Only balances for blockchains tagged with all the specified tags are returned. Please see the response of the /chains endpoint for the tags on each blockchain.

exclude_spam_tokens
string | null

Specify this to exclude spam tokens from the response

filters
enum<string> | null

Specify erc20 or native to get only ERC20 tokens or native assets, respectively

Available options:
erc20,
native
metadata
string | null

A comma separated list of additional metadata fields to include for each token. Supported values: logo, url

offset
string | null

The offset to paginate through result sets. This is a cursor being passed from the previous response, only use what the backend returns here.

limit
integer | null

Maximum number of transactions to return

Required range: x >= 0

Response

200
application/json

Successful Response

The response is of type object.