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

What is XML parameter for OSLC queries?

The following return HTML by default. How do I get them to return XML?

List all work item types for a project:
https://SERVER:PORT/jazz/oslc/types/PROJECTID/

List all states for a work item type:
https://SERVER:PORT/jazz/oslc/workflows/PROJECTID/states/WORKFLOWID/

0 votes



2 answers

Permanent link
 Try adding this Accept:application/xml in heder if you are using a REST client .


See http://open-services.net/bin/view/Main/CmRestApiV1?sortcol=table;up=#Media_Types_Used

Edit: What is the content of the html? is it about login? then you might need to login

0 votes

Comments

https://SERVER:PORT/jazz/oslc/types/PROJECTID/?Accept:application/xml

Did not work. The parameter was ignored.


Permanent link
Hi, Mike

In my test with RTC 4.0.4, I simply run via Firefox, it will still return XML instead of HTML.


What version of RTC do you use and what browser did you try? I remember that I did see the same issue before in Poster when login is not done properly(somehow I have to login to the server via browser first and then run the same commands in Posters.
The headers can be set to
Accept=application/xml
OSLC-Core-Version=2.0
in Poster (or other REST Client) to GET the XML response.

0 votes

Comments

I need it in IE, which is defaulting to HTML. I am looking for a "?" parameter to add to the above URLs.


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
× 10,934
× 515
× 478
× 31

Question asked: May 13 '14, 5:56 p.m.

Question was seen: 6,981 times

Last updated: May 14 '14, 1:32 p.m.

Confirmation Cancel Confirm