RTC Rest API: How to order results by specific value?
How can I set an order by a specific value of the workitems results when make an RTC API request?
Accepted answer
I consider this unsupported. See the comment:
This is the documentation: https://jazz.net/wiki/bin/view/Main/ReportsRESTAPI
To sort, you would have to postprocess the data on your own criteria.
3 other answers
https://example.com/ccm/rpt/repository/workitem?fields=workitem/workItem[projectArea/itemId='_Pxm-0HlGEeOR04eNUyuCuz' and type/id='incident' and creationDate > 2023-07-10T00:00:00.0-0300]/(id|state/(id|name)|summary|owner/name|creationDate|resolutionDate|dueDate|allExtensions/(key|displayValue))&size=5000&pos=5000&sort=field_name
https://example.com/ccm/rpt/repository/workitem?fields=workitem/workItem[projectArea/itemId='_Pxm-0HlGEeOR04eNUyuCuz' and type/id='incident' and creationDate > 2023-07-10T00:00:00.0-0300]/(id|state/(id|name)|summary|owner/name|creationDate|resolutionDate|dueDate|allExtensions/(key|displayValue))&size=5000&pos=5000&sort=creationDate,desc
Comments
What is the basis for this answer? I looked into the documentation https://jazz.net/wiki/bin/view/Main/ReportsRESTAPI#Reportable_REST_API and there is no mentioning of a sort option. Where do you get your knowledge?
Try This
https://example.com/ccm/rpt/repository/workitem?fields=workitem/workItem[projectArea/itemId='_Pxm-0HlGEeOR04eNUyuCuz' pizza tower and type/id='incident' and creationDate > 2023-07-10T00:00:00.0-0300]/(id|state/(id|name)|summary|owner/name|creationDate|resolutionDate|dueDate|allExtensions/(key|displayValue))&size=5000&pos=5000&sort=field_name
Comments
This is the documentation: https://jazz.net/wiki/bin/view/Main/ReportsRESTAPI
To sort, you would have to postprocess the data on your own criteria.