It's all about the answers!

Ask a question

How to get id for new created test result by using REST API through RQMUrlUtility?

jane zhou (106552) | asked May 26 '18, 5:31 p.m.


Hi Someone who may concern,
       We are working on CLM 6.0.4.
       We used the RQMUrlUtility to upload our test case result to REST API as 
<website>/qm/service/<project name>/executionresult/?

      And we can upload them properly. 
      However, we want to know the id of test case result created by using this way.  We want to know the id because we want to create link between defect and test case result ( failed ones)automatically by sending http command to rest API of RTC to update  the related defect.

      But when I checked the response from RQMUrlUtility, it only said  

RQMUrlUtility: Server Response code: 201
RQMUrlUtility: [ SUCCESS ] File : "xxx.xml" successfully posted to URL :
"https:<local site>:9443/qm/service/
ionService/resources/<local site>/executionresult/? "
Disconnecting from the IBM Rational Quality Manager server.

       So we are wondering whether we could add some options in our request to get id just created?

Best regards,
Jane Zhou

Accepted answer

permanent link
Paul Slauenwhite (8.4k12) | answered Jun 12 '18, 6:41 a.m.

 Hi Jane, 

If you're using a PUT request with an external ID, you already know the ID.  Otherwise, POST requests return the generated ID in the Content-Location response header (see  Unfortunately, this header is not exposed by the RQM URL Utility.  Alternatively, if you know the web ID of the test artifact, you could use the internal ID (see  Finally, you could query for the test artifact using the one it's properties and the fields filtering support (see

For the types of IDs supported, see

I would suggest using a HTTP client (see instead of the RQM URL Utility.

jane zhou selected this answer as the correct answer

jane zhou commented Jun 18 '18, 10:20 a.m.

Hi Paul,

      Thanks for your detailed explanation!

Best Regards,
Jane Zhou 

Your answer

Register or to post your answer.