Accessing Role Assignments of a specific team area via REST Api
![]() Hallo,
for my current project i need to get all contributor roles of a team area and team area only using REST api. I tried to get them using Process Api and Reportable REST Api, but every time i get all contributor roles for the entire hierarchy in wich particular team area is part of.
The two calls i am using look like this:
I know that by using JAVA Api i can get roles for specific process area. Is it possible to do the same with any particular REST Api?
|
2 answers
![]() Isn't /ccm/rpt/repository/foundation?fields=foundation/teamArea[itemId=%27teamAreaUUID%27]/roles just what you want? I'm not quite sure why you included contributors/users in your example.
Comments Hello Donald. Thank you for your answer.
As Marko mentioned we want only the roles which contributers have in the specific team area. Your suggestion would retrieve the pool of roles defined for this team area, from wich roles are assigned to process members.
We do not need the information which roles are available in the context of a specific team area.
What we need is to know which roles are explicitly assigned to the users that are explicit members of a given team/project area.
Now I understand what you try to do. So, if user Marko has Team Member role in the project area, while having Scrum Master role in a team area, you want to show him having just the Scrum Master role in the team area, just like what the Manage Team Area page shows, not effectively having both Team Member and Scrum Master roles. Correct?
Due to our highly complex CLM setup and usage we need to develop our own CLM user administration tool. And this tool needs to know the exact role assignments and not the effective ones. In that case, probably have a look at the internal API
Hi Marko,
showing 5 of 6
show 1 more comments
|
![]() Hello Fabien,
Yes, we have got whatever we were expecting. And for this we have used the internal API -
/ccm/service/com.ibm.team.process.internal.service.web.IProcessWebUIService/teamAreaByUUIDWithLimitedMembers?processAreaItemId=<teamAreaUUID>.
As a response we will get a SOAP response, in which you have an element "<members>...</members>", as shown below -
This will provide us a details, process roles assigned to each member of the team.
<members>
<itemId>_6JGiMbBTEeSuG621rZPROg</itemId>
<archived>false</archived>
<emailAddress>abc.com</emailAddress>
<name>abc</name>
<userId>abc@abc</userId>
<processRoles>
<description>
The default role, implicitly assigned to each user. This role cannot be assigned, removed, or reordered.
</description>
<id>default</id>
<label>default</label>
<cardinality>0</cardinality>
</processRoles>
</members>
and there will be an element <admins>...</admins> which explains the admin member details. as shown below -
<admins>
<itemId>_6JGiMbBTEeSuG621rZPROg</itemId>
<archived>false</archived>
<emailAddress>abc.com</emailAddress>
<name>abc</name>
<userId>abc@abc</userId>
<processRoles>
<description>
The default role, implicitly assigned to each user. This role cannot be assigned, removed, or reordered.
</description>
<id>default</id>
<label>default</label>
<cardinality>0</cardinality>
</processRoles>
</admins>.
We have used XPathExpression to resolve the xml to construct required POJO's.
Hope that answered your question.
Thank you,
Praveen S H
|
Comments
The problem here is that we want the roles that are explicitly assigned to the user in the given team area. But what we get is the number of roles that the user in the end has in the context of the team area.