Hello dear Community,
Can you please help me with the following question?
How do I enable the execution of multiple actions in a single automation? I would like to send Slack messages to approvers and would like to avoid having to create a separate automation for every approver.
So my idea was to create an automation, check the approver in already filtered tickets (the ones with the status "Waiting for approval") and go through these in a chain so to say:
The problem here is that the first one gets executed and then the automation ends. I would like that all the comparisons are done.
Can you please enlighten me how this could be done?
Thank you in advance!
Depending on how the rule is configured and what your log shows, this may not be the entire problem, but the way you have the components set up in that screenshot, it will only ever send the first message, or none.
If everything is on the main trunk of the rule, then as you go down the line, it will check the issue against each condition. If a condition passes, the automation keeps going, but as soon as a condition fails, it stops, and nothing after the failed condition will run.
Assuming you're checking different names in each condition, if the name on the issue matches the name in the condition, it will run the action (send the slack message) and move on to check the next condition. But if the name matched the first condition, it will fail the next condition, which then kills the automation.
The simplest solution for your use case would be to use an If / else block:
This way even if a condition fails, the automation will keep going and evaluate the remaining conditions. You can use most of the other conditions within an If / else block, which makes it pretty versatile, and useful for more complex automation rules.
Most of the time an If / else block is going to be the best choice, but if you need to check multiple unrelated conditions that don't fit well into an If / else block, like if you need more than one of the blocks to pass and perform the actions, you can use branches:
You'd want to use Branch rule / related issues on the current issue. You can use multiple branches to run parts of the automation that should not interrupt the main process even if a condition fails.
Dear Cat W,
Thank you for your help! The branching was the solution for my requirements.
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.