I need to take an export of JIRA users from a particular project . How can I do it? It should be an export of all users in that JIRA project with their respective roles. Kindly advise.
Hi @Priyanka and welcome to the community!
I would suggest a solution like below:
Fetch all the available roles for a project using the GET /rest/api/3/project/{projectIdOrKey}/role . Then for each of the project roles that will be fetched in the previous request, call the below request to get the list of users
GET /rest/api/3/project/{projectIdOrKey}/role/{id}
Let me know if that helps!
Alex
There's a pretty solid REST interface for getting role members https://docs.atlassian.com/software/jira/docs/api/REST/8.22.3/#project-getProject
When you open the example response, in the json, it contains "roles" - and this will contain a hyperlink to get users for each of your project roles. From there it's just about data collection.
So, what you can get out of box is users per role, but not quite the "roles for user". If you need specifically the latter, then that'd be an extra step to build it, based on the above data.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.