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

Why does the Requirements Management Reportable Rest API return a 400 error when the same query for QM and CCM return the correct XML?

Using Postman or C# to access the foundation portion of the Requirements Management Reportable Rest API returns an HTML page instead of the appropriate XML.

Accessing the same query in a web browser returns the correct XML result.
Accessing a similar query in Postman or C# for CCM or QM also return the correct XML result.

How do I get RM to return the XML from C#? Is it expecting some header in the request?

0 votes

Comments

 I think by masterly avoiding to put any useful information into the question you will never get an answer. See How should I ask a question in the Forum if I want to receive useful answers? to get better.


1. What URL?
2. What makes a query same?
3. What makes a query similar?

Answers:
1. https://<domain>/rm/rpt/repository/foundation?fields=foundation/projectArea/(name|archived|roleAssignments/(contributor/(userId|name|emailAddress)))
2. https://<domain>/rm/rpt/repository/foundation?fields=foundation/projectArea/(name|archived|roleAssignments/(contributor/(userId|name|emailAddress)))
3. https://<domain>/ccm/rpt/repository/foundation?fields=foundation/projectArea/(name|archived|roleAssignments/(contributor/(userId|name|emailAddress)))



One answer

Permanent link

Shot into the blue. Have you cared to read the html code you get back? Does it try to display a login page? Have you logged in and provided the headers with the login information?

0 votes

Comments

400 BAD REQUEST is only responded if there is no login. 

Use Postman integrated in Chrome, login to CLM and then all above links work.
You need to perform the login and provide the cookies

Yes, I've looked at the HTML I get back. It's JavaScript doing something with oAuth, but I don't know what. I do know that it opens a window, runs the JavaScript function doit(), and immediately closes. This is the header:
<!--
    This page is always sent as the OAuth callback from the Jazz web UI. It
    expects to have been launched in a popup window and expects that the calling
    application contain a function named jazz.__oauthCallback(oauth_token) that
    will resume control flow after the OAuth provider calls back to this page.
-->
Authentication is handled by smart card. I don't need to provide headers for the CCM or QM applications and they return the expected query results.

Yes, smart card authentication is supported. I assume there is support in the browser and there is definitely something in the Eclipse client. But perhaps there is none for C#? Assuming because it works in your browser then it works everywhere else is a bit of a stretch.

I'm not assuming it works for C#. It does work for C# for CCM and QM applications, only RM is causing issues. Would RM typically require headers and NativeClientAuthentication when CCM and QM do not?

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

Question asked: Oct 18 '18, 11:14 a.m.

Question was seen: 4,591 times

Last updated: Oct 24 '18, 3:30 p.m.

Confirmation Cancel Confirm