To send an SMS once a Contact is created or updated with a "Tag" using workflows, follow the below-mentioned steps:
Note: This workflow can only be used in the case of an active "Salesmate Voice & Text" feature with a valid Salesmate number enabled for Text Messaging. It will not log the SMS sent out via this method.
- Navigate to the Profile icon on the top right corner
- Click on Setup
- Head over to the Automation category
- Click on Workflow
- Add a Workflow - Create a " + New Rule"
Basic Information
- Select the Module on whose action the workflow will execute (Ex: Contact)
- Mention the Rule Name & Description that you wish to create Workflow for
- Rule Name: Send Text
- Description: Send a text when contact is created or updated with a "Tags" equal to "SMS". Add STOP condition "Tags" not equal to "SMS_Sent" to avoid sending SMS again to the same contact.
- Once done click on Next
2. Execute On
- Choose an action based on which the rule will be executed: Create or Update
3. Rule Criteria:
- Click on Add Condition
- Tags - equals to - SMS [checks this tag exists on the contact being created/ updated/ imported]
- Tags - not equal to - SMS_Sent [ is a STOP tag that prevents the text from being sent again to the same contact ]
4. Choose Actions:
- Call Webhooks
- Give the action name: Send SMS
- Method: POST
- URL To Notify: https://apis.salesmate.io/text-and-calling/v1/text-messages/single
- Headers Tab: Add the key and values below for your Salesmate domain
key | value |
Content-Type | application/JSON |
accessToken | 817bb2f0-a486-11e7-8d3c-************ |
x-linkname | *********.salesmate.io |
Note: AccessToken can be fetched by navigating to the Profile Icon >> Go to My Accounts >> Access Token >>
- Click on Save
- Navigate to Body Tab: Select option : raw: JSON(application/json)
Copy the below content to the body area and change the fields as needed.
{ "toNumber": "{{Contact.mobile}}", "from": "+1xxx7xxx8x", "moduleId": 1, "objectId": "{{Contact.id}}", "provider": "Twilio", "body": "Hello this is a test message." }
body | It is the text message you would like to send (In case you want to use a field where you will enter the text message you can use that field variable example: {{Contact.description}} ) |
toNumber | It is the number on which you would like to send the message (Here we have mapped it to the Contact's mobile number) |
from | It is your Salesmate Mobile Number. |
associatedModuleId |
It is the contact's module ID where the text message will appear. |
associatedObjectId | It is the related Salesmate contact to whom the message is being sent. |
provider | Twilio |
- Click Save
- Status should be Active - Marked in Blue Colour for the workflow to execute
Comments
0 comments
Article is closed for comments.