URL shortening & tracking solution

A solution that automatically shortens URLs and tracks click-through rates.

After developing an app your next step will be to promote it. One of the safest and most reliable ways to do that is with an SMS, but what can you do if your URL is too long?

URL shortening and tracking solution will not only automatically shorten your long links but will also track your users’ click-through rates. Just put the original URL into the message body, set the track parameter and everything else will be done by the Infobip platform.

These features are set in the tracking objects in the Fully-featured textual message API method:

Example

POST /sms/1/text/advanced HTTP/1.1
Host: api.infobip.com
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==
Content-Type: application/json

{
   "messages":[
      {
         "from":"InfoSMS",
         "destinations":[
            {
               "to":"41793026727"
            }
         ],
         "text":"Hey, take a look at this awesome app. Can you beat my score: http://www.example.com/awesomeApp/someUserId"
      }
   ],
   "tracking":{
      "track":"URL",
      "type":"SOCIAL_INVITES"
   }
}
POST /sms/1/text/advanced HTTP/1.1
Host: api.infobip.com
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==
Content-Type: application/xml

<request>
  <bulkId>BULK-ID-123-xyz</bulkId>
  <messages>
    <message>
      <from>InfoSMS</from>
      <destinations>
        <destination>
          <to>41793026727</to>
          <messageId>MESSAGE-ID-123-xyz</messageId>
        </destination>
        <destination>
          <to>41793026731</to>
        </destination>
      </destinations>
      <text>Hey, take a look at this awesome app. Can you beat my score: http://www.example.com/awesomeApp/someUserId</text>
    </message>
  </messages>
    <tracking>
        <track>URL</track>
        <type>SOCIAL_INVITES</type>
    </tracking>
</request>

The user will receive the original SMS message with a shortened URL:

Hey, take a look at this awesome app. Can you beat my score: http://eel.nu/NJxE/cJ9UH

Important:

Each sent message gets a unique Infobip short URL and it will take 25 characters out of your message.

As soon as the user clicks the link, we can automatically send you the user’s phone number so you will instantly know when the conversion happens.

Additionally, we collect CTR together with other useful information:

  • User’s mobile phone number
  • Network prefix
  • Country prefix
  • Mobile phone operating system

Contact us for additional information and setup assistance.

Custom base url

As discussed above, the URL shortening feature will use an Infobip domain: eel.nu. If you wish to use your own domain, but still benefit from Conversion rate tracking, you can specify your own domain in the send SMS request:

POST /sms/1/text/advanced HTTP/1.1
Host: api.infobip.com
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==
Content-Type: application/json

{
   "messages":[
      {
         "from":"InfoSMS",
         "destinations":[
            {
               "to":"41793026727"
            }
         ],
         "text":"Hey, take a look at this awesome app. Can you beat my score: http://www.example.com/awesomeApp/someUserId"
      }
   ],
   "tracking":{
      "track":"URL",
      "type":"SOCIAL_INVITES",
      "baseUrl":"http://www.example.com/redirect"
   }
}
POST /sms/1/text/advanced HTTP/1.1
Host: api.infobip.com
Authorization: Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==
Content-Type: application/xml

<request>
  <bulkId>BULK-ID-123-xyz</bulkId>
  <messages>
    <message>
      <from>InfoSMS</from>
      <destinations>
        <destination>
          <to>41793026727</to>
          <messageId>MESSAGE-ID-123-xyz</messageId>
        </destination>
        <destination>
          <to>41793026731</to>
        </destination>
      </destinations>
      <text>Hey, take a look at this awesome app. Can you beat my score: http://www.example.com/awesomeApp/someUserId</text>
    </message>
  </messages>
    <tracking>
        <track>URL</track>
        <type>SOCIAL_INVITES</type>
    <baseUrl>http://www.example.com/redirect</baseUrl>
    </tracking>
</request>

In this case your users would receive an SMS with the following text:

Hey, take a look at this awesome app. Can you beat my score: http://www.example.com/redirect/NJxE/cJ9UH

This way users will be able to recognize your domain and are more likely to click through as a result. On the other hand, note that url shortening is somewhat reduced in this case, since your full domain is retained in the final SMS text.

Important:

When using the custom baseUrl feature of the URL tracking your users will receive links to your domain. You need to configure your servers to redirect all requests that arrive to the base URL you provided back to http://eel.nu. Otherwise, URL shortening and Conversion rate tracking will not work.

Note that path parameters following the base url need to remain intact when redirecting to the Infobip domain, since they are the key identifier used in Conversion tracking. In the above example, you should configure your endpoint so that a request to http://www.example.com/redirect/NJxE/cJ9UH ends up redirected to http://eel.nu/NJxE/cJ9UH.