zenhub-mcp

zenhub-mcp

Provides full access to the ZenHub GraphQL API. Enables project management operations like creating issues, epics, workspaces, and sprints through natural language.

Category
访问服务器

README

ZenHub MCP Server

An MCP (Model Context Protocol) server that provides full access to the ZenHub GraphQL API.

Features

  • Full GraphQL Access: Execute any GraphQL query against the ZenHub API
  • Common Operations: Built-in tools for frequent tasks like creating issues, epics, workspaces, and sprints
  • Secure Authentication: API key-based authentication for all requests
  • Error Handling: Comprehensive error handling and validation

Installation

For Development

npm install
npm run build

Setup API Key

  1. Get your ZenHub API key from ZenHub Settings

  2. Set the environment variable:

export ZENHUB_API_KEY=your_api_key_here

Or create a .env file (copy from .env.example):

cp .env.example .env
# Edit .env and add your API key

For Claude Desktop

  1. Build the server:
npm install
npm run build
  1. Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
  "mcpServers": {
    "zenhub": {
      "command": "npx",
      "args": ["zenhub-mcp-server"],
      "env": {
        "ZENHUB_API_KEY": "your_api_key_here"
      }
    }
  }
}

For Cursor

  1. Build the server:
npm install
npm run build
  1. In Cursor, go to Settings > MCP Servers and add:
{
  "name": "zenhub",
  "command": "node",
  "args": ["/path/to/zenhub-mcp/dist/index.js"],
  "env": {
    "ZENHUB_API_KEY": "zh_",
    "GITHUB_PAT": "github_pat_"
  }
}

Or use the development server:

{
  "name": "zenhub-dev",
  "command": "npm",
  "args": ["run", "dev"],
  "cwd": "/path/to/zenhub-mcp",
  "env": {
    "ZENHUB_API_KEY": "your_api_key_here"
  }
}

Tools

The server provides 54 tools across 10 categories, implementing the most commonly used ZenHub operations:

No API key required in tool calls - Set ZENHUB_API_KEY environment variable once and use all tools!

Query Tools (7 tools)

zenhub_query

Execute any GraphQL query against the ZenHub API.

  • query (required): GraphQL query string
  • variables (optional): Variables for the query

zenhub_search_issues

Search for issues in a pipeline.

  • pipeline_id (required): Pipeline ID to search in
  • query (optional): Search query for title
  • filters (optional): Object with filters for labels and assignees

zenhub_search_issues_in_repository

Search and filter issues inside repository.

  • repository_id (required): Repository ID to search in
  • query (optional): Search query
  • filters (optional): Filter options

zenhub_get_workspace_issues

Get all issues in a workspace (paginated).

  • workspace_id (required): Workspace ID
  • after (optional): Cursor for pagination

zenhub_get_viewer

Get current ZenHub user information.

zenhub_get_issue_by_info

Lookup an issue by repository and issue number.

  • repository_gh_id (required): GitHub repository ID
  • issue_number (required): Issue number

zenhub_get_repositories

Lookup repositories by their GitHub IDs.

  • repository_gh_ids (required): Array of GitHub repository IDs

Issue Management (13 tools)

zenhub_create_issue

Create a new GitHub issue via ZenHub.

  • title (required): Issue title
  • repository_id (required): Repository ID
  • body (optional): Issue description
  • labels (optional): Array of label names
  • assignees (optional): Array of GitHub usernames

zenhub_close_issues

Close one or more issues.

  • issue_ids (required): Array of issue IDs

zenhub_reopen_issues

Reopen one or more closed issues.

  • issue_ids (required): Array of issue IDs
  • pipeline_id (required): Pipeline ID to move issues to
  • position (optional): Position in pipeline (START or END)

zenhub_move_issue

Move issues to a position in a pipeline.

  • issue_ids (required): Array of issue IDs
  • pipeline_id (required): Pipeline ID to move issues to
  • position (optional): Position in pipeline (0-based)

zenhub_add_assignees_to_issues

Add assignees to multiple issues.

  • issue_ids (required): Array of issue IDs
  • assignees (required): Array of GitHub usernames

zenhub_add_labels_to_issues

Add labels to multiple issues.

  • issue_ids (required): Array of issue IDs
  • labels (required): Array of label names

zenhub_set_estimate

Set an estimate for an issue.

  • issue_id (required): Issue ID
  • value (required): Estimate value

zenhub_set_multiple_estimates

Set estimates on multiple issues.

  • estimates (required): Array of issue ID and estimate value pairs

zenhub_add_issues_to_epics

Add issues to epics.

  • issue_ids (required): Array of issue IDs
  • epic_ids (required): Array of epic IDs

Epic Management (1 tool)

zenhub_create_epic

Create a new epic in ZenHub.

  • title (required): Epic title
  • repository_id (required): Repository ID
  • body (optional): Epic description

Workspace Management (4 tools)

zenhub_get_user_workspaces

Get all workspaces accessible to the current user.

  • query (optional): Search query to filter workspaces
  • first (optional): Number of workspaces to return (default: 20)

zenhub_get_user_organizations

Get all ZenHub organizations accessible to the current user.

  • query (optional): Search query to filter organizations
  • first (optional): Number of organizations to return (default: 10)

zenhub_get_organization_workspaces

Get all workspaces within a specific ZenHub organization.

  • organization_id (required): ZenHub organization ID
  • query (optional): Search query to filter workspaces
  • first (optional): Number of workspaces to return (default: 20)

zenhub_create_workspace

Create a new workspace in ZenHub.

  • name (required): Workspace name
  • description (optional): Workspace description
  • organization_id (required): ZenHub organization ID
  • repository_ids (required): Array of GitHub repository IDs
  • default_repository_id (optional): Default repository ID

Sprint Management (2 tools)

zenhub_create_sprint

Create a new sprint.

  • name (required): Sprint name
  • start_date (required): Start date (ISO format)
  • end_date (required): End date (ISO format)
  • workspace_id (required): Workspace ID
  • timezone (optional): Timezone identifier
  • settings (optional): Sprint settings object

zenhub_add_issues_to_sprints

Add issues to sprints.

  • issue_ids (required): Array of issue IDs
  • sprint_ids (required): Array of sprint IDs

Architecture

The server uses a modular architecture for easy expansion:

src/
├── index.ts           # Main MCP server
├── types.ts           # TypeScript interfaces
└── tools/
    ├── index.ts       # Tool registry
    ├── base.ts        # Base tool class
    ├── queries.ts     # Query tools
    ├── issues.ts      # Issue management tools
    ├── epics.ts       # Epic management tools
    ├── workspaces.ts  # Workspace management tools
    └── sprints.ts     # Sprint management tools

Adding New Tools

  1. Create a new tool class extending BaseTool in the appropriate category file
  2. Add it to the tool export array
  3. The tool will automatically be registered with the MCP server

Available Operations Reference

All 176 available ZenHub GraphQL operations are documented in:

  • zenhub_api_operations.json - Complete operation list with descriptions
  • mutations.json - All 157 mutations
  • queries.json - All 19 queries

Current implementation covers 54 of 176 operations (30.7%)

Development

npm run dev

Environment Variables

  • ZENHUB_API_KEY (required): Your ZenHub API key from ZenHub Settings
  • ZENHUB_MCP_CUSTOM_INSTRUCTIONS (optional): Provide additional instructions for the MCP server. If set, this value will be appended to the default instructions that the server sends to the model. Use regular newlines or \n escape sequences to format multi-line prompts.

GraphQL Endpoint

This server connects to: https://api.zenhub.com/public/graphql

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选