This documentation explains the list of publicly available REST API in synapseRT to perform the products own actions via programmatically.
...
Expand |
---|
title | Create Test Runs with Run Attribute/s Assigned from an 'Advanced Test Cycle' |
---|
|
POST /rest/synapse/latest/public/testRun/createTestRuns Note: - If you want to leave 'Urgency' as blank, set value as: null
- If you want to leave 'Tester' as 'Unassigned', set value as: Unassigned
- If you only have one run attribute created in your project, specify following for "attributeValues": "AttributeName": "AttributeValue", "-": "-"
- If there are partial test runs created due to some invalid attribute input, it will still return code 200, succeed records will be listed in response and error for invalid input will also be there.
Code Block |
---|
| {
"testCaseKeys": "FRS-14,FRS-15,FRS-16",
"cycleId": "164",
"attributeValues":
[
{
"Instance": "sbus.ins1", "Configuration": "-"
},
{
"Instance": "-", "Configuration": "Inter_Configure_1"
},
{
"Instance": "sbus.ins1", "Configuration": "Inter_Configure_1"
}
],
"urgencyValue": "High,null,Low",
"assignValue": "tester,cma,Unassigned",
"progressKey": "bulkTestRun-Create"
} |
STATUS 200 Returned if the Test Runs are successfully created from the Test Cycle STATUS 403 Returned if the user is not authorized perform the action or there is no valid license STATUS 404 Returned if the testCaseKey or cycleId or attributeValues provided is not found STATUS 500 Returned if there is any validation error with input data or any unknown Internal Server Error |
...
Expand |
---|
title | Create New Test Case with Test Suite |
---|
|
POST: /rest/synapse/latest/public/testSuite/createTestCase - If 'testSuitePath' doesn't exist, a new Test Suite will be created by API and then link Test Case to it.
- If 'TestSuitePath' exists, the Test Case will be linked to the Test Suite directly.
Code Block |
---|
| {
"fields":
{
"project":
{"key": "FRS"},
"summary": "REST API Test Case with Test Suite",
"description": "This Test Case Is Created from REST API",
"issuetype":
{"name": "Test Case"}
},
"testcasesteps":
[
{"step": "It is the first Test Step", "stepData": "It is Test Data for the first Test Step", "expectedResult": "It is the Expected Result for the first Test Step"},
{"step": "It is the second Test Step", "stepData": "It is Test Data for the second Test Step", "expectedResult": "It is the Expected Result for the second Test Step"}
],
"linkToTestSuite":
{
"testSuitePath": "ROOT Test Suite/Sub Test Suite",
"projectKey": "FRS"
}
} |
Code Block |
---|
| {
"testSuitePath": "ROOT Test Suite/Sub Test Suite",
"projectKey": "FRS",
"testCaseKey": "FRS-146",
"createdTestSuiteId": 281,
"createdTestCase": {
"id": 16282,
"key": "FRS-146"
}
} |
STATUS 200 Returned if the Test Case is successfully created STATUS 403 Returned if the user is not authorized perform the action or there is no valid license STATUS 500 Returned if there is any validation error with input data or any unknown Internal Server Error |
...
Expand |
---|
title | Link Existing Test Case/s to Test Suite |
---|
|
POST: /rest/synapse/latest/public/testSuite/linkTestCase - If 'testSuitePath' doesn't exist, a new Test Suite will be created by API and then link Test Case/s to it.
- If 'TestSuitePath' exists, the Test Case/s will be linked to the Test Suite directly.
Code Block |
---|
| {
"testCaseKeys": ["FRS-14","FRS-15"],
"testSuitePath": "ROOT Test Suite/Sub Test Suite",
"projectKey": "FRS"
}
|
STATUS 200 Returned if the Test Case/s is successfully linked to specified Test Suite STATUS 403 Returned if the user is not authorized perform the action or there is no valid license STATUS 500 Returned if there is any validation error with input data or any unknown Internal Server Error |
...