balanceOf(address) method. Use that token’s ABI and contract address on Tavchain Testnet.
You can inspect the verified GLD reference contract on Tavchain Testnet, chain ID 771002. It is a valueless demonstration token, separate from native TAV. The Hardhat guide links its deployment and transfer transactions.
Choose the asset
Confirm the chain ID and token contract address before querying. A symbol such as GLD is not a unique identifier. Native TAV useseth_getBalance; an ERC-20 keeps its own balances in contract state.
Read in Remix or the explorer
- Open your deployed ERC-20 in Remix, or open a verified token contract’s read interface in the explorer.
- Find
balanceOfand enter the holder’s public EVM address. - Read the returned integer.
- Read
decimals()from that same contract and use it to format the amount.
decimals() returns 18 and totalSupply() returns 1000000000000000000000 (1,000 GLD). Holder balances depend on the queried block; the reference transfer records a comparison at block 10833.
Read from an application
Use an EVM client library with the token ABI to encodebalanceOf(address) and perform eth_call against the token contract. The call returns ABI-encoded data, which the library decodes to an integer. Use a specific block when you need a reproducible comparison.
A read-only call does not submit a transaction or require a wallet signature. Check RPC errors and confirm the contract actually implements the expected interface.
Decimals
Token decimals are independent of native TAV’s 18 decimals. For a token with 18 decimals, a raw balance of1000000000000000000 displays as one token. Keep arithmetic integer-safe.
Create an ERC-20 · Native balance · RPC reference