Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
ZENTAO_ACCOUNTNoZenTao account name. Overrides the connection info in config.json.
ZENTAO_BASE_URLNoZenTao base URL, e.g. https://iip.sgai.com.cn/zentao. Overrides the connection info in config.json.
ZENTAO_INSECURENoSet to true to allow self-signed certificates on internal networks (equivalent to insecure: true in config.json).
ZENTAO_PASSWORDNoZenTao password. Overrides the connection info in config.json; kept locally and never sent to the model. Alternative to ZENTAO_SESSION_COOKIE.
ZENTAO_AUTOFIX_HOMENoDirectory used to store the configuration (defaults to ~/.zentao-autofix, containing config.json).
ZENTAO_SESSION_COOKIENoBrowser session cookie value (zentaosid), used instead of a password when the ZenTao instance has no REST API or you do not want to hand over the password. Only written to the local config.json and masked when shown.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

zentao-autofix:把禅道缺陷自动修掉的 MCP 服务。

标准流程:

  1. zentao_config {action:"set", baseUrl, account, password} —— 禅道地址 + 账号(会登录验证)

  2. zentao_config {action:"add_repo", product:"禅道里的所属产品名", repoPath:"本地仓库绝对路径"} —— 一个产品一条

  3. zentao_login —— 确认能登进去

  4. 循环:zentao_next → 拿上下文包 → 改代码 → zentao_report(fixed/failed)→ 再 zentao_next

  5. zentao_next 返回 action="stop" 时停止,它自带汇总;也可随时 zentao_run {action:"summary"}

铁律:

  • 改数据的缺陷(补数据、跑 SQL、订正台账、数据迁移)一律不碰,插件会自动跳过;不要绕过它。

  • 只改与这条缺陷相关的代码,不顺手重构,不改无关文件。

  • 每条都必须 zentao_report 回填,否则汇总不完整。

  • 默认只读(不写回禅道)。要写回先 zentao_config {action:"set", readonly:false},并且必须由人确认。

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}

Tools

Functions exposed to the LLM to take actions

NameDescription
zentao_configA

读取/修改本机禅道自动修复配置:禅道地址与账号、产品→代码仓库字典、修复策略。action=show 看当前配置(密码打码);action=set 改禅道连接或策略;action=add_repo 加一条「所属产品→仓库」映射;action=remove_repo 删一条;action=init 生成默认配置文件。

zentao_loginA

验证禅道登录是否可用(需求①:地址要能登录验证)。自动探测 REST API v1 token 与网页 Cookie 两条通道,成功后缓存凭证;force=true 强制重新登录。

zentao_productsA

列出禅道产品,并对照产品→仓库字典,标出哪些产品还没有配仓库(需求③的所有权归使用者,这里只做缺口提示,不猜路径)。

zentao_bugsA

读取禅道「指派给我」的缺陷,并逐条给出预判:能否自动修(fixable)、阻塞原因、以及改数据/改代码分类。改数据的缺陷在这里就会被标成跳过(需求④),不会进入修复队列。

zentao_bugA

看一条缺陷的完整信息 + 预判结论 + 对应仓库快照(分支/脏文件/最近提交)+ 关键词相关文件线索。这是真正动手改代码前的上下文包。

zentao_nextA

【核心循环】取「下一条该修的缺陷」,或告诉智能体停下来。会自动:拉取缺陷 → 跳过改数据的(需求④)→ 跳过没配仓库/超策略的 → 挑一条按优先级排序 → 返回完整上下文包。当没有可修的、或达到本轮上限、或连续失败过多时,返回 action="stop" 并附汇总(需求⑤)。

zentao_reportA

回填一条缺陷的修复结果,并告诉智能体下一步(继续下一条 / 停止并汇总)。outcome=fixed 时建议填 rootCause/fix/files/verify;outcome=failed 时填 reason。若配置里 writeBack=true 且非只读,会同时把结论评论回禅道并要求确认是否标记解决。

zentao_runA

查看/结束修复轮次。action=status 看当前进度;action=summary 出汇总报告(需求⑤);action=stop 手动停止并汇总;action=list 列历史轮次;action=resume 把已停止的轮次重新打开。

zentao_doctorA

环境自检:配置是否齐、凭证是否有效、各仓库路径是否可用、git 是否就绪。出问题先跑这个。

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A3.9/5.0

Scored across 9 tools

Disambiguation4/5

Most tools have clearly distinct roles: environment check (doctor), auth (login), config, product gap listing, and the core next→report loop. The only genuinely confusable pair is zentao_bugs (list with predictions) vs zentao_bug (single bug context pack), distinguished only by singular/plural. zentao_next also re-does some of zentao_bugs' filtering, and zentao_run overlaps slightly with zentao_report on 'summary/stop', but descriptions make the boundaries workable.

Naming Consistency4/5

All tools share a consistent zentao_ snake_case prefix with single-word nouns, which is predictable. The deviation is that names are pure nouns plus an action parameter (zentao_run, zentao_config) rather than verb_noun, and the singular/plural pair zentao_bug/zentao_bugs is a real readability hazard. Still coherent overall, just not a strict verb_noun convention.

Tool Count5/5

Nine tools is well within the ideal 3-15 range and each one maps to a distinct stage of the autofix lifecycle (auth, doctor, config, products, list, detail, next, report, run). Nothing feels redundant enough to cut, and nothing essential is obviously missing at this granularity.

Completeness4/5

The surface covers setup (config/login/doctor), discovery (products/bugs/bug), the fix loop (next/report), and session lifecycle (run with status/summary/stop/list/resume) — a full workflow arc. Gaps: there is no explicit tool to mark a bug resolved/closed in Zentao (report only hints at confirmation) and no batch/report-all operation, but agents can work around both within the stated loop.