It's all about the answers!

Ask a question

RQM REST API


Anvesh Reddy NallamaddiReddy (622) | asked Oct 07 '14, 8:30 a.m.
 I am trying to create a Test Script of type Command Line Prompt in RQM with the help of REST API's, using a xml template downloaded using GET command in REST API. The result in the Cmd prompt is shown as successfull, but Test Script is not getting created in RQM.

One answer



permanent link
Donald Nong (14.3k211) | answered Oct 08 '14, 2:16 a.m.
You need to give more details for others to help you. I have no problems with creating a Test Script using a REST client in Chrome. The basic steps are as follows.
1. Prepare the XML content to upload/post.
2. Send a POST request to https://<server>:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project>/testscript along with the XML content.
3. If successful, an HTTP 201 (created) will be returned, along with a "slug Id" in the "Content-Location" response header.
4. Append the "slug Id" to the Test Script resource URI and send a GET request - the newly created Test Script should be returned.
https://<server>:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project>/testscript/slug__aHW1QE6xEeSO2Z-9nmiDRA

Comments
Anvesh Reddy NallamaddiReddy commented Oct 08 '14, 5:37 a.m.

 Hi Donald,


Thanks for your quick response.

Actually I am successfully able to create Test Cases using REST API's and even Test Scripts of type manual using the REST API's. My only trouble is while creating Test Scripts of type Command Line Prompt using POST command.

sorry, I am not able to add the screenshot of the response.


Donald Nong commented Oct 09 '14, 8:06 p.m.

Surely you mean "Command Line" type, not "Command Line Prompt"? I actually missed this point originally. To create a test script of the "Command Line" type, you need to use the "remotescript" resource, not "testscript" resource. I assumed that you took the template "like for like" but apparently that was not the case. I have no problems with creating such test scripts using REST API following the same steps mentioned above.

Your answer


Register or to post your answer.