Authentication
Authenticate every API request with your API key. Create an account at whitelabled.securesmsc.com/register, then create a key in the dashboard under API & Integrations → API Management.
Authentication Method
Send the key in the Authorization header as a Bearer token. The header X-API-Key: YOUR_API_KEY also works. Send Accept: application/json so errors come back as JSON.
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json
Accept: application/json
A missing or wrong key returns HTTP 401, for example {"success":false,"error":"Unauthorized","message":"Invalid API key"}.
IP whitelisting
The first IP address that uses a key successfully is added to that key's allowed IPs automatically. After that, calls from any other IP address get HTTP 403 "IP address not allowed. Please whitelist your IP address to access the API." Add every server IP, or an IPv4 CIDR range, under API & Integrations → API Management → IP Whitelisting before the first call, and use a separate key for each server or integration (CRMs, serverless functions and multi-server apps call from many IPs).
GET requests
New keys accept POST only. The GET endpoints (/balance, /sms/status/{messageId}, /sender-ids, /templates and GET /sms/send) return HTTP 403 "GET method is not allowed for this API key" until you tick "Allow GET Method" for the key.