The trigger action "send-email" sends a custom email to one or more specified recipients. action (send-email) recipients (array) ❗️Recipients to send the email to (at least one recipient value must be added). A comma separated list of one or more recipients or Confluence groups is added using: one or more Atlassian userID s one or more user type workflow parameter references one or more Atlassian groupID s one or more Atlassian groupName s one or more group type workflow parameter references one or more Email addresses One or more of the following value references can also be added as a value for the "send-email" action "recipients"
notification (object) ❗️ Notification holder. Can include the following as a comma-separated list within curly brackets: the email "subject" "title"
"body"
emailContext (object) Email context object: ${content.title} | ${content.link} | ${content.space}
❗️Mandatory parameters - at least one value for "recipients" must be specified and the "notification" holder must include at least one of "subject", "title", or "body" Code Block |
---|
"triggers":
[
{"event": "on-change-state",
"conditions":
[
{"state": "Review"}
],
"actions":
[
{"action": "send-email",
"recipients":
[
"@creator",
"@watchers",
"@lastUpdatedBy",
"@document_user_reviewers@",
"@document_group_reviewers@"
],
"notification": {"subject": "${content.title} is In Review State",
"title": "${content.title} is In Review State",
"body": "Hello, ${content.link} in the ${content.space} space is in approval state and needs to be reviewed"}}
]}
] |
If adding the JSON trigger using workflow builder there is no need to include the opening "triggers": JSON markup notation, since it will be added by workflow builder. On-screen notification messages can be created using the "set-message" trigger action. Workflow trigger-generated email 'failure to send' errors are included in the Confluence log. |