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

Quering User by userId using REST API

Hi,
I was looking for a way to retrieve an user through REST API using his userId.

If I search a user with his name it works correctly with this command:

curl -k -L -b cookies.txt "http://myurl/ccm/oslc/users.json?oslc_cm.query=dc:title=%22TechUser%22%20&oslc_cm.properties=dc:title,rdf:resource,rtc_cm:userId"


and it also runs if I'm searching for the e-mail address:

curl -k -L -b cookies.txt "http://myurl/ccm/oslc/users.json?oslc_cm.query=rtc_cm:emailAddress=%22TechUser@email.me%22%20&oslc_cm.properties=dc:title,rdf:resource,rtc_cm:userId"


But if I try using rtc_cm:userId

curl -k -L -b cookies.txt "http://myurl/ccm/oslc/users.json?oslc_cm.query=rtc_cm:userId=%22TechUser%22%20&oslc_cm.properties=dc:title,rdf:resource,rtc_cm:userId"


I get a 400 error which says that userId is an unknown attribute ID.

How can I run this query?

Thanks,
Michele.

2 votes



One answer

Permanent link
If I cannot use a query to find the user I have to retrieve all the users. And with a lot of user I've find out that my result is truncated: not all the users are extracted and no error or warning has been returned to inform of this truncation.

If it is not possible to do a query by userId is it possible to extend the max result number?

Thanks,
Michele.

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
× 10,948

Question asked: Oct 21 '11, 3:58 a.m.

Question was seen: 5,293 times

Last updated: Jun 28 '12, 8:28 a.m.

Confirmation Cancel Confirm