API changes from v8.5 to v8.5.1

API changes from v8.5 to v8.5.1

With the new and upcoming releases of QMetry, we continue to add exciting and useful new features that improve the usability. With the new features and improvements being added to QMetry also necessitates changes in the APIs. This page enlists such APIs that will be changed from version 8.5 to 8.5.1. The purpose of this document is to help Integration Teams keep their code updated and current with the API changes/updates to the existing APIs.

 

Updated APIs

Update Test Case Linked to Test Suite with Latest Version

API

/rest/testsuites/link/testcaseWithLatestVersion

API

/rest/testsuites/link/testcaseWithLatestVersion

Method

POST

Impact of Change

Medium

Backward Compatible

No

Reason for Change

New feature introduced to sync all / certain test cases using bulk operation on execution screen, required adding new parameters to the request of this API.

Changes

The request structure has been modified

 

The below parameters are new in the request.

  • "tcRunID" : List of tcRunIds separated by comma for Bulk Sync

  • "SyncAll" : When set to "True" - syncs all the test cases to a given "tsRunID" and "tcRunIDs" will be ignored

  • "SyncAll" : When set to "False" - to ignore the "SyncAll" parameter and  "tsRunID" parameter.

  • "tsRunID" : Mandatory when "SyncAll" is passed as "True"

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

Request Body
{ "tcRunID": 2850695 }

 

Request Body
{ "tcRunIDs": [ 3400, 3401 ], "syncAll": true, "tsRunID": 435 }

Get List of Testcases while Linking to a Test suite

API

/rest/testcases/list/forTS

API

/rest/testcases/list/forTS

Method 

POST

Impact of Change

Medium

Backward Compatible

Yes

Reason for Change

New feature introduced to find test cases not already linked to a test suite's current release and cycle and to find test cases not linked to a test suite (irrespective of their release and cycle)

Changes

The request body is modified to include new options to filter test cases that are not already linked to this Test Suite.

  • "showUnlinked" : flag - When set to "True" will return test cases which are not linked to this TS (Does not return already linked Test Cases to this TS).

  • "showUnlinkedForReleaseCycle" : flag - When set to "True" will return test cases not linked to this TS belonging to chosen release and cycle.

The reponse body now returrns applied filter as well

  • "filter" : Returns latest saved filter information.

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

Request Body
{ "limit": 20, "start": 0, "page": 1, "getColumns": true, "filter": "[{\"type\":\"list\",\"value\":[5073],\"field\":\"release\", { \ "type\":\"list\",\"value\":[10617],\"field\":\"cycle\"}]",, "udfFilter": "[]", "showAllStateEntities": true, "getLinked": false, "showEntityWithReleaseCycle": true, "tsID": 175462 }
Request Body
{ "limit": 20, "start": 0, "page": 1, "getColumns": true, "filter": "[{\"type\":\"list\",\"value\":[295],\"field\":\"release\"}, { \ "type\":\"list\",\"value\":[345],\"field\":\"cycle\"}]", "udfFilter": "[]", "tsID": 502, "showUnlinked": false, "showUnlinkedForReleaseCycle": true, "showEntityWithReleaseCycle": false, "showAllStateEntities": true, "getLinked": false }

 

 

Response
{ "data": [{ "tcVersionID": 1336357, "tcVersion": 2, ... ... }], "total": 1, "filterTemplate": [{ "displayName": "Priority", ... ... }, ... }, { "displayName": "isParameterized", ... }] }

 

Response
{ "data": [{ "tcVersionID": 6132, "tcVersion": 2, ... ... }], "total": 1, "filterTemplate": [{ "displayName": "Priority", ... ... }, ... { "displayName": "isParameterized", ... }], "filter": [], "udfFilter": "[]", "tcFolderPath": "", "showUnlinked": false, "showUnlinkedForReleaseCycle": false, "showEntityWithReleaseCycle": true }

 


Bulk Update Run Status

API

/rest/execution/runstatus/bulkupdate

API

/rest/execution/runstatus/bulkupdate

Method 

PUT

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

API modified to return the name of execution status as chosen on execution screen for quick identification from response.

Changes

The response now returns the name of the execution status under "tcrStatusAlias" as seen in the QMetry UI.

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

Response
{ "success": true, "code": "CO.BULK_UPDATE_RUNSTATUS_SUCCESS", "message": "Status is successfully bulk updated for 2 test case(s).", "data": [{ "entityIDs": "2850696,2850697", "entityType": "TCR", "qmTsRunId": "253601", "runStatusID": 14586, "COUNT": 2, "lastExecuted": "2019-02-08 07:25:27 PM", "tcrStatus": "14586", "executedBy": "punitsamtani" }] }

 

Response
{ "success": true, "code": "CO.BULK_UPDATE_RUNSTATUS_SUCCESS", "message": "Status is successfully bulk updated for Count test case(s).", "data": [{ "entityIDs": "2577,2579", "entityType": "TCR", "qmTsRunId": "706", "runStatusID": 331, "COUNT": 2, "lastExecuted": "02-08-2019 08:57:38", "tcrStatus": "331", "tcrStatusAlias": "Failed", "executedBy": "punit" }] }

 

Get List of Requirements while Linking to a Test suite

API

/rest/requirements/list/forTS

API

/rest/requirements/list/forTS

Method 

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

New feature that preserves and saves filter on grid of the UI requires this information in the API.

Changes

Changed Response Structure. Below is the new parameter added in response structure.

  • "filter" : Returns latest saved filter information.

 

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "data": [{ "priority": 275405, "priorityAlias": "Blocker", ... ... }], "total": 2, "filterTemplate": [{ "displayName": "Priority", ... }, ... }, { "displayName": "Owner", ... }] }

 

Response
{ "data": [{ "priority": 17673, "priorityAlias": "Blocker", ... ... }], "total": 2, "filterTemplate": [{ "displayName": "Priority", ... }, ... "displayName": "Owner", ... }], "filter": [{ "type": "list", "value": [343, 295], "field": "release" }, { "type": "list", "value": [345, 401], "field": "cycle" }], "udfFilter": "[]", "rqFolderPath": "" }

 

Get List of Testcases for a Requirement

 

API

/rest/testcases/list/forRQ

API

/rest/testcases/list/forRQ

Method

POST

Impact of Change

Medium

Backward Compatible

Yes

Reason for Change

New feature that preserves and saves filter on grid of the UI requires this information in the API.

Changes

Changed Response Structure. Below is the new parameter added in response structure.

  • "filter" : Returns latest saved filter information.

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "data": [{ "tcVersionID": 1336358, "tcVersion": 2, "isArchived": false, ... }], "total": 1, "filterTemplate": [{ "displayName": "Priority", "field": "priorityAlias", "fieldType": "list", "isUDF": false }, ... ... { "displayName": "isParameterized", ... }] }

 

Response
{ "data": [{ "tcVersionID": 6131, "tcVersion": 2, "isArchived": false, ... }], "total": 1, "filterTemplate": [{ "displayName": "Priority", "field": "priorityAlias", "fieldType": "list", "isUDF": false ... ... { "displayName": "isParameterized", ... }], "filter": [{ "type": "list", "value": [3372], "field": "priorityAlias" }], "udfFilter": "[]", "tcFolderPath": "" }

 

Get Test Suite List along with Fields

API

/rest/testsuites/list/viewColumns

API

/rest/testsuites/list/viewColumns

Method

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change 

New feature that preserves and saves filter on grid of the UI requires this information in the API

Changes

The response structure is changed with sorting retained and returned in the response with "sort".

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "data": [{ "name": "Test Suite B", "entityKey": "AT-TS-2", "attachmentCount": 0, ... }, { "name": "Test Suite A", "entityKey": "AT-TS-1", ... "isArchived": false }], "total": 2, "viewId": 6160, "filter": "[]", "viewName": "Custom", "filterTemplate": [{ "displayName": "Status", ... }, ... ... }], "columns": { "visibleColumns": [{ "displayName": "Summary", ... }], "hiddenColumns": [{ "displayName": "Owner", "field": "owner", ... }] }, "udfFilter": "[]", "folderSortColumn": "name", "folderSortOrder": "ASC", "hideEmptyFolders": false, "getSubEntities": true }

 

Response
{ "data": [{ "name": "Test Suite B", "entityKey": "AT-TS-1", "attachmentCount": 0, ... }, { "name": "Test Suite A", "entityKey": "AT-TS-2", ... "isArchived": false }], "total": 2, "viewId": 317, "filter": "[]", "sort": "[{\"property\":\"name\",\"direction\":\"DESC\"}]", "viewName": "Custom", "filterTemplate": [{ "displayName": "Status", ... }, ... ... }], "columns": { "visibleColumns": [{ "displayName": "Summary", ... }], "hiddenColumns": [{ "displayName": "Owner", "field": "owner", ... }] }, "udfFilter": "[]", "folderSortColumn": "name", "folderSortOrder": "ASC", "hideEmptyFolders": false, "getSubEntities": true }

Delete User

API

/rest/admin/user/delete

API

/rest/admin/user/delete

Method

PUT

Impact of Change

Low

Backward Compatible

No

Reason for Change

A bugfix related to audit logs message requires change in the API

Changes

The method changes from POST to PUT, request and response are unchanged.

 

 

Delete Project

API

/rest/admin/project/delete

API

/rest/admin/project/delete

Method

PUT

Impact of Change

Low

Backward Compatible

No

Reason for Change

A bugfix related to audit logs message requires change in the API

Changes

The method changes from POST to PUT, request and response are unchanged.

 

 

Add New Parameters

API

/rest/parameter

API

/rest/parameter

Method

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

In case a duplicate parameter is found, it can now be distinguished its with paramID

Changes

New Response Parameter "paramID" added.

 

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "success": true, "data": { "name": "Employee", "description": "Employee Parameter", "isArchived": false, "createdDate": "2019-02-08T14:10:46", "updatedDate": "", "value": [{ "paramValueID": 1927, "value": "Manager" }, { "paramValueID": 1928, "value": "Team Member" }] } }

 

Response
{ "success": true, "data": { "paramID" : 432, "name": "Employee", "description": "Employee Parameter", "isArchived": false, "createdDate": "2019-02-08T14:10:46", "updatedDate": "", "value": [{ "paramValueID": 1927, "value": "Manager" }, { "paramValueID": 1928, "value": "Team Member" }] } }

 

Get Requirements List along with Fields

API

/rest/requirements/list/viewColumns

API

/rest/requirements/list/viewColumns

Method

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

New feature that preserves sorting order on requirements grid requires change in the API

Changes

The response structure is changed with sorting retained and returned in the response with "sort"

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "data": [{ "entityKey": "PP-RQ-3", "associatedVersion": 2, "name": "RQ1-v2", ... }], "total": 1, "viewId": 736, "filter": "[{\"type\":\"list\",\"value\":[0,1],\"field\":\"isArchived\"}]", "viewName": "Custom", ... ], "columns": { "visibleColumns": [{ ... }, ... ], "hiddenColumns": [{ ... }, "udfFilter": "[]", "folderSortColumn": "name", "folderSortOrder": "ASC", "hideEmptyFolders": false, "getSubEntities": false }

 

Response
{ "data": [{ "entityKey": "1PT-RQ-1353", "associatedVersion": 1, "name": "RQ1-v2", ... }], "total": 1, "viewId": 1887, "filter": "[{\"type\":\"list\",\"value\":[0,1],\"field\":\"isArchived\"}]", "sort": null, "viewName": "Custom", ... }], "columns": { "visibleColumns": [{ ... }], "hiddenColumns": [{ ... }] }, "udfFilter": "[]", "folderSortColumn": "name", "folderSortOrder": "ASC", "hideEmptyFolders": false, "getSubEntities": true }

 

Get Test Cases List along with Fields

API

/rest/testcases/list/viewColumns

API

/rest/testcases/list/viewColumns

Method

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

New feature added to filter test cases that have shared test cases and the feature to save the sorting of test cases in grid require changes  in the API

Changes

A new flag is added in request and response with changes in the request and response structure.

  • "havingSharedTestcases" : flag - When set to True will get data of all test cases having Shared Test Cases linked to them.

  • The response structure is changed with sorting retained and returned in the response with "sort".

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

Request Body
{ "start": 0, "page": 1, "limit": 20, "scope": "project", "getSubEntities": true, "hideEmptyFolders": false, "folderSortColumn": "name", "folderSortOrder": "ASC", "viewId": 6159, "folderPath": "/API Test", "restoreDefaultColumns": false, "filter": "[]", "udfFilter": "[]" }

 

Request Body
{ "start": 0, "page": 1, "limit": 10, "scope": "project", "havingSharedTestcases": true, "getSubEntities": true, "hideEmptyFolders": true, "folderSortColumn": "name", "folderSortOrder": "ASC", "viewId": 316, "folderPath": "/API Test", "restoreDefaultColumns": false, "filter": "[]", "udfFilter": "[]" }

 

Response
{ "data": [{ "entityKey": "AT-TC-1", "tcFolderId": 102635, "associatedVersion": 2, ... }], "total": 1, "viewId": 6159, "filter": "[]", "viewName": "Custom", "filterTemplate": [{ ... }, ... }], "columns": { "visibleColumns": [{ "displayName": "Entity Key", ... }], "hiddenColumns": [{ "displayName": "Testing Type", "field": "testingTypeAlias", "isUDF": false, "order": 10, "width": "150" }, ... ... }] }, "udfFilter": "[]", "folderSortColumn": "name", "folderSortOrder": "ASC", "hideEmptyFolders": false, "getSubEntities": true, "isParameterized": false }

 

Response
{ "data": [{ "entityKey": "AT-TC-2", "tcFolderId": 389, "associatedVersion": 4, ... }], "total": 1, "viewId": 316, "filter": "[]", "sort": "[{\"property\":\"priorityAlias\",\"direction\":\"ASC\"}]", "viewName": "Custom", "filterTemplate": [{ ... }, ... }], "columns": { "visibleColumns": [{ "displayName": "Entity Key", ... }], "hiddenColumns": [{ "displayName": "Testing Type", "field": "testingTypeAlias", "isUDF": false, "order": 10, "width": "150" }, ... ... }] }, "udfFilter": "[]", "folderSortColumn": "name", "folderSortOrder": "ASC", "hideEmptyFolders": false, "getSubEntities": true, "isParameterized": false, "havingSharedTestcases": true }

Create Requirement

API

/rest/requirements

API

/rest/requirements

Method

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

rqVersionId in this API will help to avoid an addtional API call required to fetch rqVersionId from other APIs 

Changes 

A new flag is added in request and response with changes in the request and response structure.

  • "rqVersionId" : flag - added for quicker reuse in other APIs

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "success": true, "code": "RQ.ADD_ENTITY_SUCCESS", "message": "New requirement PP-RQ-4 created successfully", "data": [ { "id": 194071, "entityKey": "PP-RQ-4", "rqFolderId": 1925 } ] }

 

Response
{ "success": true, "code": "RQ.ADD_ENTITY_SUCCESS", "message": "New requirement 1PT-RQ-1353 created successfully", "data": [{ "id": 337678, "rqVersionId": 335711, "entityKey": "1PT-RQ-1353", "rqFolderId": 1183 }] }

Get Issues List along with Fields

API

/rest/issues/list/viewColumns

API

/rest/issues/list/viewColumns

Method

POST

Impact of Change

Low

Backward Compatible

Yes

Reason for Change

New feature that preserves sorting on the issues grid requires change in this API

Changes

The response structure is changed with sorting retained and returned in the response with "sort".

 

Version 8.5

Version 8.5.1

Version 8.5

Version 8.5.1

 

Response
{ "data": [{ "name": "Bug while testing API", "entityKey": "AT-IS-1", ... }], "total": 1, "viewId": 6164, "filter": "[]", "viewName": "Custom", "filterTemplate": [{ "displayName": "Entity Key", ... }], "columns": { "visibleColumns": [{ "displayName": "Summary", ... }], "hiddenColumns": [{ ... }] }, "udfFilter": "[]" }

 

Response
{ "data": [{ "name": "Bug while testing API", "entityKey": "AT-IS-1", ... }], "total": 1, "viewId": 324, "filter": "[]", "sort": "[{\"property\":\"typeAlias\",\"direction\":\"ASC\"}]", "viewName": "Custom", "filterTemplate": [{ "displayName": "Entity Key", ... }], "columns": { "visibleColumns": [{ "displayName": "Summary", ... }], "hiddenColumns": [{ ... }] }, "udfFilter": "[]" }

 

Deprecated APIs - APIs which will be deprecated in March 2019

API Name

Deprecated Rest Link

Alternative Rest Link

API Name

Deprecated Rest Link

Alternative Rest Link

Get list of Issue linked to Test case Run

rest/issues/getForTCRun

/rest/execution/issue/list/forTCRun

Get list of issue linked to Test case Step Run

rest/issues/getForTCStepRun

/rest/execution/issue/list/forTCStepRun