Generate test artifacts
wopee_generate_artifactGenerate AI-powered test artifacts, including app context, user stories, test cases, and steps, for a Wopee.io suite in the required order.
Instructions
Generate AI-powered test artifacts for a suite using the Wopee.io AI engine. Each call creates one artifact type — call multiple times for different types. Generation order matters: APP_CONTEXT must be generated before user stories, and user stories before test cases. If called out of order, the AI may produce lower quality results. By default the call waits up to 5 minutes for the generation and returns the generated artifact: APP_CONTEXT or GENERAL_USER_STORIES, or the suite's USER_STORIES (stories with their test cases and steps) for every other type. No wopee_fetch_artifact call is needed after it. With async: true, for TEST_CASES and USER_STORIES_WITH_TEST_CASES only, the call returns "Queued: …" at once; read the result later with wopee_fetch_artifact. If the 5 minutes pass first, the call fails with a [TIMEOUT] error while the generation goes on: do not call again (that starts a second generation), read the result later with wopee_fetch_artifact, and pass async: true next time for a long TEST_CASES or USER_STORIES_WITH_TEST_CASES generation. Do NOT use this to hand-edit existing artifacts — use wopee_update_artifact instead. TEST_CASES runs in UPDATE mode by default: existing test cases keep their steps and run history, and instructions says what to add or change. Destructive generations are mode CREATE (replaces the test cases in scope and deletes their steps, runs and code), USER_STORIES_WITH_TEST_CASES (rebuilds every story and test case) and TEST_CASE_STEPS (replaces the steps of the test cases in scope): use them only when the user explicitly asks for that, and scope them with selectedUserStories / selectedTestCases when the user named stories or test cases. Login credentials are project variables, referenced in steps as ${TESTING_USERNAME} / ${TESTING_PASSWORD}: check which exist with wopee_fetch_variables and set missing ones with wopee_update_variables before generating. Never put a password or other secret value in instructions — it would be copied into the artifact.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"type": "<type>",
"suiteUuid": "<suiteUuid>"
},
"name": "wopee_generate_artifact"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | TEST_CASES only. UPDATE (default) keeps every existing test case with its steps and run history, and adds or changes test cases around them. CREATE replaces the test cases of the stories in scope — of the whole suite when selectedUserStories is empty — and deletes their steps, run history and Playwright code. Use CREATE only when the user explicitly asks to start over. | UPDATE |
| type | Yes | Type of test artifact to generate. One of: APP_CONTEXT, GENERAL_USER_STORIES, USER_STORIES_WITH_TEST_CASES, TEST_CASES, TEST_CASE_STEPS, REUSABLE_TEST_CASES, REUSABLE_TEST_CASE_STEPS. Start with APP_CONTEXT, then generate stories and test cases from it. | |
| async | No | TEST_CASES and USER_STORIES_WITH_TEST_CASES only. true returns as soon as the generation is queued instead of waiting for it (a large suite can take several minutes); the content is then read later with wopee_fetch_artifact. Default false: wait and return the generated artifact. | |
| suiteUuid | Yes | UUID of the analysis suite to generate artifacts for. Get this from wopee_create_blank_suite or wopee_fetch_analysis_suites. | |
| instructions | No | What the user asked for, in their words, e.g. 'add a negative test for an expired card'. Passed to the AI engine as the change request; without it, UPDATE removes no test case. | |
| selectedTestCases | No | Test case identifiers to limit TEST_CASE_STEPS to, e.g. ['US001:TC002']. Leave empty for every test case in scope. Regenerating steps replaces the steps those test cases have. | |
| selectedUserStories | No | User story ids to limit the generation to, e.g. ['US001', 'US003']. Leave empty for every story in the suite. Used by TEST_CASES and TEST_CASE_STEPS. |