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

# 客户端配置指南

> 在 ChatGPT、Claude、Cursor、Gemini、OpenClaw、VS Code 等客户端中连接八爪鱼 MCP。

## 服务地址

```text theme={null}
https://mcp.bazhuayu.com
```

认证方式：**OAuth 2.1**（推荐）或 **API Key**（Header：`x-api-key`）。API Key 创建见 [获取 API Key](/docs/zh/mcp/quick-start/api-key)。

## Agent 对话安装

WorkBuddy、QClaw、豆包专业版等能够自行管理工具配置的 Agent，可直接通过对话添加八爪鱼 MCP。推荐使用[获取 API Key](/docs/zh/mcp/quick-start/api-key)页面提供的完整提示词，让 Agent 写入 `x-api-key` 请求头、刷新工具列表并完成连接测试。

<Note>
  对这类 Agent，应明确要求本次接入仅使用 API Key，不要把 Key 配置成 OAuth 凭据或 `Authorization: Bearer`。不支持自主配置的客户端，请继续按下方平台步骤手动操作。
</Note>

## ChatGPT

1. 打开 ChatGPT → **Settings** → **Connectors**（或「连接器」）。
2. 添加 MCP 连接器，URL 填写 `https://mcp.bazhuayu.com` 或 `https://mcp.octoparse.com`。
3. 选择 **OAuth** 完成八爪鱼登录，或使用 API Key（若界面支持自定义 Header）。
4. 在新对话中启用该连接器后测试搜索模板。

## Claude（桌面 / Web）

1. **Settings** → **Connectors** → **Add connector**。
2. 输入 MCP URL：`https://mcp.bazhuayu.com` 或 `https://mcp.octoparse.com`。
3. 通过 OAuth 授权八爪鱼账户。
4. 在对话中确认已勾选八爪鱼 MCP 工具。

## Claude Code

编辑 `~/.claude/settings.json`：

```json theme={null}
{
  "mcpServers": {
    "octoparse": {
      "type": "http",
      "url": "https://mcp.bazhuayu.com",
      "headers": {
        "x-api-key": "你的APIKey"
      }
    }
  }
}
```

或使用 OAuth 流程（以 Claude Code 当前版本文档为准）。详见 [获取 API Key](/docs/zh/mcp/quick-start/api-key)。

## Cursor

编辑 `~/.cursor/mcp.json`（Windows 为 `%USERPROFILE%\.cursor\mcp.json`）：

```json theme={null}
{
  "mcpServers": {
    "octoparse": {
      "type": "http",
      "url": "https://mcp.bazhuayu.com",
      "headers": {
        "x-api-key": "你的APIKey"
      }
    }
  }
}
```

保存后重启 Cursor，在 **Settings → MCP** 中确认服务在线。

## Gemini

若使用的 Gemini 客户端或 IDE 扩展支持 MCP 连接器：

1. 在 **Settings → MCP / Extensions / Connectors** 中添加 HTTP MCP 服务。
2. URL：`https://mcp.bazhuayu.com` 或 `https://mcp.octoparse.com`。
3. OAuth 登录八爪鱼，或在 Headers 中配置 `x-api-key`。
4. 在对话中启用八爪鱼工具后测试 `list_platforms` 或 `search_templates`。

具体入口名称因 Gemini 集成产品（Google AI Studio、第三方 IDE 插件等）而异，以当前客户端文档为准。

## VS Code（GitHub Copilot）

1. 安装支持 MCP 的 Copilot 扩展版本。
2. 在 `settings.json` 或 MCP 配置文件中添加与 Cursor 相同的 `mcpServers` 块。
3. URL 使用 `https://mcp.bazhuayu.com`，Header 使用 `x-api-key`。

## OpenClaw

OpenClaw 可作为 MCP **客户端**连接八爪鱼（出站 MCP），命令形态因版本而异，典型流程：

1. 确保 OpenClaw Gateway 已运行。
2. 注册八爪鱼 MCP 服务（URL：`https://mcp.bazhuayu.com`，并配置 API Key）。
3. 使用 `openclaw mcp list` 确认工具已加载。

QClaw 用户也可使用 [QClaw 图形界面配置](/docs/zh/mcp/integrations/qclaw)，无需命令行。

## 验证连接

连接成功后，服务端应公开以下 10 个工具。部分客户端会翻译显示名称，但工具标识应保持不变：

* `search_templates`
* `search_tasks`
* `execute_task`
* `export_data`
* `start_or_stop_task`
* `redeem_coupon_code`
* `search_platform_content`
* `list_platforms`
* `ecommerce_data_task`
* `query_collected_reviews`

建议先发送「列出数据中心当前支持的平台」进行只读联调。也可以搜索模板；不要用创建任务、启停任务或兑换优惠码来测试连接。

如果仍只看到旧的 6 个工具，请刷新 MCP 工具列表、断开后重新连接，或重启客户端。服务支持 `tools.listChanged`，但客户端是否自动响应更新取决于其实现。

## 下一步

<CardGroup cols={2}>
  <Card title="工作流程" href="/docs/zh/mcp/workflow">
    搜模板 → 运行 → 导出完整示例。
  </Card>

  <Card title="故障排查" href="/docs/zh/mcp/troubleshooting">
    OAuth 循环、工具不可见等问题。
  </Card>
</CardGroup>
