Forums

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

Need to convert my script from Datacenter to cloud

Balaji Shriram Murkute
Contributor
February 8, 2023

Hi team , 

 

I have one requirements to convert my script from Datacenter to cloud So could you please anyone help me for the correct path to convert my script .

Fast-track transition an issue.

isUserMemberOfRole('Abc')||isUserMemberOfRole('Pqr')

regards,

Balaji

1 answer

1 vote
Blue Ridge Consultants
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.
February 9, 2023

It seems like this is a ScriptRunner script. You'll want to use this Jira Cloud API to return users for specific roles, then test if the user performing the transition is among the returned results.

https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-project-roles/#api-rest-api-3-project-projectidorkey-roledetails-get

Then you'll need to transition the issue with this:

https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issues/#api-rest-api-3-issue-issueidorkey-transitions-post

 

I recommend using this for examples:

https://library.adaptavist.com/

Further reading:

https://docs.adaptavist.com/sr4jc/latest/differences-between-scriptrunner-for-jira-server-and-jira-cloud

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events