list_datasets
Retrieve a list of all available cryo datasets from the Cryo MCP Server, enabling users to query Ethereum blockchain data efficiently through MCP-compatible clients.
Instructions
Return a list of all available cryo datasets
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Input Schema (JSON Schema)
{
"properties": {},
"title": "list_datasetsArguments",
"type": "object"
}
Implementation Reference
- cryo_mcp/server.py:54-79 (handler)The list_datasets tool handler: runs 'cryo help datasets' subprocess, parses output to return list of available Cryo datasets. Registered via @mcp.tool() decorator.@mcp.tool() def list_datasets() -> List[str]: """Return a list of all available cryo datasets""" # Ensure we have the RPC URL rpc_url = os.environ.get("ETH_RPC_URL", DEFAULT_RPC_URL) result = subprocess.run( ["cryo", "help", "datasets", "-r", rpc_url], capture_output=True, text=True ) # Parse the output to extract dataset names lines = result.stdout.split('\n') datasets = [] for line in lines: if line.startswith('- ') and not line.startswith('- blocks_and_transactions:'): # Extract dataset name, removing any aliases dataset = line[2:].split(' (alias')[0].strip() datasets.append(dataset) if line == 'dataset group names': break return datasets