getTokenBalancesByAddress
Fetch the token balances (ERC20 standard) for a specific wallet by address
This function returns the balance of all tokens currently supported by Venly. The list of supported tokens can be found on Github. Tokens need to be based on the ERC20 standard, this included for example ERC20, VIP180, TRC20, ...
1
venlyConnect.api.getTokenBalancesByAddress("MATIC", "0xA5dC4fb59eBCaf00100C00776b45c3E4b58c6B95");
Copied!
πŸ§™ To add support in Venly for a certain token, simply submit a pull request.

Signature

1
venlyConnect.api.getTokenBalancesByAddress(secretType: SecretType, walletAddress: string): Promise<TokenBalance[]>
Copied!

Returns

1
Promise<TokenBalance[]>
Copied!

Parameters

Parameter
Required
Description
secretType
True
Parameter to indicate on which chain the token balance should be fetched
walletAddress
True
The address of the wallet to fetch token balance for

Example

1
venlyConnect.api.getTokenBalancesByAddress("MATIC", "0xA5dC4fb59eBCaf00100C00776b45c3E4b58c6B95");
Copied!

Object Types

​