एसएमएस एपीआई

A plain REST API for एसएमएस भेजना

POST your sender, recipient and content with a Token header. Get a message ID straight back, and delivery reports pushed to your server.

अपना पहला एसएमएस भेजें

One request, one message

Authenticate with your access key, POST the message, and read the msgid from the response. Press the button to see it run.

curl -X POST https://secure.smslocal.com/api/service/enterprise-service/external/sms \
  -H "Token: $SMSLOCAL_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "from": "SMSLOCAL",
    "to": "14155550123",
    "content": "Your code is 481920."
  }'
पोस्ट/बाहरी/एसएमएस
डाक/external/sms
प्रतिक्रिया

Run the request to see the response.

Built for developers

Nothing exotic to learn

Three ideas cover the whole API, which follows plain REST conventions.

  1. Authentication

    Token authentication

    Send your access key in a Token header on every request, with JSON in and JSON out.

    • No SDK required
    • Works from any language
    • Keep the key in an environment variable
  2. प्रतिक्रिया

    Know it was accepted

    Every send returns a msgid and an errorcode immediately.

    • Store the msgid against your own record
    • errorcode 0 means accepted
    • Use the msgid to match reports later
  3. Replies

    Two-way by default

    Replies arrive on the same callback, marked as mobile originated.

    • Same message shape as reports
    • Tell directions apart with mt / mo
    • Route replies to your support tools
डिलिवरी रिपोर्ट

See what happened to every message

A status report is posted to your callback URL when a message reaches its final state.

  1. 1
    Match by msgidEvery report carries the ID you were given at send time.
  2. 2
    Final states onlyYou hear about a message when it is delivered or has failed.
  3. 3
    One callback URLThe same endpoint receives reports and replies.
Delivery logउदाहराणदर्शक
  • 9f2a7c10+1 415 ••• 0123पहुंचा दियाjust now
  • 9f2a7c11+91 98••• 43210पहुंचा दिया3 s ago
  • 9f2a7c12+44 7••• 123456लंबित5 s ago
  • 9f2a7c13+91 99••• 00012असफल9 s ago
Know before you send

See how a message is counted

Longer text and non-Latin characters change how many parts a message is billed as. Try your own wording, and look up a number before you send.

GSM746 अक्षर160 per part
1partbilled separately
  • Part 1
    46 / 160

One part holds 160 characters in GSM7 or 70 in Unicode. One non-GSM character, such as an emoji or a Hindi letter, switches the whole message to Unicode.

Why an API

Stop gluing messaging together by hand

Drag the divider to compare.

With the SMS APIYour appSMS APIone endpointCustomersdelivery reports and replies, pushed back
  • Messages sent from your own code
  • A report for every message
  • Replies pushed to your system
Without a messaging APIYour teamCSV exportSpreadsheetVendor portalShared inboxCustomers???
  • Manual exports and uploads
  • No idea if a message arrived
  • Replies land in someone’s inbox
Before you go live

A short pre-launch checklist

0%0 का 9

Tick items off as you go. Nothing here is saved.

01खाता
02Compliance (India)
03Testing
आपके प्रश्नों के उत्तर

SMS API — frequently asked questions

Pass your access key in a Token header on every request, along with Content-Type: application/json.

Every send returns a msgid. Point us at a callback URL and we post a status report to it when the message reaches its final state.

160 characters on GSM7 encoding, or 70 on Unicode. Longer messages are joined from several parts, each billed separately.

Yes. Inbound replies are delivered to the same callback URL and marked as mobile originated.

Yes. SMS to Indian numbers must use an approved entity, sender header and template. Our team helps you register them during onboarding.

शुरू हो जाओ

Send your first SMS in minutes

Create an account, grab your access key and make your first request.