@qase/mcp-server 2.3.0 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +47 -0
- package/build/index.d.ts +1 -1
- package/build/index.d.ts.map +1 -1
- package/build/index.js +2 -161
- package/build/index.js.map +1 -1
- package/build/operations-v2/composites/ci-report.js +9 -3
- package/build/operations-v2/composites/ci-report.js.map +1 -1
- package/build/operations-v2/composites/regression-run.js +8 -3
- package/build/operations-v2/composites/regression-run.js.map +1 -1
- package/build/operations-v2/composites/triage-defect.js +15 -5
- package/build/operations-v2/composites/triage-defect.js.map +1 -1
- package/build/operations-v2/escape/api.js +27 -5
- package/build/operations-v2/escape/api.js.map +1 -1
- package/build/operations-v2/index.d.ts +2 -0
- package/build/operations-v2/index.d.ts.map +1 -1
- package/build/operations-v2/index.js +2 -0
- package/build/operations-v2/index.js.map +1 -1
- package/build/operations-v2/meta/discover.js +8 -3
- package/build/operations-v2/meta/discover.js.map +1 -1
- package/build/operations-v2/qql/index.js +19 -6
- package/build/operations-v2/qql/index.js.map +1 -1
- package/build/operations-v2/read/get.js +10 -4
- package/build/operations-v2/read/get.js.map +1 -1
- package/build/operations-v2/read/project-context.js +11 -7
- package/build/operations-v2/read/project-context.js.map +1 -1
- package/build/operations-v2/write/attachments.js +17 -8
- package/build/operations-v2/write/attachments.js.map +1 -1
- package/build/operations-v2/write/cases-bulk.js +9 -5
- package/build/operations-v2/write/cases-bulk.js.map +1 -1
- package/build/operations-v2/write/cases.js +16 -6
- package/build/operations-v2/write/cases.js.map +1 -1
- package/build/operations-v2/write/custom-fields.d.ts +2 -0
- package/build/operations-v2/write/custom-fields.d.ts.map +1 -0
- package/build/operations-v2/write/custom-fields.js +226 -0
- package/build/operations-v2/write/custom-fields.js.map +1 -0
- package/build/operations-v2/write/defects.js +26 -4
- package/build/operations-v2/write/defects.js.map +1 -1
- package/build/operations-v2/write/environments.js +11 -3
- package/build/operations-v2/write/environments.js.map +1 -1
- package/build/operations-v2/write/external-issues.js +7 -5
- package/build/operations-v2/write/external-issues.js.map +1 -1
- package/build/operations-v2/write/milestones.js +10 -3
- package/build/operations-v2/write/milestones.js.map +1 -1
- package/build/operations-v2/write/plans.js +11 -3
- package/build/operations-v2/write/plans.js.map +1 -1
- package/build/operations-v2/write/projects.d.ts +2 -0
- package/build/operations-v2/write/projects.d.ts.map +1 -0
- package/build/operations-v2/write/projects.js +77 -0
- package/build/operations-v2/write/projects.js.map +1 -0
- package/build/operations-v2/write/results.js +15 -4
- package/build/operations-v2/write/results.js.map +1 -1
- package/build/operations-v2/write/reviews.js +28 -13
- package/build/operations-v2/write/reviews.js.map +1 -1
- package/build/operations-v2/write/runs.js +20 -3
- package/build/operations-v2/write/runs.js.map +1 -1
- package/build/operations-v2/write/shared-steps.js +11 -3
- package/build/operations-v2/write/shared-steps.js.map +1 -1
- package/build/operations-v2/write/suites.js +17 -5
- package/build/operations-v2/write/suites.js.map +1 -1
- package/build/server-instructions.d.ts +9 -0
- package/build/server-instructions.d.ts.map +1 -0
- package/build/server-instructions.js +21 -0
- package/build/server-instructions.js.map +1 -0
- package/build/server.d.ts +18 -0
- package/build/server.d.ts.map +1 -0
- package/build/server.js +181 -0
- package/build/server.js.map +1 -0
- package/build/transports/sse.d.ts.map +1 -1
- package/build/transports/sse.js +7 -2
- package/build/transports/sse.js.map +1 -1
- package/build/transports/streamableHttp.d.ts.map +1 -1
- package/build/transports/streamableHttp.js +3 -1
- package/build/transports/streamableHttp.js.map +1 -1
- package/build/utils/case-enums.d.ts +6 -0
- package/build/utils/case-enums.d.ts.map +1 -1
- package/build/utils/case-enums.js +11 -3
- package/build/utils/case-enums.js.map +1 -1
- package/build/utils/registry.d.ts.map +1 -1
- package/build/utils/registry.js +11 -3
- package/build/utils/registry.js.map +1 -1
- package/build/utils/server-context.d.ts +26 -6
- package/build/utils/server-context.d.ts.map +1 -1
- package/build/utils/server-context.js +37 -26
- package/build/utils/server-context.js.map +1 -1
- package/build/version.d.ts +1 -1
- package/build/version.js +1 -1
- package/package.json +2 -2
- package/server.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,53 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [2.4.0]
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- **Projects can be created and deleted.** `qase_project_create` takes a title and a code, plus optional description, access level (`all` / `group` / `none`, with a group hash required for `group`) and settings. There is deliberately no upsert: the API has no update endpoint for a project, and an `id`-style switch would imply an edit that cannot happen. `qase_project_delete` takes a code and removes the project with every case, suite, run, result, defect and milestone in it — the most destructive call in the API, and it goes through the confirmation gate like every other deletion.
|
|
13
|
+
|
|
14
|
+
- **Custom fields have a full lifecycle.** `qase_custom_field_upsert` creates a field or, given an `id`, updates one; `qase_custom_field_delete` removes it along with the values entered for it. Reading them already worked through `qase_project_context` and `qase_get`.
|
|
15
|
+
|
|
16
|
+
The tools speak labels where the API speaks numbers: `entity` is `case` / `run` / `defect` and `type` is `number` / `string` / `text` / `selectbox` / `checkbox` / `radio` / `multiselect` / `url` / `user` / `datetime`, mapped to their codes on the way out. Nothing has to know that a selectbox is a 3. Option lists are given as plain strings and wrapped into the objects the API expects.
|
|
17
|
+
|
|
18
|
+
Updating carries over what the call did not mention. The endpoint replaces the record rather than patching it, so a rename that sent only a title used to empty `projects_codes` and unscope the field from every project it belonged to, and a select-type field rejected the update outright with nothing but `Data is invalid` to explain itself. The current placeholder, default value, flags, project scoping and options are read and sent back, option ids included — dropping those would recreate the options and orphan the values already chosen on cases.
|
|
19
|
+
|
|
20
|
+
`entity` and `type` are fixed when a field is created. The update endpoint has no field for either, so passing a different `type` to an update returns a warning saying the field kept its shape and what to do instead, rather than silently accepting a change that never happened.
|
|
21
|
+
|
|
22
|
+
- **Every tool description now says what it does, when to use something else, and what the call costs.** Descriptions averaged 202 characters against the 2000 Claude will read, twenty-one of them under 200, the shortest eighteen — and not one mentioned latency or pointed at a cheaper alternative. Agents behaved accordingly: 518K single-record calls against 242K list calls over thirteen weeks. They now average 578 characters and each ends with a measured `Cost:` line, taken from timing the tools against the live API rather than estimated. The pairs an agent gets wrong cross-reference each other in both directions, with the numbers attached: ten `qase_get` calls measured 5.3s against 1.2s for one `qql_search` returning the same ten records, and ten `qase_case_upsert` calls 5.6s against 1.2s for one `qase_case_bulk_create`. `descriptions.test.ts` holds the line: length bounds, a cost statement in every description, and the cross-references.
|
|
23
|
+
|
|
24
|
+
- **The server now ships `instructions`.** Sent once with the `initialize` response and read before any tool is chosen, they say where to start (`qase_project_context`), when to search rather than fetch (`qql_search`), that hidden tools exist and how to reach them (`qase_discover_tools`), and that batch calls beat loops. Previously the server said nothing about itself and every agent had to infer the map from tool names.
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
|
|
28
|
+
- **No defect could be created at all.** `qase_defect_upsert` and `qase_triage_defect` advertise severity as a label — "blocker", "major" — and forwarded it to an API that takes only the numeric ID from the workspace's `severity` system field, so every attempt came back as a bare `Data is invalid`. Cases have had label normalisation since v2; defects never got it. Both tools now map the label through the same cached system-field lookup, custom options included. Confirmed against the live API on two projects, before and after: `severity: "major"` went from a flat rejection to a created defect. The existing triage test had frozen the broken behaviour by asserting the label was forwarded verbatim; it now asserts the numeric ID.
|
|
29
|
+
|
|
30
|
+
- **`qase_discover_tools` found nothing for the most natural queries.** The search matched the whole query as one literal substring, so `delete project` returned zero results — that exact phrase appears in no tool, even though `qase_project_delete` contains both words. `create custom field` and `delete test case` were empty too. Single words worked, which is why this went unnoticed. It matters more than it looks: every `*_delete` tool and both new pairs are `discoverable`, meaning search is the only way to reach them, so a miss hides them entirely. The query is now split into words, and a tool matches when all of them appear in its name or description.
|
|
31
|
+
|
|
32
|
+
- **`qase_api` could delete without asking.** The escape hatch is annotated `destructiveHint: false` — correctly, since most calls through it read, and a `GET` must not prompt — but that also placed it outside the confirmation gate that every `*_delete` tool goes through. A `DELETE /v1/project/DEMO` therefore removed an entire project unasked, which became harder to justify now that `qase_project_delete` exists and does ask. The handler now requests confirmation itself whenever the method is `DELETE`, naming the path in the prompt. Other methods are untouched.
|
|
33
|
+
|
|
34
|
+
## [2.3.1]
|
|
35
|
+
|
|
36
|
+
### Fixed
|
|
37
|
+
|
|
38
|
+
- **Entities were deleted without the confirmation the server thought it was asking for.** On the HTTP transports — that is, on the hosted connector — the destructive-action gate never worked. A client that does not declare the `elicitation` capability was waved straight through (`return true`), and a client that *does* declare it fared no better: the prompt was sent without a `relatedRequestId`, so the SDK routed it to the standalone SSE stream opened by `GET /mcp`, which MCP clients do not open. With no event store configured the request was dropped in silence, `elicitInput()` waited out its 60-second timeout, and the `catch` around it treated the timeout as a reason to proceed. Every deletion therefore either happened unasked, or froze for a minute and then happened unasked. The confirmation users did see in some clients came from the client's own `destructiveHint` gate, never from this server.
|
|
39
|
+
|
|
40
|
+
Three changes make the prompt arrive and make an unanswered prompt mean *no*: `confirmDestructiveAction()` now passes `relatedRequestId`, so the request travels on the stream of the very `tools/call` that triggered it; the streamable-http transport no longer sets `enableJsonResponse`, because a JSON response cannot carry a server→client request mid-call; and the gate is now fail-closed — it returns a reason (`declined`, `unsupported`, `undeliverable`) instead of a bare boolean, and only an explicit yes lets the deletion run.
|
|
41
|
+
|
|
42
|
+
The prompt asks for no form fields. Accepting it *is* the confirmation, and the client's own decline button is the refusal — an extra "Confirm deletion" checkbox inside the form (which is what this originally sent) only produced false refusals: people accepted the dialog, left the box at its default `false`, and were told they had declined. Verified against Claude Code, which does declare the `elicitation` capability.
|
|
43
|
+
|
|
44
|
+
A refusal explains itself. `unsupported` (the client cannot be asked) and `undeliverable` (the prompt went unanswered) come back with `isError: true` and say what to do about it; a plain `declined` does not, because a human saying no is a decision rather than a failure. Clients that cannot be asked are refused in milliseconds instead of hanging for a minute.
|
|
45
|
+
|
|
46
|
+
- **The legacy HTTP+SSE transport was dead on arrival — every client call failed.** `express.json()` consumes the request body, but `handlePostMessage()` was called without the parsed body, so the SDK tried to read a spent stream and answered `HTTP 400: stream is not readable` to every `tools/call`. Nothing behind `--transport sse` worked, confirmation included. The body is now handed over. The transport is deprecated in the MCP spec (Streamable HTTP replaced it in revision 2025-03-26) and the hosted connector does not use it, but while it ships it should not be broken. It had no test coverage at all; `sse.test.ts` now drives it over real HTTP.
|
|
47
|
+
|
|
48
|
+
- **Two tool descriptions promised behaviour the API does not have**, both found by running the tools against the live API rather than reading the code. `qase_run_complete` claimed a completed run stops accepting results — it does not; results recorded afterwards are accepted and change the run's counts, so completion is a reporting state and not a lock. `qase_suite_delete` claimed that without `delete_cases` the cases move up to the parent suite — they do not; they are deleted with the suite. The `delete_cases` parameter has no effect at all: the server sends `after_delete_case`, a field this endpoint does not accept, so the outcome is the same whether it is true, false or omitted. The endpoint's real mechanism is a destination suite to move cases into, which the tool does not expose. Both descriptions now say what actually happens, and the dead parameter says so in its own description; making it work is left for a separate change.
|
|
49
|
+
|
|
50
|
+
### Changed
|
|
51
|
+
|
|
52
|
+
- **Responses on the streamable-http transport are now SSE rather than JSON**, the default the spec assumes. Any client that ever worked already declares `Accept: application/json, text/event-stream` — the SDK rejects the request otherwise — so no supported client loses the transport.
|
|
53
|
+
- **The 11 `*_delete` tools now refuse to run on clients without the `elicitation` capability.** This is the point of the fix: previously they deleted unasked. Deletions from such a client have to move to a client that supports elicitation, or to the Qase UI.
|
|
54
|
+
|
|
8
55
|
## [2.3.0]
|
|
9
56
|
|
|
10
57
|
### Added
|
package/build/index.d.ts
CHANGED
package/build/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA;;;;;;;;;;;GAWG
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAEA;;;;;;;;;;;GAWG"}
|
package/build/index.js
CHANGED
|
@@ -11,171 +11,12 @@
|
|
|
11
11
|
* - Operation modules self-register their tools on import
|
|
12
12
|
* - All API errors are handled gracefully with user-friendly messages
|
|
13
13
|
*/
|
|
14
|
-
import { Server } from '@modelcontextprotocol/sdk/server/index.js';
|
|
15
14
|
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
|
|
16
|
-
import {
|
|
15
|
+
import { createServer } from './server.js';
|
|
17
16
|
import { toolRegistry } from './utils/registry.js';
|
|
18
|
-
import {
|
|
19
|
-
import { compactResponse } from './utils/response-shape.js';
|
|
20
|
-
import { isRichResult } from './utils/rich-response.js';
|
|
21
|
-
import { serverStorage, confirmDestructiveAction } from './utils/server-context.js';
|
|
22
|
-
import { extractCallMarkers } from './utils/call-markers.js';
|
|
23
|
-
import { parseProducerMarker } from './utils/producer-marker.js';
|
|
24
|
-
import { producerStorage } from './utils/producer-context.js';
|
|
25
|
-
import { callIntegrationStorage } from './utils/integration-context.js';
|
|
17
|
+
import { VERSION } from './version.js';
|
|
26
18
|
import { setupSSETransport } from './transports/sse.js';
|
|
27
19
|
import { setupStreamableHttpTransport } from './transports/streamableHttp.js';
|
|
28
|
-
import { VERSION } from './version.js';
|
|
29
|
-
import { listPrompts, getPrompt } from './prompts/index.js';
|
|
30
|
-
// Import operation modules - each module registers its tools on import
|
|
31
|
-
import './operations-v2/index.js';
|
|
32
|
-
/**
|
|
33
|
-
* Create and configure a new MCP Server instance.
|
|
34
|
-
*
|
|
35
|
-
* Called once for stdio/SSE (single connection) and once per session for
|
|
36
|
-
* Streamable HTTP (multiple concurrent connections). Each session needs its
|
|
37
|
-
* own Server instance because the SDK enforces one transport per server.
|
|
38
|
-
*/
|
|
39
|
-
function createServer() {
|
|
40
|
-
const server = new Server({
|
|
41
|
-
name: 'qase-mcp-server',
|
|
42
|
-
version: VERSION,
|
|
43
|
-
}, {
|
|
44
|
-
capabilities: {
|
|
45
|
-
tools: { listChanged: true },
|
|
46
|
-
prompts: {},
|
|
47
|
-
},
|
|
48
|
-
});
|
|
49
|
-
/**
|
|
50
|
-
* Handler: List all available tools
|
|
51
|
-
*
|
|
52
|
-
* Returns all tools registered in the tool registry.
|
|
53
|
-
* Called when the MCP client wants to discover available tools.
|
|
54
|
-
*/
|
|
55
|
-
server.setRequestHandler(ListToolsRequestSchema, async () => {
|
|
56
|
-
const tools = toolRegistry.getTools();
|
|
57
|
-
console.error(`[Server] Listing ${tools.length} tools`);
|
|
58
|
-
return { tools };
|
|
59
|
-
});
|
|
60
|
-
/**
|
|
61
|
-
* Handler: List available prompts (workflow templates)
|
|
62
|
-
*/
|
|
63
|
-
server.setRequestHandler(ListPromptsRequestSchema, async () => {
|
|
64
|
-
const prompts = listPrompts();
|
|
65
|
-
console.error(`[Server] Listing ${prompts.length} prompts`);
|
|
66
|
-
return { prompts };
|
|
67
|
-
});
|
|
68
|
-
/**
|
|
69
|
-
* Handler: Get a specific prompt with arguments
|
|
70
|
-
*/
|
|
71
|
-
server.setRequestHandler(GetPromptRequestSchema, async (request) => {
|
|
72
|
-
const { name, arguments: args } = request.params;
|
|
73
|
-
console.error(`[Server] Getting prompt: ${name}`);
|
|
74
|
-
return getPrompt(name, args);
|
|
75
|
-
});
|
|
76
|
-
/**
|
|
77
|
-
* Handler: Execute a tool
|
|
78
|
-
*
|
|
79
|
-
* Executes the specified tool with provided arguments.
|
|
80
|
-
* Arguments are validated against the tool's schema before execution.
|
|
81
|
-
*/
|
|
82
|
-
server.setRequestHandler(CallToolRequestSchema, async (request) => {
|
|
83
|
-
return serverStorage.run(server, async () => {
|
|
84
|
-
const { name, arguments: rawArgs } = request.params;
|
|
85
|
-
// The two hidden attribution arguments never reach a tool handler — see
|
|
86
|
-
// call-markers.ts for why they travel as arguments rather than a header.
|
|
87
|
-
const markers = extractCallMarkers(rawArgs);
|
|
88
|
-
const args = markers.rest;
|
|
89
|
-
console.error(`[Server] Executing tool: ${name}`);
|
|
90
|
-
const runCall = async () => {
|
|
91
|
-
// Get tool handler from registry
|
|
92
|
-
const handler = toolRegistry.getHandler(name);
|
|
93
|
-
if (!handler) {
|
|
94
|
-
throw new Error(`Unknown tool: ${name}. Use list_tools to see available tools.`);
|
|
95
|
-
}
|
|
96
|
-
// Elicitation: confirm destructive actions before execution
|
|
97
|
-
const toolDef = toolRegistry.getTool(name);
|
|
98
|
-
if (toolDef?.annotations?.destructiveHint === true) {
|
|
99
|
-
const confirmed = await confirmDestructiveAction(name, args || {});
|
|
100
|
-
if (!confirmed) {
|
|
101
|
-
return {
|
|
102
|
-
content: [{ type: 'text', text: `Action "${name}" cancelled by user.` }],
|
|
103
|
-
};
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
try {
|
|
107
|
-
// Execute the tool handler with provided arguments
|
|
108
|
-
const result = await handler(args || {});
|
|
109
|
-
// Rich results: pass through pre-formatted content blocks directly
|
|
110
|
-
if (isRichResult(result)) {
|
|
111
|
-
return {
|
|
112
|
-
content: result.content,
|
|
113
|
-
...(result.structuredContent && { structuredContent: result.structuredContent }),
|
|
114
|
-
};
|
|
115
|
-
}
|
|
116
|
-
// Default: wrap in compact JSON text block
|
|
117
|
-
const compacted = compactResponse(result);
|
|
118
|
-
const hasOutputSchema = toolDef?.outputSchema !== undefined;
|
|
119
|
-
return {
|
|
120
|
-
content: [
|
|
121
|
-
{
|
|
122
|
-
type: 'text',
|
|
123
|
-
text: JSON.stringify(compacted),
|
|
124
|
-
},
|
|
125
|
-
],
|
|
126
|
-
// SDK requires structuredContent when outputSchema is defined
|
|
127
|
-
...(hasOutputSchema && { structuredContent: compacted }),
|
|
128
|
-
};
|
|
129
|
-
}
|
|
130
|
-
catch (error) {
|
|
131
|
-
// Handle tool execution errors (expected failures like validation, API errors)
|
|
132
|
-
// These are returned with isError: true so the LLM can understand and recover
|
|
133
|
-
if (error instanceof ToolExecutionError) {
|
|
134
|
-
console.error(`[Server] Tool '${name}' execution error:`, error.message);
|
|
135
|
-
return {
|
|
136
|
-
content: [
|
|
137
|
-
{
|
|
138
|
-
type: 'text',
|
|
139
|
-
text: error.toUserMessage(),
|
|
140
|
-
},
|
|
141
|
-
],
|
|
142
|
-
isError: true,
|
|
143
|
-
};
|
|
144
|
-
}
|
|
145
|
-
// Handle unexpected errors (protocol-level failures)
|
|
146
|
-
// Format error message using our error utilities
|
|
147
|
-
const errorMessage = formatApiError(error);
|
|
148
|
-
console.error(`[Server] Tool '${name}' unexpected error:`, errorMessage);
|
|
149
|
-
// Return as tool execution error with isError: true for better LLM recovery
|
|
150
|
-
return {
|
|
151
|
-
content: [
|
|
152
|
-
{
|
|
153
|
-
type: 'text',
|
|
154
|
-
text: errorMessage,
|
|
155
|
-
},
|
|
156
|
-
],
|
|
157
|
-
isError: true,
|
|
158
|
-
};
|
|
159
|
-
}
|
|
160
|
-
};
|
|
161
|
-
// Both scopes stay open for the whole call, so the outbound interceptor
|
|
162
|
-
// sees them however deep in the handler the API request is made.
|
|
163
|
-
const producer = parseProducerMarker(markers.producer);
|
|
164
|
-
const withProducer = producer ? () => producerStorage.run(producer, runCall) : runCall;
|
|
165
|
-
return markers.integration
|
|
166
|
-
? callIntegrationStorage.run(markers.integration, withProducer)
|
|
167
|
-
: withProducer();
|
|
168
|
-
});
|
|
169
|
-
});
|
|
170
|
-
// Wire tool discovery notifications: when tools are activated via qase_discover_tools,
|
|
171
|
-
// notify the client so it re-queries the tool list
|
|
172
|
-
toolRegistry.onToolsChanged = () => {
|
|
173
|
-
server.sendToolListChanged().catch((err) => {
|
|
174
|
-
console.error('[Server] Failed to send tool list changed notification:', err);
|
|
175
|
-
});
|
|
176
|
-
};
|
|
177
|
-
return server;
|
|
178
|
-
}
|
|
179
20
|
/**
|
|
180
21
|
* Parse command line arguments
|
|
181
22
|
*/
|
package/build/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"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C,CAAC;gBAC/C,OAAO,CAAC,KAAK,CAAC,8BAA8B,CAAC,CAAC;gBAC9C,OAAO,CAAC,KAAK,CAAC,6BAA6B,CAAC,CAAC;gBAC7C,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;gBAClB,MAAM;YACR,CAAC;YAED;gBACE,MAAM,IAAI,KAAK,CACb,+BAA+B,SAAS,gDAAgD,CACzF,CAAC;QACN,CAAC;IACH,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;QACjF,OAAO,CAAC,KAAK,CAAC,qCAAqC,CAAC,CAAC;QACrD,OAAO,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;QACjF,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACrB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC;AACH,CAAC;AAED;;GAEG;AACH,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,KAAK,EAAE,EAAE;IACrB,OAAO,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;IACjF,OAAO,CAAC,KAAK,CAAC,qCAAqC,CAAC,CAAC;IACrD,OAAO,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;IACjF,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACrB,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
|
|
@@ -91,9 +91,15 @@ async function handler(args) {
|
|
|
91
91
|
}
|
|
92
92
|
toolRegistry.register({
|
|
93
93
|
name: 'qase_ci_report',
|
|
94
|
-
description: 'Report CI
|
|
95
|
-
'
|
|
96
|
-
'
|
|
94
|
+
description: 'Report a whole CI run in one call: creates the run, records every result, and completes it. ' +
|
|
95
|
+
'This is the tool for a pipeline that has just finished — it replaces qase_run_upsert, then ' +
|
|
96
|
+
'qase_result_record, then qase_run_complete, and leaves no half-open run behind if the agent ' +
|
|
97
|
+
'stops early. Each result needs a numeric `case_id` plus a status, and may carry duration, ' +
|
|
98
|
+
'comment, stacktrace and attachment hashes. Use qase_result_record instead when the run ' +
|
|
99
|
+
'already exists and results arrive in stages; use qase_run_upsert when you need the run left ' +
|
|
100
|
+
'open. Cost: one tool call covering three API operations. A run with two results measured ' +
|
|
101
|
+
'about 0.7s, against roughly 1.5s for the same work as three separate calls, and it grows ' +
|
|
102
|
+
'with the number of results rather than with the number of round trips.',
|
|
97
103
|
schema: Schema,
|
|
98
104
|
handler,
|
|
99
105
|
annotations: CreateAnnotation,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ci-report.js","sourceRoot":"","sources":["../../../src/operations-v2/composites/ci-report.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACvE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC/D,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAElG,MAAM,gBAAgB,GAAG,CAAC,CAAC,MAAM,CAAC;IAChC,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACpC,MAAM,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,QAAQ,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC,CAAC;IACrE,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC9B,OAAO,EAAE,CA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C9F,6FAA6F;QAC7F,8FAA8F;QAC9F,4FAA4F;QAC5F,yFAAyF;QACzF,8FAA8F;QAC9F,2FAA2F;QAC3F,2FAA2F;QAC3F,wEAAwE;IAC1E,MAAM,EAAE,MAAM;IACd,OAAO;IACP,WAAW,EAAE,gBAAgB;IAC7B,YAAY,EAAE,cAAc;CAC7B,CAAC,CAAC"}
|
|
@@ -70,9 +70,14 @@ async function handler(args) {
|
|
|
70
70
|
}
|
|
71
71
|
toolRegistry.register({
|
|
72
72
|
name: 'qase_regression_run',
|
|
73
|
-
description: '
|
|
74
|
-
'
|
|
75
|
-
'
|
|
73
|
+
description: 'Build and start a test run from a suite, a test plan, or an explicit list of case IDs, in ' +
|
|
74
|
+
'one step. Use it to launch a regression cycle without first querying for cases and then ' +
|
|
75
|
+
'creating a run around them — give it the source and it resolves the cases itself. For a run ' +
|
|
76
|
+
'you assemble by hand, use qase_run_upsert and pass the case IDs. For a pipeline that has ' +
|
|
77
|
+
'already finished and just needs its results filed, use qase_ci_report instead: this tool ' +
|
|
78
|
+
'opens a run, it does not close one. Cost: two API calls behind one tool call — resolving the ' +
|
|
79
|
+
'source, then creating the run — roughly 1s, growing with the number of cases the source ' +
|
|
80
|
+
'resolves to.',
|
|
76
81
|
schema: Schema,
|
|
77
82
|
handler,
|
|
78
83
|
annotations: CreateAnnotation,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"regression-run.js","sourceRoot":"","sources":["../../../src/operations-v2/composites/regression-run.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACvE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAA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K,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,EAAE,SAAS,CAAC,UAAU,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC;AACzF,CAAC;AAED,YAAY,CAAC,QAAQ,CAAC;IACpB,IAAI,EAAE,qBAAqB;IAC3B,WAAW,EACT,4FAA4F;QAC5F,0FAA0F;QAC1F,8FAA8F;QAC9F,2FAA2F;QAC3F,2FAA2F;QAC3F,+FAA+F;QAC/F,0FAA0F;QAC1F,cAAc;IAChB,MAAM,EAAE,MAAM;IACd,OAAO;IACP,WAAW,EAAE,gBAAgB;IAC7B,YAAY,EAAE,mBAAmB;CAClC,CAAC,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { getApiClient } from '../../client/index.js';
|
|
3
|
+
import { normalizeEnumFields } from '../../utils/case-enums.js';
|
|
3
4
|
import { toolRegistry, CreateAnnotation } from '../../utils/registry.js';
|
|
4
5
|
import { toResultAsync, createToolError } from '../../utils/errors.js';
|
|
5
6
|
import { ProjectCodeSchema } from '../../utils/validation.js';
|
|
@@ -24,7 +25,10 @@ const Schema = z.object({
|
|
|
24
25
|
});
|
|
25
26
|
async function handler(args) {
|
|
26
27
|
const client = getApiClient();
|
|
27
|
-
const { code, ...
|
|
28
|
+
const { code, ...rest } = args;
|
|
29
|
+
// Same as qase_defect_upsert: the API wants severity as a numeric ID and
|
|
30
|
+
// rejects the label with a bare "Data is invalid".
|
|
31
|
+
const defectData = await normalizeEnumFields(rest, ['severity']);
|
|
28
32
|
// Create defect
|
|
29
33
|
const defectRes = await toResultAsync(client.defects.createDefect(code, defectData));
|
|
30
34
|
const defect = defectRes.match((r) => r.data.result, (e) => {
|
|
@@ -55,10 +59,16 @@ async function handler(args) {
|
|
|
55
59
|
}
|
|
56
60
|
toolRegistry.register({
|
|
57
61
|
name: 'qase_triage_defect',
|
|
58
|
-
description: 'Create a defect from a test failure
|
|
59
|
-
'
|
|
60
|
-
'
|
|
61
|
-
'
|
|
62
|
+
description: 'Create a defect from a test failure, with the failure context written into it. Requires ' +
|
|
63
|
+
'title, actual_result and severity — the API rejects a defect missing any of the three. ' +
|
|
64
|
+
'Note: the API offers no way to attach existing runs or results to a defect. The runs and ' +
|
|
65
|
+
'results seen on a defect in the UI are populated by the test runner when it reports a ' +
|
|
66
|
+
'result as a defect, so there is nothing to pass here for that — reference the failing ' +
|
|
67
|
+
'results inside actual_result instead, and do not expect a link to appear. For a defect ' +
|
|
68
|
+
'unrelated to a test failure use qase_defect_upsert. Cost: one API call, about 0.5s. ' +
|
|
69
|
+
'Triaging a whole run means ' +
|
|
70
|
+
'one call per defect, so cluster identical failures and file one defect per distinct cause ' +
|
|
71
|
+
'rather than one per failed test.',
|
|
62
72
|
schema: Schema,
|
|
63
73
|
handler,
|
|
64
74
|
annotations: CreateAnnotation,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"triage-defect.js","sourceRoot":"","sources":["../../../src/operations-v2/composites/triage-defect.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AACzE,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACvE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAC;AACnE,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAEnF,MAAM,MAAM,GAAG,CAAC,CAAC,MAAM,CAAC;IACtB,IAAI,EAAE,iBAAiB;IACvB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,CAA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AAC,UAAU,CAAC,CAAC,EAAE,UAAU,CAAC,CAAC;AACzF,CAAC;AAED,YAAY,CAAC,QAAQ,CAAC;IACpB,IAAI,EAAE,oBAAoB;IAC1B,WAAW,EACT,0FAA0F;QAC1F,yFAAyF;QACzF,2FAA2F;QAC3F,wFAAwF;QACxF,wFAAwF;QACxF,yFAAyF;QACzF,sFAAsF;QACtF,6BAA6B;QAC7B,4FAA4F;QAC5F,kCAAkC;IACpC,MAAM,EAAE,MAAM;IACd,OAAO;IACP,WAAW,EAAE,gBAAgB;IAC7B,YAAY,EAAE,kBAAkB;CACjC,CAAC,CAAC"}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { getApiClient } from '../../client/index.js';
|
|
3
3
|
import { toolRegistry } from '../../utils/registry.js';
|
|
4
|
+
import { confirmDestructiveAction, describeRefusal } from '../../utils/server-context.js';
|
|
5
|
+
import { ToolExecutionError } from '../../utils/errors.js';
|
|
4
6
|
const Schema = z.object({
|
|
5
7
|
method: z.enum(['GET', 'POST', 'PUT', 'PATCH', 'DELETE']).default('GET').describe('HTTP method'),
|
|
6
8
|
path: z.string().min(1).describe('API path starting with /v1/ (e.g., "/v1/project/DEMO/run")'),
|
|
@@ -10,6 +12,22 @@ const Schema = z.object({
|
|
|
10
12
|
async function handler(args) {
|
|
11
13
|
const client = getApiClient();
|
|
12
14
|
const { method, path, body, query } = args;
|
|
15
|
+
// The tool is annotated destructiveHint: false, because most calls through it
|
|
16
|
+
// read — a GET must not prompt. That leaves DELETE outside the annotation
|
|
17
|
+
// gate, and a DELETE here reaches endpoints no dedicated tool covers, up to
|
|
18
|
+
// removing a whole project. So ask on the method actually used.
|
|
19
|
+
if (method === 'DELETE') {
|
|
20
|
+
const confirmation = await confirmDestructiveAction('qase_api', { method, path });
|
|
21
|
+
if (!confirmation.allowed) {
|
|
22
|
+
const text = describeRefusal(`qase_api (DELETE ${path})`, confirmation.reason);
|
|
23
|
+
// A decline is the user's decision, so it comes back as an ordinary
|
|
24
|
+
// result; the other reasons are failures the caller has to act on, and
|
|
25
|
+
// throwing is what gets them `isError: true` from the tools/call handler.
|
|
26
|
+
if (confirmation.reason === 'declined')
|
|
27
|
+
return { cancelled: true, message: text };
|
|
28
|
+
throw new ToolExecutionError(text);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
13
31
|
return client.request(path, {
|
|
14
32
|
method,
|
|
15
33
|
data: body,
|
|
@@ -18,11 +36,15 @@ async function handler(args) {
|
|
|
18
36
|
}
|
|
19
37
|
toolRegistry.register({
|
|
20
38
|
name: 'qase_api',
|
|
21
|
-
description: '
|
|
22
|
-
'
|
|
23
|
-
'
|
|
24
|
-
'
|
|
25
|
-
'
|
|
39
|
+
description: 'Call any Qase REST endpoint directly, for the few things no dedicated tool covers. Pass the ' +
|
|
40
|
+
'HTTP method, a path starting with /v1/, and an optional body or query. See ' +
|
|
41
|
+
'developers.qase.io for the reference. Prefer a dedicated tool wherever one exists: they ' +
|
|
42
|
+
'normalize enums, validate arguments before spending a round trip, and shape the response for ' +
|
|
43
|
+
'a model. This one hands back whatever the API returns. It sends JSON only and cannot upload ' +
|
|
44
|
+
'files — multipart uploads go through qase_attachment_upload. A DELETE through this tool asks ' +
|
|
45
|
+
'for confirmation the same way the dedicated delete tools do. Cost: one API call, typically ' +
|
|
46
|
+
'0.3-1.5s depending on the endpoint. No caching, no pagination help, no retries beyond the ' +
|
|
47
|
+
'client defaults.',
|
|
26
48
|
schema: Schema,
|
|
27
49
|
handler,
|
|
28
50
|
annotations: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.js","sourceRoot":"","sources":["../../../src/operations-v2/escape/api.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":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AAM,wBAAwB,CAAC,UAAU,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;QAClF,IAAI,CAAC,YAAY,CAAC,OAAO,EAAE,CAAC;YAC1B,MAAM,IAAI,GAAG,eAAe,CAAC,oBAAoB,IAAI,GAAG,EAAE,YAAY,CAAC,MAAM,CAAC,CAAC;YAC/E,oEAAoE;YACpE,uEAAuE;YACvE,0EAA0E;YAC1E,IAAI,YAAY,CAAC,MAAM,KAAK,UAAU;gBAAE,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;YAClF,MAAM,IAAI,kBAAkB,CAAC,IAAI,CAAC,CAAC;QACrC,CAAC;IACH,CAAC;IAED,OAAO,MAAM,CAAC,OAAO,CAAC,IAAI,EAAE;QAC1B,MAAM;QACN,IAAI,EAAE,IAAI;QACV,MAAM,EAAE,KAAK;KACd,CAAC,CAAC;AACL,CAAC;AAED,YAAY,CAAC,QAAQ,CAAC;IACpB,IAAI,EAAE,UAAU;IAChB,WAAW,EACT,8FAA8F;QAC9F,6EAA6E;QAC7E,0FAA0F;QAC1F,+FAA+F;QAC/F,8FAA8F;QAC9F,+FAA+F;QAC/F,6FAA6F;QAC7F,4FAA4F;QAC5F,kBAAkB;IACpB,MAAM,EAAE,MAAM;IACd,OAAO;IACP,WAAW,EAAE;QACX,YAAY,EAAE,KAAK;QACnB,eAAe,EAAE,KAAK;QACtB,cAAc,EAAE,KAAK;QACrB,aAAa,EAAE,IAAI;KACpB;CACF,CAAC,CAAC"}
|
|
@@ -14,6 +14,8 @@ import './write/environments.js';
|
|
|
14
14
|
import './write/attachments.js';
|
|
15
15
|
import './write/external-issues.js';
|
|
16
16
|
import './write/reviews.js';
|
|
17
|
+
import './write/projects.js';
|
|
18
|
+
import './write/custom-fields.js';
|
|
17
19
|
import './composites/ci-report.js';
|
|
18
20
|
import './composites/triage-defect.js';
|
|
19
21
|
import './composites/regression-run.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/operations-v2/index.ts"],"names":[],"mappings":"AACA,OAAO,2BAA2B,CAAC;AACnC,OAAO,eAAe,CAAC;AAGvB,OAAO,gBAAgB,CAAC;AAGxB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,iBAAiB,CAAC;AACzB,OAAO,oBAAoB,CAAC;AAC5B,OAAO,oBAAoB,CAAC;AAC5B,OAAO,mBAAmB,CAAC;AAC3B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,kBAAkB,CAAC;AAC1B,OAAO,yBAAyB,CAAC;AACjC,OAAO,yBAAyB,CAAC;AACjC,OAAO,wBAAwB,CAAC;AAChC,OAAO,4BAA4B,CAAC;AACpC,OAAO,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/operations-v2/index.ts"],"names":[],"mappings":"AACA,OAAO,2BAA2B,CAAC;AACnC,OAAO,eAAe,CAAC;AAGvB,OAAO,gBAAgB,CAAC;AAGxB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,iBAAiB,CAAC;AACzB,OAAO,oBAAoB,CAAC;AAC5B,OAAO,oBAAoB,CAAC;AAC5B,OAAO,mBAAmB,CAAC;AAC3B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,kBAAkB,CAAC;AAC1B,OAAO,yBAAyB,CAAC;AACjC,OAAO,yBAAyB,CAAC;AACjC,OAAO,wBAAwB,CAAC;AAChC,OAAO,4BAA4B,CAAC;AACpC,OAAO,oBAAoB,CAAC;AAC5B,OAAO,qBAAqB,CAAC;AAC7B,OAAO,0BAA0B,CAAC;AAGlC,OAAO,2BAA2B,CAAC;AACnC,OAAO,+BAA+B,CAAC;AACvC,OAAO,gCAAgC,CAAC;AAGxC,OAAO,oBAAoB,CAAC;AAG5B,OAAO,iBAAiB,CAAC"}
|
|
@@ -17,6 +17,8 @@ import './write/environments.js';
|
|
|
17
17
|
import './write/attachments.js';
|
|
18
18
|
import './write/external-issues.js';
|
|
19
19
|
import './write/reviews.js';
|
|
20
|
+
import './write/projects.js';
|
|
21
|
+
import './write/custom-fields.js';
|
|
20
22
|
// Composites
|
|
21
23
|
import './composites/ci-report.js';
|
|
22
24
|
import './composites/triage-defect.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/operations-v2/index.ts"],"names":[],"mappings":"AAAA,aAAa;AACb,OAAO,2BAA2B,CAAC;AACnC,OAAO,eAAe,CAAC;AAEvB,YAAY;AACZ,OAAO,gBAAgB,CAAC;AAExB,cAAc;AACd,OAAO,kBAAkB,CAAC;AAC1B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,iBAAiB,CAAC;AACzB,OAAO,oBAAoB,CAAC;AAC5B,OAAO,oBAAoB,CAAC;AAC5B,OAAO,mBAAmB,CAAC;AAC3B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,kBAAkB,CAAC;AAC1B,OAAO,yBAAyB,CAAC;AACjC,OAAO,yBAAyB,CAAC;AACjC,OAAO,wBAAwB,CAAC;AAChC,OAAO,4BAA4B,CAAC;AACpC,OAAO,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/operations-v2/index.ts"],"names":[],"mappings":"AAAA,aAAa;AACb,OAAO,2BAA2B,CAAC;AACnC,OAAO,eAAe,CAAC;AAEvB,YAAY;AACZ,OAAO,gBAAgB,CAAC;AAExB,cAAc;AACd,OAAO,kBAAkB,CAAC;AAC1B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,iBAAiB,CAAC;AACzB,OAAO,oBAAoB,CAAC;AAC5B,OAAO,oBAAoB,CAAC;AAC5B,OAAO,mBAAmB,CAAC;AAC3B,OAAO,uBAAuB,CAAC;AAC/B,OAAO,kBAAkB,CAAC;AAC1B,OAAO,yBAAyB,CAAC;AACjC,OAAO,yBAAyB,CAAC;AACjC,OAAO,wBAAwB,CAAC;AAChC,OAAO,4BAA4B,CAAC;AACpC,OAAO,oBAAoB,CAAC;AAC5B,OAAO,qBAAqB,CAAC;AAC7B,OAAO,0BAA0B,CAAC;AAElC,aAAa;AACb,OAAO,2BAA2B,CAAC;AACnC,OAAO,+BAA+B,CAAC;AACvC,OAAO,gCAAgC,CAAC;AAExC,aAAa;AACb,OAAO,oBAAoB,CAAC;AAE5B,eAAe;AACf,OAAO,iBAAiB,CAAC"}
|
|
@@ -68,9 +68,14 @@ async function handler(args) {
|
|
|
68
68
|
}
|
|
69
69
|
toolRegistry.register({
|
|
70
70
|
name: 'qase_discover_tools',
|
|
71
|
-
description: '
|
|
72
|
-
'
|
|
73
|
-
'
|
|
71
|
+
description: 'Find and switch on tools that are hidden by default. Only core tools appear in the tool ' +
|
|
72
|
+
'list; deletes, shared steps and parameters, attachments, external issue links, case reviews, ' +
|
|
73
|
+
'defect triage, and project and custom-field management all exist but stay hidden until ' +
|
|
74
|
+
'discovered. Search by what you are trying to do — "delete", "milestone", "attachment", ' +
|
|
75
|
+
'"review", "custom field" — and matching tools are activated and become callable. Every word ' +
|
|
76
|
+
"in the query must appear in a tool's name or description, so prefer two or three words over " +
|
|
77
|
+
'a sentence. Never conclude a capability is missing without searching here first. Cost: no ' +
|
|
78
|
+
'API call, matching happens in memory, about 3ms. Free to call as often as needed.',
|
|
74
79
|
schema: Schema,
|
|
75
80
|
handler,
|
|
76
81
|
annotations: ReadAnnotation,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"discover.js","sourceRoot":"","sources":["../../../src/operations-v2/meta/discover.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACvE,OAAO,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AA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