Addon without "Browse users and groups" permission can't request users by email thorugh API

Oswaldo Diaz April 12, 2018

We created an add-on and it's working correctly for most endpoints using JWT, but for our integration we need to look for user information on Jira by their emails. For that, we're doing this API call:

https://ourdomain.atlassian.net/rest/api/2/user/search?username=oswaldo.diaz@ourdomain.com

This call is returning an empty array if the add-on user is not in a group with Browse users and groups permission.

In the API Cloud documentation it says that the user only needs READ permission to make this call and we specify that in our atlassian-connect.json but it doesn't work until we add manually these permission.

There's any programmatic way to set these permissions when installing the add-on? We want to reduce the number of steps the user needs to do to make our add-on works

0 answers

Suggest an answer

Log in or Sign up to answer