Pricing plans  Services  API  Partners  About the service  Contacts 
8 (800) 700 7672
Free in Russia
 

Integration with the service (API)

The API allows you to send messages through your projects and services over the HTTP/HTTPS, SMTP, and SMPP protocols. Ready-made libraries in different programming languages connect to your project and help you send messages from anywhere with a single command.


HTTP/HTTPS SMTP SMPP SOAP OMS SMS Commands Libraries and code examples

SENDING MESSAGES

MANAGING MAILING LISTS

MESSAGE STATUSES

CHECKING THE BALANCE STATUS

CONTACT MANAGEMENT

CLIENT MANAGEMENT

MANAGING SENDER NAMES (SENDER ID)

GETTING DATA

VARIOUS

Connecting dedicated numbers for receiving messages

You can use special API commands to get a list of available dedicated numbers for receiving SMS messages and connect any number to your username, paying the cost for the remaining days in the current month. When you connect a dedicated number, you automatically agree to the terms of use of such numbers.

To get a list of available allocated numbers, call the following address using the GET or POST method: https://smscentre.com/sys/receive_phones.php?get=1&login=<login>&psw=<password>
To connect a dedicated number, you need to call the address using the GET or POST method: https://smscentre.com/sys/receive_phones.php?buy=1&login=<login>&psw=<password>&phone=<phone>
To change the attribute of the extension of the allocated number for the next month, you must call the address by the GET or POST method: https://smscentre.com/sys/receive_phones.php?chg=1&login=<login>&psw=<password>&phone=<phone>&noprolong=<noprolong>
Description of the parameters passed to the Server:

OptionThe value
loginCustomer Login.
pswClient Password (you can add or change it on this page).
phonePlug-in number.
noprolongIndicates whether the allocated number is extended for the next month. This parameter can also be specified when connecting the number in the buy command.
0 (default) - enable automatic number renewal.
1 Ц disable automatic number renewal.

If an error occurs, the Server returns the following string:
  • ERROR = N (description)

  • When fmt = 1:
    0,-N

  • When fmt = 2:
    <result>
    <error>description</error>
    <error_code>N</error_code>
    </result>

  • When fmt = 3:
    {
    "error": "description",
    "error_code": N
    }
N Ц error number, can take the following values:

The valueDescription
1Error in parameters.
2Invalid username or password. Also occurs when trying to send a message from an IP address that is not included in the list of allowed by the Client (if such a list was previously configured by the Client).
3Insufficient funds in the account to rent a room.
4The IP address is temporarily blocked.
9Attempt to send more than two identical requests to get a list of available rooms for rent, or to connect a number, or to change the properties of a dedicated number within a minute.
This error also occurs when you try to send fifteen or more requests simultaneously from different connections under the same username (too many concurrent requests).

If the request is successful, the Server returns a response in the form of a string.

To get a list of available numbers:
  • when fmt = 0:
    phone = <phone>, type = <type>, cost = <cost>, current_cost = <current_cost>, info = <info>
    ...

  • when fmt = 1:
    <phone>,<type>,<cost>,<current_cost>,<info>
    ...

  • when fmt = 2:
    <list>
    <receive_phone>
    <phone>phone</phone>
    <type>type</type>
    <cost>cost</cost>
    <current_cost>current_cost</current_cost>
    <info>info</info>
    </receive_phone>
    ...
    </list>

  • when fmt = 3:
    [{
    "phone": "<phone>",
    "type": <type>,
    "cost": "<cost>",
    "current_cost": "<current_cost>"
    "info": "<info>"
    },
    ...]

Where:
<phone> Ц phone number.
<type> Ц number type: 1,4-dedicated virtual number, 2-number on the SIM hosting service.
<cost> Ц the cost of renting a room for a full month.
<current_cost> Ц the cost of renting a room for the remaining days until the end of the current month.
<info> Ц operator name and supported notification types.

To rent a room:
  • when fmt = 0: cost = <cost>

  • when fmt = 1: <cost>

  • when fmt = 2:
    <phone>
    <cost>cost</cost>
    </phone>

  • when fmt = 3:
    {
    "cost": "<cost>"
    }

Where:
<cost> Ц the amount debited from the Client's account for the rental of the room.

To change the extension attribute of the number:
  • when fmt = 0,1: OK

  • when fmt = 2:
    <result>OK</result>

  • when fmt = 3:
    {
    "result": "OK"
    }



Examples:

Getting a list of available rooms for rent:

https://smscentre.com/sys/receive_phones.php?get=1&login=alex&psw=123
Connecting the number " 79999999999":

https://smscentre.com/sys/receive_phones.php?buy=1&login=alex&psw=123&phone=79999999999
Disabling the ability to extend the allocated number "79999999999" for the next month:

https://smscentre.com/sys/receive_phones.php?chg=1&login=alex&psw=123&phone=79999999999&noprolong=1

The server does not accept more than two identical requests within a minute to get a list of available numbers for rent or to connect a number, or to change the properties of the allocated number to reduce the load and protect against errors and loops in the Client-side program.




© 2003Ц2023 SMS Center LLC
License no. 166255
support@smscentre.com
Contacts
Design Ч Artemy Lebedev Studio
Site Information
SMS Center for Android Yandex. Metrica