Skip to main content
Skip table of contents

Create a DHCP pool group

Create a DHCP pool group

When creating, access to this group is automatically granted to the current administrator. If access needs to be given to other administrators, it can be done through:

POST /api/admin/v1/dhcp-subnet-groups

Method parameters

string title, group name


array users, array of user IDs

200 OK

Successful response

JSON
{
    "id": 64,
    "title": "Group",
    "users": [
        {
            "id": 1,
            "name": "admin",
            "login": "admin@mail.com",
            "created_at": "2021-05-27 15:43:37",
            "updated_at": "2022-05-06 14:19:13",
            "expired_at": null,
            "is_licence_limit_reached": false,
            "ptz_priority": 10,
            "access_token_id": null
        }
    ]
}

400 Bad Request

This error means that DHCP groups are currently unavailable due to the lack of configured DHCP settings.

401 Unauthorized

Authorization token is not provided or is invalid. Obtaining a token

cURL
BASH
curl -k --request POST \
	--url 'https://your-domain/api/admin/v1/dhcp-subnet-groups' \
	--header 'Content-Type: application/json' \
	--header 'Accept: application/json' \
	--data '{
    "title": "string",
    "users": []
}'
PHP
PHP
$data = array (
  'title' => 'string',
  'users' => 
  array (
  ),
);
$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/admin/v1/dhcp-subnet-groups', false, $context);
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.