openapi: 3.0.3 info: title: VRt.Admin [AD] version: 7.6.2491 license: name: Proprietary url: https://veeroute.ru/ termsOfService: https://veeroute.ru/resources/terms_of_service contact: name: Veeroute Support Team email: servicedesk@veeroute.com x-logo: url: ../images/admin.svg backgroundColor: '#FAFAFA' altText: VRt.Admin description: '# Описание Программный интерфейс для администрирования Veeroute. ## Диаграмма сущностей ![erd](../uml/admin.svg) ' servers: - url: https://api.edge7.veeroute.cloud description: Окружение для интеграции и ознакомления с новой функциональностью - url: https://api.prod7.veeroute.cloud description: Основное окружение security: - ApiKeyAuth: [] tags: - name: Companies description: 'Управление компаниями. ' - name: Users description: 'Управление пользователями. ' - name: Audit description: 'Пользовательские действия. ' - name: Data description: 'Пользовательские данные. ' - name: Statistics description: 'Статистика. ' - name: Quotas description: 'Квотирование. ' - name: System description: 'Системные функции. Вспомогательный функционал, общий для всех сервисов. ' externalDocs: description: Сайт компании Veeroute url: https://veeroute.ru/ paths: /admin/statistics: get: tags: - Statistics summary: Статистика за период description: 'Статистика по пользователям за период. Если пользователь не указывается - статистика возвращается по всем пользователям. Если период не указывается - возвращается статистика за текущий месяц (с начала месяца по текущий день, не включая текущий день). Если дата `с` не указана - берется начало текущего месяца. Если дата `по` не указана - берется текущий день (не включая его). Пустые поля сервиса и типа процесса означают возвращать статистику по всем сервисами и типам процесса. ' operationId: generate_statistics parameters: - $ref: '#/components/parameters/username_qr' - $ref: '#/components/parameters/date_from' - $ref: '#/components/parameters/date_to' - $ref: '#/components/parameters/service_qr' - $ref: '#/components/parameters/process_type_qr' responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/statistics_result' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/report: get: tags: - Statistics summary: Создание отчета description: 'Отчет по пользователям за период. Если пользователь не указывается - отчет возвращается по всем пользователям. Если период не указывается - возвращается отчет за текущий месяц (с начала месяца по текущий день, не включая текущий день). Если дата `с` не указана - берется начало текущего месяца. Если дата `по` не указана - берется текущий день (не включая его). Пустые поля сервиса и типа процесса означают возвращать статистику по всем сервисами и типам процесса. ' operationId: generate_report parameters: - $ref: '#/components/parameters/username_qr' - $ref: '#/components/parameters/date_from' - $ref: '#/components/parameters/date_to' - $ref: '#/components/parameters/service_qr' - $ref: '#/components/parameters/process_type_qr' responses: '200': description: Отчет успешно создан content: application/octet-stream: schema: $ref: '#/components/schemas/file_xlsx' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/quota/{username}: parameters: - $ref: '#/components/parameters/username_pt' post: tags: - Quotas summary: Установка квот description: Установка квот для пользователя. operationId: update_quota requestBody: description: Запрос на изменение квоты. required: true content: application/json: schema: $ref: '#/components/schemas/quota_base' responses: '200': description: Квота успешно обновлена. '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' get: tags: - Quotas summary: Чтение списка квот description: Чтение списка квот по пользователю. operationId: read_quota responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/quotas_result' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' delete: tags: - Quotas summary: Удаление квот description: Удаление квоты для пользователя. operationId: delete_quota responses: '204': description: Основная квота удалена '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/audit: get: tags: - Audit summary: Действия пользователей description: 'Действия пользователей. Если период не указывается - возвращаются данные за текущий день - с начала дня по текущее время включительно. Если имя пользователя не указывается - обрабатываются данные по всем пользователям. ' operationId: read_audit_data parameters: - $ref: '#/components/parameters/company_key_qr' - $ref: '#/components/parameters/username_qr' - $ref: '#/components/parameters/offset' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/datetime_from' - $ref: '#/components/parameters/datetime_to' - $ref: '#/components/parameters/service_qr' - $ref: '#/components/parameters/operation_qr' - $ref: '#/components/parameters/process_type_qr' - $ref: '#/components/parameters/status_qr' - $ref: '#/components/parameters/sort_field' - $ref: '#/components/parameters/sort_direction' responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/audit_result' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/companies: post: tags: - Companies summary: Создание компании description: Создание новой компании. operationId: create_company requestBody: description: Запрос на создание компании. required: true content: application/json: schema: $ref: '#/components/schemas/company' responses: '201': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/company' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' put: tags: - Companies summary: Обновление компании description: Обновление информации о комании. operationId: update_company requestBody: description: Запрос на обновление компании. required: true content: application/json: schema: $ref: '#/components/schemas/company' responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/company' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' get: tags: - Companies summary: Список компаний description: Получение списка компаний. operationId: read_companies parameters: - $ref: '#/components/parameters/offset' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/filter' - $ref: '#/components/parameters/sort_field' - $ref: '#/components/parameters/sort_direction' responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/company_list' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/companies/{company_key}: parameters: - $ref: '#/components/parameters/company_key_pt' get: tags: - Companies summary: Чтение компании description: Получение информации о компании по ее ключу. operationId: read_company responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/company' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' delete: tags: - Companies summary: Удаление компании description: Удаление компании. operationId: delete_company responses: '204': description: Успешное выполнение '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/users: post: tags: - Users summary: Создание пользователя description: Создание нового пользователя. operationId: create_user requestBody: description: Запрос на создание пользователя. required: true content: application/json: schema: $ref: '#/components/schemas/user' responses: '201': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/user' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' put: tags: - Users summary: Обновление пользователя description: 'Обновление информации о пользователе по его логину. Поле username изменить нельзя. ' operationId: update_user requestBody: description: Запрос на обновление пользователя. required: true content: application/json: schema: $ref: '#/components/schemas/user' responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/user' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' get: tags: - Users summary: Список пользователей description: Получение списка пользователей. operationId: read_users parameters: - $ref: '#/components/parameters/offset' - $ref: '#/components/parameters/limit' - $ref: '#/components/parameters/filter' - $ref: '#/components/parameters/sort_field' - $ref: '#/components/parameters/sort_direction' - $ref: '#/components/parameters/company_key_qr' - name: user_group description: Логические группы пользователей. in: query required: false schema: $ref: '#/components/schemas/user_groups' responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/user_list' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/users/{username}: parameters: - $ref: '#/components/parameters/username_pt' get: tags: - Users summary: Информация о пользователе description: Получение информации о пользователе по его логину. operationId: read_user responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/user' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' delete: tags: - Users summary: Удаление пользователя description: Удаление пользователя по его логину. operationId: delete_user responses: '204': description: Успешное выполнение - пользователь удален '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/data/{process_code}: get: tags: - Data summary: Чтение данных description: Получение данных по `tracedata.process_code`. operationId: read_data parameters: - $ref: '#/components/parameters/process_code_pt' - $ref: '#/components/parameters/data_flow_type' - $ref: '#/components/parameters/data_flow_stage' responses: '200': description: Успешное выполнение content: application/octet-stream: schema: $ref: '#/components/schemas/file_binary' '400': $ref: '#/components/responses/400' '401': $ref: '#/components/responses/401' '402': $ref: '#/components/responses/402' '403': $ref: '#/components/responses/403' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/system/check: get: tags: - System summary: Проверка доступности description: Проверка доступности сервиса. operationId: check security: [] responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/check_result' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/system/version: get: tags: - System summary: Получение версии сервиса description: Получение версии сервиса. operationId: version security: [] responses: '200': description: Успешное выполнение content: application/json: schema: $ref: '#/components/schemas/version_result' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' /admin/file/{filename}: parameters: - $ref: '#/components/parameters/filename_pt' get: tags: - System summary: Получение документации description: Получение файла с документацией на этот сервис. operationId: file security: [] responses: '200': description: Успешное выполнение content: text/html: schema: $ref: '#/components/schemas/file_html' text/plain: schema: $ref: '#/components/schemas/file_json' '404': $ref: '#/components/responses/404' '405': $ref: '#/components/responses/405' '406': $ref: '#/components/responses/406' '415': $ref: '#/components/responses/415' '429': $ref: '#/components/responses/429' '500': $ref: '#/components/responses/500' '501': $ref: '#/components/responses/501' '502': $ref: '#/components/responses/502' '503': $ref: '#/components/responses/503' '504': $ref: '#/components/responses/504' default: $ref: '#/components/responses/503' components: securitySchemes: ApiKeyAuth: description: "Для [аутентификации](https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication)\ \ клиента \nиспользуется [JWT токен](https://ru.wikipedia.org/wiki/JSON_Web_Token),\ \ \nкоторый необходимо указывать в заголовке для каждого запроса в формате:\n\ \n`Authorization: Bearer `.\n\nУникальный токен для пользовательского\ \ аккаунта необходимо получить с помощью VRt.Account API.\n" type: http scheme: bearer bearerFormat: JWT schemas: user_username: description: Уникальное имя пользователя для авторизации. type: string pattern: \w+ minLength: 2 maxLength: 256 example: username_for_login service: description: Название сервиса. type: string enum: - UNIVERSAL - ROUTING - ACCOUNT - ADMIN - STUDIO - MONITOR - PACKER - AGRO example: UNIVERSAL process_type: description: "Тип процесса. Уникальность точек считается в рамках одного типа.\ \ \n" type: string enum: - NOTRACE - TRACE - PLAN - ACTUALIZE - CONVERT - VALIDATE - ROUTE - MATRIX example: PLAN process_statistics: description: Статистика по использованию метода сервиса. type: object additionalProperties: false properties: process_type: $ref: '#/components/schemas/process_type' unique_points_per_day: description: Уникальные точки в день. type: integer format: int32 minimum: 0 maximum: 100000000 example: 1500 points_per_day: description: Неуникальные точки в день. type: integer format: int32 minimum: 0 maximum: 100000000 example: 2500 elements_per_day: description: Неуникальные элементы результата в день. type: integer format: int32 minimum: 0 maximum: 100000000 example: 2500 processes_per_day: description: Суммарное количество процессов в день. type: integer format: int32 minimum: 0 maximum: 100000000 example: 776 required: - process_type - unique_points_per_day - points_per_day - elements_per_day - processes_per_day service_statistics: description: Статистика по использованию всех процессов сервиса. type: object additionalProperties: false properties: service: $ref: '#/components/schemas/service' processes: description: Список статистик по использованию процессов указанного сервиса. type: array minItems: 1 maxItems: 100 items: $ref: '#/components/schemas/process_statistics' required: - service - processes date_statistics: description: Статистика за определенную дату. type: object additionalProperties: false properties: date: description: Дата в формате YYYY-MM-DD. type: string format: date example: '2024-08-05' services: description: Список статистик по каждому сервису на указанную дату. type: array minItems: 0 maxItems: 8 items: $ref: '#/components/schemas/service_statistics' required: - date - services user_statistics: description: Статистика по использованию сервисов конкретным пользователем. type: object additionalProperties: false properties: username: $ref: '#/components/schemas/user_username' dates: description: Список статистик по каждому дню для указанного пользователя. type: array minItems: 0 maxItems: 3653 items: $ref: '#/components/schemas/date_statistics' required: - username - dates statistics_result: description: Результат запроса статистики. type: object additionalProperties: false properties: users: description: Список статистик по пользователям. type: array uniqueItems: false minItems: 0 maxItems: 10000000 items: $ref: '#/components/schemas/user_statistics' required: - users process_code: description: 'Уникальный идентификатор процесса. Создается один на процесс, одинаковый для разных запросов по одному процессу. ' type: string format: uuid example: 11111111-2222-3333-4444-555555555555 request_code: description: 'Уникальный идентификатор запроса. Создается новый на каждый запрос. ' type: string format: uuid example: aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee company_key: description: Уникальный идентификатор компании. type: string pattern: \w+ minLength: 3 maxLength: 256 example: smart_company operation: description: Наименование операции (запроса). type: string minLength: 3 maxLength: 256 example: run_plan_calculation tracedata: description: Данные используемые для трассировки запросов. type: object additionalProperties: false properties: process_code: $ref: '#/components/schemas/process_code' request_code: $ref: '#/components/schemas/request_code' username: $ref: '#/components/schemas/user_username' company: $ref: '#/components/schemas/company_key' service: $ref: '#/components/schemas/service' operation: $ref: '#/components/schemas/operation' env: description: Уникальный идентификатор окружения. type: string pattern: \w+ minLength: 2 maxLength: 256 example: edge7 pod: description: Уникальный идентификатор pod. type: string pattern: \w+ minLength: 2 maxLength: 256 example: 11111111-2222-3333-4444-555555555555 time: description: Дата и время вызова метода сервиса в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6). type: string format: date-time example: '2024-08-21T09:30:00+03:00' required: - process_code - request_code - username - company - service - operation - env - pod - time general_400: description: Детализация по ошибке 400. type: object additionalProperties: false properties: tracedata: $ref: '#/components/schemas/tracedata' message: description: Сообщение об ошибке. type: string nullable: true example: Bad Request required: - tracedata general_402: description: Детализация по ошибке 402. type: object additionalProperties: false properties: tracedata: $ref: '#/components/schemas/tracedata' message: description: Сообщение об ошибке. type: string nullable: true example: Payment Required required: - tracedata general_403: description: Детализация по ошибке 403. type: object additionalProperties: false properties: tracedata: $ref: '#/components/schemas/tracedata' message: description: Сообщение об ошибке. type: string nullable: true example: Forbidden required: - tracedata general_404: description: Детализация по ошибке 404. type: object additionalProperties: false properties: resource_key: description: Идентификатор ресурса. type: string nullable: true default: null example: resource_key detail: description: Детализация по ресурсу. type: object additionalProperties: false nullable: true properties: tracedata: $ref: '#/components/schemas/tracedata' required: - tracedata general_429: description: Детализация по ошибке 429. type: object additionalProperties: false properties: tracedata: $ref: '#/components/schemas/tracedata' message: description: Сообщение об ошибке. type: string nullable: true example: Too many requests required: - tracedata general_500: description: Детализация по ошибке 500. type: object additionalProperties: false properties: tracedata: $ref: '#/components/schemas/tracedata' message: description: Сообщение об ошибке. type: string nullable: true example: Internal Server Error required: - tracedata file_xlsx: description: Файл с данными в формате [XLSX](https://ru.wikipedia.org/wiki/Microsoft_Excel). type: string format: byte process_quota: description: 'Квота на тип процессов сервиса. При превышении любой из квот запрос не возвращается с ошибкой превышения квоты. ' type: object additionalProperties: false properties: process_type: $ref: '#/components/schemas/process_type' points_per_request: description: Максимальное количество неуникальных точек на один запрос. type: integer format: int32 minimum: 0 maximum: 1000000 example: 1500 points_per_day: description: Максимальное количество неуникальных точек на один запрос в сутки. type: integer format: int32 minimum: 0 maximum: 100000000 example: 25000 max_concurrent_execution: description: 'Максимальное количество одновременных расчетов. Параметр ограничен сверху максимальным значением для конкретной среды. ' type: integer format: int32 minimum: 0 maximum: 1000 example: 5 required: - process_type - points_per_request - points_per_day - max_concurrent_execution service_quota: description: Квота на сервис. type: object additionalProperties: false properties: service: $ref: '#/components/schemas/service' processes: description: Список квот на типы процессов. type: array minItems: 1 maxItems: 100 items: $ref: '#/components/schemas/process_quota' required: - service - processes quota_base: description: Квота на все сервисы. type: object additionalProperties: false properties: services: description: Список квот на сервисы. type: array uniqueItems: true minItems: 1 maxItems: 8 items: $ref: '#/components/schemas/service_quota' required: - services quotas_result: description: Результат запроса на квоты. type: object additionalProperties: false properties: base: $ref: '#/components/schemas/quota_base' required: - base calculation_status: description: "Статус расчета:\n * `WAITING` - расчет ожидает запуска.\n *\ \ `IN_PROGRESS` - расчет в процессе.\n * `FINISHED_IN_TIME` - расчет корректно\ \ завершился раньше указанного максимального времени.\n * `FINISHED_OUT_OF_TIME`\ \ - расчет завершился, так как закончилось указанное время на расчет, может\ \ влиять на качество результата в худшую сторону.\n * `CANCELED` - расчет\ \ был отменен, так как была получена команда на отмену.\n * `CANCELED_BY_TIMEOUT`\ \ - расчет был отменен автоматически, так как превышено время ожидания в очереди.\n\ \ * `FAILED` - расчет завершился с ошибкой.\n" type: string enum: - WAITING - IN_PROGRESS - FINISHED_IN_TIME - FINISHED_OUT_OF_TIME - CANCELED - CANCELED_BY_TIMEOUT - FAILED example: FINISHED_IN_TIME time_duration: description: Продолжительность временного отрезка в формате [ISO 8601 duration](https://ru.wikipedia.org/wiki/ISO_8601#Durations). type: string format: duration x-custom-format: duration pattern: ^P(?!$)((\d+Y)|(\d+\.\d+Y$))?((\d+M)|(\d+\.\d+M$))?((\d+W)|(\d+\.\d+W$))?((\d+D)|(\d+\.\d+D$))?(T(?=\d)((\d+H)|(\d+\.\d+H$))?((\d+M)|(\d+\.\d+M$))?(\d+(\.\d+)?S)?)??$ minLength: 3 maxLength: 16 default: PT0S example: PT1H45M calculation_info: description: Информация о расчете. type: object additionalProperties: false properties: status: $ref: '#/components/schemas/calculation_status' result_version: description: Версия текущего результата расчета. type: integer format: int32 minimum: 0 maximum: 1000000 example: 133 preparing_time: $ref: '#/components/schemas/time_duration' description: Время подготовки к расчету (конвертация данных), формат [ISO 8601 duration](https://ru.wikipedia.org/wiki/ISO_8601#Durations). business_validation_time: $ref: '#/components/schemas/time_duration' description: Время бизнес-проверки данных, формат [ISO 8601 duration](https://ru.wikipedia.org/wiki/ISO_8601#Durations). math_validation_time: $ref: '#/components/schemas/time_duration' description: Время математической проверки данных, формат [ISO 8601 duration](https://ru.wikipedia.org/wiki/ISO_8601#Durations). waiting_time: $ref: '#/components/schemas/time_duration' description: Время ожидания расчета в очереди, формат [ISO 8601 duration](https://ru.wikipedia.org/wiki/ISO_8601#Durations). calculation_time: $ref: '#/components/schemas/time_duration' description: Время фактического расчета, формат [ISO 8601 duration](https://ru.wikipedia.org/wiki/ISO_8601#Durations). required: - status - result_version - preparing_time - business_validation_time - math_validation_time - waiting_time - calculation_time audit_action_statistics: description: 'Детальная статистика по процессу. ' type: object additionalProperties: false properties: request_points_count: description: Количество неуникальных точек в запросе. type: integer format: int32 minimum: 0 maximum: 100000000 nullable: true default: null example: 1500 result_elements_count: description: Количество запланированных элементов в ответе. type: integer format: int32 minimum: 0 maximum: 100000000 nullable: true default: null example: 500 calculation_info: $ref: '#/components/schemas/calculation_info' required: - calculation_info audit_action: description: Действие пользователя - список запросов, сгруппированный по одному процессу. type: object additionalProperties: false properties: process_code: $ref: '#/components/schemas/process_code' process_type: $ref: '#/components/schemas/process_type' username: $ref: '#/components/schemas/user_username' company: $ref: '#/components/schemas/company_key' service: $ref: '#/components/schemas/service' time: description: Дата и время создания процесса в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6). type: string format: date-time example: '2024-08-21T09:30:00+03:00' requests: description: Список запросов, которые относятся к одному процессу. type: array minItems: 0 maximum: 100000000 items: $ref: '#/components/schemas/tracedata' statistics: $ref: '#/components/schemas/audit_action_statistics' input_file_exists: description: Признак наличия сохраненного входного файла. type: boolean default: false example: true output_file_exists: description: Признак наличия сохраненного выходного файла. type: boolean default: false example: true required: - process_code - process_type - username - company - service - time - requests - statistics audit_counters_detail: description: Детальные счетчики по списку записей. type: object additionalProperties: false properties: total: description: Количество записей. type: integer format: int32 minimum: 0 maximum: 100000000 example: 1 required: - total audit_counters: description: Счетчики по списку записей. type: object additionalProperties: false properties: overall: $ref: '#/components/schemas/audit_counters_detail' filter: $ref: '#/components/schemas/audit_counters_detail' required: - overall - filter audit_result: description: Результат запроса действий по пользователям. type: object additionalProperties: false properties: actions: description: Список действий по пользователям. type: array uniqueItems: false minItems: 0 maxItems: 10000000 items: $ref: '#/components/schemas/audit_action' counters: $ref: '#/components/schemas/audit_counters' required: - actions - counters company: description: Компания. type: object additionalProperties: false properties: key: $ref: '#/components/schemas/company_key' specification: description: Описание компании. type: string nullable: true default: null minLength: 2 maxLength: 256 example: Company full name required: - key company_list_counters_detail: description: Детальная статистика по списку компаний. type: object additionalProperties: false properties: total: description: Количество компаний. type: integer format: int32 minimum: 0 maximum: 100000 example: 1 required: - total company_list_counters: description: Статистика по списку компаний. type: object additionalProperties: false properties: overall: $ref: '#/components/schemas/company_list_counters_detail' description: Общая статистика, не зависит от фильтра. filter: $ref: '#/components/schemas/company_list_counters_detail' description: Статистика по отфильтрованным компаниям. required: - overall - filter company_list: description: Список компаний. type: object additionalProperties: false properties: companies: description: Список компаний. type: array uniqueItems: false minItems: 0 maxItems: 10000000 items: $ref: '#/components/schemas/company' counters: $ref: '#/components/schemas/company_list_counters' required: - companies - counters user_groups: description: Логические группы пользователей. type: string enum: - TOTAL - ACTIVE - BLOCKED - ADMINS default: TOTAL example: ACTIVE user_password: description: Пароль. type: string nullable: true default: null format: password minLength: 10 maxLength: 256 example: long_strong_password writeOnly: true user_specification: description: Описание пользователя. type: string nullable: true default: null minLength: 2 maxLength: 256 example: User full name user_email: description: Почта пользователя. type: string format: email nullable: true default: null minLength: 5 maxLength: 256 example: admin@company.com user_phone: description: Телефон пользователя. type: string nullable: true default: null minLength: 5 maxLength: 32 example: '+71112223333' user_role: description: Роль. type: string enum: - ADMIN - PARTNER - USER - BOT example: USER user_role_list: description: Перечень ролей пользователя. type: array uniqueItems: true minItems: 0 maxItems: 2 items: $ref: '#/components/schemas/user_role' timezone: description: Временная зона. type: integer format: int32 minimum: -12 maximum: 12 default: 0 example: 3 attribute: description: Атрибут. type: object additionalProperties: false properties: key: description: Ключ атрибута. type: string minLength: 1 maxLength: 100 example: attribute_name value: description: Значение атрибута. type: string minLength: 0 maxLength: 2000 example: X51 required: - key - value attributes: description: Атрибуты. Используются для указания служебной информации. type: array minItems: 0 maxItems: 1000 uniqueItems: true default: [] items: $ref: '#/components/schemas/attribute' user: description: Пользователь. type: object additionalProperties: false properties: username: $ref: '#/components/schemas/user_username' password: $ref: '#/components/schemas/user_password' specification: $ref: '#/components/schemas/user_specification' email: $ref: '#/components/schemas/user_email' phone: $ref: '#/components/schemas/user_phone' company_key: $ref: '#/components/schemas/company_key' enabled: description: Статус пользователя. type: boolean default: true example: true roles: $ref: '#/components/schemas/user_role_list' timezone: $ref: '#/components/schemas/timezone' description: Базовая временная зона, которая используется для расчета статистики. edit_date: description: 'Дата и время последнего редактирования в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6). ' type: string format: date-time nullable: true default: null readOnly: true example: '2024-08-21T19:45:00Z' creation_date: description: 'Дата и время создания в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6). ' type: string format: date-time nullable: true default: null readOnly: true example: '2024-08-21T19:45:00Z' attributes: $ref: '#/components/schemas/attributes' required: - username - company_key - roles user_list_counters_detail: description: Детальная статистика по списку пользователей. type: object additionalProperties: false properties: total: description: Количество пользователей. type: integer format: int32 minimum: 0 maximum: 100000 example: 1 active: description: Количество активных. type: integer format: int32 minimum: 0 maximum: 100000 example: 1 blocked: description: Количество заблокированных. type: integer format: int32 minimum: 0 maximum: 100000 example: 1 admins: description: Количество администраторов. type: integer format: int32 minimum: 0 maximum: 100000 example: 1 required: - total - active - blocked - admins user_list_counters: description: Статистика по списку пользователей. type: object additionalProperties: false properties: overall: $ref: '#/components/schemas/user_list_counters_detail' description: Общая статистика, не зависит от фильтра. filter: $ref: '#/components/schemas/user_list_counters_detail' description: Статистика по отфильтрованным пользователям (при расчете статистики не учитываются группы пользователей). required: - overall - filter user_list: description: Список пользователей. type: object additionalProperties: false properties: users: description: Список пользователей. type: array uniqueItems: false minItems: 0 maxItems: 10000000 items: $ref: '#/components/schemas/user' counters: $ref: '#/components/schemas/user_list_counters' required: - users - counters flow_type: description: Тип потока обработки данных. type: string enum: - INPUT - OUTPUT default: INPUT example: OUTPUT file_binary: description: Файл с данными (octet-stream). type: string format: byte check_result: description: Результат проверки работоспособности сервиса. type: object additionalProperties: false properties: health: description: "Текущий показатель здоровья сервиса. \n * `0.0` означает\ \ неготовность сервиса выполнять задачи. \n * `1.0` означает полную\ \ готовность сервиса для выполнения задач.\n" type: number format: double minimum: 0 maximum: 1 example: 0.999 required: - health version_result: description: Версия сервиса. type: object additionalProperties: false properties: major: description: "Версия продукта.\nВ рамках одной версии гарантируется совместимость\ \ общих структур данных между сервисами. \nИзменение версии указывает\ \ на несовместимые с предыдущими версиями продукта (и, соответственно,\ \ всех сервисов) изменения.\n" type: integer format: int32 minimum: 1 maximum: 100 example: 7 minor: description: 'Минорная версия сервиса. Изменение версии указывает на новую функциональность. Обновление имеет обратную совместимость в рамках мажорной версии сервиса. ' type: integer format: int32 minimum: 0 maximum: 111 example: 5 build: description: "Версия сборки. \nИзменяется при обновлении документации\ \ и исправлении ошибок.\n" type: string minLength: 1 maxLength: 64 example: 3754RC required: - major - minor - build file_html: description: Файл с данными в формате [HTML](https://html.spec.whatwg.org/). type: string file_json: description: Файл с данными в формате [JSON](https://www.json.org/). type: string parameters: username_qr: name: username description: Параметр (query) с именем пользователя. in: query required: false schema: $ref: '#/components/schemas/user_username' date_from: name: from description: Дата `от` в формате YYYY-MM-DD. in: query required: false schema: description: Дата `от` в формате YYYY-MM-DD. type: string format: date example: '2024-08-22' date_to: name: to description: Дата `до` (включительно) в формате YYYY-MM-DD. in: query required: false schema: description: Дата `до` (включительно) в формате YYYY-MM-DD. type: string format: date example: '2024-08-26' service_qr: name: service description: Название сервиса. in: query required: false schema: $ref: '#/components/schemas/service' process_type_qr: name: process_type description: Тип процесса. in: query required: false schema: $ref: '#/components/schemas/process_type' username_pt: name: username description: Параметр (path) с именем пользователя. in: path required: true schema: $ref: '#/components/schemas/user_username' company_key_qr: name: company_key description: Параметр (query) с ключом компании. in: query required: false schema: $ref: '#/components/schemas/company_key' offset: name: offset description: Количество пропущенных сущностей до возвращаемого списка. in: query required: false schema: description: Количество пропущенных сущностей до возвращаемого списка. type: integer format: int32 minimum: 0 maximum: 10000000 default: 0 example: 10 limit: name: limit description: Максимальное количество возвращаемых сущностей. in: query required: false schema: description: Максимальное количество возвращаемых сущностей. type: integer format: int32 minimum: 1 maximum: 10000000 default: 100 example: 10 datetime_from: name: from description: 'Дата и время в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6), начиная с которого (включительно) будет производится выгрузка данных. Если не указано - возвращаются данные с начала текущего дня. ' in: query required: false schema: description: 'Дата и время в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6), начиная с которого (включительно) будет производится выгрузка данных. Если не указано - возвращаются данные с начала текущего дня. ' type: string format: date-time example: '2024-08-21T09:30:00+03:00' datetime_to: name: to description: 'Дата и время в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6), до которого (включительно) будет производится выгрузка данных. Если не указано - возвращаются данные до текущего времени. ' in: query required: false schema: description: 'Дата и время в соответствии с [ISO 8601](https://tools.ietf.org/html/rfc3339#section-5.6), до которого (включительно) будет производится выгрузка данных. Если не указано - возвращаются данные до текущего времени. ' type: string format: date-time example: '2024-08-21T18:00:00+03:00' operation_qr: name: operation description: Название операции. in: query required: false schema: $ref: '#/components/schemas/operation' status_qr: name: status description: Статус процесса. in: query required: false schema: $ref: '#/components/schemas/calculation_status' sort_field: name: sort_field description: Поле, по которому необходимо делать сортировку. in: query required: false schema: description: Поле, по которому необходимо делать сортировку. type: string minLength: 1 maxLength: 64 example: name sort_direction: name: sort_direction description: Направление сортировки. in: query required: false schema: description: Направление сортировки. type: string nullable: false enum: - ASC - DESC default: ASC example: DESC filter: name: filter description: Фильтр для поиска по текстовым полям. in: query required: false schema: description: Фильтр для поиска по текстовым полям. type: string minLength: 1 maxLength: 64 example: example text company_key_pt: name: company_key description: Параметр (path) с ключом компании. in: path required: true schema: $ref: '#/components/schemas/company_key' process_code_pt: name: process_code description: Уникальный идентификатор процесса. in: path required: true schema: $ref: '#/components/schemas/process_code' data_flow_type: name: data_flow_type description: Тип потока обработки данных. in: query required: false schema: $ref: '#/components/schemas/flow_type' data_flow_stage: name: data_flow_stage description: Этап потока обработки данных. in: query required: false schema: description: "Этап потока обработки данных:\n * `RAW` - сырые данные, полученные\ \ от клиента или отправленные клиенту\n" type: string nullable: false enum: - RAW default: RAW example: RAW filename_pt: name: filename description: Название файла. in: path required: true schema: description: Название файла. type: string minLength: 6 maxLength: 128 example: file_en.html responses: '400': description: Неверный запрос - входные данные содержат ошибки content: application/json: schema: $ref: '#/components/schemas/general_400' '401': description: Ошибка доступа - неверные реквизиты для авторизации, токен отсутствует или невалиден '402': description: Необходима оплата content: application/json: schema: $ref: '#/components/schemas/general_402' '403': description: Действие запрещено - уровень прав доступа не позволяет совершить данное действие content: application/json: schema: $ref: '#/components/schemas/general_403' '404': description: Запрашиваемая сущность не найдена content: application/json: schema: $ref: '#/components/schemas/general_404' '405': description: Метод запрещен для данного ресурса, проверьте указанный метод (POST, GET, ...) '406': description: Клиент не способен обработать формат ответа, проверьте заголовки '415': description: Неприемлемый формат запроса, проверьте заголовки '429': description: Превышено количество запросов content: application/json: schema: $ref: '#/components/schemas/general_429' '500': description: Внутренняя ошибка сервера content: application/json: schema: $ref: '#/components/schemas/general_500' '501': description: Функциональность не доступна для использования '502': description: Неверный шлюз '503': description: Сервис не доступен '504': description: Шлюз не отвечает