All Collections
Integrations
Microsoft Dynamics 365
Add a Simplesat survey to Microsoft Dynamics 365
Add a Simplesat survey to Microsoft Dynamics 365

How to add your CSAT, customer effort score (CES), and NPS embed codes to Microsoft Dynamics CRM.

Cory Brown avatar
Written by Cory Brown
Updated over a week ago

Simplesat allows you to create a CSAT, CES, or NPS survey that you can embed directly in Front email notifications templates.

In this article:


Create your survey

First, create a new survey.

Customize the survey settings to your heart's desires. 😁 Then, choose the Integrate with another tool option in the Publish tab.

Select Microsoft Dynamics 365 in the pop-up box.

Click the Generate Embed Code button. Make sure you're on the HTML option. Then, click Copy survey.


Microsoft Power Automate email placeholders

These are automatically included when you generate a Microsoft Dynamics 365 survey embed code, but here they are just in case. πŸ˜‰

Team Member Email

@{outputs('Owner')?['body/internalemailaddress']}

Team Member ID

@{outputs('Owner')?['body/systemuserid']}

Team Member First Name

@{outputs('Owner')?['body/firstname']}

Team Member Last Name

@{outputs('Owner')?['body/firstname']}

Customer Email

@{outputs('Customer')?['body/emailaddress1']}

Customer ID

@{triggerOutputs()?['body/_primarycontactid_value']}

Customer First Name

@{outputs('Customer')?['body/firstname']}

Customer Last Name

@{outputs('Customer')?['body/lastname']}

Company Name

Ticket ID

@{triggerOutputs()?['body/ticketnumber']}

Ticket Subject

@{triggerOutputs()?['body/title']}

We're assuming the 'Get customer' and 'Get owner' steps of the flow are called 'Customer' and 'Owner' respectively. The placeholders change depending on what the steps are called.


Send a Simplesat survey on case closure

Microsoft Dynamics can send out a Simplesat survey automatically whenever a case gets marked as resolved.

To do this, open any case and click the three dots in the top bar. Then go to flow and select create a flow.

A new page will open with Microsoft Power Automate. Click my flows in the left sidebar and create a new automated cloud flow.

Give your flow a name and set the trigger to when a row is modified, added or deleted from Microsoft Dataverse. Then click create.

In the first step set the following info:

  • Change type: Modified

  • Table name: Cases

  • Scope: User

Click new step and add a condition.

Set the condition to AND and add a group. Set that group to OR and add two conditions:

  • Status equals 1

  • Status equals 2

Status 1 means 'resolved', and status 2 means 'cancelled'. If you don't want to send a survey on case cancellation, then only add status 1.

Press the bottom +Add and add a new row, then add the following:

field 1 expression: empty(triggerOutputs()?['body/new_simplesatrating'])

field 2: is equal to

field 3 expression: true

This isn't required for the email to work. But will make sure that the survey only gets sent if the customer hasn't left any feedback yet.

Eventually it should look like this:

Next, under if yes add two get row by ID steps from Microsoft Dataverse

Name the first step Owner (this is required) and set these values:

  • Table name: Users

  • Row ID: Owner (Value)

Name the second step Customer (this is required) and set these values:

  • Table name: Contacts

  • Row ID: Customer (Value)

Lastly, add an email step. In this example we're using the Gmail connector, but there are also steps for Outlook 365, or SMTP.

When adding this step for the first time it'll ask you to authenticate with Gmail/Outlook365 or set up SMTP settings. After doing that you should be able to configure your email template.

In the to field fill in the customer email and set the subject.

Next, click the </> button to switch to HTML mode.

Paste your survey HTML code which you copied from Simplesat earlier and press save at the top of the page. Then go back to the previous page.

Try it out!

Create a test ticket with yourself as the requester and set it to resolved. Check your email and click any rating that you like. Once you do, new feedback should instantly show up in your Simplesat dashboard. 🎊

If you run into any issues let us know and we'll be happy to help troubleshoot. πŸ™Œ

Did this answer your question?