# Request to get the time of change of something

## Request to get the time of change of something

<mark style="color:green;">`POST`</mark> `http://lk.mysmpp.ru/xml/check_change.php`

#### Headers

| Name                                           | Type   | Description                    |
| ---------------------------------------------- | ------ | ------------------------------ |
| Content-type<mark style="color:red;">\*</mark> | String | **`text/xml; charset=utf-8;`** |

#### Request Body

| Name                                             | Type   | Description                                                                                       |
| ------------------------------------------------ | ------ | ------------------------------------------------------------------------------------------------- |
| login.value<mark style="color:red;">\*</mark>    | String | Your login in the system                                                                          |
| check.obgect<mark style="color:red;">\*</mark>   | String | Object type: database (**`base`**), stop list (**`stop`**)                                        |
| token.value<mark style="color:red;">\*</mark>    | String | You can use a secret key instead of login and password. To obtain it, please contact your manager |
| password.value<mark style="color:red;">\*</mark> | String | Your password in the system                                                                       |
| check.id<mark style="color:red;">\*</mark>       | String | Unique object number                                                                              |

{% tabs %}
{% tab title="200: OK If a valid XML document is received" %}

```xml
<?xml version="1.0" encoding="utf-8" ?>
<response>
    <obgect time_update="2012-01-01 12:12:12" />
</response>
```

{% endtab %}

{% tab title="400: Bad Request If an error occurs in the sent XML document" %}

```xml
<?xml version="1.0" encoding="utf-8"?>
<response>
     <error>Error message</error>
</response>
```

{% endtab %}
{% endtabs %}

### Deciphering parameters in query responses

<table><thead><tr><th width="144.33333333333331">Parameter</th><th width="175">Data type</th><th>Description</th></tr></thead><tbody><tr><td>obgect.time_update</td><td>Int</td><td>Time of last modification of the object</td></tr><tr><td>error</td><td>String</td><td><p>The error text can take the following values:</p><ul><li>Incorrect XML document format </li><li>Incorrect login or password </li><li>POST data is missing</li></ul></td></tr></tbody></table>

### Example XML request

```xml
<?xml  version="1.0" encoding="utf-8" ?>
<request>
     <security>
          <login value="login" />
          <password value="password" />
     </security>
     <check obgect="base" id="1"/>
</request>
```
