Links

Balance check request

post
http://lk.mysmpp.ru/xml/balance.php
Balance check request
Parameters
Header
Content-type*
String
text/xml; charset=utf-8;
Body
login.value*
String
Your login in the system
password.value*
String
Your password in the system
token.value*
String
You can use a secret key instead of login and password. To obtain it, please contact your manager
Responses
200: OK
If a valid XML document is received
400: Bad Request
If an error occurs in the sent XML document

Deciphering parameters in query responses

Parameter
Data type
Description
money
Int
Fund balance
sms
Int
Number of available SMS messages for this destination
sms.area
String
The direction in which a given quantity of SMS can be shipped
error
String
The error text can take the following values:
  • Incorrect XML document format
  • Incorrect login or password
  • POST data is missing

Example XML request

<?xml  version="1.0" encoding="utf-8" ?>
<request>
<security>
<login value="login" />
<password value="password" />
</security>
</request>
The number of SMS cannot be summarized for different directions. When sending SMS in one direction, the number of available SMS messages in all other directions is reduced according to their cost.

Example

You have 10 y.e. on your balance.
The cost of SMS message sent to Russia is 1 y.e.
The cost of SMS message sent to Ukraine is 2 y.e.
The following XML document will be returned to you:
<?xml version="1.0" encoding="utf-8" ?>
<response>
<money>10</money>
<sms area="Russia">10</sms>
<sms area="Ukraine">5</sms>
</response>
If you send two sms to Russia, the XML document will change as follows:
<?xml version="1.0" encoding="utf-8" ?>
<response>
<money>8</money>
<sms area="Russia">8</sms>
<sms area="Ukraine">4</sms>
</response>
Last modified 5mo ago