Is it possible to run a custom script when a status change occurs?

Ian Keller October 2, 2019

I have written a custom script that will take the URL from a JIRA issue, run a lighthouse test and based on the scores send it back or let it move forward. I want to automate this process so that when a developer changes the issue status from "In Development" to "QA Ready", my custom script can run. Is this possible? 

1 answer

0 votes
Nic Brough -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.
October 2, 2019

What is the "custom script" and how are you trying to inject it into the process?

Ian Keller October 3, 2019

The custom script is one to run a lighthouse analysis on a website. The script itself works when I use the Rest API to pull information from a Jira ticket manually, but I want to figure out how to inject it into the process so that it runs each time a certain status change occurs. 

Nic Brough -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.
October 15, 2019

Ok, I get "lighthouse analysis", but there's nothing on how the script runs, what triggers it, or what it updates outside Jira.

However, at a guess, I'd say you want "stuff that script does runs as part of a transition in Jira"?  There's a range of things you could do here. 

If your script is working perfectly, then, as an engineer (we believe in what works in real life, not on paper or in ivory towers), the most simple thing to do is create a post-function that says "run script on an OS level (probably with parameters from Jira?)"

The other end of the scale would be to write a plugin (or get a plugin that enables scripting) and move your code into Jira.  It'll run faster than an external call and it will be easier to deal with errors, but you'll need to spend some time to do it.

Suggest an answer

Log in or Sign up to answer