Skip to main content
Glama

Function selector and event topic

util_selector

Use when an agent is building calldata by hand or filtering logs and needs the exact identifiers: it turns a Solidity signature such as transfer(address,uint256) into its 4-byte function selector and its 32-byte event topic0. Do not use to run the call once you have the calldata (/v1/evm/call) or to hash arbitrary data (/v1/util/keccak256). No API key, no account. $0.005 per call, paid over x402 (USDC).

Input Schema

NameRequiredDescriptionDefault
signatureYesCanonical signature: name(type1,type2), no spaces and no argument names.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses that no API key or account is needed and states the price and payment rail ($0.005 per call over x402/USDC). What it doesn't cover is error behavior on malformed signatures or whether both the selector and topic0 are always returned together, which is the only meaningful gap for a paid call.

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 sentences with zero filler: use case and output first, exclusions second, then cost and auth facts. The endpoint parentheticals and price detail each earn their place by preventing a wrong tool choice or an unexpected charge.

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

Completeness5/5

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

For a one-parameter pure-computation tool with no output schema, the description supplies both return artifacts (4-byte selector, 32-byte topic0), the input format with an example, sibling routing, and the cost/auth profile. An agent has everything needed to invoke it correctly and predict the charge.

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?

Schema coverage is 100%, so the baseline is 3, but the description adds the worked example 'transfer(address,uint256)', which concretely demonstrates the canonical formatting rule (no spaces, no argument names) rather than just restating the field. That example materially reduces the chance of a malformed signature.

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 ('turns a Solidity signature ... into its 4-byte function selector and its 32-byte event topic0') with a concrete example. It also explicitly differentiates itself from evm_call and util_keccak256, so an agent can pick it out of a large sibling list without opening schemas.

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?

Opens with the exact triggering conditions ('building calldata by hand or filtering logs and needs the exact identifiers') and then gives explicit exclusions with the correct alternative for each ('Do not use to run the call ... (/v1/evm/call)', 'to hash arbitrary data (/v1/util/keccak256)'). Nothing is left to inference.

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.

Resources