Sending SMS
Use messages endpoint to send Single or Bulk SMS. When you send SMS messages using this API, the API will return to you the sent messages’ ID to track them later using Cequens Get Message Details by ID API.
Authorization
bearerAuth JWT access token returned by Signing In (POST /auth/v1/tokens/).
In: header
Request Body
application/json
The message content that you want to send.
The name of the message sender.
"Cequens"Message type either text or unicode Can be text or unicode
"text"The intended recipients’ phone numbers.
An integer used as an identifier for your request to track it.
int32A string that includes the desired delivery time of the SMS.
A string to define the URL to which you would like to send the delivery receipts (DLR).
A string to define the data coding scheme of the SMS.
set it to true, if the messageText contains URL and you want to shorten it
falseResponse Body
application/json
application/json
application/json
curl -X POST "https://example.com/sms/v1/messages" \ -H "Content-Type: application/json" \ -d '{ "messageText": "string", "senderName": "Cequens", "messageType": "text", "recipients": "string" }'"{\n \"replyCode\": 0,\n \"replyMessage\": \"Request handled successfully\",\n \"requestId\": \"2fbc0560-6187-11e7-b60b-77c0e21cef84\",\n \"clientRequestId\": 0,\n \"requestTime\": \"2017-07-05T15:38:10.742\",\n \"data\": {\n \"SentSMSIDs\": [\n {\n \"SMSId\": \"0461f8f4-4c4f-4dc0-b7ed-097f4f9f85f4\"\n }\n ],\n \"InvalidRecipients\": \"\"\n }\n}"Retrieving SMS Messages GET
You can track the messages you have sent during a certain period by submitting the Get Messages Details Within Date Range API request. The API will return an array of multiple records. Each record includes the details of an SMS message that was sent during the provided date range in the API request. You can also specify the number of SMS messages you want to receive per response page, as well as the response page index number you want to receive. To use Cequens Get Messages Details Within Date Range API, first submit an HTTP Request with the date range, and other optional details, and then receive a Response that includes the details of all SMS messages sent during the provided date range.
Getting Account Balance GET
Through Get Your Current Balance API, you can directly retrieve your current Cequens account balance. You can also get the current balance of your sub-accounts, along with their details, in case your account is a master account. Using Cequens Get Your Current Balance API is quite simple. First, submit an HTTP Request to the API’s designated URL, and then receive a Response that includes your account balance details.