How to get ERC-20 token metadata (name, symbol, decimals) via API
Updated 2026-11-10
Use when an agent needs an ERC-20 token's name, symbol, decimals and supply before handling its amounts.
From an MCP client, add https://tanod.dev/mcp and call get_token_info; the first 10 calls per IP per UTC day are free (shared by all chainpeek reads), then each call is USD 0.003 with x402, no key or signup.
POST a chain and a token contract address to /v1/chain/token. It returns the token's name, symbol, decimals and total supply, or is_erc20:false if the address does not behave like an ERC-20.
Request
chain is ethereum or base; address is the token contract (0x plus 40 hex characters).
curl -s -X POST https://tanod.dev/v1/chain/token \
-H 'X-Tanod-Free: 1' -H 'content-type: application/json' \
-d '{"chain":"base","address":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"}'Response
{
"chain": "base",
"address": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
"is_erc20": true,
"name": "USD Coin",
"symbol": "USDC",
"decimals": 6,
"total_supply_raw": "4440602565916867",
"total_supply": "4440602565.916867"
}Limits and caveats
Attacker-controlled strings. Name and symbol are written by the token's deployer. Impersonating tokens reuse well-known names and symbols, so identify a token by its address, never by its symbol.
Metadata is not safety. A valid ERC-20 shape says nothing about whether the token can be sold or whether an owner can mint or freeze. For that, run an address risk check.
Use decimals to turn raw amounts into display amounts; total_supply is already formatted.
Price and free allowance
USD 0.003 per call, paid in USDC on Base, Polygon, Solana, BNB Chain or Arbitrum with x402. 10 free chain reads per IP per UTC day with the header X-Tanod-Free: 1, in one pool shared with the other chainpeek reads. MCP tool: get_token_info at https://tanod.dev/mcp, where the free tier is automatic.
Use it from Claude without writing code: in claude.ai or Claude Desktop, add https://tanod.dev/mcp/chain?via=erc20-token-metadata-api as a custom connector (steps), then ask in plain words, for example "What are the name, symbol, decimals and total supply of the token at 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48?" The free daily allowance is applied automatically over MCP. Beyond it a call needs an x402 payment, which these clients can make.
Related guides: How to get an ETH or ERC-20 balance of an address via API, How to check a contract or token address for risk before you transact, How to check an ERC-20 approval (allowance). Back to tanod.dev or the guide index. Results are automated and heuristic.