Skip to main content
Glama
chia-mcp

chia-mcp

Official
by Chia-Network

get_coin_record_by_name

Read-only

Retrieve a Chia coin record by its coin ID to view creation and spent block heights, verify whether it is spent, and obtain the height needed for get_puzzle_and_solution.

Instructions

Get a specific coin record by its coin ID (also called 'name'). The coin ID is the sha256 hash of (parent_coin_id + puzzle_hash + amount). Returns the coin's details including confirmed_block_index (creation height) and spent_block_index (spend height; 0 if unspent — use spent_block_index > 0 to test spent status; the 'spent' boolean exists via a compat shim but prefer spent_block_index as the canonical field). Pass spent_block_index as the height argument to get_puzzle_and_solution.

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

Input Schema

NameRequiredDescriptionDefault
nameYesThe coin ID / name (0x-prefixed, 32 bytes hex). This is sha256(parent_id || puzzle_hash || amount).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.2

TDQS

A4.1/5.0
Behavior4/5

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

Annotations only declare readOnlyHint=true, so the description adds real value by documenting return semantics: confirmed_block_index is the creation height, spent_block_index is the spend height and 0 means unspent, plus the warning that the 'spent' boolean is a compat shim and spent_block_index > 0 is canonical. That is substantive behavioral context beyond what the annotation supplies, though it omits what happens when the coin is not found.

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?

Three tight sentences, front-loaded with the purpose and identifier, then the derivation, then return/next-step guidance. The parenthetical about the compat shim is slightly verbose but earns its place by preventing an agent from relying on a deprecated field.

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?

There is no output schema, so the description must carry return documentation, and it does explain the two key height fields and the canonical spent test. The main gap is the not-found behavior and any confirmation/error semantics, which an agent would still need to discover empirically.

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 schema itself already states the 0x-prefixed 32-byte pattern and the sha256(parent_id || puzzle_hash || amount) derivation. The description restates essentially the same facts rather than adding format, edge-case, or validation detail beyond the schema, so the baseline of 3 applies.

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 ('Get a specific coin record') and names the identifier ('coin ID (also called name)'), which lets an agent distinguish it from the plural lookup siblings like get_coin_records_by_names without opening either schema.

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

Usage Guidelines4/5

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

Gives clear context for when to call it (single-coin lookup by sha256 ID) and an explicit next-step handoff: 'Pass spent_block_index as the height argument to get_puzzle_and_solution.' It does not explicitly say when not to use it versus the bulk lookup tools, so no exclusion is stated.

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