Skip to main content
Glama
chia-mcp

chia-mcp

Official
by Chia-Network

get_block_spends

Read-only

Fetch all coin spends in a Chia block by header hash, returning the puzzle and solution for each spent coin.

Instructions

Get all coin spends in a block by its header hash. Returns the puzzle and solution for each coin spent in the block.

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

Input Schema

NameRequiredDescriptionDefault
header_hashYesThe header hash of the block (0x-prefixed, 32 bytes hex)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.2

TDQS

A3.6/5.0
Behavior3/5

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

The readOnlyHint=true annotation already signals this is a safe read, and the description adds the useful detail that each spend includes its puzzle and solution. It says nothing about ordering, completeness guarantees (e.g., whether coinbase spends are included), or behavior for unknown/empty blocks, so it adds moderate value beyond the annotation.

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?

Two short sentences, with the core action and lookup key front-loaded and the return content summarized second. Nothing is redundant or padded.

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 simple single-parameter read tool with annotation coverage, the description covers what it does, the key it takes, and what comes back. Only minor gaps remain (ordering, edge-case behavior for empty blocks), which is acceptable given no output schema is declared.

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 single parameter already documents the 0x-prefixed 32-byte hex format with a regex pattern. The description only restates 'by its header hash', so it adds essentially no meaning beyond the schema; baseline 3 applies.

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 description states a specific verb and resource ('Get all coin spends in a block') plus the lookup key ('by its header hash'), which clearly separates it from get_block (block data) and get_puzzle_and_solution (a single coin). It does not name a sibling explicitly, so it is clear but not maximally differentiated.

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?

Usage is implied by the wording: use it to retrieve every coin spend in a given block. There is no explicit when-to-use/when-not guidance and no pointer to alternatives such as get_block_spends_with_conditions or get_puzzle_and_solution when only one coin is of interest.

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