Hi, I would like to create a rule, in order to when I create a ticket of any issuetype, and the parent of that ticket is a specific Epic, I want to add to the ticket a specific label.
How can I do that?
Hello @Sara Chaves
Have you tried to create this Automation Rule? If so, please show us what you have so far.
Do you have any experience with creating Automation Rules? If you have little or no experience with this feature I encourage you to take advantage of the free, on-demand training available from Atlassian University, You can find topics with this search:
https://university.atlassian.com/student/catalog/list?search=jira+automation
The documentation for Automation Rules is here:
https://support.atlassian.com/cloud-automation/docs/jira-cloud-automation/
The basic structure of your rule would be:
TRIGGER: Issue Created
CONDITION: Related issues condition
Related issues: Parent
Condition: Matches specified JQL
Matching JQL: key = insert issue key for the Epic
ACTION: Edit issue
Select the Labels field
specify the Label value to add
I yes I have already been creating automation rules, and I followed that basic strutucture.
My problem here is that is what is the issueKey for that specific epic?
I tried with Epic Name = Epic Name but it didn't work.
Here is what I did:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The issue key for any issue is the ABC-123 identifier for that issue.
Below the JQL field in the Related Issues Condition there is a Validate query feature. If you click that do you get any results for your current JQL?
If you change the JQL do to what I suggested do you get any results from the Validate feature?
With your rule as it currently is, what information is written to the rule execution Audit Log when the rule executes?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You're welcome!
If my response helped you solve your requirement please consider clicking on the Accept Answer button to mark your Question as Solved.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Also another question, is it possible in the same rule, say that I want to apply this to any issue created and to the issues that already exist in the epic?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The rule is currently triggered by Issue Created, so it will run for each newly created issue.
You could also, within this rule, review all the issues under the same parent Epic to make sure they have the Label if it should be there. To do that you would add a For Each: Related Issues: JQL step. Use that step to find and iterate over all the issues that have the same Parent as the trigger issue.
If you wanted to evaluate all the existing child issues for a set of existing Epics then you could use a rule that uses a Scheduled trigger and use a JQL in that trigger to lookup all the issues in a specified set of Epics:
parent in (ABC-123, ABC-456, ABC-789)
Then use the same condition and action used in your existing rule to update the child issues found.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Show up and give back by attending an Atlassian Community Event: we’ll donate $10 for every event attendee in March!
Join an Atlassian Community Event!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.