Is there any way to copy users from one role to another

Gaurav Arora December 5, 2019

Hi All,

Can anyone help me out with a way to copy all the users from one role to another for all the Jira Projects?

I have created a new role and want to copy all the users from an already created role to this one. This is required for all the Projects in our instance.

Currently, there are 250+ projects and that's why I needed a way of automation doing it.

If any more information needed, kindly let me know.

BR,

Gaurav

1 answer

0 votes
Amith Mathur _Appfire_
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.
December 5, 2019

Hi @Gaurav Arora , 

You can use one of our app to do this, JIRA CLI

You can add users to different roles in different projects. One of the CLI actions to do this is 

--action addProjectRole

Please review more on this page 

Thanks,
Amith Mathur

Gaurav Arora December 6, 2019

Hello Amith,

Thanks for the reply.

I am checking this plugin currently as a trial version.

Could you please be more generous and share an example to copy the users to the new role.

I am new to using this plugin and this is a priority requirement for us. I would very much appreciate it if you could help us out here.

Thanks,

Gaurav

Amith Mathur _Appfire_
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.
December 26, 2019

Hi @Gaurav Arora , 

Sorry about the delay. Somehow, I missed it. 

You can use the action, addProjectRole, to add the users to new role. If you want to get the list then you can use the other action, getProjectRoleList. 

All the actions are listed in this examples page

We also have some more how to articles on this page

Let me know if you are still facing the issue. 

Thanks,
Amith Mathur

Gaurav Arora December 26, 2019

Hi @Amith Mathur _Appfire_ ,

No worries.

I have written a python script for this now using the APIs to set the project role users.

 

BR,

Gaurav Arora

Suggest an answer

Log in or Sign up to answer