Skip to main content
Glama

Check whether an EVM contract is verified and its ABI

evm_contract
Read-only

Whether a contract's source is verified on Sourcify (exact or partial match), with its name, compiler version, license, and the functions and events from its ABI. A contract without verified source is answered with verified false, not an error. Chains: base (default), ethereum, arbitrum, optimism, polygon. Read-only. Related tools on this server, for a different need: evm_balance when you need ERC-20 balance of an address for one token contract; evm_call when you need to read the result of a read-only EVM contract function. Price: $0.002 per successful call, paid with x402 (USDC on Base, Solana and 10 more networks); failed calls are not charged.

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": {
      "address": "<address>"
    },
    "name": "evm_contract"
  }
}

Input Schema

NameRequiredDescriptionDefault
chainNobase (default), ethereum, arbitrum, optimism or polygon
addressYesContract address, 0x…

Output Schema

NameRequiredDescriptionDefault
nameNo
chainNo
matchNo
eventsNo
sourceNo
addressNo
chainIdNo
licenseNo
verifiedNo
checkedAtNo
functionsNo
compilerVersionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior4/5

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

Beyond readOnlyHint/openWorldHint it discloses that an unverified contract returns verified=false rather than an error, which is the key behavioral edge case for this tool. It also explains cost semantics: $0.002 per successful call via x402, with failed calls not charged. Return contents are only summarized, but an output schema exists, so that is acceptable.

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

Conciseness4/5

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

Front-loaded with purpose and the unverified-case behavior before chains, alternatives, and pricing. Every sentence carries information, though the pricing/payment sentence is long and slightly over-detailed relative to the rest.

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 two-parameter read tool with an output schema and annotations already present, the description covers the ambiguous case (unverified source), the chain scope, cost, and sibling routing. Nothing an agent needs to select or invoke it correctly is missing.

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 coverage is 100%, so both the address format and the chain enumeration with its default are already documented. The description restates the chain list and default without adding format, normalization, or matching semantics beyond the schema — baseline 3 is appropriate.

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?

The description opens with a specific verb-plus-resource: it checks whether a contract's source is verified on Sourcify, with exact or partial match, and returns name, compiler version, license, and ABI functions/events. It explicitly separates itself from evm_balance and evm_call by naming what those tools do instead.

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?

It states the supported chains with the default (base), names two sibling tools and the precise condition under which each is the better choice (ERC-20 balance, reading a read-only function result). That is explicit when-to-use and alternative routing, not implied guidance.

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