Skip to main content
Glama

evm_get_nft_owner

Retrieves the current owner address of a minted ERC721 token by querying ownerOf on a specified EVM chain. Use it to verify NFT ownership before transfers or marketplace actions.

Instructions

Get current owner address of specific ERC721 token.

Queries ownerOf function on NFT contract. Returns current owner's address. Fails if token doesn't exist or hasn't been minted. Read-only operation with no gas cost.

CRITICAL RULES:

  • Token must be minted

  • Read-only operation (no gas cost)

  • Returns current owner only

  • Ownership changes after transfers

  • Reverts if token doesn't exist

PARAMETERS:

  • chain: EVM chain to query (required)

    • Must support ERC721 standard

  • contractAddress: NFT collection address (required)

    • Must be valid ERC721 contract

    • Format: "0x..." (42 characters)

  • tokenId: Token ID to query (required)

    • Must be minted token

    • Format: string (not number for large IDs)

EXAMPLES: ✅ Check owner of NFT #123: {chain: "polygon", contractAddress: "0x7227E4D7...", tokenId: "123"}

✅ Verify ownership of rare token: {chain: "ethereum", contractAddress: "0xBC4CA0E...", tokenId: "8762"}

❌ Invalid - non-existent token: {chain: "polygon", contractAddress: "0x7227E4D7...", tokenId: "999999999"}

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: • owner: Current owner address • tokenId: Queried token ID • collection: Contract address

COMMON MISTAKES:

  • Querying unminted tokens

  • Not handling revert for non-existent IDs

  • Caching owner without checking for transfers

  • Assuming token exists in collection

USE CASES:

  • Verify ownership before operations

  • Display current holder in marketplace

  • Validate ownership claims

  • Track NFT provenance

  • Check if address owns specific token

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>",
      "contractAddress": "<contractAddress>",
      "tokenId": "<tokenId>"
    },
    "name": "evm_get_nft_owner"
  }
}

Input Schema

NameRequiredDescriptionDefault
chainYesEVM chain to query
tokenIdYesToken ID to query
contractAddressYesNFT contract address (0x...)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.4/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 load and does well on the essentials: it declares a read-only operation with no gas cost, states it reverts for non-existent/unminted tokens, and warns that ownership changes after transfers and should not be cached. This is undercut by boilerplate that tells the agent to 'always check gas price before executing transactions', which is contradictory noise for a view call.

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 is front-loaded in one good paragraph, but roughly 80% of the text is unrelated boilerplate: per-chain gas economics, faucet notes, and an entirely off-topic 'Running on Linux / apt / yum / python3 / xdg-open' section. Large blocks (CRITICAL RULES restating the opening sentence) repeat rather than inform.

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

Completeness3/5

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

For a simple 3-parameter read call, the essential facts are all present: return fields (owner, tokenId, collection) are listed even without an output schema, and the revert condition is disclosed. Completeness is offset by the absence of any sibling routing and by extraneous environment notes that add no calling information and risk confusing the agent.

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% and the enum already constrains chain, so the schema does the heavy lifting. The description adds only marginal meaning: tokenId must be a string rather than a number for large IDs, and contractAddress must be a valid 42-character ERC721 address — useful but not a substantive extension beyond the schema text.

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?

The opening line states a specific verb and resource ('Get current owner address of specific ERC721 token') and even names the underlying call ('ownerOf function'). It is clear enough to distinguish from siblings like evm_get_nfts_by_owner or evm_get_nft_info without opening the schema, though it never explicitly contrasts itself with them.

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 and COMMON MISTAKES sections imply when to reach for this tool (verify ownership, display holder), and the failure condition ('Fails if token doesn't exist or hasn't been minted') is stated. However, no alternative tool is ever named or excluded, so the agent must infer that ownership-enumeration belongs to evm_get_nfts_by_owner.

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