It's all about the answers!

Ask a question

Creating new Requirement via OSLC POST fails


magnus Elfving (348) | asked Apr 13 '21, 2:19 a.m.
edited Apr 13 '21, 2:20 a.m.

 Hello,


I've now successfully queried and and updated requirements through OSLC GET and PUT messages.

However, when I try to create a requirement via POST I get "(403) Forbidden" response.

Below follows the setup for the POST message:

Any ideas why I fail to create the requirement ?  

Headers:
   httpWebRequest.Headers.Add("OSLC-Core-Version", "2.0")
   httpWebRequest.Accept = "application/rdf+xml"
   httpWebRequest.ContentType = "application/rdf+xml"
   httpWebRequest.Method = "POST"
URL:
https://.../rm/requirementFactory?projectURL=https%3A%2F%2F...%2Frm%2Fprocess%2Fproject-areas%2F_u9BacHJ7EeuYaNFaR904Vg

Body:
<rdf:RDF
        xmlns:rm="http://www.ibm.com/xmlns/rdm/rdf/"
        xmlns:acp="http://jazz.net/ns/acp#"
        xmlns:rm_property="https://.../rm/types/"
        xmlns:oslc="http://open-services.net/ns/core#"
        xmlns:nav="http://jazz.net/ns/rm/navigation#"
        xmlns:oslc_rm="http://open-services.net/ns/rm#">
      <rdf:Description rdf:about="">                           
<oslc:instanceShape rdf:resource="https://.../rm/types/_EhdMTnJ8EeuYaNFaR904Vg"/                              
                <dcterms:title rdf:parseType="Literal">New Requirments xyz</dcterms:title>
</rdf:Description>
</rdf:RDF> 
   

Accepted answer


permanent link
magnus Elfving (348) | answered Apr 13 '21, 7:49 a.m.

 Problem solved, bad xml formatting.


Ralph Schoon selected this answer as the correct answer

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.