Get Wallet Balance
Changed onGet the balance of a wallet for a given chain and currency
API scope required: wallets:balance.read
get/unstable/wallets/{walletLocator}/balances
Request
- Base URL: https://staging.crossmint.com/api
- URL: https://staging.crossmint.com/api/unstable/wallets/{walletLocator}/balances
- Auth: none declared. Required headers: X-API-KEY
Path parameters
walletLocatorstring required
A wallet locator can be of the format:
- <walletAddress>
- email:<email>:<chainType>[:<walletType>][:alias:<alias>] (walletType defaults to 'smart')
- userId:<userId>:<chainType>[:<walletType>][:alias:<alias>] (white label user example)
- phoneNumber:<phoneNumber>:<chainType>[:<walletType>][:alias:<alias>]
- twitter:<handle>:<chainType>[:<walletType>][:alias:<alias>]
- x:<handle>:<chainType>[:<walletType>][:alias:<alias>]
- me:<chainType>[:<walletType>][:alias:<alias>] (Use when calling from the client side with a client API key)
- chainType[:<walletType>]:alias:<alias>
Query parameters
chainsstring
The blockchain(s) to query. Comma-separated list of chains
tokensstring required
The tokens to query. Comma-separated list of either tokens or token locator strings
Headers
X-API-KEYstring required
API key required for authentication
Response
Returns the balance of the wallet for the given chain and currency
Example response
[
{
"name": "USDC Token",
"decimals": 18,
"amount": "18.8343253454",
"rawAmount": "18834161225104097789",
"chains": {
"base": {
"contractAddress": "0x123",
"locator": "base:0x123",
"amount": "18.833423432423",
"rawAmount": "18834161225104097789"
},
"solana": {
"mintHash": "123123",
"locator": "solana:132",
"amount": "0",
"rawAmount": "00000000000000000"
},
"stellar": {
"contractId": "CAS3J7GYLGXMF6TDJBBYYSE3HQ6BBSMLNUQ34T6TZMYMW2EVH34XOWMA",
"locator": "stellar:xlm",
"amount": "100.5000000",
"rawAmount": "1005000000"
}
}
}
]Changes
- info
added
subschema #1subschema #2subschema #3to the//response propertyanyOflist for the response status - info
removed
subschema #1subschema #2subschema #3from the//response propertyanyOflist for the response status
- info
- info
added the optional property
to the response with the status
- info