Skip to main content
GET
Python (SDK)

Authorizations

x-api-key
string
header
required

Your Compass API Key. Get your key here.

Query Parameters

chain
enum<string>
default:arbitrum
required
Available options:
arbitrum,
base,
ethereum
user
string
default:0x29F20a192328eF1aD35e1564aBFf4Be9C5ce5f7B
required

The user to get the token balance of.

token
string
default:USDC
required

The symbol or address of the token for which the balance is checked. A token identifier - either a supported symbol (e.g., USDC, WETH) or a valid Ethereum address (0x...)

Examples:

"USDC"

"WETH"

"0xA0b86a33E6441ccF30EE5DdEF1E9b652C91ac1c8"

Response

Successful Response

Response model for token balance information.

amount
string
required

Amount of tokens a particular address holds

Pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
Example:

1.5

decimals
integer
required

Number of decimals of the token

Example:

18

token_symbol
string
required

Symbol of the token

token_address
string
required

Address of the token

Example:

"0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"