Send Automatic Emails to New Lead Contacts
When entering net new leads, salespeople can add brand new contacts who don't yet exist in the application. These new contacts don't become "official" contacts until after leads are converted to opportunities.
This means that, when activities are created for net new leads, the associated new contacts won't receive automatic email notifications. You can, however, set up automatic email notification so that new contacts are kept informed of important activities on the lead, such as new appointments.
Setting up automatic email notifications involves a few configuration steps on the Activity object:
-
Create an email template.
-
Create two custom fields.
-
Create an object workflow.
Let's look at these steps in detail.
Create the Email Template
Outside an active sandbox, create an email template on the Activity object.
-
In Application Composer, navigate Common Setup > Email Templates.
-
Click the Create icon.
-
Select the Activity object.
-
Enter a template name and then enter the template details, such as the email subject and body, for the desired notification.
-
Click Save and Close.
Create Custom Fields
Next, create two custom fields on the Activity object. One field captures the new contact's email address. The other field captures the type of Leads UI that the customer is using.
-
Enter a sandbox and, in Application Composer, navigate Standard Objects > Activity > Fields.
-
Click the Create a custom field icon.
-
Select the Formula option, then OK.
-
Create the email field on the Activity object:
Field Attribute
Value
Field type
Formula (text type)
Display name
Lead Contact Email
API name
LeadContactEmail_c
Script
return LeadVOVA?.PrimaryContactEmailAddress;
Include in Service Payload check box
Selected
-
Create the UI indicator field on the Activity object. You create the field to check the type of Leads UI that the customer is using.
Field Attribute
Value
Field type
Formula (text type)
Display name
Lead Simplified Indicator
API name
LeadSimplifiedIndicator_c
Script
return LeadVOVA?.SimplifiedLeadIndicator;
Include in Service Payload check box
Selected
Create the Object Workflow
Now that you've created the email template and custom fields on the Activity object, create an object workflow to send automatic email notifications to new lead contacts.
-
Still inside your sandbox, in Application Composer, navigate Common Setup > Object Workflows.
-
Click Actions > Create.
-
Select the Activity object and enter the object workflow name.
-
Enter the condition that must be true before the object workflow executes:
if (LeadContactEmail_c != null && LeadSimplifiedIndicator_c == 'Y' ) { return true; } else { return false; }
-
In the Actions region, click Create next to Email Notification.
-
Enter the email notification name and details, including the email template that you previously created.
-
Click Save > Save and Close.
When a new activity is created on a lead, an automatic email notification will be sent if the lead was created in the simplified UI with a brand new contact.