Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Error when create workitem via Rest API

Hi, guys
I try create workitem via Rest API with attribute(Description) containing text inside  <text>.  After creating wortkiten in Rational Team Concert the text and <> is removed.
REQUEST BODY:
<oslc_cm:ChangeRequest xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:oslc_disc="http://open-services.net/xmlns/discovery/1.0/" xmlns:dc="http://purl.org/dc/terms/" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:oslc_cm="http://open-services.net/xmlns/cm/1.0/" xmlns:jp="http://jazz.net/xmlns/prod/jazz/process/1.0/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:oslc_qm="http://open-services.net/xmlns/qm/1.0/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:calm="http://jazz.net/xmlns/prod/jazz/calm/1.0/" xmlns:rtc_cm="http://jazz.net/xmlns/prod/jazz/rtc/cm/1.0/" xmlns:jd="http://jazz.net/xmlns/prod/jazz/discovery/1.0/" xmlns:oslc_rm="http://open-services.net/xmlns/rm/1.0/"><dc:type rdf:resource="https://stend-fr2:9443/jazz/oslc/types/https://eld64:9443/jazz/oslc/contexts/_dlsysLIzEeGCN8XOKY-7rQ/workitems/ЗНИ"/><dc:description>test <test> test</dc:description><rtc_cm:id_ppmc>132403</rtc_cm:id_ppmc><dc:title>132403 <test> 12345</dc:title><rtc_project_name>Test</rtc_project_name><rtc_cm:state></rtc_cm:state><rtc_cm:автор>Admin User</rtc_cm:автор><rtc_cm:номер>132111</rtc_cm:номер></oslc_cm:ChangeRequest>

0 votes



2 answers

Permanent link
The error is caused most likely by the illegal char "<" and ">" to the xml entity

http://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references

you can give a try with

<dc:description>test &amp;lt; &amp;lt;  &amp;gt; &amp;gt; test</dc:description>

hope it works

0 votes


Permanent link
Hi all
i try encode under XML specification(How i can insert HTML in forum?)
And in time creating workitem the text area between symbols (&lt and &gt) and symbols themselves were removed.

0 votes

Your answer

Register or log in 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 480

Question asked: Aug 02 '12, 2:38 a.m.

Question was seen: 5,084 times

Last updated: Aug 06 '12, 5:33 a.m.

Confirmation Cancel Confirm