Twilio for Salesforce

So I have had it on my list to find a declarative and affordable way to bring in texting (SMS) platform services to our organization for a long while. That way has arrived! It’s Twilio for Salesforce combined with the Twillio.org Impact Program for discounted pay-as-you-go pricing.

Here’s what I did in about six hours to learn and bring our installation up…

  1. Installed and got outgoing and incoming messages to work on my trial Twilio account.
    • You have to sign up for a free trial account on Twilio. I managed to send and receive my first messages on the Twilio web very fast.
    • I upgraded my account to paid so that I could have the ability to send to numbers I haven’t preregistered.
    • I registered for my discounted services and $500 credit through Twilio.org but I did have to pay to get started.
  2. Installed the private beta Salesforce for Twilio from Appexchange.
    • It has to be accessed by getting permission from Twilio at this time (request access on the Twilio for Salesforce page), but that was quick and easy. I anticipate they will open it up eventually.
  3. Connected Salesforce with Twilio and got the bidirectional real-time SMS messaging going inside Salesforce!
    • I following the step by step instructions. It was very clear and no more complex than any connection setup. This allows both outgoing and incoming messages.
    • I added a provided SMS chat lightning component to my contact page, making it visible only if there is a mobile phone number. I also a custom field called SMS Opt Out to record people who don’t want us texting them. I made the component invisible in that case.
    • Conversations appear to be near real-time. I read in the documentation that on the chat window, Salesforce is updated every 15 seconds for any new messages. Outgoing messages were immediate.
  4. Sent my first campaign to frequent volunteers who have provided their mobile number so we can remind them.
    • I created a Salesforce campaign and assembled the frequent volunteers.
    • I added the provided Bulk Message component to the campaign page.  I will consider adding a checkbox for Enable Bulk SMS Sending on the campaign. The component would only be visible if the checkbox is true. And if the checkbox is true, we would automatically remove anyone who has not opted in for SMS in a field we call SMS Opt In.  This would prevent us from sending undesired automated messages.
    • I edited my first bulk message, including merging in a First name and sent it. Several people were delighted and two said No. So we updated manually their choice as SMS Opt Out. The inbound and outbound message appears in a new SF record. The bulk message appeared in the SMS window of the contacts even though I sent it in the bulk campaign. A bulk message record also exists to record activity. So everything is trackable.
  5. Hooked my Twilio account up to my Zapier account to give inbound message notification.
    • I created a simple Zap that fires on an inbound message. This is probably not our final solution but I wanted to make sure it was possible and to have something in place while we pilot programs.
    • It first looks up the contact in SF using the mobile number. If it is found, we now have the Salesforce ID and contact name.
    • Then I notified from Zapier a designated person of the new inbound message so we can take action. 
  6. Created my first outbound message using Process Builder.
    • I learned how to send outgoing messages using process builder by invoking a provided APEX method.
    • In particular, I made a Process Builder to send a welcome message to anyone who sets SMS Opt In.
  7. Created my first outbound message using Flow.
    • I learned how to send outgoing messages using flow again invoking a provided APEX method.
    • In particular, I made a flow that just sends a message and allows entering a media URL and record ID.  I played with these two optional elements since I couldn’t find any documentation on them.
    • Media URL send MMS pictures. I think that will be very good for visual prompts like Thank You! or Welcome! to go along with text.
    • The Record ID parameter created a completed activity related to the salesforce recorded specified by the ID. This would be great for adding closed activities to accounts or opportunities.
  8. Kearned how to respond to incoming messages using Process Builder.
    • All incoming messages are a Message salesforce record. They are not yet associated with a contact. So to do most things you are going to need to run a flow to find the contact based on the mobile phone.
    • Once you’ve connected the msmessageo the contact, you can do whatever is needed (created a task, update a record for SMS Opt In, SMS Opt Out, etc.)

So that was a lot for six hours! What’s next?

  • My first project is to recreate our volunteer reminder emails (implemented with Volunteers for Salesforce) in SMS for those contacts who use SMS Opt In and have a mobile phone.
  • Next is to handle volunteer check-in by a “Checkin” keyword text by finding the contact using the phone number and finding their volunteer record and changing status from confirmed to completed. It would be nicer to have location services, too, of course, so we know they are where they are supposed to be!
  • After that, we want to handle volunteer dropin registration. We collect name and email and create records. It seems like we could pretty easily do that with a keyword text and some data. We find contact if it exists and create volunteer record. Or we give them further information and ask first name, last name, and email and then do it.
  • Then we plan to enable subscribing to our newsletters by texting Newsletter, Print, Prayer, or Volunteer to us. It would find the contact if exists by mobile phone. If not, it would ask first name, last name, and email and create contact and subscription. We plan on adding this to welcome and reminder and check-in text when the user is already working with us.

I’m not sure where we will implement our little Bots. I have several methods at my disposal: (1) using Zapier and keeping it very simple or (2) using process builder and flow and keeping it very simple. There are also other possibilities toinvestigatee: (3) Trilio native capabilities for bots, (4) Einstein Bots from Salesforce, and (5) third-party capabilities for simple bots.

Conclusion

I had a lot of fun and I’m very excited! Users want SMS. We want SMS. And we want the efficiency of asking people right in front of us to initiate effective and efficient automation steps! The future looks solid!

Leave a Reply

Your email address will not be published. Required fields are marked *