Below are the list of REST APIs we developed related to test run.
Get Test Run Details GET /rest/testray/latest/public/testRun/{testRunID}
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/60000
REQUEST BODY NULL
Update Test Run Result PUT /rest/testray/latest/public/testRun/update
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/update
REQUEST BODY
JSON
{
"runId":60000,
"result": "Failed",
"comment": "REST API Comment",
"bugs":["TPB-1278", "TPB-1279"],
"testRunFields":
{
"Run Field 1":["Run Field 1 - Value 1", "Run Field 1 - Value 2"],
"Run Field 2":["Run Field 2 - Value 1", "Run Field 2 - Value 2"]
},
"executorId": "5f115539e5efc1001bbd5051"
}
Update Test Step Result from a Test Run PUT /rest/testray/latest/public/testRun/updateStep
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/updateStep
REQUEST BODY
JSON
{
"runStepId": 392720,
"result": "Passed",
"actualResult": "REST API Updated Actual Result, Step 1",
"bugs":["TPB-1212"],
"executorId": "5f115539e5efc1001bbd5051"
}
Update Multiple Test Run Results POST /rest/testray/latest/public/testPlan/{testPlanIssueKey}/bulkStatusUpdate
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testPlan/TAT-200/bulkStatusUpdate
REQUEST BODY
JSON
{
"testCycleId":600,
"status":"Passed",
"runIds":[60000,60001]
}
Add Attachment to a Test Run POST /rest/testray/latest/public/testRun/attachment/{testRunID}/testrun
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/attachment/60000/testrun
REQUEST BODY
SUPPORTED CONTENT TYPE MULTIPART_FORM_DATA
NOTE Make sure to include key named "files" and of type "File" to select the files
Add Attachment to a Test Run Step POST /rest/testray/latest/public/testRun/attachment/{testRunID}/testrun/step/{testRunStepID}
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/attachment/60000/testrun/step/100000
REQUEST BODY
SUPPORTED CONTENT TYPE MULTIPART_FORM_DATA
NOTE Make sure to include key named "files" and of type "File" to select the files
Get Attachment Details from a Test Run GET /rest/testray/latest/public/testRun/{testRunID}/getAttachmentDetails
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/60000/getAttachmentDetails
REQUEST BODY NULL
Delete Attachment from a Test Run DELETE /rest/testray/latest/public/testRun/{testRunID}/deleteAttachment/{attachmentID}
SAMPLE http://testray.goldfingerholdings.onl/rest/testray/latest/public/testRun/60000/deleteAttachment/500
REQUEST BODY NULL