
Qtm4j Mcp Server
io.github.salehrifai42由 GitHub 帳號 salehrifai42 發布v0.1.1更新於 Oct 24, 2026
MCP server for QMetry Test Management for Jira (QTM4J): test cases, cycles, executions, plans.
概覽
針對 QMetry Test Management for Jira(QTM4J)的 MCP 伺服器,提供 87 個工具,讓助理搜尋與管理測試案例、測試週期、執行與測試計畫。
- 可以做什麼
- 搜尋、建立、更新、刪除、封存與複製測試案例,包含測試步驟
- 管理測試週期與測試計畫,並將週期連結至計畫或解除連結
- 讀取與更新測試執行及步驟執行,批次更新執行結果,上傳、列出或刪除執行附件
- 為測試案例、測試週期與測試計畫新增、修改和刪除留言
- 在測試執行與步驟執行上連結或解除連結缺陷,並讀取週期缺陷彙總
- 列出與建立資料夾,連結或執行自動化規則,讀取狀態、優先順序、建置、標籤、元件與自訂欄位等專案中繼資料
- 適用情境
- 適合以 QMetry Test Management for Jira 管理測試的團隊,希望助理在聊天用戶端中查詢或更新測試案例、週期、計畫與執行結果,而不必開啟網頁介面。也適合批次更新執行結果,以及透過隨附流程匯入 Excel 測試案例。
- 執行需求
- 透過 npm 套件 qtm4j-mcp-server 以 stdio 在本機執行,需要 Node.js 18 以上版本。需在 QTM4J_API_KEY 環境變數提供 QMetry API 金鑰,可於 QMetry 的 API Keys 頁面產生。選用變數 QTM4J_REGION 可選擇 US(預設)或 AU 叢集。需要能連線至 QMetry 雲端端點。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Qtm4j Mcp Server,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
QTM4J MCP Server
[npm] [npm downloads] [Node] [License]
An MCP server with 87 tools for QMetry Test Management for Jira (QTM4J). Search and manage test cases, cycles, executions, plans, folders, comments, defects, automation rules, and project metadata from Claude Desktop, Claude Code, VS Code Copilot, Cursor, or any MCP-compatible client.
Distribution:
- npm:
qtm4j-mcp-server - MCP Registry:
io.github.salehrifai42/qtm4j-mcp-server - GitHub:
salehrifai42/qmetrymcp
Quick start (no clone required)
You need a QMetry API key (QMetry → API Keys) and Node.js 18+.
Claude Desktop
Edit your config file and restart Claude:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json - Linux:
~/.config/Claude/claude_desktop_config.json
Claude Code (CLI)
VS Code (GitHub Copilot Agent mode)
Create .vscode/mcp.json in your workspace:
Switch Copilot Chat to Agent mode and the qtm4j_* tools appear automatically.
Cursor
Add to ~/.cursor/mcp.json (or <project>/.cursor/mcp.json for project-level):
The example configs above pin the package to
^0.1so a future breaking release won't auto-upgrade you. Drop the@^0.1suffix if you'd rather always run the latest.
Global install (faster startup)
npx re-resolves the package on every launch, which adds a few seconds of startup latency. If you use the server frequently, install it globally and point your client at the binary directly:
Then in your client config, replace the npx command:
Tradeoff: instant startup and works offline, but you'll need to run npm update -g qtm4j-mcp-server to get new versions.
Configuration
💡 Set
QTM4J_REGION=AUif your QMetry instance is on the Sydney cluster.
Tools
All tools are prefixed with qtm4j_ to avoid collisions with other MCP servers.
See docs/TOOLS.md for the full reference and docs/COOKBOOK.md for example prompts colleagues can paste into any MCP client.
Every tool ships with annotations (readOnlyHint, destructiveHint, idempotentHint, openWorldHint) so clients can decide whether to ask for confirmation. Read tools accept a response_format parameter (json default, or markdown for human-readable output). Large responses are automatically truncated at 25k characters with a hint to narrow the query.
All tools validate inputs with Zod, paginate via startAt/maxResults, and automatically retry rate-limited (HTTP 429) responses with exponential back-off (up to 3 attempts).
Trying it out
Once connected, ask your assistant something like:
Search QMetry project
<your project ID>for test cases with status "To Do" and show me the first 5.
The client will call qtm4j_search_test_cases and render the response.
Get all executions in test cycle
<KEY>-TR-747and mark any unexecuted ones as Pass.
Example tool calls
Replace
<projectId>and<KEY>with your tenant's numeric Jira project ID and project key. Find them in the project URL:…?projectId=<projectId>&projectKey=<KEY>. Useqtm4j_get_execution_resultsto discover your tenant'sexecutionResultIdvalues.
Troubleshooting
- Tools don't appear in my client. Restart the client after editing config. Check
claude mcp list(Claude Code) or VS Code's MCP panel for connection status. On first run,npx -y qtm4j-mcp-servermay take a few seconds to download the package. - 401 Unauthorized. Your
QTM4J_API_KEYis invalid or expired. Generate a new one in QMetry → API Keys. - 404 on execution or search endpoints. Many endpoints want the internal numeric
id, not the human key like<KEY>-TR-747. Callqtm4j_get_test_cyclefirst to translate the key into the internal id. - Empty or oversized folder response. Pass
folderIdtoqtm4j_list_foldersto scope to a subtree — full project trees on large projects can exceed the response size limit. projectIdrejected. Use the numeric Jira project ID, not the project key string. You can find it in the Jira project URL:…?projectId=<numeric-id>&projectKey=<KEY>.
Notes
- Search endpoints use
POST /…/search— filters go in the body underfilter, pagination/sort on the query string. Tool handlers wrap this for you. 204 No Contentresponses resolve as{ message: "…" }.- The Swagger spec does not currently document a framework-style automation import-result endpoint (e.g. JUnit/TestNG/Cucumber ingestion); the automation tools cover the rules-run and rule-link flows exposed in the spec.
Development
Local setup if you want to modify the server:
Test changes with the MCP Inspector:
Run the unit tests (no API key or network needed — the HTTP client's transport is faked in-memory):
Replicating the bulk xlsx import workflow
The repo ships a Claude Code skill (.claude/skills/xlsx-to-qmetry/) and a Python importer (scripts/import-xlsx-to-qmetry.py) for pushing folders of Excel test cases into QMetry. Tenant-specific IDs (project, parent folder, status, custom-field IDs, components) are kept out of git — you supply them in your own config.json.
First-run after cloning:
Discover the IDs you need with the running MCP server (qtm4j_get_projects, qtm4j_get_statuses, qtm4j_get_components, qtm4j_get_custom_fields, qtm4j_list_folders) or with node scripts/refresh-field-reference.mjs to dump everything to field_reference.json.
Then launch Claude Code from the repo root and the xlsx-to-qmetry skill auto-loads. Drop your workbooks under Input/<batch-name>/ and ask Claude to import them — see docs/EXCEL-IMPORT-GUIDE.md for the full workflow.
Bugs and contributions
Found a bug or want to suggest a feature? Open an issue at https://github.com/salehrifai42/qmetrymcp/issues. PRs welcome.
License
來源:README.md,提交 a5a0e2a
工具
0版本歷史
1- v0.1.1最新Sep 16, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分