Please Wait...
Method | POST |
---|---|
Request URL | https://insprl.com/api/sms/send-to-batch |
Authentication | Required How to Generate API keys? |
Parameter | Type | Description |
---|---|---|
Authorization | String | Use your "CLIENT KEY" for this Parameter |
Parameter | Type | Validate | Description |
---|---|---|---|
client_id | String | Required | Use your "CLIENT ID" for this Parameter |
sender_id | String | Required | 6 Digits "SENDER ID" |
msgtype | String | Required | Subscribed package type "promo" (Promotional), "txn" (Transactional), "txnotp" (Txn OTP) |
mobile | Digits | Required | 10 Digits indian mobile number (Multiple saperated with comma) |
temp_id | String | Required | Add DLT Approved template ID |
message | String | Required | Add DLT Approved template message |
schedule_date | Date | Optional | Format: dd-mm-yyyy |
schedule_time | Time | Conditional | Required with "schedule_date". Format: HH:MM (24 hours) |
unicode | Numeric | Optional | Set "1" for YES |
flash | Numeric | Optional | Set "1" for YES |
campaign_name | String | Optional | Maximum 100 characters allowed. |
Parameter | Type | Description |
---|---|---|
code | Numeric | Find the code information below under "API Codes" |
message | String / Array | As per the request handler |
batchid | String | Batch Reference ID |
msg | Numeric | Success message |
credit | Numeric | Spent SMS credits |
Code | Mode | Type | Description |
---|---|---|---|
100 | success | String | On Success |
101 | failed | String | Authorization Error |
102 | failed | Array | Parameter Validation Error |
echo <<$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"https://insprl.com/api/sms/send-to-batch");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_HTTPHEADER, array( 'Authorization: {CLIENT_KEY}'
));
curl_setopt($ch, CURLOPT_POSTFIELDS,
http_build_query(
array(
'client_id' => '{CLIENT_ID}',
'sender_id' => '{6_CHAR_SENDER_ID}',
'msgtype' => 'txn',
'mobile' => '9999999999,8989898989,6336363636',
'temp_id' => '17005689642563136526',
'message' => 'Hi Customer, This is an alert Message',
'schedule_date' => '03-02-2020',
'schedule_time' => '13:20',
'unicode' => 0,
'flash' => 0,
'campaign_name' => 'My campaign 2020 Jan'
)
));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
curl_close ($ch);
{
"code":"100",
"message":"success",
"data":{
"batchid":"2392392933",
"msg":"Your message has been sent to 3 no(s).",
"credit": 3
}
}
If you'd like to use our REST API into your application, Feel free to contact us.
8088 948 172 or Contact Us
Read our latest posts from our blog
If you are into marketing, you must have heard of Bulk URL shortening. They are saying Bulk URL shortening is the new ..
Every profit driven business enterprise is adopting and incorporating URL Shortening as a part of best business ..
If your company or business isn’t using email promoting, ought to they? The solution is affirmative, as email is ..
This website uses cookies in order to offer you the most relevant information. We may place cookies on your computer for functional, marketing and tracking purposes to improve our site and to show personalised content. You can read more about our cookies here: Cookie Policy. Please accept cookies for optimal performance.
Yes, I accept Cookies.