26.09 26.06 26.05 25.12
26.09 26.06 26.05 25.12 Russian English

Manage user module status

Manage user module status

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

Allows individual modules to be activated or blocked independently of the user's overall status. Currently supported modules are: cameras (cameras), intercoms (intercoms), bridges (Bridge devices), and camera-agents (Camera (Agent) cameras).

Example request:

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

Behavior:

  • For cameras the camera access status is updated for the user and all their subusers, and a push notification is sent.cameras_status_changed.

  • For intercoms the status applies to all the user's apartments. Blocking also clears the phone number and access permissions (key, code, face), as with blocking the user entirely.

  • For bridges camera access status is updated for cameras connected through Bridge for the user and all their subusers, and blocked_at is set or removed for the user's Bridge devices.

  • For camera-agents the behavior is the same as for bridges but applies to cameras connected through Camera (Agent).

  • For bridges/camera-agents: when blocked, the permission bridges/camera-agents is also revoked from subusers. Reactivating the module does not restore it automatically: camera access (camera_user) and the primary user's permission are restored, but subuser permissions must be granted separately.

Method parameters

string login, User login


string module, User module. Allowed values: `cameras`, `intercoms`, `bridges`, `camera-agents`


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

204  No Content

Successful response

422  Unprocessable Entity

Returns a JSON error object.

For more information, see General information > Validation.

JSON
{
    "message": "No informative message is provided here",
    "errors": {
        "any_key": [
            "The reason for the error is 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);