Create an Email Template for Notify Tasks

If you have an email template, you can manually enter the HTML markup directly into the code editor provided in the Create an Email Template pane and modify the markup as per requirements.

To reference data objects in the email template, you can use any of the following code formats:

  • Reference using an object:

    Format

    {{#payload}}{{#DOName}}{{AttributeName}}{{/DOName}}{{/payload}}

    Object:

    <div class="container">
     <div class="label">Hello {{#payload}}{{#DOName}}{{firstName}}{{/DOName}}{{/payload}} {{#payload}}{{#DOName}}{{lastName}}{{/DOName}}{{/payload}}
     </div>
    </div>
  • Reference using an array loop:

    The following sample code shows the employee name, age and experience details defined as elements at the second level.

    {{#payload}}{{#secondLevelListDO}}{{#secondLevelList}}{{#employee}}
    <li>Employee Name:{{empName}}<br>Employee experience: {{empExp}}<br>Employee age:{{empAge}}</li>
    {{/employee}}{{/secondLevelList}}{{/secondLevelListDO}}{{/payload}}

    Here is an example:


    Array loop for human task email notification

  • Directly referencing the data object (Deprecated from April 2025):

    Format

    ${DOName.prop('AttributeName')}

    For example:

    ${loanApplicationDataObject.prop('loanAmount')}

Note:

Email templates for notify tasks do not support:

  • Referencing process variables that are not part of a data object.

    Note:

    To use values from process or task variables that are not predefined, associate the variable values with a user defined data object before referencing.
  • Predefined variables
  • Array data in data objects