Automation to link tickets to a new epic on a schedule.

AB March 26, 2024

I have a scenario where tickets are created from another external source and we would like to create an automation to run on a weekly basis that will create a new epic and then for all tickets that meet a JQL query set the parent field to the newly created epic. I have tried some other options on the community but most assume that the stories/task tickets are not yet created where in our case they are already created. Any help would be appreciated. Stuck at the moment.

 

Requirements:

Should run weekly based on a JQL query

  1. If Tickets meet the criteria within the last 7 days
  2. Create epic
  3. Set parent field of all tickets that match step 1 as epic key from step 2

What I have so far...

When this runs it creates an epic for every ticket that matches the JQL query and does not link stories to an epic.

Screenshot 2024-03-26 at 10.38.09 AM.png

1 answer

0 votes
Ste Wright
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 30, 2024

Hi @AB 

This rule should work...

  • Trigger: Scheduled
    • Run rule every = 1 Weeks
  • Action: Create Issue
    • Project = Project A
    • Issue Type = Epic
    • Summary = <summary here>
  • Branch: Related Issues
    • Type = JQL
    • JQL = <JQL to find child issues here>
      • Branch-Action: Edit Issue
        • Field = Parent
          • Value = {{createdissue.key}}

Let us know if it works for you :)

Ste

AB April 1, 2024

Thanks Stephen, This works, but how would you set a condition to only create the epic if new tickets are found in the last 7 days? Each time we add the JQL into the trigger it creates a new epic for each ticket found in the JQL query.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events