Auto transition of issue based on JQL Condition by script runner

Pooja February 19, 2020

Hi Team,

We are using jira service desk cloud, and integrated with script runner for jira.

We have a field name Contract expire(date picker), 

and JQL Query like : project =xyz and and contract expired =now 

If this JQL query stratifies the issue has to auto transition to next status

Is there any way we can achieve in script runner for jira.

 

Regards,

Pooja

1 answer

0 votes
Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 20, 2020

Hi Pooja,

Thank you for your question.

I can confirm that ScriptRunner for Jira Cloud does not provide any polling functionality to automatically check when an issue field is updated via a JQL query and then to perform an action on it such as transitioning the issue.

However, I can confirm that it does have the Escalation Service feature as documented here which allows you to specify a JQL query which is run at a set period such as every hour and then perform an action on all issues returned such as to transition them. 

I can confirm we have an example of transitioning issues returned by an escalation service inside of the documentation page located here that you may find a useful reference to achieve your requirement.

Alternatively you could use a Script Listener which runs on the issue updated event and has some code to check if the condition is met on the issue and if it is then to make a rest call to transition the issue which will be similar to the rest call shown in the escalation service example linked above.

I hope this information helps.

Regards,

Kristian

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events