@qa-ai-stlc/mcp-server 0.1.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/README.md ADDED
@@ -0,0 +1,15 @@
1
+ # @qa-ai-stlc/mcp-server
2
+
3
+ A local stdio MCP server over `@qa-ai-stlc/core`: a tool registry with Zod input/output schemas
4
+ (AGENTS.md 12.3). A `ToolDefinition`'s `handler` returns a value matching its `outputSchema` or
5
+ throws — a `QaError` for an expected failure, anything else for a bug — and `registerTool` turns
6
+ that into a structured `CallToolResult` carrying a stable `code` and, when there is one, a
7
+ `remediation`, never a raw stack trace. The server calls no model itself; it is driven by the
8
+ agent host's own model over the MCP protocol.
9
+
10
+ `qa-mcp-server` starts the stdio server with the built-in tools (currently `qa.ping`, a health
11
+ check that does not touch `.qa/`). The engine-operation tools (doctor, explore, scope, cases,
12
+ approve, validate, report) are a separate, later task.
13
+
14
+ Part of [QA-AI-STLC](https://github.com/Klim-101/QA-AI-STLC). See the repository root for
15
+ license, contributing and security information.
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=mcp-server.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mcp-server.d.ts","sourceRoot":"","sources":["../../src/bin/mcp-server.ts"],"names":[],"mappings":""}
@@ -0,0 +1,10 @@
1
+ #!/usr/bin/env node
2
+ // Copyright The QA-AI-STLC Authors
3
+ // SPDX-License-Identifier: Apache-2.0
4
+ import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
5
+ import { readPackageVersion } from '../package-version.js';
6
+ import { createQaMcpServer } from '../server.js';
7
+ import { BUILTIN_TOOLS } from '../tools/index.js';
8
+ const server = createQaMcpServer({ version: readPackageVersion(), tools: BUILTIN_TOOLS });
9
+ await server.connect(new StdioServerTransport());
10
+ //# sourceMappingURL=mcp-server.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mcp-server.js","sourceRoot":"","sources":["../../src/bin/mcp-server.ts"],"names":[],"mappings":";AACA,mCAAmC;AACnC,sCAAsC;AAEtC,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,MAAM,MAAM,GAAG,iBAAiB,CAAC,EAAE,OAAO,EAAE,kBAAkB,EAAE,EAAE,KAAK,EAAE,aAAa,EAAE,CAAC,CAAC;AAC1F,MAAM,MAAM,CAAC,OAAO,CAAC,IAAI,oBAAoB,EAAE,CAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ export * from './tool.js';
2
+ export * from './tool-error.js';
3
+ export * from './registry.js';
4
+ export * from './server.js';
5
+ export * from './package-version.js';
6
+ export * from './tools/index.js';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,kBAAkB,CAAC"}
package/dist/index.js ADDED
@@ -0,0 +1,9 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ export * from './tool.js';
4
+ export * from './tool-error.js';
5
+ export * from './registry.js';
6
+ export * from './server.js';
7
+ export * from './package-version.js';
8
+ export * from './tools/index.js';
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAEtC,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,cAAc,kBAAkB,CAAC"}
@@ -0,0 +1,3 @@
1
+ /** The published version of this server package, read from its own `package.json`. */
2
+ export declare function readPackageVersion(): string;
3
+ //# sourceMappingURL=package-version.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"package-version.d.ts","sourceRoot":"","sources":["../src/package-version.ts"],"names":[],"mappings":"AAKA,sFAAsF;AACtF,wBAAgB,kBAAkB,IAAI,MAAM,CAI3C"}
@@ -0,0 +1,10 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ import { createRequire } from 'node:module';
4
+ /** The published version of this server package, read from its own `package.json`. */
5
+ export function readPackageVersion() {
6
+ const require = createRequire(import.meta.url);
7
+ const packageJson = require('../package.json');
8
+ return packageJson.version;
9
+ }
10
+ //# sourceMappingURL=package-version.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"package-version.js","sourceRoot":"","sources":["../src/package-version.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAEtC,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAE5C,sFAAsF;AACtF,MAAM,UAAU,kBAAkB;IAChC,MAAM,OAAO,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAC/C,MAAM,WAAW,GAAG,OAAO,CAAC,iBAAiB,CAAiC,CAAC;IAC/E,OAAO,WAAW,CAAC,OAAO,CAAC;AAC7B,CAAC"}
@@ -0,0 +1,11 @@
1
+ import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ import type { z } from 'zod';
3
+ import type { ToolDefinition } from './tool.js';
4
+ /**
5
+ * Registers `definition` on `server`, adapting its `z.ZodObject` schemas into the SDK's raw-shape
6
+ * tool API. A thrown error becomes a structured, coded `CallToolResult` (AGENTS.md 5.4, 12.3)
7
+ * built here, rather than reaching the SDK's own generic catch, which would collapse it to a bare
8
+ * message string and drop the `code`/`remediation` an agent needs to act on it.
9
+ */
10
+ export declare function registerTool<Input extends z.ZodObject, Output extends z.ZodObject>(server: McpServer, definition: ToolDefinition<Input, Output>): void;
11
+ //# sourceMappingURL=registry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEzE,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAC7B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAGhD;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,KAAK,SAAS,CAAC,CAAC,SAAS,EAAE,MAAM,SAAS,CAAC,CAAC,SAAS,EAChF,MAAM,EAAE,SAAS,EACjB,UAAU,EAAE,cAAc,CAAC,KAAK,EAAE,MAAM,CAAC,GACxC,IAAI,CAyBN"}
@@ -0,0 +1,33 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ import { toToolErrorPayload } from './tool-error.js';
4
+ /**
5
+ * Registers `definition` on `server`, adapting its `z.ZodObject` schemas into the SDK's raw-shape
6
+ * tool API. A thrown error becomes a structured, coded `CallToolResult` (AGENTS.md 5.4, 12.3)
7
+ * built here, rather than reaching the SDK's own generic catch, which would collapse it to a bare
8
+ * message string and drop the `code`/`remediation` an agent needs to act on it.
9
+ */
10
+ export function registerTool(server, definition) {
11
+ server.registerTool(definition.name, {
12
+ description: definition.description,
13
+ inputSchema: definition.inputSchema.shape,
14
+ outputSchema: definition.outputSchema.shape,
15
+ }, async (rawInput) => {
16
+ try {
17
+ // The SDK already validated `rawInput` against `definition.inputSchema.shape` before
18
+ // calling this handler, so it is a real `z.infer<Input>` at runtime; TypeScript cannot
19
+ // prove that through two layers of generic indirection (registerTool's own generics,
20
+ // then the SDK's), so the cast documents an invariant the SDK enforces, not a bypass.
21
+ const output = await definition.handler(rawInput);
22
+ return {
23
+ content: [{ type: 'text', text: `${definition.name} succeeded.` }],
24
+ structuredContent: output,
25
+ };
26
+ }
27
+ catch (error) {
28
+ const payload = toToolErrorPayload(error);
29
+ return { content: [{ type: 'text', text: JSON.stringify(payload) }], isError: true };
30
+ }
31
+ });
32
+ }
33
+ //# sourceMappingURL=registry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"registry.js","sourceRoot":"","sources":["../src/registry.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAMtC,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAErD;;;;;GAKG;AACH,MAAM,UAAU,YAAY,CAC1B,MAAiB,EACjB,UAAyC;IAEzC,MAAM,CAAC,YAAY,CACjB,UAAU,CAAC,IAAI,EACf;QACE,WAAW,EAAE,UAAU,CAAC,WAAW;QACnC,WAAW,EAAE,UAAU,CAAC,WAAW,CAAC,KAAK;QACzC,YAAY,EAAE,UAAU,CAAC,YAAY,CAAC,KAAK;KAC5C,EACD,KAAK,EAAE,QAAiB,EAA2B,EAAE;QACnD,IAAI,CAAC;YACH,qFAAqF;YACrF,uFAAuF;YACvF,qFAAqF;YACrF,sFAAsF;YACtF,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC,QAA0B,CAAC,CAAC;YACpE,OAAO;gBACL,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,UAAU,CAAC,IAAI,aAAa,EAAE,CAAC;gBAClE,iBAAiB,EAAE,MAAM;aAC1B,CAAC;QACJ,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,OAAO,GAAG,kBAAkB,CAAC,KAAK,CAAC,CAAC;YAC1C,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;QACvF,CAAC;IACH,CAAC,CACF,CAAC;AACJ,CAAC"}
@@ -0,0 +1,10 @@
1
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ import type { ToolDefinition } from './tool.js';
3
+ export interface CreateQaMcpServerOptions {
4
+ /** The running server's own version, reported to clients during initialization. */
5
+ readonly version: string;
6
+ readonly tools: readonly ToolDefinition[];
7
+ }
8
+ /** Builds the MCP server every tool registers on, not yet attached to a transport. */
9
+ export declare function createQaMcpServer(options: CreateQaMcpServerOptions): McpServer;
10
+ //# sourceMappingURL=server.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AAEpE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAIhD,MAAM,WAAW,wBAAwB;IACvC,mFAAmF;IACnF,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,SAAS,cAAc,EAAE,CAAC;CAC3C;AAED,sFAAsF;AACtF,wBAAgB,iBAAiB,CAAC,OAAO,EAAE,wBAAwB,GAAG,SAAS,CAM9E"}
package/dist/server.js ADDED
@@ -0,0 +1,14 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
4
+ import { registerTool } from './registry.js';
5
+ const SERVER_NAME = 'qa-ai-stlc';
6
+ /** Builds the MCP server every tool registers on, not yet attached to a transport. */
7
+ export function createQaMcpServer(options) {
8
+ const server = new McpServer({ name: SERVER_NAME, version: options.version });
9
+ for (const tool of options.tools) {
10
+ registerTool(server, tool);
11
+ }
12
+ return server;
13
+ }
14
+ //# sourceMappingURL=server.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.js","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAEtC,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAG7C,MAAM,WAAW,GAAG,YAAY,CAAC;AAQjC,sFAAsF;AACtF,MAAM,UAAU,iBAAiB,CAAC,OAAiC;IACjE,MAAM,MAAM,GAAG,IAAI,SAAS,CAAC,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,OAAO,CAAC,OAAO,EAAE,CAAC,CAAC;IAC9E,KAAK,MAAM,IAAI,IAAI,OAAO,CAAC,KAAK,EAAE,CAAC;QACjC,YAAY,CAAC,MAAM,EAAE,IAAI,CAAC,CAAC;IAC7B,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * What a tool call result's error content carries (AGENTS.md 5.4, 12.3): a stable code an agent
3
+ * can branch on and, when there is one, a remediation it can act on — never a raw stack trace.
4
+ */
5
+ export interface ToolErrorPayload {
6
+ readonly code: string;
7
+ readonly message: string;
8
+ readonly remediation?: string;
9
+ }
10
+ /**
11
+ * Converts whatever a tool handler threw into a structured payload: a `QaError`'s own `code` and
12
+ * `remediation` pass through unchanged; anything else (a real bug, not an expected failure) gets
13
+ * a generic code and no remediation, since there is nothing actionable to suggest.
14
+ */
15
+ export declare function toToolErrorPayload(error: unknown): ToolErrorPayload;
16
+ //# sourceMappingURL=tool-error.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool-error.d.ts","sourceRoot":"","sources":["../src/tool-error.ts"],"names":[],"mappings":"AAKA;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;CAC/B;AAID;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,OAAO,GAAG,gBAAgB,CASnE"}
@@ -0,0 +1,20 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ import { QaError } from '@qa-ai-stlc/core';
4
+ const INTERNAL_ERROR_CODE = 'MCP_TOOL_INTERNAL_ERROR';
5
+ /**
6
+ * Converts whatever a tool handler threw into a structured payload: a `QaError`'s own `code` and
7
+ * `remediation` pass through unchanged; anything else (a real bug, not an expected failure) gets
8
+ * a generic code and no remediation, since there is nothing actionable to suggest.
9
+ */
10
+ export function toToolErrorPayload(error) {
11
+ if (error instanceof QaError) {
12
+ return {
13
+ code: error.code,
14
+ message: error.message,
15
+ ...(error.remediation !== undefined ? { remediation: error.remediation } : {}),
16
+ };
17
+ }
18
+ return { code: INTERNAL_ERROR_CODE, message: error instanceof Error ? error.message : String(error) };
19
+ }
20
+ //# sourceMappingURL=tool-error.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool-error.js","sourceRoot":"","sources":["../src/tool-error.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAEtC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAY3C,MAAM,mBAAmB,GAAG,yBAAyB,CAAC;AAEtD;;;;GAIG;AACH,MAAM,UAAU,kBAAkB,CAAC,KAAc;IAC/C,IAAI,KAAK,YAAY,OAAO,EAAE,CAAC;QAC7B,OAAO;YACL,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,OAAO,EAAE,KAAK,CAAC,OAAO;YACtB,GAAG,CAAC,KAAK,CAAC,WAAW,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,KAAK,CAAC,WAAW,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;SAC/E,CAAC;IACJ,CAAC;IACD,OAAO,EAAE,IAAI,EAAE,mBAAmB,EAAE,OAAO,EAAE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC;AACxG,CAAC"}
package/dist/tool.d.ts ADDED
@@ -0,0 +1,15 @@
1
+ import type { z } from 'zod';
2
+ /**
3
+ * One MCP tool (AGENTS.md 12.3): a Zod input and output schema, and a handler that either
4
+ * returns a value matching `outputSchema` or throws (a `QaError` for an expected failure, any
5
+ * other error for a bug). `registerTool` (registry.ts) is the only place that turns a throw into
6
+ * a structured, coded MCP result — handlers never format their own error response.
7
+ */
8
+ export interface ToolDefinition<Input extends z.ZodObject = z.ZodObject, Output extends z.ZodObject = z.ZodObject> {
9
+ readonly name: string;
10
+ readonly description: string;
11
+ readonly inputSchema: Input;
12
+ readonly outputSchema: Output;
13
+ handler(input: z.infer<Input>): Promise<z.infer<Output>>;
14
+ }
15
+ //# sourceMappingURL=tool.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool.d.ts","sourceRoot":"","sources":["../src/tool.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAE7B;;;;;GAKG;AACH,MAAM,WAAW,cAAc,CAC7B,KAAK,SAAS,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,SAAS,EACvC,MAAM,SAAS,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,SAAS;IAExC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,WAAW,EAAE,KAAK,CAAC;IAC5B,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,OAAO,CAAC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;CAC1D"}
package/dist/tool.js ADDED
@@ -0,0 +1,4 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ export {};
4
+ //# sourceMappingURL=tool.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool.js","sourceRoot":"","sources":["../src/tool.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC"}
@@ -0,0 +1,4 @@
1
+ import type { ToolDefinition } from '../tool.js';
2
+ /** Every tool the server registers by default. P2-05 adds the real engine-operation tools here. */
3
+ export declare const BUILTIN_TOOLS: readonly ToolDefinition[];
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEjD,mGAAmG;AACnG,eAAO,MAAM,aAAa,EAAE,SAAS,cAAc,EAAe,CAAC"}
@@ -0,0 +1,6 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ import { pingTool } from './ping.js';
4
+ /** Every tool the server registers by default. P2-05 adds the real engine-operation tools here. */
5
+ export const BUILTIN_TOOLS = [pingTool];
6
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAEtC,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAGrC,mGAAmG;AACnG,MAAM,CAAC,MAAM,aAAa,GAA8B,CAAC,QAAQ,CAAC,CAAC"}
@@ -0,0 +1,15 @@
1
+ import { z } from 'zod';
2
+ import type { ToolDefinition } from '../tool.js';
3
+ declare const InputSchema: z.ZodObject<{}, z.core.$strip>;
4
+ declare const OutputSchema: z.ZodObject<{
5
+ pong: z.ZodLiteral<true>;
6
+ version: z.ZodString;
7
+ }, z.core.$strip>;
8
+ /**
9
+ * A health check owned by the server itself, not an engine operation (those are P2-05's tools):
10
+ * proves the process is up and the tool-call round trip works, without touching `.qa/` or the
11
+ * engine at all.
12
+ */
13
+ export declare const pingTool: ToolDefinition<typeof InputSchema, typeof OutputSchema>;
14
+ export {};
15
+ //# sourceMappingURL=ping.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ping.d.ts","sourceRoot":"","sources":["../../src/tools/ping.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAEjD,QAAA,MAAM,WAAW,gCAAe,CAAC;AACjC,QAAA,MAAM,YAAY;;;iBAGhB,CAAC;AAEH;;;;GAIG;AACH,eAAO,MAAM,QAAQ,EAAE,cAAc,CAAC,OAAO,WAAW,EAAE,OAAO,YAAY,CAM5E,CAAC"}
@@ -0,0 +1,22 @@
1
+ // Copyright The QA-AI-STLC Authors
2
+ // SPDX-License-Identifier: Apache-2.0
3
+ import { z } from 'zod';
4
+ import { readPackageVersion } from '../package-version.js';
5
+ const InputSchema = z.object({});
6
+ const OutputSchema = z.object({
7
+ pong: z.literal(true),
8
+ version: z.string(),
9
+ });
10
+ /**
11
+ * A health check owned by the server itself, not an engine operation (those are P2-05's tools):
12
+ * proves the process is up and the tool-call round trip works, without touching `.qa/` or the
13
+ * engine at all.
14
+ */
15
+ export const pingTool = {
16
+ name: 'qa.ping',
17
+ description: 'Checks that the QA-AI-STLC MCP server is running and responding to tool calls.',
18
+ inputSchema: InputSchema,
19
+ outputSchema: OutputSchema,
20
+ handler: () => Promise.resolve({ pong: true, version: readPackageVersion() }),
21
+ };
22
+ //# sourceMappingURL=ping.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ping.js","sourceRoot":"","sources":["../../src/tools/ping.ts"],"names":[],"mappings":"AAAA,mCAAmC;AACnC,sCAAsC;AAEtC,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAG3D,MAAM,WAAW,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;AACjC,MAAM,YAAY,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5B,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC;IACrB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;CACpB,CAAC,CAAC;AAEH;;;;GAIG;AACH,MAAM,CAAC,MAAM,QAAQ,GAA4D;IAC/E,IAAI,EAAE,SAAS;IACf,WAAW,EAAE,gFAAgF;IAC7F,WAAW,EAAE,WAAW;IACxB,YAAY,EAAE,YAAY;IAC1B,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,kBAAkB,EAAE,EAAE,CAAC;CAC9E,CAAC"}
package/package.json ADDED
@@ -0,0 +1,42 @@
1
+ {
2
+ "name": "@qa-ai-stlc/mcp-server",
3
+ "version": "0.1.0",
4
+ "description": "Local stdio MCP server over the core engine API: a tool registry with Zod input/output schemas and coded errors. Calls no model itself.",
5
+ "type": "module",
6
+ "license": "Apache-2.0",
7
+ "homepage": "https://github.com/Klim-101/QA-AI-STLC/tree/main/packages/mcp-server#readme",
8
+ "repository": {
9
+ "type": "git",
10
+ "url": "git+https://github.com/Klim-101/QA-AI-STLC.git",
11
+ "directory": "packages/mcp-server"
12
+ },
13
+ "bugs": "https://github.com/Klim-101/QA-AI-STLC/issues",
14
+ "files": [
15
+ "dist"
16
+ ],
17
+ "bin": {
18
+ "qa-mcp-server": "./dist/bin/mcp-server.js"
19
+ },
20
+ "exports": {
21
+ ".": "./dist/index.js"
22
+ },
23
+ "scripts": {
24
+ "pretypecheck": "npm run build --workspace @qa-ai-stlc/schemas --workspace @qa-ai-stlc/core --workspace @qa-ai-stlc/test-utils",
25
+ "typecheck": "tsc --noEmit -p .",
26
+ "pretest": "npm run build --workspace @qa-ai-stlc/schemas --workspace @qa-ai-stlc/core --workspace @qa-ai-stlc/test-utils",
27
+ "test": "vitest run",
28
+ "pretest:coverage": "npm run build --workspace @qa-ai-stlc/schemas --workspace @qa-ai-stlc/core --workspace @qa-ai-stlc/test-utils",
29
+ "test:coverage": "vitest run --coverage",
30
+ "build": "tsc -b tsconfig.build.json",
31
+ "clean": "node ../../scripts/clean-dir.mjs dist"
32
+ },
33
+ "dependencies": {
34
+ "@modelcontextprotocol/sdk": "1.30.0",
35
+ "@qa-ai-stlc/core": "0.6.0",
36
+ "@qa-ai-stlc/schemas": "0.7.0",
37
+ "zod": "4.6.5"
38
+ },
39
+ "devDependencies": {
40
+ "@qa-ai-stlc/test-utils": "0.0.0"
41
+ }
42
+ }