get https://testops.katalon.io/api/v1/test-cases/
A successful request to this endpoint returns details of a specified test case.
Request
This request uses the GET method, which is used to retrieve data of a specific test case from the specified resource.
For basic authorization, replace this with your actual username and password (or API key) in the header request in the username:password
or username:api_key
format. Your user creds are combined to form a Base64 encoded string.
You need to provide the following required query parameters:
id
: the alphanumeric ID of the test case.
Response
The response is in JSON. This API response provides detailed information about the test case after the GET operation.
See the following example:
{
"id":3468915,
"name":"TC_Book An Agent",
"path":"Test Cases/TC Katalon Health Care",
"alias":"tc_book-an-agent",
"webUrl":"https://testops.katalon.io/team/xxx/project/xxx/test-design/test-cases/3468915-tc_book-an-agent",
"project": {...},
"lastExecutionTestCase": {
"status":"PASSED",
"startTime":"2022-11-26T11:10:17.661+0000",
"endTime":"2022-11-26T11:10:17.661+0000",
"duration":0,"totalTests":1,
"totalPassedTests":1,
"totalFailedTests":0,
"totalErrorTests":0,
"totalIncompleteTests":0,
"totalSkippedTests":0,
"executionId":13679106,
"executionOrder":41,
"testCaseId":3468915,
"projectId":964154
},
"externalIssues":[],
"type":"TEST_CASE",
"averageDuration":0.0,
"maxDuration":0,
"minDuration":0,
"flakiness":0.0,
"testResultAssertion":{},
"updatedAt":"2022-11-30T07:10:18.939+0000",
"numberOfExecutions":12,
"urlId":"3468915-tc_book-an-agent"
}
Refer to the following table about the response body parameters:
Property | Type | Description |
---|---|---|
id | integer | The unique identifier of the test case. |
name | string | The name of the test case. |
path | string | The file folder location of the test case in TestOps. |
alias | string | The alias for the test class used in a test script. |
webUrl | string | The URL of the test case detail page. |
project | project object | The project object associated with the test case. |
lastExecutionTestCase | lastExecutionTestCase object | This object contains details of the latest execution of a test case, including execution status, total tests executed, duration, execution ID, and start and end times. |
externalIssues | Array of externalIssues objects | |
averageDuration | integer | The mean average time running an execution in a test case. |
maxDuration | integer | The maximum time it takes for an execution to run in a test case. |
minDuration | integer | The shortest or minimum time it takes for an execution to run in a test case. |
flakiness | integer | The number of times the status of test results changes over the total number of test results. |
testResultAssertion | Array of testResultAssertion objects | Test case assertion logs or scripts. |
updatedAt | string | The date and time when the test case was last updated. |
numberOfExecutions | integer | The number of executions done in the test case. |
urlId | string | The unique URL identifier of a test case. |
Try it!
- Enter the test case ID below.
- Select the language in Language.
- Enter your user name or API credentials.
- Review your API call and click Try it!