How to create Jira Automation rule for - Send email when all stories for an epic are done

Justin Princehorn February 23, 2022

Hi, I have a jira project that has only epic issues and then a second project that has only user story issues. The user stories are linked to the epics from the other project.

I'd like to write a jira automation rule so that anytime a user story is marked Done, I want a rule to trigger that essentially does the following:

1. Checks if all other stories in that same epic as the triggering story issue are already marked Done

2. IF True, then send an email.

So far I've tried using the following steps:

1. Trigger - when a issue transitions to Done

2. Condition - Check for related issues using jql "epic link" = {issue.parent.epiclink} and the condition for those all matching this specified jql  status = Done

However, the epic link jql noted above is not acceptable syntax and can't figure out how to write it.

3. Action - if condition true, send email

Please help!

Thank you,

Justin

1 answer

1 accepted

1 vote
Answer accepted
Mikael Sandberg
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 23, 2022

Hi @Justin Princehorn,

Welcome to Atlassian Community! 

You could use the "When all stories are completed → then close epic" automation in the Library as your start

Screen Shot 2022-02-23 at 10.23.59 AM.png

Instead of the transition at the end, replace that one with the Send email action.

Justin Princehorn February 23, 2022

Hi Mikael, 

I tried that but no actions are performed when the rule triggers.

see snapshot 

Any suggestions?

 

3F377B66-AA79-4535-9C31-AD6AF7B2F30C.jpeg

Mikael Sandberg
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 23, 2022

I missed that you are dealing with two different projects. In this case you have to configure the automation to be under the Global administration, then from the Rule details you can change the automation to be for multiple projects.

Justin Princehorn February 23, 2022

Thank you! I will need to work with the jira admin I think to try this out. I’ll let you know if that does the trick.

Like Mikael Sandberg likes this
Justin Princehorn February 24, 2022

Great news! It worked after those edits.

 

I really appreciate the assist on this.

 

thanks!

Like Mikael Sandberg likes this
Justin Princehorn March 1, 2022

Hi, I’m building more in the body email of the alert.

I’m trying display a bulleted list of all the child issues under the epic in play with this automation rule.

I’m trying to do this with using the LookupIssues function.

see pic below on how I place it in the email body.

I read that you have to define what is LookupIssues… so my attempt is shown in 2nd pic below. But instead of specifying “LPL-98” epic , I want to make that part a smart value and be dynamic. Basically I’m struggling to write successful JQL for this LookupIssues Jira rule action.

 

any help is super appreciated!

 

653A4945-73E6-4F44-9F1D-8F1D487742AD.jpegC1C52CBB-8651-457C-84A5-36F2118FAA72.jpeg

Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 1, 2022

You should be able to use {{issue.key}} in your lookup query, since you at that point is on the epic level, not the triggering issue.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events