MadKudu Docs

Home

Sales team notifications using Salesforce

This article will help you use salesforce to send your sales team email notifications about important opportunities to engage with your leads.

Example:

What follows are step-by-step instructions on how to set up Salesforce so that it sends your SDR/BDM/Account Executives an email when an important signup to welcome, a trial ready to convert, or a customer ready for an upsell.

Setting up email notifications

Let’s start by creating email templates.

In Salesforce, go to “Setup”, then “Communication templates”, “Email templates” and click “New Template”.

Let’s pick “Custom” as the type of email template.

Now, let’s get fancy and write a nice and actionable email using merge fields.

Here are 3 templates you can re-use and adapt.

Email template 1: New qualified lead

The template below will create an email notification like this one:

Subject:

New qualified lead: {!Lead.Email}{!IF(Lead.mk_job_title__c!="", ", " + Lead.mk_job_title__c,"")}{!IF(Lead.mk_company_name__c != ""," at " + Lead.mk_company_name__c,"")}

Body (HTML version):

{!Lead.OwnerFirstName}, here is some information about this new lead!
<p>

<table border="0" style="margin-bottom: 25px;">
<tr>
    <td style="padding-right:20px">Company</td>
    <td><b>{!IF(Lead.Company != "", Lead.Company, Lead.mk_company_name__c)}</b></td>
</tr>
<tr>
    <td>Name</td>
    <td>{!IF(Lead.FirstName != "", Lead.FirstName + " ", "") + Lead.LastName}</td>
</tr>
<tr>
    <td>Title</td>
    <td>{!IF(Lead.Title != "", Lead.Title, Lead.mk_job_title__c)}</td>
</tr>
<tr>
    <td>LinkedIn</td>
    <td><a href="{!Lead.mk_linkedin_url__c}">See profile</a></td>
</tr>
<tr>
    <td>Email</td>
    <td><a href="mailto:{!Lead.Email}">{!Lead.Email}</a></td>
</tr>
<tr>
    <td>Phone</td>
    <td>{!Lead.Phone}</td>
</tr>
<tr>
    <td>Website</td>
    <td><a href="{!Lead.Website}">{!Lead.Website}</a></td>
</tr>
<tr>
    <td>Lead source</td>
    <td>{!Lead.LeadSource}</td>
</tr>
<tr>
    <td>Number of employees</td>
    <td>{!Lead.NumberOfEmployees}</td>
</tr>
<tr>
    <td>Industry</td>
    <td>{!Lead.Industry}</td>
</tr>
<tr>
    <td>Last Activity</td>
    <td>{!Lead.LastActivityDate}</td>
</tr>
</table>

<div><!--[if mso]>
  <v:rect xmlns:v="urn:schemas-microsoft-com:vml" xmlns:w="urn:schemas-microsoft-com:office:word" href="{!Lead.Link}" style="height:60px;v-text-anchor:middle;width:200px;" stroke="f" fillcolor="#2595FF">
    <w:anchorlock/>
    <center>
  <![endif]-->
      <a href="{!Lead.Link}"
style="background-color:#2595FF;color:#ffffff;display:inline-block;font-family:sans-serif;font-size:13px;font-weight:bold;line-height:60px;text-align:center;text-decoration:none;width:200px;-webkit-text-size-adjust:none;">Go to Salesforce lead profile</a>
  <!--[if mso]>
    </center>
  </v:rect>
<![endif]--></div>

Body (text version):

{!Lead.OwnerFirstName}, here is some information about this new lead!

Salesforce lead profile: {!Lead.Link}

Company: {!IF(Lead.Company != "", Lead.Company, Lead.mk_company_name__c)}
Name: {!IF(Lead.FirstName != "", Lead.FirstName + " ", "") + Lead.LastName}
Title: {!IF(Lead.Title != "", Lead.Title, Lead.mk_job_title__c)}
LinkedIn: {!Lead.mk_linkedin_url__c}
Email: {!Lead.Email}
Phone: {!Lead.Phone}
Website: {!Lead.Website}
Lead source: {!Lead.LeadSource}
Number of employees: {!Lead.NumberOfEmployees}
Industry: {!Lead.Industry}
Last Activity: {!Lead.LastActivityDate}

Email template 2: A lead is ready to buy

The template below will create an email notification like this one:

Subject:

Ready to buy: {!Lead.Email}{!IF(Lead.mk_job_title__c!="", ", " + Lead.mk_job_title__c,"")}{!IF(Lead.mk_company_name__c != ""," at " + Lead.mk_company_name__c,"")}

Body (HTML version):

{!Lead.OwnerFirstName}, this company has been identified as likely to buy based on their actions (product usage, number of active users, etc.). Might be a good time to check in!
<p>

<b>Lead info</b>
<table border="0" style="margin-bottom: 25px;">
<tr>
    <td style="padding-right:20px">Company</td>
    <td><b>{!IF(Lead.Company != "", Lead.Company, Lead.mk_company_name__c)}</b></td>
</tr>
<tr>
    <td>Name</td>
    <td>{!IF(Lead.FirstName != "", Lead.FirstName + " ", "") + Lead.LastName}</td>
</tr>
<tr>
    <td>Title</td>
    <td>{!IF(Lead.Title != "", Lead.Title, Lead.mk_job_title__c)}</td>
</tr>
<tr>
    <td>LinkedIn</td>
    <td><a href="{!Lead.mk_linkedin_url__c}">See profile</a></td>
</tr>
<tr>
    <td>Email</td>
    <td><a href="mailto:{!Lead.Email}">{!Lead.Email}</a></td>
</tr>
<tr>
    <td>Phone</td>
    <td>{!Lead.Phone}</td>
</tr>
<tr>
    <td>Website</td>
    <td><a href="{!Lead.Website}">{!Lead.Website}</a></td>
</tr>
<tr>
    <td>Number of employees</td>
    <td>{!Lead.NumberOfEmployees}</td>
</tr>
<tr>
    <td>Industry</td>
    <td>{!Lead.Industry}</td>
</tr>
<tr>
    <td>Last CRM Activity</td>
    <td>{!Lead.LastActivityDate}</td>
</tr>
</table>

<b>In-app behavior</b>

<table border="0" style="margin-bottom: 25px;">
<tr>
    <td style="padding-right:20px">Account: number of active app users</td>
    <td> $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
</tr>
<tr>
    <td>Lead: last login date</td>
    <td> $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
</tr>
<tr>
    <td>Lead: number of sessions in last 7 days</td>
    <td> $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
</tr>
<tr>
    <td>Lead: number of reports created in the app</td>
    <td> $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
</tr>
</table>

<div><!--[if mso]>
  <v:rect xmlns:v="urn:schemas-microsoft-com:vml" xmlns:w="urn:schemas-microsoft-com:office:word" href="{!Lead.Link}" style="height:60px;v-text-anchor:middle;width:200px;" stroke="f" fillcolor="#2595FF">
    <w:anchorlock/>
    <center>
  <![endif]-->
      <a href="{!Lead.Link}"
style="background-color:#2595FF;color:#ffffff;display:inline-block;font-family:sans-serif;font-size:13px;font-weight:bold;line-height:60px;text-align:center;text-decoration:none;width:200px;-webkit-text-size-adjust:none;">Go to Salesforce lead profile</a>
  <!--[if mso]>
    </center>
  </v:rect>
<![endif]--></div>

Body (text version):

{!Lead.OwnerFirstName}, here is some information about this new lead!

Salesforce lead profile: {!Lead.Link}

Lead info
====================
Company: {!IF(Lead.Company != "", Lead.Company, Lead.mk_company_name__c)}
Name: {!IF(Lead.FirstName != "", Lead.FirstName + " ", "") + Lead.LastName}
Title: {!IF(Lead.Title != "", Lead.Title, Lead.mk_job_title__c)}
LinkedIn: {!Lead.mk_linkedin_url__c}
Email: {!Lead.Email}
Phone: {!Lead.Phone}
Website: {!Lead.Website}
Number of employees: {!Lead.NumberOfEmployees}
Industry: {!Lead.Industry}
Last Activity: {!Lead.LastActivityDate}

In app behavior
====================
Account - number of active app users: $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
Lead - last login date: $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
Lead - number of sessions in last 7 days: $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>
Lead - number of reports created in the app: $REPLACE THIS WITH THE CORRESPONDING LEAD PROPERTY$ </td>

Now let’s create the workflow rules that will trigger those email notifications

In Salesforce, go to “Setup”, then “Create”, “Workflow and Approvals”, “Workflow Rules” and click “New Rule”.

Choose “Lead” as the Salesforce object to which the workflow rule applies (or it might be “Contact” depending on how your Salesforce lead management process).

Setup the proper workflow rules to trigger the emails we created earlier.

Here are some rule templates for the standard MadKudu use cases. Feel free to add some extra logic that could be specific to your business (eg. never trigger a “new qualified lead” notification if the lead is coming from a country you don’t do business with).

Rule template: New qualified lead

New qualified lead rule

Rule description:

Send an email notification to the lead owner when a new qualified lead is created.

Rule logic:

Important: don’t forget to implement the rule that says Lead: number of days since lead creation <= 2. This rules prevents Salesforce from sending email notifications for old qualified leads when you set those alerts up for the first time, or in the situation where the customer fit model changes and updates older leads. Don’t have a “number of days since lead creation field” or wondering how to create one? Please check the FAQ section for more information!

Rule template: Ready to buy

New qualified lead rule

Rule description:

Send an email notification to the lead owner when a new qualified lead is created.

Rule logic:

Last, create a workflow action to send email notifications

Click “Add Workflow Action”, then “New Email Alert”.

Choose the email template created earlier, select “account owner” as the selected recipient, and save.

Last step: don’t forget to click on “activate” to turn on this email notification.

You’re all set!

FAQ

How do I create a “Number of days since lead creation” field?

In Salesforce, go to “Setup”, “Build”, “Customize”, “Leads”, “Fields”, and then click “New” in the “Lead Custom Fields & Relationships” section.

Choose “Formula” as the field type for this new field. Then enter a name and use the following formula:

Round((  NOW() - CreatedDate ),0)

Last, pick the right permissions and save.