On this page

Use case

Send automatically an email to the selected users when a field is updated with the updated information of the field in the body of the email.


Configuration

Create a new rule and name it appropriately.

Providing a description will help you to identify what the rule does.

Issue event


Add a trigger → Issue event → Issue Updated

No further configuration is needed. The automation rule is triggered every time that an issue is updated.

Boolean condition


Add a ConditionBoolean Condition 

Expression

Use the following Parser Expression:

lastFieldChangeTime(%{trigger.issue.description})+ 3*{SECOND}>=({system.currentDateTime})

Replace the field code for the issue description with the field code for the field of your choice.

Send email action


Next to the Boolean condition click on Add → Action → Send email

From

Select the user that the email will be sent from.

To

Select the recipients.

Message

First, enter a subject for the email.

The description of %{trigger.issue.key} has been updated.

Then, enter the body of the email in HTML format and set the parsing mode to Mixed.

<p>Updated description: </p>
{{{wikiToHTML(%{issue.description})}}}

Create as many Boolean conditions and Send email actions as necessary following the same pattern for other required fields.

Import the example

Import the JSON file below to get started in no time.

JSON

After importing the JSON file, make sure to check the configuration of the rule. Non-existing configuration elements (issue types, fields, values etc.) will be highlighted.

{
    "name": "Send email when a field is updated",
    "description": "Send automatically an email to the selected users when a field is updated with the updated information of the field.",
    "creator": "admin",
    "status": false,
    "triggerData": "2",
    "triggerType": "ISSUE_EVENT",
    "configuration": {
        "refs": [
            "issue",
            "system",
            "trigger.issue",
            "trigger.parent"
        ],
        "triggerType": "2"
    },
    "children": [
        {
            "sequence": 0,
            "type": "BOOLEAN_CONDITION",
            "ruleEntityType": "CONDITION",
            "configuration": {
                "refs": [
                    "issue",
                    "project",
                    "system",
                    "trigger",
                    "trigger.issue",
                    "trigger.parent"
                ],
                "expression": "lastFieldChangeTime(%{trigger.issue.summary})+ 3*{SECOND}>=({system.currentDateTime})",
                "expressionParsingMode": "logical",
                "actingUser": "field_00020"
            },
            "children": [
                {
                    "sequence": 0,
                    "type": "SEND_MAIL",
                    "ruleEntityType": "ACTION",
                    "configuration": {
                        "refs": [
                            "issue",
                            "project",
                            "system",
                            "trigger",
                            "trigger.issue",
                            "trigger.parent"
                        ],
                        "fromOption": "default",
                        "toUsersInField": [
                            "00003"
                        ],
                        "subject": "The summary of %{trigger.issue.key} has been updated.",
                        "subjectParsingMode": "textBasic",
                        "contentType": "text/html",
                        "mailPriority": "3",
                        "sendingMode": "common",
                        "body": "Updated description: %{trigger.issue.summary}",
                        "bodyParsingMode": "mixed"
                    },
                    "children": null,
                    "hasChildren": false
                }
            ],
            "hasChildren": true
        },
        {
            "sequence": 1,
            "type": "BOOLEAN_CONDITION",
            "ruleEntityType": "CONDITION",
            "configuration": {
                "refs": [
                    "issue",
                    "project",
                    "system",
                    "trigger",
                    "trigger.issue",
                    "trigger.parent"
                ],
                "expression": "lastFieldChangeTime(%{trigger.issue.description})+ 3*{SECOND}>=({system.currentDateTime})",
                "expressionParsingMode": "logical",
                "actingUser": "field_00020"
            },
            "children": [
                {
                    "sequence": 0,
                    "type": "SEND_MAIL",
                    "ruleEntityType": "ACTION",
                    "configuration": {
                        "refs": [
                            "issue",
                            "project",
                            "system",
                            "trigger",
                            "trigger.issue",
                            "trigger.parent"
                        ],
                        "fromOption": "default",
                        "toUsersInField": [
                            "00003"
                        ],
                        "subject": "The description of %{trigger.issue.key} has been updated.",
                        "subjectParsingMode": "textBasic",
                        "contentType": "text/html",
                        "mailPriority": "3",
                        "sendingMode": "common",
                        "body": "Updated summary: \r\n\r\n{{{wikiToHTML(%{trigger.issue.description})}}}\r\n\r\n",
                        "bodyParsingMode": "mixed"
                    },
                    "children": null,
                    "hasChildren": false
                }
            ],
            "hasChildren": true
        }
    ],
    "hasChildren": true
}

If you still have questions, feel free to refer to our support team.