Categories
Dynamics 365

Follow your recipient’s activity in Dynamics 365

Tasks: Send a notification when a contact opens a Dynamics 365 attachment
Difficulty: Intermediate
Time to implement: 1-2 hours

In this post I’ll show you how you can use the Email Engagement solution, which I showed you how to configure in my previous post, to automatically sending a notification when a contact/recipient has opened a Dynamics 365 email attachment.

Tools

  • Dynamics 365 Sales: A popular CRM system from Microsoft that allows you to track your sales pipeline and activities, opportunities, and leads.
  • Email Engagement: One of Sales Insights’ solutions that enables you to follow emails in Dynamics 365 Sales. See my post Tracking opens and clicks of Dynamics 365 emails to see how it is enabled.
  • Power Automate: A service from Microsoft that allows you to connect different systems and create automated processes. In this example it is used to create a task and send a notification to the owner of a Dynamics 365 email message when an attachment is opened. In this post premium connectors are used that require a premium license for Power Automate.

Email Engagement follow up options

Email Engagement allows you to follow emails you send from Dynamics 365. It also gives you an option to set reminders to follow up on emails. The available options are:

  • If I do not receive a reply by
  • If the email is not opened by
  • Remind me anyway at
Set reminder options

The reasoning behind these options is that a salesperson wants to be able to follow up if there is no recipient activity. Another use case is when there is a recipient activity, the salesperson might want to follow up. E.g. when an email attachment containing a quote or a pricing is opened. The purpose of this exercise is to expand the current options to enable notification when a contact/recipient opens an attachment that is tracked via Email Engagement. To this end we will leverage Power Automate to send the notification.

A prerequisite to perform the work in this exercise is that you have already enabled Email Engagement in your Sales Insights settings, OneDrive integration in Dynamics 365, and that you have the appropriate licenses and permissions, of course.

Create and configure a flow

You start by navigating to flow.microsoft.com, create a flow from blank and choose the ‘When a record is updated’ trigger. This will open up the flow designer. To configure the flow you:

  1. Choose current environment in Environment.
  2. Choose Email messages in Entity name.
  3. Choose Organization in Scope.
  4. Under advanced options choose attachmentopencount. This lets the Flow know which fields on the email record you would like to monitor. In this case you want to monitor changes to the Attachment open count.

Next you insert a condition that checks if the number of opens your attachment has received is more than zero and that a category does not contain a specific value (we will come back to this later).

  1. Click on the ‘New step’ button.
  2. Select Condition.
  3. In the first condition insert Attachment open count equal to or greater than 1.
  4. In the second condition insert Category does not contain ‘Notification sent’.
When a record is updated trigger and the condition

When the condition is true you want the email notification to be sent. First you need to get the user information and then you will send the notification. Lastly you want to update the email message to ensure that the user doesn’t receive more than one notification.

  1. In the ‘If yes’ box click ‘Add an action’.
  2. Choose Get record (CDS).
  3. Choose current environment in Environment.
  4. Choose Users in Entity name.
  5. Put in the Owner of the email message as the Item identifier.
  6. Below the Get record action, click ‘Add an action’.
  7. Choose Send an email notification (V3). You might have to authenticate or accept to continue.
  8. In the To field insert the Primary Email from the user record.
  9. Fill in the subject and body of the email. You can use Dynamic content here which is recommended so the user knows which email/contact you are referring to.
Get record and Send an email notification (V3) actions
  1. Below the Send an email notification (V3) action, click ‘Add an action’.
  2. Choose Update a record (CDS).
  3. Choose current environment in Environment.
  4. Choose Email Messages in Entity name.
  5. In the record identifier put in the Email Message ID.
  6. Click ’Show advanced options’ and type in ‘Notification sent’. This is necessary to indicate somewhere on the record that a notification has been sent to the user. You can use any field. In this case I am using an OOB field called Category. If you are using Category for something else you may consider creating a custom field to store this value.
  7. Click Save to save your flow.
Update the Email Message

Testing the flow

You can now test your flow to see if everything works as it should. Do a couple of test runs on the same email message to verify that only one notification email is sent when an attachment is opened multiple times (note that the email must be sent through Dynamics 365 with a followed attachment). For more information about performing the tests, please refer to the blog post’s video above.

Categories
Dynamics 365

Tracking opens and clicks of Dynamics 365 emails

Task: Enable and configure Email Engagement to follow emails
Difficulty: Medium
Time to implement: 1-2 hours

In this post I am going to show you how you can follow emails in Dynamics 365 Sales. This is a very useful feature that is part of Sales Insights (free) solutions.

Watch the video

Tools used

  • Dynamics 365 Sales: A popular CRM system from Microsoft that allows you to track your sales pipeline and activities, opportunities, and leads.
  • Sales Insights: Free solutions that come with your Dynamics 365 Sales subscription.
  • Email Engagement: One of Sales Insights’ solutions that allows you to follow emails in Dynamics 365 Sales.

Enable Sales Insights

First I’ll show you how to enable Sales Insights:

  1. Navigate to Sales Hub.
  2. In the switch area choose Sales Insights settings.
  3. Click on the Accept Terms button.

Enable Email Engagement

Once you have enabled Sales Insights, you can enable the Email Engagement solution.

  1. Navigate to Sales Hub.
  2. In the switch area choose Sales Insights settings.
  3. Click on the Grant permissions button. Once you have granted the permissions this button changes to Set up.
Email engagement
Grant permission for Email engagement
  1. Click on the Set up button
  2. Switch on the Enable email engagement. Now you have set up the Email Engagement.

Create and send an email message

To test the solution you need to send a test email. You can send it to yourself. You do this by:

  1. Navigating to a contact record in Dynamics 365 and creating an email message on the contacts timeline. Try adding a link to the email message.
  2. Send the email message and once it has been sent, open it and click the link (you have to have sent to yourself to do that).

View the opens

To view the opens you have two options. Either view it directly from the contact’s timeline or from the All Followed Emails view on the Activities page.

To view it from the contact record:

  1. Navigate to the contact you sent to. You can see in the Timeline that the email has been sent and that it has been opened (if you followed step 3 in the previous section).
follow email results
Viewing the opens from the contact’s timeline

To view it from the Activities page:

  1. Navigate to the Activities page.
  2. Select the All Followed Email view. You can see four metrics that belong to the Email Engagement solution, Open count, Attachment open count, Links clicked count, and Reply count.

Author’s comments

I used a template in my testing and it appears that links inserted into a template for reuse are not tracked by the Email Engagement solution. Therefore, it is recommended to always manually inserting a link even when using an email template. This is something that Microsoft should consider improving on their side.

References

https://docs.microsoft.com/en-us/dynamics365/ai/sales/email-engagement