SMS, OTP and webhooks — one REST API.
Send SMS and OTP from your application, schedule sends and manage your contacts; receive delivery reports and inbound SMS on your own server through webhooks.
https://api.turkeysms.com.tr
What you can do with the API
Sending SMS
Immediate or scheduled sending to one or more numbers; many numbers in one request, with the same text or a different text per number.
/sms/send/group/send/group/sendMixedOTP verification
TurkeySMS generates the verification code; send it to a single number with a ready-made template, or with your own Sender ID and text.
/otp/send/otp/detailedWebhook
Events reach your server as HTTP POST requests: sms.sent, sms.delivered, sms.failed, sms.received. When a secret is set, requests are signed with HMAC.
Contacts and number blocking
Create, rename, delete and list groups, and add numbers to them. Add numbers to your blocking list and check their status (the list applies to panel sends).
/groups/*/contacts/add/blacklist/post/*Queries and reports
Query your balance, Sender IDs and message status; get summary and detailed sending reports.
/balance//senderid/check/sms/status/reports/*API keys and scopes
Verify your key; manage each key's scopes in the panel under API Center → My Keys.
/auth/post/check/Your first request
Fill in your API key and an approved Sender ID, then send the request. The key goes in the api_key field of the body.
curl -X POST https://api.turkeysms.com.tr/sms/send \ -H "Content-Type: application/json" \ -d '{ "api_key": "YOUR_API_KEY", "title": "YOUR_SENDER", "sentto": "905XXXXXXXXX,905YYYYYYYYY", "text": "Your appointment is tomorrow at 10:00.", "sms_lang": 0 }'
{
"result": true,
"result_code": "TS-1024",
"result_message": "SMS dispatched successfully.",
"sms_id": 48213377,
"number_of_sms": 2,
"total_recipients": 2,
"success_count": 2
}
Requests are live
Every request sent to this address is processed for real: /sms/send sends real SMS and the cost is deducted from your balance. Requests sent from Swagger UI are live too, which is why “Try it out” is off by default.
Test with your own number, and never put your API key in code that runs in a browser or a mobile app.
HTTPS, POST and JSON
All requests are sent over HTTPS with POST; the body can be JSON or form data, and responses are JSON.
Clear response codes
Results and error codes (TS-xxxx) are returned in the response body; evaluate the result from the body, not the HTTP status. All codes are in the Response codes section.
OpenAPI 3.1
Download the specification and import it into your API client or code generator.