API integration for sending SMS
This is the JSON: API
To communicate with the server, the browser needs the POST method. Requests are sent to the required address via the HTTP protocol, using the standard text format – JSON (JavaScript Object Notation).
The right to access user resources is carried out through the OAuth 2.0 authorization protocol. To authenticate requests, you need a token, to obtain which go to the Profile section of your Personal Account. Select the token and paste it into the request header: ‘Authorization: Bearer your_token’.
How to send personalized SMS in SMS Club
Internet address of the service: https://im.smsclub.mobi/sms/send
{ "phone" : ["380989361131"], "message" : "test text", "src_addr" : "VashZakaz" }
{ "success_request": { "info": { "106": "380989361131" } } }
How to get SMS status
Internet address of the service: https://im.smsclub.mobi/sms/status
{ "id_sms" : ["107"], }
{ "success_request": { "info": { "107": "ENROUTE" } } }
Status options
Errors
Getting alphanumeric subscriber names
Internet address of technical support: https://im.smsclub.mobi/sms/originator
You can get active alpha names by requesting them at the above URL. It is enough to send the available data that does not include text content.
If the request is successful, the program will provide a list of free alpha names:
{ "success_request": { "info": [ "test1", "test2" ] } }
How to get a user balance
Online address of technical support: https://im.smsclub.mobi/sms/balance
If the request is completed, the program will return the “info” array, which contains
money — balance
currency — currency
{ "success_request": { "info": [ "money": "8121.1800", "currency": "UAH" ] } }