Did you know that you can automate SMS communication? TheSMS API from Octopush offers a very attractive feature for this: SMS replies! This option replaces your sender ID with a short, non-premium virtual number that your users can reply to. This option must be requested.
Communicating via SMS becomes possible, and you can intercept responses from your own users.
Why intercept your users' responses?
Take your business to the next level by automating a new form of direct communication: text messaging! It is no longer just aboutsending an SMS without the possibility of a reply, but actually intercepting your users' responses and, why not, engaging in a near-direct conversation with the user on their phone! This new direct communication channel enables new marketing prospecting techniques, such as:
- Organizing contests (by intercepting user entries or even answers provided by your customers);
- Inquiries about a purchase (verifying a postal address, etc.);
- Requesting feedback on products and services;
- Product delivery (confirming availability, etc.).
How can you intercept your users' responses?
The Octopush API offers three web-based interception services:
- Reply by email (responses are sent to the email address you specified in your customer account).
- Reply by callback (responses are sent to the URL you provided; please note that this URL must be validated by the Octopush technical team. The URL must not return any results during each call). Certain parameters will be provided during the callback, such as the message ID (the sending ticket), your recipient's mobile number, your user's response, the date the response was received, and the SMS sending ticket.
- Reply in your customer account (responses are visible there, with access by campaign or by date).
For practical reasons, using the URL method is preferable; it is more flexible and will facilitate the organization of your company database.
How do you intercept responses using the cURL SMS API?
cURL is primarily a command-line interface designed to extract information from a remote URL. The cURL API provided by Octopush is accessible via the internet, and this interface can simplify your automated exchanges. Generally, developers frequently use cURL on Linux-based web servers (Debian, Ubuntu, etc.) to query the Octopush API servers via the command line.
To simplify information exchange, it is common to use web languages like PHP, ASP.net, Java, or Python, as using the Curl library directly is quite complex. Indeed, it requires you to use the command line manually or via a .sh script. Keep in mind that most modern web languages offer libraries compatible with Curl. Python, for example, provides libraries included in its standard library: urllib and urllib2. It is very simple to submit information via these two libraries. In addition to the benefits of programming data transmissions, the Curl API gives you the ability to intercept data.
The Curl SMS API allows you to communicate more quickly and easily with the SMS reply option, which is simple to set up. Once the special SMS reply function has been confirmed as active, you will need to set the "with_replies" parameter to "1" for each message sent.
To properly manage callbacks, responses can be transmitted to secure or non-secure URLs (http or https://). You will then need to intercept the variables provided by the Curl SMS API: "message_id" (the message ID number), "number" (your recipient's mobile number), "text" (the text of the reply), and "answer_date" (the date the message was replied to).
The text of the reply can be parsed, notably to extract a portion of text (such as a contest entry code, for example), or simply to process a response from customers.
For practical reasons, we recommend storing all your customer information in a database (such as MySQL, one of the most widely used RDBMS on the market). This database can store each recipient's number, the frequency of your marketing campaigns, and all possible personal information for each subscriber (last name, first name, email, etc.). Querying the database will provide additional information to communicate your SMS marketing campaign. By storing information in an RDBMS, you can leverage the power of relational tables by, for example, linking each response to a specific recipient number. This database could then be accessed via a dedicated administration platform or directly within your usual CMS. The goal: increase your responsiveness and develop an efficient SMS marketing strategy.
Finally, don't forget that the Curl SMS API also allows you to intercept unsubscribe requests in real time (all STOP replies).