Skip to main content
Glama

Tron Read Contract

tron_read_contract
Read-onlyIdempotent

Read-only (constant) call against any TRON contract, executed via external RPC. TRC-20 helpers balanceOf / allowance / decimals / symbol / name / totalSupply are built in; any other function can be called with a raw selector plus ABI-encoded parameter. No state is changed and no key is involved. When to use: an agent needs an on-chain value without trusting a third-party API - USDT balance of an address, token decimals, an allowance, or any view function. Do not use: to send a transaction (this never writes), or to look up a historical balance. Returns: ok, contract, function, output_type, value (decoded), value_human for 6-decimal tokens, raw, energy_used.

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": {
      "contract": "<contract>",
      "function": "<function>"
    },
    "name": "tron_read_contract"
  }
}

Input Schema

NameRequiredDescriptionDefault
argumentNoTRON address argument (for balanceOf / allowance)
contractYesContract address (base58 or 41-hex)
functionYesbalanceOf | allowance | decimals | symbol | name | totalSupply, or a raw selector like 'foo(uint256)'
argument2NoSecond address argument (for allowance)
parameterNoRaw ABI-encoded parameter hex, for raw selectors
output_typeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added
  2. Removed
  3. First observed

TDQS

A4.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true and destructiveHint=false, so the safety profile is not new information. The description does add genuine context beyond them: execution 'via external RPC' (a trust model), 'no key is involved', and an enumerated return set. It stops short of disclosing failure modes, rate limits, or behavior when a raw selector mismatches the ABI.

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?

Front-loads what the tool is, then helpers, then the raw-selector escape hatch, then when/when-not, then returns. Every clause carries distinct information; the return list is warranted because no output schema exists.

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?

Because there is no output schema, the description correctly compensates by enumerating ok, contract, function, output_type, value, value_human, raw and energy_used. For a 6-parameter read tool with strong annotation coverage this is close to complete; only error/edge-case behavior for raw selectors and the 6-decimal value_human heuristic's limits are unaddressed.

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

Parameters4/5

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

With 83% schema description coverage the baseline is 3, but the description earns an upgrade by explaining the relationship the schema leaves implicit: named TRC-20 helpers use `argument`/`argument2`, while arbitrary functions require a selector like 'foo(uint256)' plus an ABI-encoded `parameter`. It does not clarify `output_type` defaults or how decoding behaves when omitted.

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 and resource — a read-only constant call against any TRON contract — and scopes it to TRON, which separates it from eth_read_contract and from transaction-broadcasting siblings. It also spells out the two invocation modes (built-in TRC-20 helpers vs. raw selector), so an agent knows exactly what class of operation this covers.

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

Usage Guidelines5/5

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

Explicit 'When to use' examples (USDT balance, token decimals, an allowance, any view function) and explicit 'Do not use' exclusions (sending a transaction, historical balance lookup) are both present. The exclusions rule out the most plausible mis-invocations and route the agent away without ambiguity.

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.