Requested Participant Automation Help

Hey there!

I’ve been trying to tackle an automation that runs if checks on several custom fields. All are user picker fields and/or multi-user pickers. Trigger is work item created.

If the field is not empty, then action to edit work item fields and adds value from custom field to current work item.

It runs this rule against 5 custom fields at the moment and it is successful, however, even though I check the box “Add to existing values” it behaves like “SET” where it removes the participants already present.

I’ve reworked this a few different ways, separated all the if conditions and then actions (exact same behavior happens) as well as trying to make an array variable and using advanced options with json.

Is this a bug by chance? Thanks for any assistance!

So I broke it down into if-branches and discovered that the fields themselves work so long as it is a single user selected in the multi-user fields.

The moment, it goes from a single into a list for users to add as participants, the json can’t seem to react. Some of the things I’ve been given that could work result in a full error as an invalid JSON.

12001 is the Request Participants field and 14576 is the mutli-user picker field that will not work if more than 1 are entered following the error attached.

This advanced action in theory could work but isn’t valid.

{
"customfield_12001": [
{{#issue.customfield_14576}}
{ "add": { "accountId": "{{accountId}}" } }
{{#unless @last}},{{/unless}}
{{/issue.customfield_14576}}
]
}

Ended up making 2 separate rules, one for single user fields and one for multi user fields. Since the JSON are different to address both types and the arrays all failed to work properly, adding a 10 second delay on one rule this is now working exactly as planned. Just was hoping to achieve this in one rule.