Skip to main content
Glama

evm_get_transaction

Retrieve transaction details including status, gas used, receipt, logs, and confirmation data by chain and hash to verify success, debug failures, and analyze gas costs.

Instructions

Get transaction details including status, gas used, receipt, and execution results.

Retrieves comprehensive transaction information from the blockchain, including confirmation status, gas usage, block inclusion, and any emitted events or logs.

CRITICAL RULES:

  • Transaction hash MUST be a valid 0x-prefixed hex string (66 characters: 0x + 64 hex digits)

  • Transaction must exist on the specified chain (returns null if not found)

  • Pending transactions show null block number and confirmation count

  • Failed transactions are included (check status field)

PARAMETERS:

  • chain: EVM chain to query (required)

    • Must match one of the 7 supported chains

    • Transaction hashes are chain-specific

    • Same hash on different chains refers to different transactions

  • txHash: Transaction hash to retrieve (required)

    • Format: 0x followed by 64 hexadecimal characters

    • Case-insensitive

    • Example: "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"

EXAMPLES: ✅ Get confirmed transaction: {chain: "polygon", txHash: "0x1234...abcd"}

✅ Check pending transaction: {chain: "ethereum", txHash: "0xabcd...1234"}

✅ Analyze failed transaction: {chain: "bsc", txHash: "0x9876...fedc"}

❌ Invalid - wrong hash length: {chain: "polygon", txHash: "0x1234"}

❌ Invalid - missing 0x prefix: {chain: "ethereum", txHash: "1234567890abcdef..."}

SUPPORTED EVM CHAINS (7 networks): • ethereum (Sepolia) - EIP-1559 enabled, ~12s blocks, moderate gas costs • polygon (Amoy) - Low fees, fast finality (~2s), layer 2 • avalanche (Fuji C-Chain) - Sub-second finality, dynamic fees • bsc (BNB Testnet) - 3s blocks, low gas costs, Binance ecosystem • arbitrum (Sepolia) - Optimistic rollup, low fees, Ethereum security • base (Sepolia) - Coinbase layer 2, EIP-1559, low fees • worldchain (World Sepolia) - World Network testnet, EIP-1559

CRITICAL GAS CONSIDERATIONS:

  • Ethereum: High gas costs, use gas oracle for timing

  • Polygon/BSC: Very low gas, safe for frequent transactions

  • Arbitrum/Base: L2 optimizations, ~10-50x cheaper than Ethereum

  • Avalanche: Dynamic fees, can spike during congestion

  • Always check gas price before executing transactions

TESTNET TOKENS: All chains use testnet tokens with NO REAL VALUE. Faucets available for all supported networks.

OUTPUT STRUCTURE: • success: Boolean indicating operation success • transaction: Object with transaction details

  • hash: Transaction hash

  • from: Sender address

  • to: Recipient address (null for contract creation)

  • value: Amount transferred in wei

  • gasPrice/maxFeePerGas: Gas pricing (EIP-1559 or legacy)

  • gasUsed: Actual gas consumed

  • blockNumber: Block inclusion (null if pending)

  • status: 1 (success) or 0 (failed)

  • logs: Array of emitted events • executionTime: Time taken in milliseconds

COMMON MISTAKES:

  • Using transaction hash from wrong chain

  • Forgetting 0x prefix on hash

  • Not checking status field (assuming all transactions succeeded)

  • Expecting instant confirmation (some chains take time)

USE CASES:

  • Verify transaction succeeded before proceeding

  • Check gas costs for transaction types

  • Debug failed transactions via logs

  • Monitor transaction confirmation status

  • Analyze contract event emissions

Running on Linux.

LINUX-SPECIFIC NOTES:

  • Package manager: apt (Ubuntu/Debian), yum (RHEL/CentOS), or pacman (Arch)

  • Python 3 is typically 'python3' command

  • GNU tools are standard

  • Use 'xdg-open' command to open files/applications

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": {
      "chain": "<chain>",
      "txHash": "<txHash>"
    },
    "name": "evm_get_transaction"
  }
}

Input Schema

NameRequiredDescriptionDefault
chainYesEVM chain to query
txHashYesTransaction hash (0x... - 66 characters)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.6/5.0
Behavior4/5

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

With no annotations supplied, the description carries the full behavioral burden and does well: it discloses that a missing transaction returns null, that pending transactions show null block number and confirmation count, that failed transactions are still returned with status 0, and that hashes are chain-specific. It omits auth requirements and rate limits, which keeps it short of a 5.

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

Conciseness2/5

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

The core purpose is front-loaded and the CRITICAL RULES block is efficient, but the definition is massively bloated with material unrelated to invoking this read-only tool: gas cost strategy per chain, faucet/testnet token notes, an OUTPUT STRUCTURE dump duplicating what the tool returns, and an entirely irrelevant Linux package-manager section. A single-call getter does not need multi-paragraph chain economics.

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?

For a two-parameter read tool with no output schema, the description covers the important edge cases (not found, pending, failed) and describes the response shape, so an agent can call it and interpret results correctly. Completeness is achieved, but padded with unrelated operational advice that doesn't serve this tool.

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 real meaning beyond the schema: hashes are chain-specific and the same hash on different chains refers to different transactions, format is case-insensitive, and 7 chains are enumerated with their testnet identities. That is genuinely useful disambiguation, not schema repetition.

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

Purpose4/5

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

Opening sentence states a specific verb and resource: "Get transaction details including status, gas used, receipt, and execution results." That is more precise than the name alone. It does not, however, distinguish itself from close siblings such as evm_get_transaction_receipt or evm_get_transaction_history, even though it mentions receipts and logs.

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

Usage Guidelines3/5

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

The USE CASES block implies when the tool is appropriate (verify success, check gas costs, debug failures, monitor confirmation). However, it never says when NOT to use it, nor routes the agent to evm_get_transaction_receipt for receipt-only needs or evm_get_transaction_history for lists. Guidance is implied rather than explicit.

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

Deploy Server

Other Tools