Send Email Flow Item
The Email Flow Item within No Code Flows offers an automated solution for sending emails, seamlessly integrating email communication into various processes without manual intervention. Its purpose is to facilitate customized notifications based on specific conditions within workflows. For instance, in the scenario of an employee leaving a particular location, the regional administrator should receive a notification, whereas in other cases, the global administrator should be notified. This send email flow item allows users to tailor email notifications to suit unique requirements by configuring the flow item to match specific conditions.
The Email Flow Item can be personalized by providing the necessary parameters for workflow fulfillment in JSON. This JSON configuration allows users to customize email templates, specify recipient addresses, and set conditions for email delivery. In this article, we will explore creating email templates, configuring the flow item, and defining the fulfillment workflows required for sending emails using the send email flow item.
This doc is designed to help you create a Send Email Flow Item. However, it's important to note that this doc assumes that you are familiar with flow items and their definitions. Therefore, descriptions of inputs are not provided, and the steps and instructions given here are specific to the context of creating a Send Email Flow Item. For more detailed information, please refer to the following pages:
Additionally, since the send email flow sends an email, you must have knowledge about creating an email template in EmpowerID. Please click on the link below to find detailed information about the Email Templates
Step 1: Create an Email Template
To send an email using the send email flow, you need to create an email template in EmpowerID. If you have already created a template, please ensure it has the necessary supported objects for the fulfillment workflows described in this section.
This section covers the parameters and information needed in the body of an email template with a send email flow item. For detailed instructions on creating an email template, please follow this link Localizing Emails .
On the navbar, expand Admin, then Miscellaneous, and click Localized Emails.
Click the Add button above the grid to add a new template.
In the Email Template Details page that appears, Provide the Name, Display Name, Description, Email Body, and Email Subject fields. You can include specific objects and their properties in the Email Body and use specific object properties as email wildcards. To learn more about passing objects and using them in the email body, refer to the section Supported Email Parameters. Additionally, a sample email body is provided in the same section.
Once you've created the template, the next step would involve creating a send email flow item. But before proceeding, ensure that the email body is correctly structured and includes all necessary parameters as wildcards.
Supported Email Parameters
When you create an email template for a Send Email Flow Item, you have the option to use specific object parameters and convert them into wildcards. These objects are predefined, and their respective properties will be populated by the fulfillment workflows after you pass the objects. For instance, once you pass the TargetPerson Object, you can use {TargetPerson.FirstName} to insert the first name of the target person in the email template. The workflow for this flow item supports only certain objects listed below.
Parameters | Description | Example |
---|---|---|
TargetPerson
| This parameter refers to the Target Person object when the event is targeting a person. | {TargetPerson.FirstName} |
TargetAccount | This parameter refers to the TargetAccount object when the event is targeting an account. | {TargetAccount.EmployeeType} |
TargetPersonManager | This parameter refers to the manager of the target person. | {TargetPersonManager.FirstName} |
TargetAccountManager | This parameter refers to the manager of the target account. | {TargetAccountManager.FirstName} |
TargetBusinessRequest | This parameter refers to the specific business request or task object associated with the No Code Flow. | {TargetBusinessRequest.Friendlyname} |
TargetBusinessRequestItem | This parameter refers to the specific business request item object within the business request task associated with the No Code Flow. | {TargetBusinessRequestItem.FriendlyName} |
Email Template Samples
Below is an email template that makes use of the TargetAccount object, which is created for the onboarding person. As seen in the template, it is possible to use the properties like {TargetAccount.FriendlyName} and {TargetAccount.ExpectedHireDate} to customize the email content. Additionally, it is also possible to use custom attributes of the objects in the template.
Dear {TargetAccount.FriendlyName},
I hope this email finds you well. Please find your onboarding details.
Onboarding Details:
Employee Type: {TargetAccount.EmployeeType}
Hire Date: {TargetAccount.ExpectedHireDate}
Full Name: {TargetAccount.FriendlyName}
Preferred First Name: {TargetAccount.PreferredFirstName}
Email: {TargetAccount.Email}
Office Location: {TargetAccount.OfficeLocation}
Department: {TargetAccount.Department}
Country: {TargetAccount.Country}
SNID: {TargetAccount.CustomAttribute10}
Your assigned email address, {TargetAccount.Email}, has been set up and activated.
Step 2: Create Send Email Flow Item
On the navbar, expand Low Code and click No Code Workflows.
To create a flow item, click on the Flow Items tab and click the Add icon.
Fill in the necessary details for the new flow item, including a name and any other relevant information. Make sure to select the Item Type Action, which has an item type and fulfillment workflow specifically designed for sending emails. Once all details are entered, click the Save button to create the flow item. Below is the section Supported Fulfillment Workflows that provides information about the fulfillment workflows supporting email sending for this flow item.
After creating the flow item, the next step is to add it to a flow definition. Follow the instructions below to proceed.
Step 3: Create Flow Definition & Add Flow Item
Click on the Flow Definitions tab and click the Add icon to proceed with creating a flow definition.
Provide the required information and Click Save to save the flow definition.
To access the View One page, click on the link to the newly created flow definition.
Find the Flow Items and Sequence tab and click on the add icon to add a new flow item to the sequence. “
To configure the send email flow item, you need to provide the necessary values and click on Save. The most important input is the Fulfillment WF JSON, which contains parameters that customize the behavior of how the email will be sent. For it to work correctly, your parameters should consist of supported parameters or objects that the Supported Fulfillment Workflows support.
After saving the flow definition, it will appear in the list of flow items and sequences.
If you have followed all the steps in the walkthroughs provided for this section, you have successfully set up a Send Email Flow Item. When the No Code Flow is executed, the flow item will send an email according to the parameters you have configured. Please refer to the section below for supported parameters that you can use in the JSON.
Supported Fulfillment Workflows
The fulfillment workflows related to the 'send email' flow item should be able to send emails and handle related parameters to ensure that the recipient receives the email as intended. The following fulfillment workflows work seamlessly with the send email flow item process.
FWSendEmail: The FWSendEmail fulfillment workflow is designed to send emails to a Target Person. It also supports sending emails to management role members.
In this workflow, the Business Request's target is the object being targeted in the no-code flow event. This same object is also used in the email template. For instance, in a leaver event targeting a person, the email template can utilize the 'TargetPerson' property. Additionally, the Business Request item's target resource represents the object we send an email to. For instance, when sending an email to a leaver's manager, we would use the Item Scope as 'Person's manager.'
FWSendEmailToDistributionList: The FWSendEmailToDistributionList fulfillment workflow is designed to send messages to a distribution list. However, it can also send emails to management role members. The business request item’s target resource contains the object we want to display in the email template, for instance, ‘TargetPerson.’
While both are similar, certain parameters are different in the workflows; please refer to the section below for parameters.
Workflows Parameters
The fulfillment workflow supports various workflow parameters. These parameters enable you to customize your emails by specifying the recipients and the email template to be used.
Parameter | Description | Optional Parameter? | Supporting Workflows |
---|---|---|---|
EmailTemplateName | Specifies the name of the email template to be used to send the email. Ensure that you have created the template as described in the #step1 and configured all necessary parameters within it. | No | FWSendEmail, FWSendEmailToDistributionList |
EmailAddressToNotify | Specifies the email address to which the notification email will be sent. This parameter can be used with ManagementRoleIDToNotify. If both are provided, all members in the management role and the specified recipient will receive the email. | Yes | FWSendEmailToDistributionList |
DoNotSendEmailToTargetPerson | When set to true, the email will not be sent to the target person (i.e. Business Request's target resource id) for whom the workflow is executed. For instance, if the workflow is executed for a leaver , setting this parameter to true will prevent the email from being sent to that leaver. This optional parameter is typically set to true when we want to send the email to management role members instead of the target person by specifying the ManagementRoleIDToNotify parameter. | Yes | FWSendEmail |
ManagementRoleIDToNotify | Specify the GUID of a management role to send the email. The email will be sent to all members within the management role. | Yes | FWSendEmail, FWSendEmailToDistributionList |
Fulfillment WF JSON Samples
The most basic fulfillment WF JSON sample would only include the email template name, as all other parameters are optional. Please make sure to replace the parameter values with valid ones.
{
"EmailTemplateName": "MyEmailTemplateName"
}
Below is an example of a JSON with multiple parameters. In this example, the ManagementRoleIDToNotify parameter is specified, and the DoNotSendEmailToTargetPerson parameter is set to false. This means that the email will be sent to all persons specified by the GUID of the management role. Please make sure to replace the parameter values with valid ones.
{
"EmailTemplateName": "Test_Joiner_WelcomeEmail",
"DoNotSendEmailToTargetPerson": "false",
"ManagementRoleIDToNotify": "064f430e-49e5-4568-94ad-7aecd702bd79"
}
IN THIS ARTICLE