После получения успешного ответа приходит пуш c типом 'generate_report' со ссылкой на скачивание отчета
POST /api/admin/v1/reports?type=users_activity
array cameras, Фильтрация по камерам, массив id камер (используется для фильтрации событий, которые относятся к группе system_camera_events).
array
system_camera_events
date from, Дата начала.
date
date to, Дата окончания.
string timezone, Часовой пояс для отображения даты создания в отчете. Пример - Europe/Paris.
string
201 Created
Created
Успешный ответ
{ "id": 6438, "type": "users_activity", "from": "2020-05-24", "to": "2021-05-24", "url": "https://vms.local:8080/storage/", "created_at": "2023-03-09T13:15:35.000000Z" }
401 Unauthorized
Unauthorized
Токен авторизации не передан или не валидный
curl -k --request POST \ --url 'https://your-domain/api/admin/v1/reports?type=users_activity' \ --header 'Content-Type: application/json' \ --header 'Accept: application/json' \ --data '{ "cameras": [], "from": "date", "to": "date", "timezone": "string" }'
$data = array ( 'cameras' => array ( ), 'from' => 'date', 'to' => 'date', 'timezone' => '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/admin/v1/reports?type=users_activity', false, $context);
Please note, these errors can depend on your browser setup.
If this problem persists, please contact our support.