Sending SMS with HubSpot – Using Zapier, Front, Twillio

We recently dealt with an uncommon issue: our customers weren’t reading their emails.

Okay. Maybe it’s not that uncommon. However, these guys really weren’t reading them, at all. We could send them long drip sequences and they wouldn’t open them.

We did validate that by talking to our clients and saw that most people within that target market weren’t using Email to communicate.

We also learnt that they were heavily relying on SMS to communicate with friends and their clients. So we decided to send them SMS.

Until now, it’s an easy reasoning. The main issue is that we were using HubSpot. And HubSpot doesn’t have any out-of-the-box solution to send SMS.

We had to become creative… In this article I’m going to tell you all the steps that we followed to send SMS with HubSpot.

The Overall Setup

We needed the ability to:

  1. Send SMS as part of a workflow within HubSpot
  2. Receive potential replies

Sending SMS is an easy task with an API like Twilio.

The 2nd point wasn’t necessary but we felt like our leads might answer to these texts. That’s why we decided to use Front.

The company we work with heavily relies on Zapier so we decided to use that to make it all work together.

In a nutshell, here is how it works:

  1. We have custom property on each Contact specifying the text of the message and a Yes / No property to send the message
  2. As soon as the Yes / No goes to “Yes”, it triggers actions into Zapier
  3. Zapier sends the message to Front which takes care of sending the message through Twilio

Whenever someone replies back to the message, you can then see his reply in Front.

Steps by Steps

1. Create an account on Front, Twillio and Zapier.

2. Add Custom Properties to your Contacts in HubSpot

You can call the first one “Send SMS” as a radio-select (Yes / No).

When this field will be at “Yes”, it will send the message contained in the 2nd property.

You can therefore create another property called “Message SMS” as a multi-line text.

3. Head over to your Zapier account and create a new Zap.

You want to trigger your Zap whenever a “New Contact Property Change”:

Whenever the “Send SMS” property changes:

4. Add a Filter to your Zap so that “Send SMS” needs to be at “Yes” to keep executing

5. You’ll probably need to add a “Code” action running Python so that you can format the phone number

Front only accepts phone numbers with the country prefix (like +1 for US numbers). So you need to make sure that the number matches the format required by Front, otherwise the SMS won’t be sent.

You can also process “shortcodes” from your SMS. For instance, we added a “{firstname}” as a variable in our message. This token can only be replaced by Zapier so we handle that in the script.

You can see the full script that we used here.

You’ll then output the “Clean Phone Number” so that you can use that into the next step.

6. Now add a new Action to your Zap that will “Find or Create Contact” on Zapier.

7. Add one Action to your Zap “Front Send Messages”, which looks like that:

8. Add one last action to your Zap to Update the HubSpot Contacts.

In this one, you’ll update “Send SMS” to “No” and “Message SMS” to “Empty”. Thus you won’t risk of sending the same message again next time.

Sending SMS

To send SMS, you need to

  1. Set the “Message SMS” property on the contact to the message that you wish to send
  2. Set the “Send SMS” property to “Yes”

Zapier will then take care of the rest.

You could do so manually on a contact basis or handle these changes through a workflow. It’s your call.

I hope that this tutorial was helpful to you. Let me know if you have questions or if you struggle with anything.