ZenTao MCP Server
ZenTao MCP-Server (API V1.0)
Ein ZenTao MCP-Dienst basierend auf TypeScript + Node.js + @modelcontextprotocol/sdk, der Folgendes unterstützt:
Login-Initialisierung (
initZentao)Produkte anzeigen (
getProducts)Meine Bugs anzeigen (
getMyBugs)Bug-Details anzeigen (
getBugDetail)Bug lösen (
resolveBug)Bug aktivieren (
activateBug, erneut öffnen)
1. Umgebungsvorbereitung
npm install
cp .env.example .envBitte konfigurieren Sie die ZenTao-URL und die Authentifizierungsinformationen in .env (es wird empfohlen, Benutzername und Passwort zur Laufzeit über initZentao zu übergeben, anstatt sie im Klartext in Dateien zu speichern).
Related MCP server: ZenTao MCP Server
2. Ausführung über npm / npx (empfohlen für andere Maschinen)
npm-Paketname: @wudidada/zentao-mcp-server (Scoped Package; ausführbarer Befehl zentao-mcp-server).
Anforderungen: Node.js >= 20. Für Linux/macOS wird die Installation von systemweitem curl empfohlen (Standard-HTTP-Backend ist curl).
2.1 Testlauf über die Befehlszeile
npx -y @wudidada/zentao-mcp-serverBeispiel für den HTTP-Modus:
MCP_TRANSPORT=http npx -y @wudidada/zentao-mcp-server2.2 Cursor mcp.json (stdio + Umgebungsvariablen)
Konfigurieren Sie dies in der .cursor/mcp.json im Projekt- oder Benutzerverzeichnis, zum Beispiel:
{
"mcpServers": {
"zentao": {
"command": "npx",
"args": ["-y", "@wudidada/zentao-mcp-server"],
"env": {
"ZENTAO_BASE_URL": "http://your-host/zentao/api.php/v1",
"ZENTAO_ACCOUNT": "your_account",
"ZENTAO_PASSWORD": "your_password",
"ZENTAO_HTTP_BACKEND": "curl",
"LOG_LEVEL": "info"
}
}
}
}Bitte starten Sie Cursor nach der Konfigurationsänderung vollständig neu. Sie können den Paketnamen in args auch auf eine feste Version ändern, z. B. @wudidada/zentao-mcp-server@1.0.1.
2.3 Betreuer: Veröffentlichung auf npm
npm run build
npm test
npm publish --access publicVor der ersten Veröffentlichung ist npm login erforderlich. Stellen Sie sicher, dass die version in der package.json noch nicht vergeben ist.
Quellcode-Repository: https://github.com/wudidada/zentao-mcp-server
3. Startmethoden
stdio (bevorzugt für lokale IDEs)
npm run start:stdioHTTP/SSE (Remote-Zugriff)
npm run start:httpStandard-Port 3000, Gesundheitsprüfung:
curl http://localhost:3000/healthz4. Build und Test
npm run build
npm test5. Erläuterung der MCP-Tool-Parameter
initZentao
baseUrl?: stringaccount: stringpassword?: stringtoken?: string
Wählen Sie entweder
passwordodertoken.
getMyBugs
status?: "active" | "resolved" | "closed" | "all"(Standardactive)productId?: number
getBugDetail
bugId: number
activateBug
bugId: numberassignedTo?: string(Zugewiesen an, Benutzerkonto)openedBuild?: string | string[](Betroffene Versionen, laut Dokumentation ein Array; wenn nicht übergeben, wird standardmäßig["trunk"]verwendet)comment?: string
resolveBug
bugId: numberresolution.resolution: "fixed" | "notrepro" | "duplicate" | "bydesign" | "willnotfix" | "tostory" | "external"resolution.resolvedBuild?: string(Wenn die Lösungfixedist, sendet der Server festtrunk, dieses Feld wird ignoriert, um Anzeigefehler in einigen ZenTao-Weboberflächen zu vermeiden)resolution.duplicateBug?: number(Erforderlich, wennresolution=duplicate)resolution.comment?: string
6. Sicherheits- und Betriebsgrundlagen
Protokolle maskieren standardmäßig
password/token/authorization.Standard-Anfrage-Timeout beträgt
10s.Abfrage-Schnittstellen (GET) unterstützen Wiederholungsversuche mit exponentiellem Backoff.
Der HTTP-Modus bietet eine
/healthz-Gesundheitsprüfung.Wenn
ZENTAO_BASE_URL+ZENTAO_ACCOUNT+ (ZENTAO_PASSWORDoderZENTAO_TOKEN) konfiguriert sind, erfolgt der Login beim Prozessstart automatisch, ohne dassinitZentaojedes Mal aufgerufen werden muss.ZENTAO_HTTP_BACKEND:axiosverwendet das integrierte Node-HTTP;curlruft das System-curlauf. Unter Nicht-Windows-Systemen istcurlStandard, um Probleme zu vermeiden, bei denen einige ZenTao-Instanzen bei "Node-Client +Token-Header + GET" lange nicht reagieren.
6.1 Übersicht der Umgebungsvariablen
Variable | Beschreibung |
| ZenTao API V1 Basis-URL, z. B. |
| Für den automatischen Login (Passwort oder Token wählen) |
|
|
7. Projektstruktur
src/
adapters/ # 禅道 API V1.0 适配层
schemas/ # zod 参数校验
server/ # stdio/http 双入口
services/ # 领域服务
tools/ # MCP 工具实现8. Hinweise
Die aktuelle Implementierung basiert auf den gängigen REST-Pfaden der ZenTao API V1.0 (
/tokens,/bugs,/products).Bug lösen: Die offizielle v1-Schnittstelle ist
POST /bugs/{id}/resolve(nicht PUT). Bei falscher Verwendung von PUT kann es vorkommen, dass die HTTP-Anfrage erfolgreich ist, der Status in ZenTao jedoch nicht aktualisiert wird.Wenn Ihre ZenTao-Instanz andere Pfade oder Authentifizierungsfelder verwendet, können Sie diese in
src/adapters/zentaoApiV1.tsanpassen.
Available Tools
7 toolsactivateBugB
激活(重新打开)Bug,对应禅道 API v1:POST /bugs/{id}/active。适用于已解决/已关闭后重新激活。
Inputs: bugId (required), assignedTo, openedBuild, comment.
getBugDetailBRead-only
查看单个 bug 详情。
Inputs: bugId (required).
getMyBugsBRead-only
按状态与产品筛选我的 bug 列表。
Inputs: status, productId.
getProductsBRead-only
获取禅道产品列表。
Inputs: no named parameters.
healthCheckBRead-only
检查当前会话与服务可用性。
Inputs: no named parameters.
initZentaoC
初始化禅道连接并登录(支持 password 或 token)。
Inputs: baseUrl, account, password, token.
resolveBugC
提交 Bug 解决动作(fixed/notrepro/duplicate/...)。
Inputs: bugId (required), resolution (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 7 tools
Each tool has a clearly distinct purpose with no ambiguity. activateBug, resolveBug, getBugDetail, and getMyBugs handle different bug lifecycle stages and views, while getProducts, healthCheck, and initZentao cover separate administrative and setup functions. The descriptions make it easy to distinguish between tools like activateBug (reopen) and resolveBug (close with resolution).
The naming follows a mostly consistent verb_noun pattern with minor deviations. Tools like activateBug, getBugDetail, getMyBugs, getProducts, and resolveBug use clear action-object naming. However, healthCheck and initZentao deviate slightly by using compound nouns without verbs, though they remain readable and intuitive.
With 7 tools, this server is well-scoped for bug tracking and system management in ZenTao. Each tool earns its place by covering essential operations: bug lifecycle (activate, resolve, view), product listing, and system setup/health. The count is neither too sparse nor bloated, fitting the domain appropriately.
The tool set provides strong coverage for bug management with create, read, update (activate/resolve), and delete implied through resolution. Minor gaps exist, such as no explicit tool for creating bugs or managing other entities like tasks or users, but agents can work around this with the available tools for core workflows.
Maintenance
Related MCP Connectors
Task management for people and AI agents, with scoped OAuth access to issues, projects, and docs.
Task management for people and AI agents, with scoped OAuth access to issues, projects, and docs.
Task and bug tracker for AI coding agents: 75 tools to file, triage and update work.
Manage Loom projects, tasks, bugs, defects, clients and phases from AI assistants
Related MCP Servers
- AlicenseAqualityNot gradedmaintenanceEnables direct integration with Zentao bug tracking systems through Cursor. Supports authentication, bug retrieval, searching, and listing operations for comprehensive bug management through natural language.57 npm-
- FlicenseBqualityNot gradedmaintenanceEnables interaction with ZenTao project management system through RESTful API v1. Supports bug tracking, project/product management, and automated token authentication for seamless integration.102-
- FlicenseAqualityBmaintenanceEnables interaction with ZenTao project management system through RESTful APIs. Supports listing products, managing bugs, viewing statistics, and filtering personal bug assignments through natural language.430 npm16-
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to manage Zentao bugs, requirements, and test cases through natural language interactions. It supports querying, creating, and updating various Zentao data entities including products, projects, and executions.12MIT