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

Returning multiple resource entries from a single REST get

Hello,

I am attempting to use the RQM REST API to get all of the reservations within a project.

I started by doing a GET for the following URL:
https://SERVER:PORT/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/PROJECT/reservation

That returned an XML file containing a list of reservation IDs, which I can then append to the end of the above URL to get an XML file that contains the reservation's id, reserved and reserve fields.

However, if I just append ?fields=anything to the end of the URL, like this:
https://SERVER:PORT/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/PROJECT/reservation?fields=literallyanytext

Then I get an XML file with an <entry> block for each reservation and each <entry> block contains all of the above information.

1) Is the extra information that RQM returned when I added the ?fields= parameter expected? I hope so, as it would greatly reduce the # of REST GET requests I'd have to make.
2) Is there any way that I can select the fields that I want from the reservations? (e.g. I'd want the above listed fields + the specific machine information for each reservation)

Thank you for your time

0 votes



2 answers

Permanent link
You should get same data which contains rqm's feed format, having entry for each artifact with minimal info like name, summary, modified, href etc.

See https://<your>:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/schema/feed.xsd
for feed schema shape.

0 votes


Permanent link
Hello,

I am attempting to use the RQM REST API to get all of the reservations within a project.

I started by doing a GET for the following URL:
https://SERVER:PORT/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/PROJECT/reservation

That returned an XML file containing a list of reservation IDs, which I can then append to the end of the above URL to get an XML file that contains the reservation's id, reserved and reserve fields.

However, if I just append ?fields=anything to the end of the URL, like this:
https://SERVER:PORT/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/PROJECT/reservation?fields=literallyanytext

Then I get an XML file with an <entry> block for each reservation and each <entry> block contains all of the above information.

1) Is the extra information that RQM returned when I added the ?fields= parameter expected? I hope so, as it would greatly reduce the # of REST GET requests I'd have to make.
2) Is there any way that I can select the fields that I want from the reservations? (e.g. I'd want the above listed fields + the specific machine information for each reservation)

Thank you for your time


The fact that .../reservation?fields=literallyanytext is returning all of the fields for reservation sees to be a convenient bug, so I wouldn't count on it continuing to work. Try .../reservation?abbreviate=false. This should return all of the fields in a supported way.

The fields command is not currently supported for reservation, so the feed will either contain the abbreviated fields or will contain them all.

- Rob

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

Question asked: Aug 03 '11, 3:08 a.m.

Question was seen: 8,377 times

Last updated: Aug 03 '11, 3:08 a.m.

Confirmation Cancel Confirm