It's all about the answers!

Ask a question

Creating an execution work item using REST API


Julie DeMeester (13616) | asked Oct 27 '15, 5:08 p.m.
I am using the Chrome Postman and I am able to get existing execution results, but it is unclear from all the documentation that I have read, how to create one.  My assumption is that I would use the POST command with the following

https://,<my rqm server>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Test+Project/executionresult/webid=?

and that it would return the ID of the created executionworkitem and that I could then fill in the details, like pass or fail. 

Can someone help. 

2 answers



permanent link
Frank McGrath (242162) | answered Oct 27 '15, 5:25 p.m.
JAZZ DEVELOPER
 You need to do a PUT to a URL such as 
https://localhost:9443/jazz/secure/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Quality+Manager/executionresult/N5_1


with an XML body such as

<?xml version="1.0" encoding="UTF-8"?>
<ns2:executionresult xmlns:ns1="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:ns10="http://jazz.net/xmlns/alm/qm/qmadapter/task/v0.1" xmlns:ns11="http://jazz.net/xmlns/alm/qm/qmadapter/v0.1" xmlns:ns12="http://jazz.net/xmlns/alm/qm/v0.1/executionworkitem/v0.1" xmlns:ns13="http://open-services.net/ns/core#" xmlns:ns14="http://open-services.net/ns/qm#" xmlns:ns15="http://jazz.net/xmlns/prod/jazz/rqm/process/1.0/" xmlns:ns16="http://www.w3.org/2002/07/owl#" xmlns:ns17="http://jazz.net/xmlns/alm/qm/v0.1/executionresult/v0.1" xmlns:ns18="http://jazz.net/xmlns/alm/qm/v0.1/catalog/v0.1" xmlns:ns2="http://jazz.net/xmlns/alm/qm/v0.1/" xmlns:ns3="http://schema.ibm.com/vega/2008/" xmlns:ns4="http://purl.org/dc/elements/1.1/" xmlns:ns5="http://jazz.net/xmlns/prod/jazz/process/0.6/" xmlns:ns6="http://jazz.net/xmlns/alm/v0.1/" xmlns:ns7="http://purl.org/dc/terms/" xmlns:ns8="http://jazz.net/xmlns/alm/qm/v0.1/tsl/v0.1/" xmlns:ns9="http://jazz.net/xmlns/alm/qm/v0.1/testscript/v0.1/">
  <ns4:title>Results for WebSphere Commerce Sutie_1 EWI 1.1</ns4:title>
  <ns4:description>ExecutionResult: At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,  sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,  At accusam aliquyam diam diam dolore dolores duo eirmod eos erat, et nonumy sed tempor et et invidunt justo labore Stet clita ea et gubergren, kasd magna no rebum. sanctus sea sed takimata ut vero voluptua. est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr,  sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat.</ns4:description>
  <ns6:state>com.ibm.rqm.execution.common.state.perm_failed</ns6:state>
  <ns4:creator ns1:resource="https://localhost:9443/jazz/resource/itemName/com.ibm.team.repository.Contributor/TestJazzAdmin1">TestJazzAdmin1</ns4:creator>
  <ns6:owner ns1:resource="https://localhost:9443/jazz/resource/itemName/com.ibm.team.repository.Contributor/TestJazzAdmin2">TestJazzAdmin2</ns6:owner>
  <ns17:machine>machine name</ns17:machine>
  <ns17:log>log name</ns17:log>
  <ns17:starttime>2015-01-01T02:12:22.474-05:00</ns17:starttime>
  <ns17:endtime>2015-01-01T02:13:22.000-05:00</ns17:endtime>
  <ns17:weight>75</ns17:weight>
  <ns17:pointspassed>0</ns17:pointspassed>
  <ns17:pointsfailed>0</ns17:pointsfailed>
  <ns17:pointsattempted>75</ns17:pointsattempted>
  <ns17:pointsblocked>0</ns17:pointsblocked>
  <ns17:pointsinconclusive>0</ns17:pointsinconclusive>
  <ns2:pointspermfailed>75</ns2:pointspermfailed>
  <ns2:pointsdeferred>0</ns2:pointsdeferred>
  <ns2:testcase href="https://localhost:9443/jazz/secure/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Quality+Manager/testcase/N5_1"/>
  <ns2:testscript href="https://localhost:9443/jazz/secure/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Quality+Manager/testscript/N5_1"/>
  <ns2:executionworkitem href="https://localhost:9443/jazz/secure/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Quality+Manager/executionworkitem/N5_1"/>
</ns2:executionresult>


permanent link
Frank McGrath (242162) | answered Oct 29 '15, 4:33 p.m.
JAZZ DEVELOPER
 The N5_1 stuff is the external id of a test case, script, ...  mine all happened to magically start with "N5_" and then this example was for the first test case, script, ... hence "N5_1".  Your IDs would be different.  And yes - those URIs are references to the various artifacts.

I am not sure why you are getting the ns2.. error.  That is the namespace from 


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.