SMS API
Send an SMS with a single request.
Authenticate with a bearer key, post a destination and a body — we validate, price, queue, route and report back.
Request
cURL
curl -X POST https://api.blacksms.in/api/v1/sms/send \
-H "Authorization: Bearer bsk_live_xxx" \
-H "Content-Type: application/json" \
-d '{"to":"919876543210","sender_id":"BLKSMS","message":"Hello from blacksms"}'202 Accepted
{
"success": true,
"data": {
"message_id": "MSG_8f21c0d43a9b1e77",
"to": "919876543210",
"status": "queued",
"segments": 1,
"encoding": "GSM7",
"cost": 0.18
},
"request_id": "REQ_4c1f9ab2d0e7"
}- Numbers are normalised to E.164 and validated before charging
- Segment count and encoding are returned with every accepted message
- Duplicate bodies to the same number inside 60 seconds are rejected
- Failed and rejected messages are refunded to your wallet automatically