PaulSeth/gitee-mcp-server
This MCP server lets AI clients inspect and manage Gitee repositories via natural language through six tools and one resource.
get_repo_stats: get star/fork/watch counts and open issue count for a repo.list_stargazers: list users who starred a repo (requires PAT; falls back to mock without credentials).list_issues: list issues filtered by state (open/closed/all) and comma-separated labels.create_issue: create a new issue with title, optional body, and labels.update_issue: update an issue's state and/or labels, e.g. auto-label or close it.generate_changelog: generate a Chinese CHANGELOG from recent commits, with optional max count and since_tag.Resource
gitee://repo/{owner}/{repo}: returns repo stats plus a snapshot of the latest 5 commits.Supports mock mode for demos/no token and real Gitee API v5 mode with
GITEE_ACCESS_TOKEN.
Provides tools for interacting with Gitee repositories via the Gitee API (v5), enabling AI agents to fetch repository stats (stars, forks, watches, open issues), list stargazers, list issues with status/label filters, create and update issues (status/labels), and generate Chinese CHANGELOGs from commit history. Also exposes a gitee://repo/{owner}/{repo} resource returning repo statistics plus a snapshot of the latest 5 commits.
Gitee MCP Server
让任意 AI 模型用自然语言管理 Gitee 仓库的 MCP Server。
一句话就能替你管 Gitee:"social-media-bot-cn-generic 现在多少 star?" "给这几个 issue 打上 bug 标签" "基于最近 commit 帮我生成一份中文 CHANGELOG 贴进 README"。
本 Server 是 MCP(Model Context Protocol) 标准实现,可接入任何支持 MCP 的 AI 客户端(WorkBuddy / Claude Desktop / Cursor / 任意 Agent 框架)。
✨ 功能(v1)
工具 | 作用 |
| 仓库统计:star / fork / watch / 开放 issue 数 |
| 列出点 star 的用户(⚠️ 需 PAT) |
| 列出 Issue,支持按状态/标签过滤 |
| 新建 Issue(收需求/建任务) |
| 更新 Issue 状态/标签(自动打标签/关单) |
| 基于 commit 生成中文 CHANGELOG(Gitee 无原生 API,靠 commits 组合拼出) |
资源:gitee://repo/{owner}/{repo} —— 返回仓库统计 + 最近 5 条 commit 快照,AI 可直接读取。
Related MCP server: Gitingest MCP Server
🚀 快速开始
方式一:npx 直接运行(推荐,无需克隆)
npx -y gitee-mcp首次运行会自动下载;默认 Mock 模式,无需 token 即可演示。
方式二:源码运行
git clone https://gitee.com/jokerbhind/gitee-mcp-server.git
cd gitee-mcp-server
npm install
npm run build
npm start # 默认 Mock 模式,无需 token 即可演示接 WorkBuddy / Claude Desktop
在 ~/.workbuddy/mcp.json(或对应 MCP 配置)中加入:
{
"mcpServers": {
"gitee-mcp-server": {
"command": "npx",
"args": ["-y", "gitee-mcp"]
}
}
}或使用本地构建产物(command 用绝对路径的 node,避免客户端不继承 PATH):
{
"mcpServers": {
"gitee-mcp-server": {
"command": "C:/绝对路径/node.exe",
"args": ["H:/绝对路径/gitee-mcp-server/build/index.js"]
}
}
}🔑 真实模式(Real)
复制 .env.example 为 .env 并填入 Gitee 私人令牌:
cp .env.example .env
# 编辑 .env:填入 GITEE_ACCESS_TOKEN变量 | 说明 |
| Gitee 私人令牌(设置 → 私人令牌,勾选 projects 权限)。stargazers/subscribers 接口强制鉴权,无 token 会 401 |
| 留空=自动判定; |
Server 会自动从项目根目录的 .env 读取(无需设置 cwd),填好 token 后即自动切 Real 模式。
🐶 Dogfood 示例
本项目本身就用 generate_changelog 给 jokerbhind/social-media-bot-cn-generic 生成 CHANGELOG。真实 commit 输出示例:
## CHANGELOG · jokerbhind/social-media-bot-cn-generic
> 基于最近 1 条 commit 自动生成(Gitee MCP Server)
### ✨ 新功能
- feat: 社媒客服 Bot 泛用版 Starter Kit _by PaulSeth(2026-09-03)_这就是「gap filler」的溢价逻辑:Gitee 官方没有 CHANGELOG API,本 Server 用现成的
/commits组合出人人想要的能力。
🧩 架构
AI 模型 ←→ MCP(STDIO) ←→ GiteeMcpServer
│
GiteeService(Mock/Real 双模式路由)
├─ mock.ts 本地快照(无凭证可演示)
└─ api.ts Gitee API v5(填 token 后生效)Mock 模式让公开仓库也能 npm start 直接演示、被 Glama 自动收录,且不泄露任何凭证。
📦 发布与收录
目标 | 状态 | 做法 |
Gitee 公开仓 | ✅ 已上线 | |
GitHub 镜像仓 | ✅ 已上线 | |
npm | ✅ 已发布 v0.1.0 | |
Glama | ✅ 已提交并通过构建检查 | 提交 GitHub 镜像仓 URL 后由 Glama 自动生成镜像跑安全/质量检查 |
MCP Registry | ⏳ 待发布 |
|
本项目的
CHANGELOG.md由 本 Server 的generate_changelog工具自己生成(dogfood)。
Glama 索引的是 GitHub 仓库,故需先将本仓库镜像到 GitHub 再提交。
🗺️ Roadmap(Phase 2,按需再做)
comment_on_issue/pr:AI 自动回复webhook_auto_label:监听 Webhook 自动打标签gitee_to_github_mirror:Gitee↔GitHub 双平台镜像list_pulls/merge_pull:PR 管理create_release:基于 CHANGELOG 自动发版
📄 License
MIT © 2026 Paul (Gitee: jokerbhind / GitHub: PaulSeth)
Available Tools
6 toolscreate_issueB
在仓库新建 Issue(收需求/建任务)
Inputs: repo (required), owner (required), title (required), body, +1 more.
generate_changelogB
基于最近 commit 生成中文 CHANGELOG(Gitee 无原生 API,靠 commits 组合)
Inputs: repo (required), owner (required), max, since_tag.
get_repo_statsB
获取 Gitee 仓库统计:star/fork/watch 数、开放 issue 数
Inputs: repo (required), owner (required).
list_issuesC
列出仓库 Issue,支持按状态/标签过滤
Inputs: repo (required), owner (required), state, labels.
list_stargazersA
列出给仓库点 star 的用户(需 PAT,无凭证走 mock)
Inputs: repo (required), owner (required), page.
update_issueC
更新 Issue 状态或标签(自动打标签/关单)
Inputs: repo (required), owner (required), number (required), state, +1 more.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Each tool addresses a distinct resource or action: repo stats, stargazers, issue listing, issue creation, issue updating, and changelog generation. No two tools overlap enough to cause misselection; get_repo_stats returns aggregate counts while list_issues returns issue objects.
All names follow a consistent snake_case verb_noun pattern (get_repo_stats, list_stargazers, list_issues, create_issue, update_issue, generate_changelog). There are no mixed conventions or vague verbs.
Six tools is well-scoped for a focused Gitee assistant covering stats, stargazers, issue management, and changelog. Each tool has a clear purpose and none appear redundant or trivial.
The issue surface has list/create/update but lacks get-issue detail, delete, and commenting, and there is no direct commit or PR access despite the generic server name. These are notable gaps, though some can be worked around via list_issues and update_issue.
Related MCP Connectors
MCP server for GLM chat completions using Zhipu AI models via AceDataCloud
Related MCP Servers
- AlicenseBqualityDmaintenanceMCP Tool Server for Gitee, supporting the management of repository files/branches, Issues, and Pull Requests.206MIT
- MIT
- MIT
- AlicenseNot gradedqualityDmaintenanceAn MCP server for managing your repositories on Forgejo/Gitea server.70Mozilla Public 2.0