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

How to check if the user exists in RTC ?

Hello All,

We have a usecase wherein we need to automate the user account creation.

As a part of first step. Given the userID, we need to check if the user has account in RTC.

Is there any OSLC/REST query to check this ? Or any other APIs to check the user existence ?


Request you to assist on this.

Thanks

0 votes



2 answers

Permanent link

 Options for automation


  1. Repotools -exportUsers
  2. Repotools -importUsers
  3. Repotools -createUsers
  4. Java API https://rsjazz.wordpress.com/2013/01/08/maintaing-user-photos-with-the-plain-java-client-libraries/ and https://rsjazz.wordpress.com/2012/10/12/changing-the-jazz-user-id-using-the-rtc-plain-java-client-libraries/ show at least how to get the users and find them using an ID.

0 votes


Permanent link

Shwetha,
I use this code snippet from the server-side Java API to retrieve a user (contributor) with a given userid:

IContributorService contributorService = getService(IContributorService.class);
IContributorHandle contributorHandle = contributorService.fetchContributorByUserId(userid);         
IContributor contributor = (IContributor) repositoryItemService.fetchItem(contributorHandle, IRepositoryItemService.COMPLETE);


In order to check whether a user exists in RTC, you could check if contributorHandle is null.

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
× 457

Question asked: Apr 28 '17, 7:18 a.m.

Question was seen: 3,885 times

Last updated: Apr 28 '17, 8:07 a.m.

Confirmation Cancel Confirm