Skip to main content
Glama

OpenFinance — Easy Trading: Crypto, Stocks, Perps & Prediction Markets

onchain_get_token_metadata

Get ERC-20 / SPL token metadata (name, symbol, logo URL, decimals) for one or many tokens on a given chain. Pass tokenAddress as comma-separated for batch lookups, or "native" for the chain's native asset (ETH, MATIC, SOL, etc.). Use this to resolve a token contract into a human-readable display before showing holdings to a user, or to look up decimals before formatting an on-chain balance.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "chainId": "<chainId>",
      "tokenAddress": "<tokenAddress>"
    },
    "name": "onchain_get_token_metadata"
  }
}

Input Schema

NameRequiredDescriptionDefault
chainIdYesChain identifier — "1" Ethereum, "137" Polygon, "42161" Arbitrum, "8453" Base, "4663" Robinhood Chain, "solana", etc.
providerNoForce a specific provider: Alchemy, GoldRush, Moralis, Tatum, Helius, SolScan, Shyft, Uniblock
includeRawNoReturn raw provider data (disables backup providers)
tokenAddressYesToken contract address, comma-separated for batch, or "native"

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden. It usefully discloses batch behavior and the 'native' sentinel, but says nothing about provider fallback/backup behavior, rate limits, or handling of unknown/invalid tokens — meaningful gaps for a metadata lookup that silently picks among providers.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three well-ordered sentences: verb+resource+return fields first, then parameter usage, then intent. No filler, and each sentence earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, and the description compensates by enumerating returned fields (name, symbol, logo URL, decimals). Combined with 100% schema coverage it is largely complete, though it omits provider/fallback and error semantics.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all four parameters, including the comma-separated batch and 'native' semantics that the description repeats. Baseline 3 is appropriate since the description adds no parameter detail beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Get) and resource (ERC-20 / SPL token metadata) plus the exact fields returned (name, symbol, logo URL, decimals). This clearly separates it from siblings like onchain_search_tokens and onchain_get_token_usd_price, which handle discovery and pricing respectively.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete when-to-use guidance: resolve a contract into a human-readable display before showing holdings, or look up decimals before formatting a balance. It also documents the 'native' and comma-separated batch modes. It stops short of explicitly naming when NOT to use it or naming alternative tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.