Breadcrumbs

Manage status of user's modules

User module status management

Allows activating or blocking individual user modules independently of the general user status. Currently supported modules: cameras and intercoms.

Request example:

JSON
{
    "login": "test@mail.com",
    "module": "cameras",
    "status": "blocked"
}

Notes:

  • For cameras, updates camera access status for the user and all their subusers and sends cameras_status_changed push.

  • For intercoms, applies status to all user's flats. When blocking, additionally resets landline number and access flags (key, code, face) similar to global blocking.

POST  /api/v1/billing/user/manage/modules/status

Параметры метода

string login, User login


string module, User module. Allowed values: cameras, intercoms


string status, Module status. Allowed values: active, blocked

204  No Content

Successful response

422  Unprocessable Entity

Returns a JSON object with an error.

JSON
{
    "message": "There will be no informative message here",
    "errors": {
        "any_key": [
            "The cause of the error will be described here"
        ]
    }
}
cURL
Bash
curl -k --request POST \
	--url 'https://your-domain/api/v1/billing/user/manage/modules/status' \
	--header 'Content-Type: application/json' \
	--header 'Accept: application/json' \
	--data '{
    "login": "string",
    "module": "string",
    "status": "string"
}'
PHP
PHP
$data = array (
  'login' => 'string',
  'module' => 'string',
  'status' => 'string',
);
$context = stream_context_create([
	'ssl'=>['verify_peer' => false],
	'http' => [
		'method' => 'POST',
		'header' => "Content-Type: application/json\r
Accept: application/json",
		'content'=>json_encode($data)
	]
]);
$result = file_get_contents('https://your-domain/api/v1/billing/user/manage/modules/status', false, $context);