Hi all, I'm trying to create the following automation rule:
When a team is assigned to an Epic, assign the team to all issues under that epic as well.
Is this possible to do? I tried the following (and many variations), but I keep getting the same error of "Error while parsing additional fields. Not valid JSON."
{
"fields": {
"Team": {{issue.parent.Team.asJsonObject("id")}}
}
}
Any help would be greatly appreciated!
Thanks in advance,
Joe
Hello @Joe Zulli
What do you expect to get when you us asJsonObject? Are you expecting to get the value of the "id" attribute for the Team field? I don't think that is how the function works per the documentation.
I think the output of the asJsonObject field would instead by
{"id" : "some value"}
You might be able to use this instead:
{{issue.parent.Team.value.asJsonString}}
You might also want to use the Log action to print to the rule audit log the output of {{issue.parent.Team}}, {{issue.parent.Team.value}}, and other smart values you are trying to use.
This article shows the proper syntax for setting the AR Team field in an issue:
It looks like you may also have to reference the Team field by its custom field identifier rather than by name.
Disclaimer: I have not actually tested any of this out. I know there are multiple posts in the communities about using Automation to set the AR Team field. You might want to try an internet search for "jira cloud automation set team field" to find those and see if they offer relevant advice.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.