Actions6
- Wallet Actions
- Transaction Actions
- Token Actions
Overview
This node interacts with the Ethereum blockchain, specifically focusing on ERC20 token operations under the "Token" resource. The "Get Token Balance" operation retrieves the balance of a specified ERC20 token for a given Ethereum address. This is useful in scenarios where you need to monitor token holdings, build dashboards showing token balances, or trigger workflows based on token amounts.
For example, you can use this node to:
- Check how many USDC tokens an address holds.
- Monitor token balances before executing trades or transfers.
- Aggregate token balances across multiple addresses for reporting.
Properties
| Name | Meaning |
|---|---|
| RPC URL | Ethereum RPC endpoint URL to connect to the blockchain (optional). Defaults to a public RPC. |
| Token Contract Address | The contract address of the ERC20 token whose balance you want to check. |
| Address | The Ethereum address to check the token balance for. If left empty, uses the credential wallet's address. |
Output
The output JSON object contains the following fields:
address: The Ethereum address for which the token balance was retrieved.tokenContract: The ERC20 token contract address queried.balance: The token balance formatted as a decimal string, adjusted for token decimals.balanceRaw: The raw token balance as a string representing the integer value from the blockchain.symbol: The token symbol (e.g., "USDC", "DAI").decimals: Number of decimals used by the token (usually 18 for most tokens).
This output provides both human-readable and raw numeric forms of the token balance, along with token metadata.
Dependencies
- Requires an Ethereum RPC endpoint URL to query the blockchain state.
- Needs an API key credential that represents an Ethereum wallet for signing transactions or providing a default address when no address is specified.
- Uses the
etherslibrary internally to interact with the Ethereum network and smart contracts.
Troubleshooting
- Missing Credentials: If no Ethereum wallet credential is provided and the address field is empty, the node will throw an error because it cannot determine which address to query.
- Invalid Token Contract Address: Providing an incorrect or non-ERC20 contract address may cause the call to fail or return unexpected results.
- RPC Endpoint Issues: Using an invalid or unreachable RPC URL will result in connection errors.
- Token Not Found or No Balance: If the address has zero balance or the token contract does not exist, the balance returned will be zero or the call might fail.
To resolve these issues:
- Ensure the Ethereum wallet credential is configured properly.
- Verify the token contract address is correct and corresponds to an ERC20 token.
- Use a reliable and accessible Ethereum RPC URL.
- Confirm the target address is valid and has interacted with the token contract.