trace_coin_lineage
Traces a coin's lineage back to its farming reward origin by following parent_coin_info links; returns the ancestor chain with flags for origin reached or max depth.
Instructions
Trace a coin's lineage back to its origin (typically a farming reward coin). Follows parent_coin_info links via repeated get_coin_record_by_name calls, returning the full chain of ancestor coins as an array ordered from the queried coin to its oldest ancestor. Stops when a coin record has coinbase: true (the farming reward flag set by consensus) or at max_depth (default 20, max 100). The response includes: reached_origin (boolean, true if a coinbase farming reward was found at the end of the chain), truncated_at_max_depth (boolean, true if max_depth was reached without finding the coinbase origin). If a parent coin record is not found mid-chain, a { status: 'NOT_FOUND' } entry is added to the lineage array and tracing stops (reached_origin will be false). Note: farming reward coins do NOT have all-zero parents — their parent ID is derived from the genesis challenge and block height. Works with any full node (Coinset, local, or simulator). Deep lineages against Coinset may trigger rate limiting; a local node has no rate limits.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "trace_coin_lineage"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| coin_id | No | The coin ID to trace (0x-prefixed, 32 bytes hex). Also accepted as coin_name. | |
| coin_name | No | Alias for coin_id — matches the field name used by similar tools (get_mempool_items_by_coin_name, get_memos_by_coin_name). | |
| max_depth | No | Maximum number of ancestors to trace (default 20, max 100) |