Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Is there any jira rest api which gives me list of group names present for the given Project

Vasundaradevi Palatla July 1, 2019

Required Functionality : When I select any project then users who belong to that project should be listed in the reporters tab when I create new issue.But I get all the users who are present in jira in reporters tab.

Issues faced: So inorder to overcome this issue Iam giving groupname then I get users who belong to that group (by using  jira rest api /rest/api/2/group? + groupname=${groupname}&expand=users[${startAt}:${maxResults}] )

But here I face an issue : I am not able to get the group name related to the selected project?

Here I dont know which project has which group in jira.If there is any jira rest api that gives me details of which project has which group then it will solve my issue

Any way to set project configuration/permissions in JIRA tool for reporters tab during issue creation:

Or you  can suggest is there any way to set project permissions in JIRA tool such that it will only list the users present in its groups(selected project containing groups) in reporters tab rather than listing all the users present in JIRA .

 

Thanks & Regards,

Vasundara Devi.

2 answers

1 accepted

1 vote
Answer accepted
Alexey Matveev
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
July 1, 2019

Hello,

Have a look at this REST API:

api/2/project/{projectIdOrKey}/role

It will return roles with actors for a project you provide. Actors contain groups and users, which are assigned to the roles

Vasundaradevi Palatla July 1, 2019

Thanks a lot, it solved my issue

0 votes
Vasundaradevi Palatla July 1, 2019

With the help of Alexey Matveev (above solution) I was able to fix the issue

Solution API:

rest api to get the actors(which contains group details) present for the given projectId :

/rest/api/2/project/${projectId}/role/10101

Suggest an answer

Log in or Sign up to answer