For developers

This is the section with API documentation for connecting your service to SMS-Man and automatic number purchasing.

API v2.0

API is a protocol of interaction between your software and our activation server. The API is needed in order to automate the process of receiving SMS messages on your side To work with the API, you must use your API key, you can get it by going to the profile page. Our software is fully compatible with competitor sites

API Protocol Description

All requests should go to https://api.sms-man.com/control/ POST or GET request. All requests must have an API key in the form of the token parameter

Balance request

https://api.sms-man.com/control/get-balance?token=$token

Parameters

Field Type Required Value
token String yes Your API key

Result

{"balance":"799.70"}

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": "Wrong token!"}

Get limits

https://api.sms-man.com/control/limits?token=$token&country_id=$country_id&application_id=$application_id

Parameters

Field Type Required Value
token String yes Your API key
country_id Integer no
Number country
application_id Integer no
Number Service

Result

[{"application_id":"1","country_id":"1","numbers":"32302"},{"application_id":"1","country_id":"2","numbers":"3494"}]

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": {"token": "Wrong token!"}}

Request a phone number

https://api.sms-man.com/control/get-number?token=$token&country_id=$country_id&application_id=$application_id

Parameters

to select a random country, use country_id=0
Field Type Required Value
token String yes Your API key
country_id Integer no
Number country
application_id Integer no
Number Service
maxPrice Integer no your desired value
currency String no RUB/USD/EUR
ref String no Pass the referral ID

Result

{"request_id":1,"country_id":1,"application_id":1,"number":"79002415539"}

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": {"token": "Wrong token!"}}

Get sms

https://api.sms-man.com/control/get-sms?token=$token&request_id=$request_id

Parameters

Field Type Required Value
token String yes Your API key
request_id Integer yes Request ID

Result

{"request_id":1,"country_id":1,"application_id":1,"number":"79002415539", "sms_code": "1243"}

Possible errors

{"request_id":1,"country_id":1,"application_id":1,"number":"79002415539", "error_code": "wait_sms", "error_msg": "Still waiting..."}

Change request status

https://api.sms-man.com/control/set-status?token=$token&request_id=$request_id&status=$status

Parameters

Field Type Required Value
token String yes Your API key
request_id Integer yes Request ID
status String yes ready / close / reject / used

Result

{"request_id": 1, "success": true}

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": "Wrong token!"}{"success":false,"error_code":"wrong_status","error_msg": "Status $status does not exists"}

Get current prices

https://api.sms-man.com/control/get-prices?token=$token&country_id=$country_id

Parameters

Field Type Required Value
token String yes Your API key
country_id Integer no
Number country

Result

{"0":{"1":{"cost":"15","count":6455},"2":{"cost":"50","count":124}}, "1":{"3":{"cost":"6","count":1000}}

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": {"token": "Wrong token!"}}

Get list of all countries

https://api.sms-man.com/control/countries?token=$token

Parameters

Field Type Required Value
token String yes Your API key

Result

[{'id':0,'title':"Russia"}, {'id':3,'title':"China"}]

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": "Wrong token!"}

Get list of all services

https://api.sms-man.com/control/applications?token=$token

Parameters

Field Type Required Value
token String yes Your API key

Result

[{'id':'1','name':"Vkontakte", "code":"vk"}, {'id':'2','name':"WeChat", "code": "wb"}, {'id':'3','name':"Telegram", "code":"tg"}]

Possible errors

{"success":false,"error_code":"wrong_token","error_msg": "Wrong token!"}
{{country.title}}
{{country.id}}
logo {{service.title}}
{{service.id}}
×

Accept