> ## Documentation Index
> Fetch the complete documentation index at: https://docs.allium.so/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> Query blockchain data from Allium Explorer using MCP.

export const chainCount = '85+';

Allium's MCP Server lets your AI agents query blockchain data using structured tool calls. Its tools cover SQL and saved queries, schema and docs search, dashboards, realtime prices and balances, and Hyperliquid, all via the [Model Context Protocol (MCP)](https://modelcontextprotocol.io/).

| Connect with              | URL                           |
| :------------------------ | :---------------------------- |
| **Sign-in (recommended)** | `https://mcp-oauth.allium.so` |
| API key                   | `https://mcp.allium.so`       |

## Quick Start

Sign in with your Allium account.

<Steps>
  <Step title="Add the server to your client">
    Add `https://mcp-oauth.allium.so` as a custom MCP server or connector, and choose **OAuth** authentication if your client asks.

    Per-client steps for [ChatGPT, Claude, and Copilot Studio](#chatbots) are below.
  </Step>

  <Step title="Sign in">
    Your client opens Allium's login page. Sign in with your Allium account and approve access.
  </Step>

  <Step title="Start Querying">
    Ask your agent to query blockchain data. It now has access to {chainCount} chains via Allium.
  </Step>
</Steps>

<Tip>
  **Using a coding agent?** With our installer, building on Allium is super straightforward:

  ```bash theme={null}
  npx @allium-labs/mcp install --client claude-code --yes
  ```

  See [Coding agents and CLIs](#coding-agents-and-clis) for the full client list.
</Tip>

## Key Benefits

<CardGroup cols={2}>
  <Card title="Structured Tool Calls" icon="code">
    Agents use standard MCP tool calls
  </Card>

  <Card title="Schema Discovery" icon="magnifying-glass">
    Semantic search and introspection of Allium's data schemas
  </Card>

  <Card title="Universal Compatibility" icon="plug">
    Works with any MCP-compatible agent framework
  </Card>

  <Card title="Production Ready" icon="shield-check">
    Reliable access to Allium's enterprise-grade blockchain data
  </Card>
</CardGroup>

## What your agent can do

<CardGroup cols={2}>
  <Card title="SQL & queries" icon="database" href="/ai/mcp/tools-reference/sql-and-queries">
    Run SQL, save reusable Explorer queries, choose a compute profile
  </Card>

  <Card title="Knowledge & discovery" icon="magnifying-glass" href="/ai/mcp/tools-reference/knowledge">
    Search schemas, docs, and analyst-built Terminal dashboards
  </Card>

  <Card title="Dashboards & sharing" icon="chart-mixed" href="/ai/mcp/tools-reference/dashboards">
    Build visuals and dashboards, publish share and embed links
  </Card>

  <Card title="Realtime data" icon="bolt" href="/ai/mcp/tools-reference/realtime">
    Prices, balances, transactions, DeFi positions, holdings PnL
  </Card>

  <Card title="Hyperliquid" icon="chart-candlestick" href="/ai/mcp/tools-reference/hyperliquid">
    Info, fills, orders, and orderbooks through a rate-limit-free proxy
  </Card>

  <Card title="Skills" icon="book-open" href="/ai/mcp/tools-reference/skills">
    Load Allium's own SQL and dashboard guidance into your agent
  </Card>
</CardGroup>

<Tip>
  Two habits make an agent noticeably better on Allium data: call `get_skill(name="sql-optimization")` before writing SQL, and call `realtime_get_supported_chains` once per session before any realtime tool.
</Tip>

## Chatbots

Per-client setup for the sign-in flow.

<Note>
  Signing in with OAuth is the recommended way to connect.
</Note>

<Tabs>
  <Tab title="ChatGPT">
    **Note:** Requires ChatGPT Plus, Pro, or Team plan. MCP is not available on the free plan.

    ChatGPT supports MCP servers as "Apps," so you can ask questions about on-chain data directly in your chat without writing code.

    <div style={{ position: "relative", paddingBottom: "56.25%", height: 0, overflow: "hidden", borderRadius: "0.5rem" }}>
      <iframe src="https://allium.navattic.com/dys0uaw" style={{ position: "absolute", top: 0, left: 0, width: "100%", height: "100%", border: "none" }} allow="fullscreen" />
    </div>

    Follow these steps to connect Allium MCP to ChatGPT:

    1. Click on your username in the bottom left
    2. Go to **Settings**
    3. Navigate to **Apps**
    4. Go to **Advanced Settings**
    5. Select and turn on **Developer Mode**
    6. Click **Create App**
    7. Set **MCP Server URL** to: `https://mcp-oauth.allium.so`
    8. Select **OAuth** as authentication

    Select the + icon and activate the Allium MCP App to use Allium's data in your chats.
  </Tab>

  <Tab title="Claude">
    **Note:** Requires Claude Pro, Max, Team, or Enterprise plan.

    Claude supports MCP servers as "connectors," so you can ask questions about on-chain data directly in your chat without writing code.

    <div style={{ position: "relative", paddingBottom: "56.25%", height: 0, overflow: "hidden", borderRadius: "0.5rem" }}>
      <iframe src="https://allium.navattic.com/l0x01fo" style={{ position: "absolute", top: 0, left: 0, width: "100%", height: "100%", border: "none" }} allow="fullscreen" />
    </div>

    Follow these steps to connect Allium MCP to Claude:

    1. Click on your user icon in the bottom left
    2. Go to **Settings** (Pro / Max plans) or **Organization Settings** (Team / Enterprise plans)
    3. Navigate to **Connectors**
    4. Scroll down to **Add Custom Connector**
    5. Add `https://mcp-oauth.allium.so` as the **Remote MCP Server URL**
    6. (On **Settings > Connectors**) Find the Allium Custom Connector and click **"Connect"**
    7. Sign in with your Allium account, using Google, SSO, or email

    Select the + icon and activate the Allium connector to use Allium's data in your chats.
  </Tab>

  <Tab title="Microsoft Copilot">
    **Note:** Requires Copilot Studio to configure MCP servers. Copilot Studio connects with an API key rather than sign-in, so it uses `https://mcp.allium.so`.

    With Copilot Studio, you can build custom agents and workflows that pull live blockchain data from Allium. This is useful for embedding on-chain insights into enterprise tools like Teams, Power Automate, or internal dashboards.

    <div style={{ position: "relative", paddingBottom: "56.25%", height: 0, overflow: "hidden", borderRadius: "0.5rem" }}>
      <iframe src="https://allium.navattic.com/z1270ni6" style={{ position: "absolute", top: 0, left: 0, width: "100%", height: "100%", border: "none" }} allow="fullscreen" />
    </div>

    Follow these steps to connect Allium MCP to Copilot Studio:

    1. Click **Create blank agent**
    2. Click on **Tools**
    3. Select **Add a Tool** then **Model Context Protocol**
    4. Add `https://mcp.allium.so` as the **Server URL**
    5. Select **API key** authentication, using the **X-API-KEY** header, and click **Create**
    6. Once the connector has been created, select **Connection > Create new connection**
    7. Copy your API key from `https://app.allium.so/settings/api-keys` and paste it into Copilot
    8. Click **Create**, then **Add and configure**

    Once connected, Copilot Studio automatically discovers Allium's tools and keeps them in sync. You can selectively enable individual tools, combine them with other connectors, and deploy your agent across Teams, Power Automate, and custom apps. See the [Copilot Studio MCP documentation](https://learn.microsoft.com/en-us/microsoft-copilot-studio/mcp-add-components-to-agent) for full integration instructions.
  </Tab>

  <Tab title="Gemini">
    Gemini web does not currently support MCP. Use **Gemini CLI** instead:

    ```bash theme={null}
    npx @allium-labs/mcp install --client gemini-cli --yes
    ```

    Gemini CLI signs in on first use. See [Coding agents and CLIs](#coding-agents-and-clis).
  </Tab>
</Tabs>

<Note>
  Want support for another chatbot platform? Reach out to [contact@allium.so](mailto:contact@allium.so).
</Note>

***

## Coding agents and CLIs

Claude Code, Cursor, Codex and the other CLI clients sign in with your Allium account. The installer writes the server into the client's own config file:

```bash theme={null}
npx @allium-labs/mcp install --client claude-code --yes
```

Swap `claude-code` for your client's slug. Most clients open the login page the first time your agent calls a tool. Claude Code and Codex need one more command before that.

| Client                   | Slug          | Sign-in                       |
| :----------------------- | :------------ | :---------------------------- |
| Claude Code              | `claude-code` | Run `/mcp`, select **allium** |
| Cursor                   | `cursor`      | On first use                  |
| Claude Desktop           | `claude`      | On first use                  |
| Codex                    | `codex`       | Run `codex mcp login allium`  |
| VS Code (GitHub Copilot) | `vscode`      | On first use                  |
| Cline                    | `cline`       | On first use                  |
| Windsurf                 | `windsurf`    | On first use                  |
| Warp                     | `warp`        | On first use                  |
| Gemini CLI               | `gemini-cli`  | On first use                  |
| Goose                    | `goose`       | On first use                  |
| Zed                      | `zed`         | On first use                  |
| OpenCode                 | `opencode`    | On first use                  |
| Tabnine                  | `tabnine`     | On first use                  |
| Roo Code                 | `roo-cline`   | API key only, see below       |

<Note>
  **Roo Code cannot sign in yet.** Its [OAuth 2.1 issue](https://github.com/RooCodeInc/Roo-Code/issues/8119) is still open, so install it with a key instead:

  ```bash theme={null}
  npx @allium-labs/mcp install --client roo-cline --api-key YOUR_KEY --yes
  ```
</Note>

To configure a client by hand, point it at `https://mcp-oauth.allium.so` and choose **OAuth** authentication if it asks:

<Tabs>
  <Tab title="Claude Code">
    ```bash theme={null}
    claude mcp add --scope user --transport http allium https://mcp-oauth.allium.so
    ```

    Then run `/mcp`, select **allium**, and finish the login in your browser.
  </Tab>

  <Tab title="Cursor">
    Add to `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project):

    ```json theme={null}
    {
      "mcpServers": {
        "allium": {
          "url": "https://mcp-oauth.allium.so"
        }
      }
    }
    ```

    Then restart Cursor.
  </Tab>

  <Tab title="Codex">
    ```bash theme={null}
    codex mcp add allium --url https://mcp-oauth.allium.so
    codex mcp login allium
    ```
  </Tab>
</Tabs>

<Note>
  Don't see your client listed? Reach out to [contact@allium.so](mailto:contact@allium.so).
</Note>

***

## API Key Authentication

<Note>
  **For autonomous agents, CI, and clients that can't sign in.** Use an API key when a browser sign-in is not practical, such as an agent running unattended. Connect to `https://mcp.allium.so` and send the key in an `X-API-KEY` header. Generate one at [app.allium.so/settings/api-keys](https://app.allium.so/settings/api-keys).
</Note>

You store and rotate the key yourself, so prefer sign-in where your client supports it. Both paths reach the same tools.

### Automatic Setup

The installer takes a key with `--api-key`, which also skips the browser step:

```bash theme={null}
npx @allium-labs/mcp install --client claude-code --api-key YOUR_KEY --yes
```

Client slugs are listed under [Coding agents and CLIs](#coding-agents-and-clis).

### Manual Setup

If you prefer to configure manually:

<Tabs>
  <Tab title="Claude Code">
    ```bash theme={null}
    claude mcp add --scope user --transport http allium https://mcp.allium.so --header "X-API-KEY: <your-api-key>"
    ```

    Then restart Claude Code.
  </Tab>

  <Tab title="Cursor">
    Add to `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project):

    ```json theme={null}
    {
      "mcpServers": {
        "allium": {
          "url": "https://mcp.allium.so",
          "headers": {
            "X-API-KEY": "<your-api-key>"
          }
        }
      }
    }
    ```

    Then restart Cursor.
  </Tab>

  <Tab title="Codex">
    Add the server:

    ```bash theme={null}
    codex mcp add allium --url https://mcp.allium.so
    ```

    Then add your API key to `~/.codex/config.toml`:

    ```toml theme={null}
    [mcp_servers.allium]
    url = "https://mcp.allium.so"
    http_headers = { "X-API-KEY" = "<your-api-key>" }
    ```

    Then restart Codex.
  </Tab>

  <Tab title="LangGraph / LangChain">
    Register tools in your agent configuration:

    ```json theme={null}
    {
      "tools": [
        {
          "name": "run_sql_query",
          "server": "https://mcp.allium.so",
          "headers": {
            "X-API-KEY": "<YOUR_API_KEY>"
          }
        },
        {
          "name": "get_query_run_results",
          "server": "https://mcp.allium.so",
          "headers": {
            "X-API-KEY": "<YOUR_API_KEY>"
          }
        }
      ]
    }
    ```

    Register `search_schemas` and `search_docs` the same way. An agent needs them to find the right tables before it writes SQL. Add any of the other [available tools](/ai/mcp/tools-reference/overview) as needed.

    <Note>
      Query execution is asynchronous: `run_sql_query` returns a `run_id`, and `get_query_run_results` fetches the rows. Register both, or your agent will never see its results. See [SQL & queries](/ai/mcp/tools-reference/sql-and-queries#the-execution-model).
    </Note>
  </Tab>

  <Tab title="mcp-remote / CLI">
    For `streamable-http` or other CLI-based setups:

    ```json theme={null}
    {
      "mcpServers": {
        "allium": {
          "command": "npx",
          "args": [
            "mcp-remote",
            "https://mcp.allium.so",
            "--header",
            "X-API-KEY:${API_KEY}"
          ],
          "env": {
            "API_KEY": "<your-api-key>"
          }
        }
      }
    }
    ```

    This enables local agent tool streaming with auth injected from environment variables.
  </Tab>

  <Tab title="Other Clients">
    Configure your MCP client to connect to `https://mcp.allium.so` with the `X-API-KEY` header set to your API key.

    Most MCP clients support HTTP transport with custom headers. Refer to your client's documentation for specific configuration details.
  </Tab>
</Tabs>

## Related Resources

<CardGroup cols={2}>
  <Card title="Plugins" icon="puzzle-piece" href="/ai/mcp/plugins">
    Extend your agent with the allium-analyst plugin
  </Card>

  <Card title="Tools Reference" icon="wrench" href="/ai/mcp/tools-reference/overview">
    Every tool, by category
  </Card>

  <Card title="Billing & limits" icon="receipt" href="/ai/mcp/tools-reference/billing-and-limits">
    Which tools cost credits, and the row and poll caps
  </Card>

  <Card title="Examples" icon="book" href="/ai/mcp/examples">
    What customers build with MCP
  </Card>

  <Card title="Run Queries" icon="rotate" href="/app/run-queries">
    Learn how to save queries in Explorer and obtain a query ID
  </Card>

  <Card title="Explorer API" icon="code" href="/api/explorer/overview">
    REST endpoints for running queries and retrieving results
  </Card>
</CardGroup>
