# Onchain Toolkit – ERC-20 Token Metadata Reader

> Onchain Toolkit – ERC-20 Token Metadata Reader is a paid API for AI agents from onchain-toolkit.bowling-anthony.workers.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-09-14).

Reads ERC-20 token name, symbol, decimals, and total supply directly from a smart contract, and verifies the address contains deployed code on the specified chain.

## Facts

- Endpoint: GET https://onchain-toolkit.bowling-anthony.workers.dev/token
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/onchain-toolkit-erc-20-token-metadata-reader-3b351c59
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_d75x9EF5pjH3HI2slJGkb

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability onchain-toolkit-erc-20-token-metadata-reader-3b351c59
```

Example prompt: What's the name, symbol, decimals, and total supply of the ERC-20 token at contract address 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 on Ethereum mainnet?

## When to prefer this

Use this endpoint when you need authoritative, on-chain ERC-20 token metadata (name, symbol, decimals, total supply) read directly from the contract rather than from a third-party token list or database. Ideal when you need to verify a token is genuinely deployed and conforms to ERC-20, or when working with obscure or newly deployed tokens not yet indexed by aggregators.

## Known failure modes

- Address has no deployed contract code — returns code-present: false and no token fields
- Address is a non-ERC-20 contract that doesn't implement the standard interface — may return partial or null fields
- Invalid or malformed contract address — likely a 400 or error response
- Unsupported chain ID — endpoint may not support all EVM chains
- Rate limit or payment failure — 402 or 429 response

## How this service works

ERC-20 name, symbol, decimals and total supply read from the contract itself, and confirmation the address has code on that chain.

## Output

Returns the ERC-20 token's on-chain name, symbol, decimals, and total supply as read directly from the contract, plus a boolean confirming whether contract bytecode exists at the given address on the specified chain.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "symbol": "USDC",
  "decimals": 6,
  "looksLikeErc20": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/onchain-toolkit-erc-20-token-metadata-reader-3b351c59/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from onchain-toolkit.bowling-anthony.workers.dev](https://www.zero.xyz/host/onchain-toolkit.bowling-anthony.workers.dev/llms.txt)
