Skip to Content
Author's profile photo Paul Kalina

Sending SMS via mobile provider’s REST service.

Hi All,

In this post I would like to show you how can we send SMS messages from ByD utilising REST service. Although I will be using an Australian mobile provider, the process would be similar to any other REST based service.

SDK Items used in this example:

– External Web Service Integration – to define the REST service

– Custom BO – to define the communication parameters and recipient’s phone number / message


– You will have to create a FREE account at and apply for the API Key and API Secret.  

– For now the SMS are restricted to Australian phone numbers.

Sending SMS in our example involves two REST services, first one is called with our API Key /Secret and returns an OAuth token. Then, the token is used to call the second service and send the SMS.

1. Create a new BO:


2. Activate and create new QA screen with the above elements.


3. Add first External Web Service Integration item  (EWS) to the solution. Select REST as the service type.


Paste the URL to the first web service (obtained from the DEV portal), you can include the parameters but it won’t matter at this stage as they will be defined in the ABSL later on anyway. As you can see the SDK will pickup the path automatically.


4. In the next screen tick the box “Create communication scenario”. Do not enter any API Keys. Click finish.

    You should end up with two new items in the solution explorer.


5. Lets now create the second EWS.

Note the new URL of the second web service.


6. After activating your objects, login to the tenant to add our new communication scenarios.

– User and Application Management -> Communication Arrangements -> New

Select our first webservice EWS_SMS_Auth


Select the associated communication system:


Ignore the Basic setting page and go straight to the Advanced settings. For our basic scenario we will set the Auth method to None and untick the “Use Basic Settings”.


Finish and active the new comm arrangement.

7. Repeat the same steps for the Second web service EWS_SMS_Send.

8. Back to studio. Create a new script file for the action we defined earlier in the BO: sendSMS.

– enter your API key and API secret.

ABSL code is fairly self explanatory, we specify the service name that we want to use, create parameters and execute the service. The only difference between the two REST services is that the second one uses POST call and has actual body content containing the message and recipient’s phone number. The only tricky bit was getting the body string right.


9. Right click on the QA screen in the SDK and select Preview.

– enter a phone number and a message


10. After you’ve hit Send button you should see the response back from the two services. The SMS result string contains the unique message ID that can be later used to query the status of the message (pending, delivered etc).


And here is our SMS:


And that’s it!  I hope this post will be helpful to others working on something similar.

ABSL code is attached.



Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Sunil Kumar Maurya
      Sunil Kumar Maurya

      Hi Paul

      Nice Blog... Good help for those who are looking for how to consume REST webservice in C4C.


      Sunil Maurya

      Author's profile photo Jacques-Antoine Ollier
      Jacques-Antoine Ollier

      Hello Paul,

      very nice blog!

      Is it safe to assume this can work with any SMS provider in the world?

      So that it is limited to Australian number only for this example because you use the API from telstra.

      Am I right?

      Thank you for your attention.

      Best regards.

      Jacques-Antoine Ollier

      Author's profile photo Paul Kalina
      Paul Kalina
      Blog Post Author


      Unfortunately, every service provider might have a different implementation, though if it's REST based that you could expect a similar structure.  My post was more to show how to consume Rest based service in ByD and the SMS gateway was a nice example to use.

      API for developers from Telstra is locked to Australian numbers but if you had a paid account with Telstra I should work for any number.



      Author's profile photo Former Member
      Former Member

      Dear John,

      great tutorial! Thank you! Unfortunately, I get connection errors when checking the URL above. Maybe you also met some difficulties during integration and can assist. I already started a discussion on this issue.

      Checking connecion to OData URL fails (Ping fails)

      Best regards,


      Author's profile photo Former Member
      Former Member


      Can anybody tell me how to get the API Key and API Secret.

      Author's profile photo Paul Kalina
      Paul Kalina
      Blog Post Author

      Hi Komal,

      The API key and Secret are provided by the mobile network provider, in my example this is Telstra - an Australian mobile provider.