SENDING SMS
This API call is made to send SMS to a single recipient.
Method: POST
URI: https://swift.jambopay.co.ke/api/public/send
Headers
{
"Authorization": "Your bearer token from step 1",
"Content-Type": "application/json"
}
The request body is as follows
{
"contact" : "Phone number",
"message" : "Message",
"callback" : "Your callback url to get the responses",
"sender_name" : "Your sendername"
}
Value | Type | Description |
---|---|---|
contact | string | Recipient's phone number |
message | string | Actual message |
callback | string | Callback URL(POST request) |
sender_name | string | Sender name |
Response sample is as follows
{
"message": [
"Messages added to the queue"
],
"message_id":"6e35e594-847e-4d61-a8ad-7176557e38fe",
"telco":"Safaricom"
}
The callback url displays data response from the queue
Sample response for the callback url
{
"contact": "0721...", //the contact phone number.
"messageType": "transactional", //type of message sent.
"status": "delivered, failed or sent", // message status.
"description": "DeliveredToTerminal" // description of the message status e.g failed to enter the queue, sender ID blocked e.t.c.
}