It's all about the answers!

Ask a question

How to update a test case state using REST API?


Paraschivoiu Alexandru (111) | asked Jul 08, 1:55 p.m.
edited Jul 08, 1:59 p.m.

Hello all,


I have a test case which can have multiple state actions like "In Work" "Blocked" "Retired" etc, how can I use REST API in order to update this state automatically? Any how-to on the web for this thing? 

I want to create a sistem that verify if testcase match with the requirement regarding an attribute(already done with REST API) and if in case it doesn't match, the testcase must be updated and as a rule the testcase cannot be updated if it isn't in a state like 'In progress" or "In Work".


Any ideas?


Comments
Michael Rowe commented Jul 08, 4:36 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR

I would suggest you start by looking at the ELM API Landing page - https://jazz.net/wiki/bin/view/Deployment/ELMProductAPILanding 

From there you will see all the publicly supported APIs that you can use to work on this.  

From there I would then look at the ETM Reportable Rest APIs to understand how to look at test case data, and the EWM APIs for how to update Work Items.

One answer



permanent link
Ralph Schoon (63.3k33646) | answered Jul 09, 2:59 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

There are two REST APIs supported by ETM. The OSLC and the Reportable REST API. As Michael pointed out in his comment, you probably want to read up on these APIs. The ETM reportable REST API supports PUT and POST (which is quite surprising). 


I have only very limited experience with the ETM APIs, but I have used the EWM OSLC API to update the state. See https://rsjazz.wordpress.com/2022/02/02/ewm-work-item-oslc-cm-api/ . I would assume the ETM OSLC API works in a similar way.  

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.