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

# 安裝方式

> 三種為 OpenClaw Agent 安裝 ChainStream Skill 的方式：Vercel Skills CLI、ClawHub 或直接 MCP 配置。

## 概述

有三種方式將 ChainStream 連線到你的 OpenClaw Agent。請選擇最適合你工作流程的方式。

| 方式                                               | 適用場景                    | 設定時間   |
| ------------------------------------------------ | ----------------------- | ------ |
| [Vercel Skills CLI](#method-1-vercel-skills-cli) | 跨 Agent 相容，支援 40+ Agent | \~30 秒 |
| [ClawHub](#method-2-clawhub)                     | OpenClaw 原生，社群生態        | \~1 分鐘 |
| [直接 MCP 配置](#method-3-direct-mcp-config)         | 完全控制，自定義部署              | \~2 分鐘 |

## Method 1: Vercel Skills CLI

Vercel Skills CLI 是一個跨 Agent 的包管理器，只需一條命令即可將 ChainStream Skill 安裝到任何支援的 AI Agent 中。

### 快速安裝

```bash theme={null}
npx skills add chainstream-io/skills
```

這會自動檢測你的 Agent 環境並相應地配置 ChainStream MCP 工具。

### 指定 Agent 安裝

要針對特定 Agent 安裝：

```bash theme={null}
npx skills add chainstream-io/skills -a openclaw
```

### 支援的 Agent

Vercel Skills CLI 支援 **40+ Agent**，包括：

| Agent          | 安裝命令                                                  |
| -------------- | ----------------------------------------------------- |
| OpenClaw       | `npx skills add chainstream-io/skills -a openclaw`    |
| Claude Code    | `npx skills add chainstream-io/skills -a claude-code` |
| Cursor         | `npx skills add chainstream-io/skills -a cursor`      |
| Cline          | `npx skills add chainstream-io/skills -a cline`       |
| GitHub Copilot | `npx skills add chainstream-io/skills -a copilot`     |
| Codex          | `npx skills add chainstream-io/skills -a codex`       |

完整相容性表格和配置檔案位置請參閱[跨 Agent 相容性](/zh-Hant/docs/ecosystem/openclaw/cross-agent-compatibility)。

<Tip>
  安裝完成後，將 API Key 設定為環境變數：

  ```bash theme={null}
  export CHAINSTREAM_API_KEY=your-key
  ```
</Tip>

## Method 2: ClawHub

[ClawHub](https://clawhub.ai) 是 OpenClaw 的原生 Skill 市場。ChainStream Skill 作為社群包釋出。

### Skill 詳情

| 欄位      | 值                                                                                          |
| ------- | ------------------------------------------------------------------------------------------ |
| URL     | [clawhub.ai/chainstream/chainstream-data](https://clawhub.ai/chainstream/chainstream-data) |
| 版本      | 3.1.1                                                                                      |
| MCP 工具數 | 17                                                                                         |
| 許可證     | MIT-0                                                                                      |

### 透過 CLI 安裝

```bash theme={null}
openclaw skills install chainstream-data
```

### 透過 ClawHub UI 安裝

1. 訪問 [clawhub.ai/chainstream/chainstream-data](https://clawhub.ai/chainstream/chainstream-data)
2. 點選 **Install**
3. 按照螢幕上的指引配置你的 API Key

### 配置 API Key

從 ClawHub 安裝後，在 OpenClaw Agent 配置中設定 API Key：

```yaml theme={null}
skills:
  chainstream-data:
    env:
      CHAINSTREAM_API_KEY: your-key
```

<Note>
  ClawHub Skill 提供 17 個 MCP 工具（15 個核心工具加 2 個 ClawHub 專用工具）。核心工具集詳情請參閱[工具參考](/zh-Hant/docs/ai-agents/mcp-server/introduction)。
</Note>

## 方式三：直接 MCP 配置

直接在 OpenClaw Agent 的配置檔案中配置 ChainStream MCP Server。ChainStream 提供兩種連線模式：

### 雲端端點（推薦）

連線託管的 MCP 端點 — 零安裝，始終最新：

```yaml theme={null}
skills:
  chainstream:
    type: mcp
    url: https://mcp.chainstream.io/mcp
    env:
      CHAINSTREAM_API_KEY: your-key
```

### 本地 npm 包

透過 `@chainstream-io/mcp` npm 包在本地執行 MCP Server。該包代你連線 ChainStream API — 適用於 Agent 框架要求本地 stdio 程序的場景：

```yaml theme={null}
skills:
  chainstream:
    type: mcp
    command: npx
    args:
      - "@chainstream-io/mcp"
    env:
      CHAINSTREAM_API_KEY: your-key
```

詳見 [MCP Server 設定](/zh-Hant/docs/ai-agents/mcp-server/setup) 瞭解 Claude Desktop、Cursor 等客戶端的詳細配置。

## 驗證安裝

使用任意方式安裝後，透過向 OpenClaw Agent 提問來驗證工具是否可用：

```
What ChainStream tools do you have access to?
```

Agent 應列出可用工具，包括 `tokens_search`、`tokens_analyze`、`wallets_profile` 等。

## 下一步

<CardGroup cols={2}>
  <Card title="跨 Agent 相容性" icon="arrows-rotate" href="/zh-Hant/docs/ecosystem/openclaw/cross-agent-compatibility">
    所有支援的 Agent 的完整相容性表格及其配置檔案位置。
  </Card>

  <Card title="安全注意事項" icon="shield" href="/zh-Hant/docs/ecosystem/openclaw/security">
    生產部署的重要安全注意事項。
  </Card>
</CardGroup>
