• Community
  • Products
  • Jira
  • Questions
  • Should "Browse Users" permission allow me to list all users in a group using the REST API? If not, what permission do I need?

Should "Browse Users" permission allow me to list all users in a group using the REST API? If not, what permission do I need?

I'm trying to use the REST API to list all users from a group and if I'm logged in as an administrator I can use this endpoint and it lists the info that I want:

/rest/api/2/group?groupname=my-group-name&expand=users

However if I try to use this endpoint as a user that only has the "Browse Users" permission I get an authorization error:

{"errorMessages":["You are not authorized to perform this action. Administrator privileges are required."],"errors":{}}

Based on the documentation it seems like that permission should be all that I need but I must be missing something:

Browse Users

Ability to select a user or group from a popup window as well as the ability to use the 'share' issues feature. Users with this permission will also be able to see names of all users and groups in the system.

 

My question is: Should I be using a different endpoint to list this information? Is the only way to list this info giving administrator access to the rest API user ? Any other ideas I can try?

 

Thanks in advanced,

Abe

4 answers

1 accepted

This widget could not be displayed.
Stephen Deutsch Community Champion May 21, 2015

I'm not sure if there are any other options, but in the documentation, that function is listed as requiring admin privileges:

https://developer.atlassian.com/static/connect/docs/latest/scopes/jira-rest-scopes.html#restapiversiongroup

This widget could not be displayed.

Hi Abe,

Actually, that error message is correct. Viewing all the users that are members of a given group is an administrative task, so only users with administrative permissions can perform this action.

I hope this helps.

Cheers,

Clarissa.

This widget could not be displayed.

Thanks guys. 

This widget could not be displayed.

You are probably looking for https://docs.atlassian.com/jira/REST/latest/#d2e160 :

/rest/api/2/groupuserpicker

Returns a list of users and groups matching query with highlighting.

Hi Matheus, thanks for your help. Unfortunately that endpoint is not what I'm looking for unless I'm not understanding how to use it well. What I need to do is to be able to retrieve all the users from a particular group. The endpoint that you suggested seems useful to find all the users or a group that match a specified query. Did I miss something?

Sorry, what I wanted to say is that that is (one of) the API that checks the Browse User permission: "Ability to select a user or group from a popup window as well as the ability to use the 'share' issues feature." That is the API to select a user or group :)

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted yesterday in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

28 views 0 1
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you