Skip to main content
Glama
SmartBear

SmartBear MCP server

Official
by SmartBear

QTM4J: Create Test Case

qtm4j_create_test_case

Create a test case in a QTM4J project with priority, status, labels, components, and steps. Auto-resolves names to IDs and defaults to the MCP Generated folder.

Instructions

Create a new test case in a QTM4J project. Supports auto-resolving human-readable names for priority, status, labels, and components.

Toolset: Test Cases

Parameters:

  • summary (string) required: Test case summary/title

  • description (string): Test case description

  • folderId (number): Numeric folder ID where the test case will be created. If omitted, the test case is created in the 'MCP Generated' folder automatically.

  • priority (string): Priority name (e.g., 'High', 'Medium', 'Low'). Auto-resolved to ID.

  • status (string): Status name (e.g., 'To Do', 'In Progress', 'Done'). Auto-resolved to ID.

  • assignee (string): Assignee account ID

  • reporter (string): Reporter account ID

  • components (array): List of component names (e.g., ['UI', 'Cloud']). Auto-resolved to IDs.

  • labels (array): List of label names (e.g., ['Release_1', 'Sprint 1']). Auto-resolved to IDs.

  • steps (array): List of test steps

Output Description: JSON object with test case ID, key, version number, and summary. Warnings included if any fields were skipped.

Use Cases: 1. Create a basic test case with just a summary 2. Create a test case with priority and status using names from set_project_context response 3. Create a test case with labels and components by exact name 4. Add detailed test steps with step descriptions, test data, and expected results 5. Create a test case in a specific folder using folderId 6. Set assignee and reporter using Jira account IDs 7. Create test cases for manual testing with step-by-step instructions 8. Create test cases with all metadata fields for comprehensive test management

Examples:

  1. Create a simple test case (project must be set via set_project_context first)

{
  "summary": "Search Functionality"
}

Expected Output: Test case created with key 'SCRUM-TC-xxx'

  1. Create a test case with priority and status

{
  "summary": "Search Functionality",
  "description": "Verify search functionality works correctly",
  "priority": "High",
  "status": "To Do"
}

Expected Output: Test case created with resolved priority and status IDs

  1. Create a test case with labels, components, and steps

{
  "summary": "Search Functionality",
  "description": "Search Functionality Test",
  "priority": "High",
  "status": "To Do",
  "labels": [
    "Release_1",
    "Sprint 1"
  ],
  "components": [
    "UI",
    "Cloud"
  ],
  "steps": [
    {
      "stepDetails": "Enter a keyword in the search box",
      "testData": "Keyword = \"Test\"",
      "expectedResult": "The keyword should be visible in the search box"
    },
    {
      "stepDetails": "Click on the Search button",
      "testData": "Click on Search Button",
      "expectedResult": "Search results matching the keyword should be displayed"
    },
    {
      "stepDetails": "Verify the search results",
      "testData": "Expected results list",
      "expectedResult": "Results should be relevant to the entered keyword"
    }
  ]
}

Expected Output: Test case created with resolved labels/components/priority/status and 3 steps

Hints: 1. PREREQUISITE: set_project_context must be called before this tool. NEVER auto-select a project. 2. Priority and status values were returned by set_project_context. Use NLP to map user input (e.g., 'Major' → 'High', 'Critical' → 'Blocker'). 3. If priority or status name is not found, the operation proceeds without that field and a warning is returned. 4. Labels and components are resolved on demand. If a name is not found, it is skipped with a warning. 5. Steps: ALWAYS include all three fields — stepDetails, testData, and expectedResult. Generate reasonable values if not provided. 6. FOLDER ID: folderId is optional. If omitted, defaults to the 'MCP Generated' folder. To place in a specific folder, ask the user to right-click the target folder in QTM4J and select 'Copy Folder Id' — never try to look it up.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
stepsNoList of test steps
labelsNoList of label names (e.g., ['Release_1', 'Sprint 1']). Auto-resolved to IDs.
statusNoStatus name (e.g., 'To Do', 'In Progress', 'Done'). Auto-resolved to ID.
summaryYesTest case summary/title
assigneeNoAssignee account ID
folderIdNoNumeric folder ID where the test case will be created. If omitted, the test case is created in the 'MCP Generated' folder automatically.
priorityNoPriority name (e.g., 'High', 'Medium', 'Low'). Auto-resolved to ID.
reporterNoReporter account ID
componentsNoList of component names (e.g., ['UI', 'Cloud']). Auto-resolved to IDs.
descriptionNoTest case description

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesUnique test case ID
keyYesTest case key (e.g., 'SCRUM-TC-190')
summaryYesTest case summary
versionNoYesVersion number

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv0.41.3
    • changedInput schema / properties / folderId / description
      Previous value: -"Folder ID to place the test case in"New value: +"Numeric folder ID where the test case will be created. If omitted, the test case is created in the 'MCP Generated' folder automatically."
    • addedInput schema / properties / folderId / exclusiveMinimum
      Added value: +0
    • addedInput schema / properties / folderId / maximum
      Added value: +9007199254740991
    • changedInput schema / properties / folderId / type
      Previous value: -"number"New value: +"integer"
  2. Addedv0.40.0
  3. Removedv0.34.0
  4. First observedv0.27.1

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Adds substantial behavior beyond the annotations (readOnlyHint=false, destructiveHint=false, idempotentHint=false): auto-resolution of human-readable names to IDs, graceful skip-with-warning when a name is unresolved, and the 'MCP Generated' default folder. The prerequisite and warning semantics are exactly the operational context an agent needs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose statement is front-loaded and useful, but the description is bloated: it restates the entire parameter list (already at 100% schema coverage), repeats the return shape captured by the output schema, and carries three fully expanded JSON examples plus eight use cases. The signal is good but the length is disproportionate.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given a 10-parameter mutation tool with a defined output schema, the description still covers the prerequisite, the default folder behavior, auto-resolution and warning handling, and step-field requirements. Nothing an agent needs to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds real operational meaning: NLP mapping of user input ('Major' → 'High'), the rule that all three step fields must be present, and the instruction to obtain folderId from the user via 'Copy Folder Id' rather than looking it up. This exceeds what the schema conveys.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Create a new test case in a QTM4J project') and scopes it to the QTM4J product, which distinguishes it from the sibling qmetry_create_test_case and zephyr_create_test_case. An agent can identify the correct tool without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Enumerates 8 concrete use cases and states a hard prerequisite ('set_project_context must be called before this tool. NEVER auto-select a project'), which is clear when-to-use guidance. It does not explicitly contrast with the QTM4J update tool or explain when NOT to use it, so it falls short of the top bar.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools