RESTful API

Our brand new REST API using predominantly HTTP POST calls and JSON.

Overview

RESTful API is ideal for the programmatic sending of SMS, regardless of volume. Developers wanting a more extensive integration solution will find that this API perfectly caters to their programmatic sending needs. The API is designed using RESTful standards over HTTP and accepts JSON data.

Required Knowledge
If you plan on using the API you should be familiar with the following:

  • JSON
  • HTTP
  • REST

Base URL

The base URL for the API is https://rest.smsportal.com and supports HTTPS. To access a specific version of the API, simply postfix the URL with the version of the API, as in the case of https://rest.smsportal.com/v1.

The base URL will always be set to use the latest version of the API. However, in order to reduce the chance of compatibility issues, always reference the version you are developing against in the URL.

API Access

To use the API you must generate a Client ID and Secret. This can be done on the Account Settings page, under the heading "API Credentials". Once you have the Client ID and Secret you will need to generate a temporary token (See Authentication Tokens) and include the token in HTTP requests. This mechanism minimises the risk of compromising your API credentials.

With the prerequisites completed, you can now start using the API. The following sections of this guide will briefly explain the available features of the REST API. For technical details about the HTTP request and response objects for each function, please refer to the following documentation.

Authentication Tokens

Once you have the Client ID and Secret you will need to generate a temporary token (See Authentication Tokens) and include the token in HTTP requests.

Authentication tokens must be generated every 24hours for them to remain valid.