Dynamics 365 SMS Integration Using Microsoft Flow and TxtSync

A differentiating factor between competing businesses is the strength of their customer services. Business communications to customers plays an important part in the perceived quality of the customer services on offer. SMS is the preferred communication channel for customers as it can deliver short, concise and relevant notifications, keeping them in the loop with whats going on. Using Microsoft Flow and TxtSync it is very easy to send SMS out of Dynamics 365 and instantly improve your customer communications.

In this guide we will explain what Microsoft Flow is, and demonstrates how it can be utilitised to send SMS through TxtSync from Dynamics 365 triggers. The example we will use is to send an SMS to a contact when a case has been raised. The SMS will act as an acknowledgement that the case has been logged and inform the contact of their case reference number.

If you are already familiar with Microsoft Flow please feel free to skip to the how to section.

What is Microsoft Flow?

As a business you’ll likely be using various software to drive parts of you business workflow. There comes a time where a workflow needs to span across your different software. This is where Microsoft Flow steps in. Flow is a service that allows software vendors to create connectors to their products. These connectors provide you with some simple triggers and actions that you can base your workflow on.

The best way to imagine Microsoft Flow is that its the glue between different products. It gives you the ability to create your workflow processes without the need of a developer writing any code.

What is TxtSync?

TxtSync is a cloud-based SMS service that delivers global SMS. Through TxtSync you can send and receive SMS and track delivery reporting. You can use TxtSync to manage contacts and deliver targeted marketing material directly to their mobile phones.

TxtSync has built a Microsoft Flow connector that makes it easy for you to send SMS as part of your Microsoft Flow actions. Alternatively you can trigger workflows on receiving an inbound message.

How to Send an SMS from Dynamics 365 using Microsoft Flow?

In this how to guide we will take you through the process of sending out an SMS when a support case is raised in Dynamics 365. The message sent out will inform the contact that the case has been logged and provide them with the case reference number.

What do you need to get started?

  • Microsoft Dynamics 365 subscription – Hopefully you already have this. 🤣
  • Microsoft Flow subscription – You’ll need to be able to access premium connectors. 👍
  • TxtSync account – You can signup for free and use the credit TxtSync provides. 😇

Setting up your TxtSync Account

  • If you haven’t got a TxtSync account you will need to create one for free here. TxtSync gives you some free credit to get started with.
  • Create an application for Microsoft Flow by clicking here. This will provide you with a Client Key and Secret that’s used for authentication in the TxtSync flow connector.
  • Take note of TxtSync’s free shared numbers that you can use to send SMS here.

Please Note: You can purchase your own dedicated number or setup a free Sender ID. This is recommended when your serious about going live with your solution as the number or Sender ID represents your brand.

Setting up Microsoft Flow

  • From within Office 365 open up Flow
  • Now select My flows – click New and select “Create from blank”.
  • Flows always start with a trigger. In our example the trigger connector will be Dynamics 365. In the connector window search for Dynamics 365.
  • Under Triggers select “When a record is created”.
  • If this is the first time you have created a Dynamics 365 flow you will need to enter your connection details by signing into Dynamics 365.
  • Now select your Organisation Name. At TxtSync we have a Production and a Sandbox (Dev) environment. It is advised to create your flow first against your Sandbox environment so that you can test it works.
  • Now select your entity name which will be Cases.
  • The next step is to create an action that you want to perform. The first thing you need to do is to get the contact record from the case so that the contacts mobile number can be accessed.
  • Click “New step”, search for Dynamics 365 and choose the “Get record” action.
  • Enter your Organisation Name.
  • Set the Entity Name to be Contacts.
  • For the Item Identifier use the Dynamic content to pass in the Customer record on the Case record.
  • The next step is to check that the Contact has a mobile phone number. Pretty important if you want to send an SMS! 😜
  • Select “New step” and search for Condition.
  • In the “Choose a value” box use the Dynamic content to select Mobile Phone under the Get Record heading.
  • Change “is equal to” to “is not equal to”.
  • In “Choose a value” use an expression of null. Then select OK.
  • Within the “if no” box select “Add an action”.
  • Search for terminate and select the action.
  • Change the Status to succeeded. This will terminate the flow if the contact doesn’t have a mobile phone.
  • Within the “if Yes” box select “Add an action”.
  • Search for TxtSync and select “Send an SMS”.
  • You will need to create a connection to TxtSync using the Client Key and Secret that you generated earlier in the guide. Give your connection a name and click Create.
  • Within the From box enter one of the free TxtSync shared numbers or your own dedicated number if you have purchased one.
  • Within the To box use Dynamic content to pass in the mobile phone of the contact.
  • Within the Message box use a combination of Dynamic content and text to compose a message to inform the contact about the support case.
  • Save your flow and in the top left hand corner give your flow a meaningful name.

Testing your Flow

To test your flow simply click on the Test button in the top right hand corner of the flow edit screen. Select the option “I’ll perform the trigger action”. Now go into Dynamics 365 and create a contact with your personal mobile number. Finally create a case record and link your contact record to the case through the customer field. Your text message will arrive shortly after! ✉️ 😎

Until next time, happy flowing!!!

Interesting in Knowing More?

If you have any questions about an SMS integration with Microsoft Flow and TxtSync please get in touch.

We also offer a full native SMS integration into Microsoft Dynamics 2016 and Dynamics 365.