How Do I update Suiteexecutionrecord
On First Time I am Able to Create SuiteExecutionrecord by below api and xml data but whenever I Try for second time I am not able to Create it.I am getting Response as status code Ok
How do I update or Create SuiteExecutionRecord on Second time
Xml Body :-
<?xml version="1.0" encoding="UTF-8"?><ns2:suiteexecutionrecord xmlns:ns2="http://jazz.net/xmlns/alm/qm/v0.1/" xmlns:ns1="http://schema.ibm.com/vega/2008/" xmlns:ns3="http://purl.org/dc/elements/1.1/" xmlns:ns4="http://jazz.net/xmlns/prod/jazz/process/0.6/" xmlns:ns5="http://jazz.net/xmlns/alm/v0.1/" xmlns:ns6="http://purl.org/dc/terms/" xmlns:ns7="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 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/" 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:ns20="http://jazz.net/xmlns/alm/qm/styleinfo/v0.1/" xmlns:ns21="http://www.w3.org/1999/XSL/Transform"><ns2:projectArea href="https://jazz.net/sandbox01-qm/resource/itemOid/com.ibm.team.process.ProjectArea/_rcueAIgqEe2oDpuX_ikGjA" alias="RQM" /><ns3:title>RQMBF3 RQM3Group</ns3:title><ns3:description /><ns3:creator ns7:resource="https://jazz.net/jts/resource/itemName/com.ibm.team.repository.Contributor/8983474163">
8983474163
</ns3:creator><ns5:owner ns7:resource="https://jazz.net/jts/resource/itemName/com.ibm.team.repository.Contributor/8983474163">
8983474163
</ns5:owner><ns12:priority ns7:resource="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/process-info/_rcueAIgqEe2oDpuX_ikGjA/priority/literal.priority.101">literal.priority.101</ns12:priority><ns12:weight>100</ns12:weight><ns2:testsuite href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/testsuite/urn:com.ibm.rqm:testsuite:132" /><ns2:testplan href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/testplan/urn:com.ibm.rqm:testplan:1166" /></ns2:suiteexecutionrecord>
Response :-
Below is the response I am getting from it
<ns2:projectArea href="https://jazz.net/sandbox01-qm/resource/itemOid/com.ibm.team.process.ProjectArea/_rcueAIgqEe2oDpuX_ikGjA" alias="RQM+%28Quality+Management%29" />
<ns4:identifier>https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/suiteexecutionrecord/slug3vrCELHGEe2b96sqg-kFNA</ns4:identifier>
<ns2:webId>2565</ns2:webId>
<ns4:title>RQMBF3 RQM3Group</ns4:title>
<ns4:description />
<ns2:creationDate>2023-02-21T09:05:22.242Z</ns2:creationDate>
<ns6:updated>2023-02-21T09:17:11.365Z</ns6:updated>
<ns4:creator name="pravin shelke" ns1:resource="https://jazz.net/sandbox01-jts/resource/itemName/com.ibm.team.repository.Contributor/8983474163">8983474163</ns4:creator>
<ns6:owner name="pravin shelke" ns1:resource="https://jazz.net/sandbox01-jts/resource/itemName/com.ibm.team.repository.Contributor/8983474163">8983474163</ns6:owner>
<ns2:weight>100</ns2:weight>
<ns2:priority ns1:resource="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/process-info/_rcueAIgqEe2oDpuX_ikGjA/priority/literal.priority.101">literal.priority.101</ns2:priority>
<ns2:testplan href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/testplan/slug7l3X4LHDEe2b96sqg-kFNA" />
<ns2:testsuite href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/testsuite/sluglsqP8LHDEe2b96sqg-kFNA" />
<ns2:currenttestsuitelog href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/testsuitelog/slughZweELHIEe2b96sqg-kFNA" relation="currenttestsuitelog" />
<ns2:testsuitelog href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/testsuitelog/slug__hZweELHIEe2b96sqg-kFNA" relation="testsuitelog" />
<ns2:component href="https://jazz.net/sandbox01-qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_rcueAIgqEe2oDpuX_ikGjA/component/_r6qXMIgqEe2oDpuX_ikGjA" />
</ns2:suiteexecutionrecord>
One answer
Here is the documentation: https://jazz.net/wiki/bin/view/Main/RqmApi
Create is POST, update is PUT https://jazz.net/wiki/bin/view/Main/RqmApi#HTTP_PUT_POST_Requests
Comments
Could you Please Share the Sample xml body for Post and Put.
For Update Should I need to pass any other tag in xml body like Id of Already Created suiteexecutionrecord Id.
Whenever I try to Create new SuiteExecutionrecord with same Xml body that time I am Getting Response Status Code as 200 "OK" it is Expected behavior ?
Above mention xml Body I am using it for Create suiteexecutionrecord, same xml body is used for update as well or something I am missing in it.
I do not have an example, but I can read the documentation. For a PUT, I would expect the request body to contain the XML you received for the POST with some modifications.
I can also google: https://www.google.com/search?q=suiteexecutionrecord%2Furn%3Acom.ibm.rqm%3Asuiteexecutionrecord+site%3Ajazz.net
Not sure if there is an answer, but you are not the first to attempt this.
Comments
Michael Rowe
FORUM ADMINISTRATOR / FORUM MODERATOR Feb 22 '23, 8:30 a.m.Can you provide the full response message?
pravin shelke
Feb 22 '23, 11:35 p.m.Michael Rowe I have posted response also in the Question Please check
Ralph Schoon
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Feb 23 '23, 6:56 a.m.In Web APIS, the Command and ther headers are also absolutely important.