wopee-mcp 1.21.0 → 1.23.1

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 CHANGED
@@ -298,7 +298,7 @@ Dispatches an autonomous testing agent to execute test cases for a selected suit
298
298
  - `testCases` - Array of test case objects to execute, each containing:
299
299
  - `testCaseId` - The ID of the test case
300
300
  - `userStoryId` - The ID of the associated user story
301
- - **Returns:** Success message indicating the agent has been dispatched
301
+ - **Returns:** Array of executed test case objects with their initial execution state (uuid, executionStatus, agentReportStatus, codeReportStatus, etc.)
302
302
 
303
303
  **Example Usage:**
304
304
 
@@ -306,6 +306,27 @@ Dispatches an autonomous testing agent to execute test cases for a selected suit
306
306
  Dispatch agent for my latest suite's user story US001 and test case TC003
307
307
  ```
308
308
 
309
+ ### Test Results
310
+
311
+ #### `wopee_fetch_executed_test_cases`
312
+
313
+ Fetches executed test cases and their results for a given analysis suite. Use this to check the status and reports of dispatched agent runs.
314
+
315
+ - **Parameters:**
316
+ - `suiteUuid` - The UUID of the analysis suite to fetch results for
317
+ - `analysisIdentifier` _(optional)_ - Analysis identifier to narrow results (e.g. `A068`)
318
+ - **Returns:** Array of results grouped by user story, each containing executed test cases with execution status, agent report, agent report status, code report, and code report status
319
+
320
+ **Example Usage:**
321
+
322
+ ```
323
+ Fetch test results for suite <suiteUuid>
324
+ ```
325
+
326
+ ```
327
+ Show me the executed test cases for my latest analysis suite
328
+ ```
329
+
309
330
  ## Typical Workflow
310
331
 
311
332
  1. **Start with a suite:**
@@ -326,6 +347,20 @@ Dispatch agent for my latest suite's user story US001 and test case TC003
326
347
  4. **Run tests:**
327
348
  - Use `wopee_dispatch_agent` to execute test cases with the autonomous testing agent
328
349
 
350
+ 5. **Check results:**
351
+ - Use `wopee_fetch_executed_test_cases` to check the status and reports of dispatched agent runs
352
+ - Or use the `fetch-test-results` prompt for a formatted summary of all test results
353
+
354
+ ## Available Prompts
355
+
356
+ ### `fetch-project-summary`
357
+
358
+ Fetches analysis suites and their user stories/test cases, then displays a formatted summary with two markdown tables: a suite overview and a detailed test case breakdown.
359
+
360
+ ### `fetch-test-results`
361
+
362
+ Fetches analysis suites and their executed test case results, then displays formatted markdown tables showing execution status, agent report status, and code report status for each test case. Also surfaces failed report details.
363
+
329
364
  ## Notes
330
365
 
331
366
  - Most tools require a `suiteUuid`. Always start by fetching or creating a suite.
@@ -0,0 +1,65 @@
1
+ import { PromptName } from "../shared/types.js";
2
+ export const fetchTestResults = {
3
+ name: PromptName.FETCH_TEST_RESULTS,
4
+ config: {
5
+ title: "Fetch test results",
6
+ description: "Fetch and display test execution results for analysis suites",
7
+ },
8
+ handler: () => ({
9
+ messages: [
10
+ {
11
+ role: "user",
12
+ content: {
13
+ type: "text",
14
+ text: `Please, fetch my analysis suites using 'wopee_fetch_analysis_suites' tool. If there are more than 5 suites, ask the user to select which suite(s) they want to see results for.
15
+
16
+ Then, for each selected suite, fetch the executed test cases using 'wopee_fetch_executed_test_cases' tool with the suite's uuid and analysisIdentifier.
17
+
18
+ After fetching all of the necessary data, summarize and display readable markdown tables as an output in the same chat conversation. Do NOT create, write, or save any files to disk - only display the formatted tables in your response.
19
+
20
+ Display the following tables:
21
+
22
+ 1. **Suite Overview Table** - one row per suite showing:
23
+ - Suite name
24
+ - Analysis identifier
25
+ - Execution status
26
+ - Suite running status
27
+
28
+ ### Example:
29
+ | Suite Name | Identifier | Execution Status | Running Status |
30
+ |------------|------------|------------------|----------------|
31
+ | Analysis - A068 | A068 | FINISHED | IDLE |
32
+ | Analysis - A067 | A067 | IN_PROGRESS | IN_PROGRESS |
33
+
34
+ ___
35
+
36
+ 2. **Test Case Results Table** - for each suite that has executed test cases:
37
+ - Suite name
38
+ - User story ID
39
+ - Test case ID
40
+ - Execution status
41
+ - Agent report status (PASSED/FAILED or N/A)
42
+ - Code report status (PASSED/FAILED or N/A)
43
+
44
+ ### Example:
45
+ | Suite Name | User Story | Test Case | Execution | Agent Status | Code Status |
46
+ |------------|------------|-----------|-----------|--------------|-------------|
47
+ | Analysis - A068 | US001 | TC001 | FINISHED | PASSED | PASSED |
48
+ | | US001 | TC002 | FINISHED | PASSED | FAILED |
49
+ | | US002 | TC001 | FINISHED | FAILED | N/A |
50
+ | Analysis - A067 | US001 | TC001 | IN_PROGRESS | N/A | N/A |
51
+
52
+ ___
53
+
54
+ 3. If any test case has a FAILED agent or code report status, display the report content below the tables under a "Failed Reports" section, showing the suite name, test case ID, and the report text.
55
+
56
+ ## Important Notes:
57
+ - If a test case's executionStatus is IN_PROGRESS, note that results are not yet available.
58
+ - Use "N/A" for report statuses that are null (not yet available).
59
+ - Group test cases by user story within each suite.
60
+ `,
61
+ },
62
+ },
63
+ ],
64
+ }),
65
+ };
@@ -1,2 +1,3 @@
1
1
  import { fetchProjectSummary } from "./fetch_project_summary/index.js";
2
- export const PROMPTS = [fetchProjectSummary];
2
+ import { fetchTestResults } from "./fetch_test_results/index.js";
3
+ export const PROMPTS = [fetchProjectSummary, fetchTestResults];
@@ -1,4 +1,5 @@
1
1
  export var PromptName;
2
2
  (function (PromptName) {
3
3
  PromptName["FETCH_PROJECT_SUMMARY"] = "fetch-project-summary";
4
+ PromptName["FETCH_TEST_RESULTS"] = "fetch-test-results";
4
5
  })(PromptName || (PromptName = {}));
@@ -5,9 +5,11 @@ import { wopeeDispatchAgent } from "./wopee_dispatch_agent/index.js";
5
5
  import { wopeeDispatchAnalysis } from "./wopee_dispatch_analysis/index.js";
6
6
  import { wopeeCreateBlankSuite } from "./wopee_create_blank_suite/index.js";
7
7
  import { wopeeFetchAnalysisSuites } from "./wopee_fetch_analysis_suites/index.js";
8
+ import { wopeeFetchExecutedTestCases } from "./wopee_fetch_executed_test_cases/index.js";
8
9
  export const TOOLS = [
9
10
  wopeeCreateBlankSuite,
10
11
  wopeeFetchAnalysisSuites,
12
+ wopeeFetchExecutedTestCases,
11
13
  wopeeDispatchAnalysis,
12
14
  wopeeDispatchAgent,
13
15
  wopeeFetchArtifact,
@@ -155,6 +155,28 @@ export const GenerateReusableTestCaseSteps = `
155
155
  generateReusableTestCaseSteps(input: $input)
156
156
  }
157
157
  `;
158
+ export const FetchExecutedTestCases = `
159
+ query FetchExecutedTestCases($input: FetchExecutedTestCasesInput!) {
160
+ fetchExecutedTestCases(input: $input) {
161
+ userStoryId
162
+ executedTestCases {
163
+ uuid
164
+ suiteUuid
165
+ analysisSuiteUuid
166
+ analysisIdentifier
167
+ userStoryId
168
+ testCaseId
169
+ executionStatus
170
+ agentReport
171
+ agentReportStatus
172
+ codeReport
173
+ codeReportStatus
174
+ createdAt
175
+ updatedAt
176
+ }
177
+ }
178
+ }
179
+ `;
158
180
  export const CreateBlankAnalysisSuite = `
159
181
  mutation CreateBlankAnalysisSuite($projectUuid: ID!) {
160
182
  createBlankAnalysisSuite(projectUuid: $projectUuid) {
@@ -2,6 +2,7 @@ export var ToolName;
2
2
  (function (ToolName) {
3
3
  ToolName["WOPEE_CREATE_BLANK_SUITE"] = "wopee_create_blank_suite";
4
4
  ToolName["WOPEE_FETCH_ANALYSIS_SUITES"] = "wopee_fetch_analysis_suites";
5
+ ToolName["WOPEE_FETCH_EXECUTED_TEST_CASES"] = "wopee_fetch_executed_test_cases";
5
6
  ToolName["WOPEE_DISPATCH_ANALYSIS"] = "wopee_dispatch_analysis";
6
7
  ToolName["WOPEE_DISPATCH_AGENT"] = "wopee_dispatch_agent";
7
8
  ToolName["WOPEE_FETCH_ARTIFACT"] = "wopee_fetch_artifact";
@@ -56,3 +57,8 @@ export var GenerationStatus;
56
57
  GenerationStatus["FINISHED"] = "FINISHED";
57
58
  GenerationStatus["FAILED"] = "FAILED";
58
59
  })(GenerationStatus || (GenerationStatus = {}));
60
+ export var ReportStatus;
61
+ (function (ReportStatus) {
62
+ ReportStatus["PASSED"] = "PASSED";
63
+ ReportStatus["FAILED"] = "FAILED";
64
+ })(ReportStatus || (ReportStatus = {}));
@@ -7,7 +7,7 @@ export const wopeeCreateBlankSuite = {
7
7
  name: ToolName.WOPEE_CREATE_BLANK_SUITE,
8
8
  config: {
9
9
  title: "Create blank analysis suite",
10
- description: "Create a blank analysis suite for a project",
10
+ description: "Create a new empty analysis suite in the current project. Use this as the first step when starting a new testing workflow — the returned suite UUID is required by generate, fetch, update, and dispatch tools. Takes no input parameters; uses the project configured via WOPEE_PROJECT_UUID. Returns the created suite object including its UUID and metadata.",
11
11
  },
12
12
  handler: async () => {
13
13
  try {
@@ -8,8 +8,8 @@ import { withRetry } from "../../utils/withRetry.js";
8
8
  export const wopeeDispatchAgent = {
9
9
  name: ToolName.WOPEE_DISPATCH_AGENT,
10
10
  config: {
11
- title: "Dispatch agent",
12
- description: "Dispatch agent testing for selected suite's test cases. Note: there is a 10-second per-project rate limit between dispatches; concurrent calls will auto-retry with backoff.",
11
+ title: "Dispatch autonomous testing agent",
12
+ description: "Run an autonomous AI testing agent on specific test cases within a suite. The agent navigates the web app, executes test steps, captures screenshots, and reports pass/fail results. Requires a suite UUID and test case ID (e.g. TC001) with its parent user story ID (e.g. US001). Use wopee_generate_artifact first to create test cases, then this tool to execute them. Rate limit: 10 seconds between dispatches per project; concurrent calls auto-retry with backoff. Returns executed test case results including status and agent report.",
13
13
  inputSchema: WopeeDispatchAgentInputSchema.shape,
14
14
  },
15
15
  handler: async (input) => {
@@ -32,7 +32,7 @@ export const wopeeDispatchAgent = {
32
32
  content: [
33
33
  {
34
34
  type: "text",
35
- text: "Agent dispatched successfully",
35
+ text: JSON.stringify(result.dispatchAgent, null, 2),
36
36
  },
37
37
  ],
38
38
  };
@@ -8,8 +8,8 @@ import { ToolName } from "../shared/types.js";
8
8
  export const wopeeDispatchAnalysis = {
9
9
  name: ToolName.WOPEE_DISPATCH_ANALYSIS,
10
10
  config: {
11
- title: "Dispatch analysis",
12
- description: "Create and dispatch analysis/crawling suite for a project. Note: there is a 10-second per-project rate limit between dispatches; concurrent calls will auto-retry with backoff.",
11
+ title: "Dispatch analysis crawl",
12
+ description: "Create a new analysis suite and dispatch an AI crawling agent to explore and analyze a web application. The agent autonomously navigates the app starting from a given URL, discovers pages, and builds a sitemap. Optionally accepts login credentials, cookie preferences, custom variables, and additional instructions to guide the crawl. Use this instead of wopee_create_blank_suite when you want to auto-analyze a web app in one step. Rate limit: 10 seconds between dispatches per project; concurrent calls auto-retry with backoff. Returns the created analysis suite.",
13
13
  inputSchema: WopeeDispatchAnalysisInputSchema.shape,
14
14
  },
15
15
  handler: async (input) => {
@@ -6,8 +6,8 @@ import { FetchAnalysisSuites } from "../shared/gql-queries.js";
6
6
  export const wopeeFetchAnalysisSuites = {
7
7
  name: ToolName.WOPEE_FETCH_ANALYSIS_SUITES,
8
8
  config: {
9
- title: "Fetch Analysis Suites",
10
- description: "Fetch project's analysis suites from Woopee",
9
+ title: "List analysis suites",
10
+ description: "List all analysis suites in the current project. Returns an array of suites with their UUIDs, names, types, and statuses. Use this to find existing suites before generating content or dispatching agents. Takes no input parameters; uses the project configured via WOPEE_PROJECT_UUID. Each suite UUID can be passed to other tools like wopee_generate_artifact, wopee_fetch_artifact, or wopee_dispatch_agent.",
11
11
  },
12
12
  handler: async () => {
13
13
  try {
@@ -4,8 +4,8 @@ import { fetchArtifact } from "../shared/handlers.js";
4
4
  export const wopeeFetchArtifact = {
5
5
  name: ToolName.WOPEE_FETCH_ARTIFACT,
6
6
  config: {
7
- title: "Fetch file(artifact)",
8
- description: "Fetch suite's file(artifact) for selected project",
7
+ title: "Fetch test artifacts",
8
+ description: "Retrieve test artifacts from a suite. Supported types: APP_CONTEXT (application description), GENERAL_USER_STORIES (user stories without test cases), USER_STORIES (user stories with test cases), PLAYWRIGHT_CODE (Playwright test code for a specific test case — requires identifier like 'US004:TC006'), PROJECT_CONTEXT (project-level context). Use after wopee_generate_artifact to review test artifacts, or to retrieve existing artifacts for editing with wopee_update_artifact.",
9
9
  inputSchema: FetchArtifactHandlerInputSchema.shape,
10
10
  },
11
11
  handler: async (input) => await fetchArtifact(input),
@@ -0,0 +1,13 @@
1
+ import { getConfig } from "../../utils/getConfig.js";
2
+ export const createFetchExecutedTestCasesInput = (input) => {
3
+ const { WOPEE_PROJECT_UUID } = getConfig();
4
+ if (!WOPEE_PROJECT_UUID)
5
+ throw new Error("WOPEE_PROJECT_UUID is not set");
6
+ return {
7
+ projectUuid: WOPEE_PROJECT_UUID,
8
+ analysisSuiteUuid: input.suiteUuid,
9
+ ...(input.analysisIdentifier
10
+ ? { analysisIdentifier: input.analysisIdentifier }
11
+ : {}),
12
+ };
13
+ };
@@ -0,0 +1,43 @@
1
+ import { WopeeFetchExecutedTestCasesInputSchema, FetchExecutedTestCasesInputSchema, } from "./schema.js";
2
+ import { ToolName } from "../shared/types.js";
3
+ import { _parseError } from "../shared/helpers.js";
4
+ import { createFetchExecutedTestCasesInput } from "./factory.js";
5
+ import { FetchExecutedTestCases } from "../shared/gql-queries.js";
6
+ import { requestClient } from "../../utils/requestClient.js";
7
+ export const wopeeFetchExecutedTestCases = {
8
+ name: ToolName.WOPEE_FETCH_EXECUTED_TEST_CASES,
9
+ config: {
10
+ title: "Fetch test execution results",
11
+ description: "Retrieve the results of test cases that have been executed by the autonomous agent. Returns each test case with its execution status (IN_PROGRESS, FINISHED, FAILED), agent report, and code report. Use this after wopee_dispatch_agent to check whether tests passed or failed and to review detailed findings. Requires the suite UUID; optionally accepts an analysis identifier (e.g. A068) to filter results.",
12
+ inputSchema: WopeeFetchExecutedTestCasesInputSchema.shape,
13
+ },
14
+ handler: async (input) => {
15
+ try {
16
+ const factoryInput = createFetchExecutedTestCasesInput(input);
17
+ const parsedInput = FetchExecutedTestCasesInputSchema.parse(factoryInput);
18
+ const result = await requestClient(FetchExecutedTestCases, {
19
+ input: parsedInput,
20
+ });
21
+ if (!result?.fetchExecutedTestCases)
22
+ return {
23
+ content: [
24
+ {
25
+ type: "text",
26
+ text: "Failed to fetch executed test cases: no data returned",
27
+ },
28
+ ],
29
+ };
30
+ return {
31
+ content: [
32
+ {
33
+ type: "text",
34
+ text: JSON.stringify(result.fetchExecutedTestCases, null, 2),
35
+ },
36
+ ],
37
+ };
38
+ }
39
+ catch (error) {
40
+ return _parseError(error);
41
+ }
42
+ },
43
+ };
@@ -0,0 +1,18 @@
1
+ import { z } from "zod";
2
+ export const WopeeFetchExecutedTestCasesInputSchema = z.object({
3
+ suiteUuid: z
4
+ .string({
5
+ description: "UUID of the analysis suite to fetch executed test cases for",
6
+ })
7
+ .min(1, "Suite UUID is required"),
8
+ analysisIdentifier: z
9
+ .string({
10
+ description: "Analysis identifier of the suite (ex. A068). Can be found in the analysis suite data.",
11
+ })
12
+ .optional(),
13
+ });
14
+ export const FetchExecutedTestCasesInputSchema = z.object({
15
+ projectUuid: z.string().min(1, "Project UUID is required"),
16
+ analysisSuiteUuid: z.string().min(1, "Suite UUID is required"),
17
+ analysisIdentifier: z.string().optional(),
18
+ });
@@ -4,8 +4,8 @@ import { generateAIDataFile } from "../shared/handlers.js";
4
4
  export const wopeeGenerateArtifact = {
5
5
  name: ToolName.WOPEE_GENERATE_ARTIFACT,
6
6
  config: {
7
- title: "Generate file(artifact)",
8
- description: "Generate AI data file for selected suite",
7
+ title: "Generate test artifacts",
8
+ description: "Generate AI-powered test artifacts for a suite. Supported types: APP_CONTEXT (analyze the application and create a description), GENERAL_USER_STORIES (generate user stories from app context), USER_STORIES_WITH_TEST_CASES (generate user stories with detailed test cases), TEST_CASES (generate test cases for existing user stories), TEST_CASE_STEPS (generate step-by-step instructions for test cases), REUSABLE_TEST_CASES (generate reusable/shared test cases), REUSABLE_TEST_CASE_STEPS (generate steps for reusable test cases). Typical workflow: generate APP_CONTEXT first, then USER_STORIES_WITH_TEST_CASES, then use wopee_dispatch_agent to execute them.",
9
9
  inputSchema: GenerateAIDataHandlerInputSchema.shape,
10
10
  },
11
11
  handler: async (input) => await generateAIDataFile(input),
@@ -4,8 +4,8 @@ import { updateArtifact } from "../shared/handlers.js";
4
4
  export const wopeeUpdateArtifact = {
5
5
  name: ToolName.WOPEE_UPDATE_ARTIFACT,
6
6
  config: {
7
- title: "Update file",
8
- description: "Update file(artifact) in the project",
7
+ title: "Update test artifacts",
8
+ description: "Update previously generated content in a suite. Use this to refine user stories, test cases, app context, or Playwright code after reviewing them with wopee_fetch_artifact. Requires the content type (APP_CONTEXT, GENERAL_USER_STORIES, USER_STORIES, PLAYWRIGHT_CODE, or PROJECT_CONTEXT), the suite UUID, and the new content as a string. For PLAYWRIGHT_CODE, also provide the test case identifier (e.g. 'US004:TC006'). This enables an iterative workflow: generate → review → update → dispatch.",
9
9
  inputSchema: UpdateArtifactHandlerInputSchema.shape,
10
10
  },
11
11
  handler: async (input) => await updateArtifact(input),
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "bin": {
5
5
  "wopee-mcp": "./build/index.js"
6
6
  },
7
- "version": "1.21.0",
7
+ "version": "1.23.1",
8
8
  "mcpName": "io.github.Wopee-io/wopee-mcp",
9
9
  "description": "Wopee.io MCP server for autonomous testing platform",
10
10
  "main": "./build/index.js",