Поиск по истории проекта (events/comments)
GET
bearerheader
AuthorizationBearer <token>Токен сервисного аккаунта. См. раздел «Аутентификация».
project_id*numbersort?array<string>По умолчанию
[ "created_at.desc"]type?stringПо умолчанию
"all"Значения
"all""comment""event"count*numberДиапазонот 1 до 1000
offset*numberДиапазонот 0
Тело ответа
responseapplication/json
count*numbersum*numberoffset*numberВозможные ошибки
401Unauthorized
unauthorized: Необходима авторизация
{ "statusCode": 401, "error": "unauthorized", "message": "Необходима авторизация"}403Forbidden
access_denied: Недостаточно прав
{ "statusCode": 403, "error": "access_denied", "message": "Недостаточно прав"}404Not Found
project_not_found: Проект не найден
{ "statusCode": 404, "error": "project_not_found", "message": "Проект не найден"}curl -X GET 'https://org.inspecto.in/api/projects/0/history?count=1&offset=0'Пример ответа
{ "items": [ { "history_type": "event", "id": 0, "user": { "id": 0, "first_name": "string", "last_name": "string", "patronymic": "string", "avatar": "string" }, "type": "create_project", "key": "string", "old_value": 0, "new_value": 0, "description": "string", "data": { "old_value": {}, "new_value": {}, "field": { "id": 4, "key": "equipment", "title": "Оборудование", "type": "string", "multiple": true }, "old_display": "Насос №1", "new_display": "Задвижка №2", "old_items": [ { "value": 12, "label": "Насос №1" } ], "new_items": [ { "value": 12, "label": "Насос №1" } ] }, "created_at": "2019-08-24T14:15:22Z" } ], "count": 0, "sum": 0, "offset": 0}