Skip to main content

Overview

Explorer tools allow your AI agents to query Allium’s historical blockchain data using SQL queries. These tools provide access to raw and decoded data across 80+ blockchains.

Available Tools

Tool NameDescription
explorer_run_queryRun a saved Explorer query using its query_id. Supports parameterization
explorer_run_sqlRun raw SQL directly against Allium’s production datasets
explorer_search_schemasSemantic search across all schema docs. Returns relevant table IDs
explorer_fetch_schemaFetch YAML schema metadata by table IDs (full table name, e.g. ethereum.raw.blocks)
Schema IDs match full table names (e.g. ethereum.raw.token_transfers). Use search before fetching.

Tool Usage

Run Saved Queries

Execute queries created in the Allium App.
1

Save Your Query

Create and save a query in Explorer to obtain its query_id.
2

Call the Tool

{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "explorer_run_query",
    "arguments": {
      "query_id": "<YOUR_QUERY_ID>"
      // "parameters": { "param": "value" } // optional
    }
  }
}
Response includes:
  • sql - Full query text
  • data - Result rows
  • meta.columns - Column names and types
  • queried_at - Execution timestamp

Run Raw SQL

Execute ad-hoc SQL queries directly:
{
  "name": "explorer_run_sql",
  "arguments": {
    "sql": "SELECT COUNT(*) FROM ethereum.raw.transactions"
  }
}
Supports up to 250,000 rows per query by default.

Explore Schemas

Find relevant tables using semantic search:
{
  "name": "explorer_search_schemas",
  "arguments": {
    "query": "erc20 token transfers"
  }
}
Returns:
["ethereum.raw.token_transfers", "ethereum.unified.transfers", ...]

Response Format

All Explorer query tools return a JSON-RPC result:
{
  "jsonrpc": "2.0",
  "id": 1,
  "result": {
    "content": {
      "text": "{\"sql\": \"SELECT ...\", \"data\": [...], \"meta\": {\"columns\": [...]}, \"queried_at\": \"2025-07-01T00:00:00Z\"}"
    }
  }
}
Parse content.text as JSON to extract:
  • sql - Full query string
  • data - List of result rows (objects)
  • meta.columns - Each column’s name and data type
  • queried_at - ISO timestamp