create-test-cycle
Create a test cycle in qTest Test Execution to organize test runs by sprint, release, or regression campaign. Provide project ID and name; optionally specify a parent cycle.
Instructions
Test Execution — create a test cycle (execution folder) in qTest Test Execution to group test runs for a sprint, release, or regression campaign
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": {
"projectId": "<projectId>",
"name": "<name>"
},
"name": "create-test-cycle"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| projectId | Yes | ||
| name | Yes | Name of the new test cycle | |
| parentId | No | Parent test cycle ID; omit to create at root |
Implementation Reference
- Full implementation file: imports config and qtestFetch, defines CreateExecutionFolderArgs and ExecutionFolder interfaces, and exports the createExecutionFolder function that makes the API call
import { config } from '@/config.js' import { qtestFetch } from '@/client.js' export interface CreateExecutionFolderArgs { projectId: string name: string parentId?: number } export interface ExecutionFolder { id: number name: string parentId?: number } export async function createExecutionFolder( args: CreateExecutionFolderArgs ): Promise<ExecutionFolder> { const { projectId, name, parentId } = args const endpoint = parentId !== undefined ? `/test-cycles?parentId=${parentId}&parentType=test-cycle` : `/test-cycles?parentType=root` const result = await qtestFetch(config, projectId, endpoint, 'POST', { name, description: '', }) return result as ExecutionFolder }