Планы контроля доступа API 1.7.0
Методы API для работы с разделом «Планы контроля доступа».
Базовый путь: https://{IP_контроллера}/api/v1.
Версия описания API: 1.7.0.
Примеры используют placeholder-значения для паролей, token, UUID, адресов и секретов. Перед выполнением запроса замените их на значения вашего контроллера.
Методы раздела
| Метод | Путь |
|---|---|
GET | /access_control_plans |
POST | /access_control_plans |
GET | /access_control_plans/{id} |
PUT | /access_control_plans/{id} |
DELETE | /access_control_plans/{id} |
GET /access_control_plans
Раздел: Планы контроля доступа.
Возвращает все планы точек прохода
Назначение | URL запроса |
Возвращает все планы точек прохода | https://{IP_контроллера}/api/v1/access_control_plans |
Параметры запроса:
Отсутствуют
Варианты ответа:
Code 200 (Successfully got all access control plans) - удачное выполнение запроса
Название, * - обязательный | Тип | Формат | Назначение |
uuid* | string | pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$ | UUID плана точек прохода |
naturalWidth* | number | Ширина изображения в пикселях | |
floor* | string | Название этажа | |
naturalHeight* | numder | Высота изображения в пикселях | |
markers* | string | Специальные маркеры точек прохода | |
building* | string | Название здания |
Пример:
[
{
"uuid": "bca48880-d254-11ef-aac8-13a3dfc60b04",
"naturalWidth": 1500,
"floor": "Этаж 1",
"naturalHeight": 844,
"markers": "{\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"f7164660-d255-11ef-aac8-13a3dfc60b04\",\"x\":1196.3580293343362,\"y\":443.66152688980816,\"diameter\":14,\"pointUuid\":\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\"},\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"fffc4270-d255-11ef-aac8-13a3dfc60b04\",\"x\":372.8987474540179,\"y\":272.4233759679775,\"diameter\":14,\"pointUuid\":\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\"},\"62683b00-8949-11ee-a75a-35e14a25c30a\":{\"uuid\":\"3f81fa20-2791-11f1-80c8-4b0ada22a4f4\",\"x\":744.4594311027093,\"y\":375.8028154540833,\"diameter\":14,\"pointUuid\":\"62683b00-8949-11ee-a75a-35e14a25c30a\"},\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\":{\"uuid\":\"f4b05820-43e7-11f1-939b-13c1d0185215\",\"x\":539.7085471655038,\"y\":147.16159471292195,\"diameter\":14,\"pointUuid\":\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\"},\"706ad140-3497-11f0-a963-433d3ef5f51c\":{\"uuid\":\"cb2db500-43e8-11f1-b244-21d5ddc3fa06\",\"x\":876.5051055790509,\"y\":479.55060020555385,\"diameter\":14,\"pointUuid\":\"706ad140-3497-11f0-a963-433d3ef5f51c\"},\"5f521240-4f78-11f1-95bf-f922e0d3c563\":{\"uuid\":\"c83e5650-4fa6-11f1-a0ab-31c0200a882e\",\"x\":1154.1292574412555,\"y\":282.4956952124506,\"diameter\":14,\"pointUuid\":\"5f521240-4f78-11f1-95bf-f922e0d3c563\"}}",
"building": "1"
}
]
Code 500 (Unexpected server error) - запрос не выполнен, получено сообщение об ошибке
Параметры и ответы по OpenAPI
{
"description": "got all access control plans",
"responses": {
"200": {
"description": "Successfully got all access control plans",
"content": {
"application/json": {
"schema": {
"type": "array",
"items": {
"type": "object",
"required": [
"uuid",
"building",
"floor",
"naturalWidth",
"naturalHeight",
"markers"
],
"properties": {
"uuid": {
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"building": {
"type": "string"
},
"floor": {
"type": "string"
},
"naturalWidth": {
"type": "number"
},
"naturalHeight": {
"type": "number"
},
"markers": {
"type": "string"
}
}
}
}
}
}
},
"500": {
"description": "Something went wrong. It seems there is a bug on server",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
}
}
}
Примеры по OpenAPI
Сформированы по схеме контроллера; значения полей необходимо заменить.
Пример запроса
curl -k -X GET "https://{IP_контроллера}/api/v1/access_control_plans" \
-H "Authorization: Bearer <token>"
Пример ответа
[
{
"uuid": "string",
"building": "string",
"floor": "string",
"naturalWidth": 1.0,
"naturalHeight": 1.0,
"markers": "string"
}
]
POST /access_control_plans
Раздел: Планы контроля доступа.
Создает план точек прохода
Назначение | URL запроса |
Создает план точек прохода | https://{IP_контроллера}/api/v1/access_control_plans |
Параметры запроса:
Название | Тип | Описание | |
access_control_plans* | object(body) | Тело запроса | |
BODY | |||
Название * - обязательный | Тип | Формат | Назначение |
uuid* | string | pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$ | UUID плана точек прохода |
building* | string | Название здания | |
floor* | string | Название этажа | |
naturalWidth* | number | Ширина изображения в пикселях | |
naturalHeight* | namder | Высота изображения в пикселях | |
markers* | string | Специальные маркеры точек прохода | |
Пример:
URL запроса: POST
https://{IP_контроллера}/api/v1/access_control_plans
Body
{
"uuid": "bca48880-d254-11ef-aac8-13a3dfc60b04",
"building": "1",
"floor": "Этаж 1",
"naturalWidth": 1500,
"naturalHeight": 844,
"markers": "{\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"f7164660-d255-11ef-aac8-13a3dfc60b04\",\"x\":1196.3580293343362,\"y\":443.66152688980816,\"diameter\":14,\"pointUuid\":\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\"},\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"fffc4270-d255-11ef-aac8-13a3dfc60b04\",\"x\":372.8987474540179,\"y\":272.4233759679775,\"diameter\":14,\"pointUuid\":\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\"},\"62683b00-8949-11ee-a75a-35e14a25c30a\":{\"uuid\":\"3f81fa20-2791-11f1-80c8-4b0ada22a4f4\",\"x\":744.4594311027093,\"y\":375.8028154540833,\"diameter\":14,\"pointUuid\":\"62683b00-8949-11ee-a75a-35e14a25c30a\"},\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\":{\"uuid\":\"f4b05820-43e7-11f1-939b-13c1d0185215\",\"x\":539.7085471655038,\"y\":147.16159471292195,\"diameter\":14,\"pointUuid\":\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\"},\"706ad140-3497-11f0-a963-433d3ef5f51c\":{\"uuid\":\"cb2db500-43e8-11f1-b244-21d5ddc3fa06\",\"x\":876.5051055790509,\"y\":479.55060020555385,\"diameter\":14,\"pointUuid\":\"706ad140-3497-11f0-a963-433d3ef5f51c\"},\"5f521240-4f78-11f1-95bf-f922e0d3c563\":{\"uuid\":\"c83e5650-4fa6-11f1-a0ab-31c0200a882e\",\"x\":1154.1292574412555,\"y\":282.4956952124506,\"diameter\":14,\"pointUuid\":\"5f521240-4f78-11f1-95bf-f922e0d3c563\"}}"
}
Варианты ответа:
Code 200 (Successfully post access control plan) - удачное выполнение запроса
{
"success": false,
"message": "string",
"data": {}
}
Code 500 (Unexpected server error) - запрос не выполнен, получено сообщение об ошибке
Параметры и ответы по OpenAPI
{
"description": "post access_control_plans",
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"uuid",
"building",
"floor",
"naturalWidth",
"naturalHeight",
"markers"
],
"properties": {
"uuid": {
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"building": {
"type": "string"
},
"floor": {
"type": "string"
},
"naturalWidth": {
"type": "number"
},
"naturalHeight": {
"type": "number"
},
"markers": {
"type": "string"
}
}
}
}
}
},
"responses": {
"200": {
"description": "Successfully post access control plan",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"500": {
"description": "Something went wrong. It seems there is a bug on server",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
}
}
}
Примеры по OpenAPI
Сформированы по схеме контроллера; значения полей необходимо заменить.
Пример запроса
curl -k -X POST "https://{IP_контроллера}/api/v1/access_control_plans" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
--data-raw '{
"uuid": "string",
"building": "string",
"floor": "string",
"naturalWidth": 1.0,
"naturalHeight": 1.0,
"markers": "string"
}'
Пример тела запроса
{
"uuid": "string",
"building": "string",
"floor": "string",
"naturalWidth": 1.0,
"naturalHeight": 1.0,
"markers": "string"
}
Пример ответа
{
"success": false,
"message": "string",
"data": {}
}
GET /access_control_plans/{id}
Раздел: Планы контроля доступа.
Возвращает план точки прохода по id
Назначение | URL запроса |
Возвращает план точки прохода по id | https://{IP_контроллера}/api/v1/access_control_plans/{id} |
Параметры запроса:
Наименование, * - обязательный | Описание |
id* string (path) | Уникальный идентификатор плана |
Варианты ответа:
Code 200 (Successfully got access control plan by name) - удачное выполнение запроса
Название, * - обязательный | Тип | Формат | Назначение |
uuid* | string | pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$ | UUID плана точек прохода |
naturalWidth* | number | Ширина изображения в пикселях | |
floor* | string | Название этажа | |
naturalHeight* | number | Высота изображения в пикселях | |
markers* | string | Специальные маркеры точек прохода | |
building* | string | Название здания |
Пример:
{
"uuid": "bca48880-d254-11ef-aac8-13a3dfc60b04",
"naturalWidth": 1500,
"floor": "Этаж 1",
"naturalHeight": 844,
"markers": "{\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"f7164660-d255-11ef-aac8-13a3dfc60b04\",\"x\":1196.3580293343362,\"y\":443.66152688980816,\"diameter\":14,\"pointUuid\":\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\"},\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"fffc4270-d255-11ef-aac8-13a3dfc60b04\",\"x\":372.8987474540179,\"y\":272.4233759679775,\"diameter\":14,\"pointUuid\":\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\"},\"62683b00-8949-11ee-a75a-35e14a25c30a\":{\"uuid\":\"3f81fa20-2791-11f1-80c8-4b0ada22a4f4\",\"x\":744.4594311027093,\"y\":375.8028154540833,\"diameter\":14,\"pointUuid\":\"62683b00-8949-11ee-a75a-35e14a25c30a\"},\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\":{\"uuid\":\"f4b05820-43e7-11f1-939b-13c1d0185215\",\"x\":539.7085471655038,\"y\":147.16159471292195,\"diameter\":14,\"pointUuid\":\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\"},\"706ad140-3497-11f0-a963-433d3ef5f51c\":{\"uuid\":\"cb2db500-43e8-11f1-b244-21d5ddc3fa06\",\"x\":876.5051055790509,\"y\":479.55060020555385,\"diameter\":14,\"pointUuid\":\"706ad140-3497-11f0-a963-433d3ef5f51c\"},\"5f521240-4f78-11f1-95bf-f922e0d3c563\":{\"uuid\":\"c83e5650-4fa6-11f1-a0ab-31c0200a882e\",\"x\":1154.1292574412555,\"y\":282.4956952124506,\"diameter\":14,\"pointUuid\":\"5f521240-4f78-11f1-95bf-f922e0d3c563\"}}",
"building": "1"
}
Code 400 (Bad request parameters) - запрос не выполнен, неверно указаны параметры запроса
Code 404 (Specified access control plan does not exist) - запрос не выполнен, указанный план не найден
Code 500 (Unexpected server error) - запрос не выполнен, получено сообщение об ошибке
Параметры и ответы по OpenAPI
{
"description": "Get access control plan by id",
"parameters": [
{
"in": "path",
"name": "id",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "Successfully got access control plan by name",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"uuid",
"building",
"floor",
"naturalWidth",
"naturalHeight",
"markers"
],
"properties": {
"uuid": {
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"building": {
"type": "string"
},
"floor": {
"type": "string"
},
"naturalWidth": {
"type": "number"
},
"naturalHeight": {
"type": "number"
},
"markers": {
"type": "string"
}
}
}
}
}
},
"400": {
"description": "Bad request",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"404": {
"description": "Specified access control plan does not exist",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"500": {
"description": "Something went wrong. It seems there is a bug on server",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
}
}
}
Примеры по OpenAPI
Сформированы по схеме контроллера; значения полей необходимо заменить.
Пример запроса
curl -k -X GET "https://{IP_контроллера}/api/v1/access_control_plans/{id}" \
-H "Authorization: Bearer <token>"
Пример ответа
{
"uuid": "string",
"building": "string",
"floor": "string",
"naturalWidth": 1.0,
"naturalHeight": 1.0,
"markers": "string"
}
PUT /access_control_plans/{id}
Раздел: Планы контроля доступа.
Обновляет план точек прохода по id
Назначение | URL запроса |
Обновляет план точек прохода по id | https://{IP_контроллера}/api/v1/access_control_plans/{id} |
Параметры запроса:
Название | Тип | Описание | |
id* | string (path) | Уникальный идентификатор плана | |
BODY | |||
Название * - обязательный | Тип | Формат | Назначение |
uuid* | string | pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$ | UUID плана точек прохода |
building* | string | Название здания | |
floor* | string | Название этажа | |
naturalWidth* | number | Ширина изображения в пикселях | |
naturalHeight* | namder | Высота изображения в пикселях | |
markers* | string | Специальные маркеры точек прохода | |
Пример:
URL запроса: PUT
https://{IP_контроллера}/api/v1/access_control_plans/{id}
Body
{
"uuid": "bca48880-d254-11ef-aac8-13a3dfc60b04",
"building": "1",
"floor": "Этаж 1",
"naturalWidth": 1500,
"naturalHeight": 844,
"markers": "{\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"f7164660-d255-11ef-aac8-13a3dfc60b04\",\"x\":1196.3580293343362,\"y\":443.66152688980816,\"diameter\":14,\"pointUuid\":\"5ed8b170-be98-11ee-8f50-cf4fc1bd5dc6\"},\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\":{\"uuid\":\"fffc4270-d255-11ef-aac8-13a3dfc60b04\",\"x\":372.8987474540179,\"y\":272.4233759679775,\"diameter\":14,\"pointUuid\":\"9bc61320-be98-11ee-8f50-cf4fc1bd5dc6\"},\"62683b00-8949-11ee-a75a-35e14a25c30a\":{\"uuid\":\"3f81fa20-2791-11f1-80c8-4b0ada22a4f4\",\"x\":744.4594311027093,\"y\":375.8028154540833,\"diameter\":14,\"pointUuid\":\"62683b00-8949-11ee-a75a-35e14a25c30a\"},\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\":{\"uuid\":\"f4b05820-43e7-11f1-939b-13c1d0185215\",\"x\":539.7085471655038,\"y\":147.16159471292195,\"diameter\":14,\"pointUuid\":\"c39ea560-eaad-11ee-9cb8-d9a87b0ee6b4\"},\"706ad140-3497-11f0-a963-433d3ef5f51c\":{\"uuid\":\"cb2db500-43e8-11f1-b244-21d5ddc3fa06\",\"x\":876.5051055790509,\"y\":479.55060020555385,\"diameter\":14,\"pointUuid\":\"706ad140-3497-11f0-a963-433d3ef5f51c\"},\"5f521240-4f78-11f1-95bf-f922e0d3c563\":{\"uuid\":\"c83e5650-4fa6-11f1-a0ab-31c0200a882e\",\"x\":1154.1292574412555,\"y\":282.4956952124506,\"diameter\":14,\"pointUuid\":\"5f521240-4f78-11f1-95bf-f922e0d3c563\"}}"
}
Варианты ответа:
Code 200 (Successfully updated access control plan with specified name) - удачное выполнение запроса
{
"success": false,
"message": "string",
"data": {}
}
Code 400 (Bad request parameters) - запрос не выполнен, неверно указаны параметры запроса
Code 404 (Specified access control plan does not exist) - запрос не выполнен, план, указанный в {id} не найден
Code 500 (Unexpected server error) - запрос не выполнен, получено сообщение об ошибке
Параметры и ответы по OpenAPI
{
"description": "Update access control plan",
"parameters": [
{
"in": "path",
"name": "id",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"uuid",
"building",
"floor",
"naturalWidth",
"naturalHeight",
"markers"
],
"properties": {
"uuid": {
"type": "string",
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[089abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$"
},
"building": {
"type": "string"
},
"floor": {
"type": "string"
},
"naturalWidth": {
"type": "number"
},
"naturalHeight": {
"type": "number"
},
"markers": {
"type": "string"
}
}
}
}
}
},
"responses": {
"200": {
"description": "Successfully updated access control plan with specified name",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"400": {
"description": "Bad request",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"404": {
"description": "Specified access control plan does not exist",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"500": {
"description": "Something went wrong. It seems there is a bug on server",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
}
}
}
Примеры по OpenAPI
Сформированы по схеме контроллера; значения полей необходимо заменить.
Пример запроса
curl -k -X PUT "https://{IP_контроллера}/api/v1/access_control_plans/{id}" \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
--data-raw '{
"uuid": "string",
"building": "string",
"floor": "string",
"naturalWidth": 1.0,
"naturalHeight": 1.0,
"markers": "string"
}'
Пример тела запроса
{
"uuid": "string",
"building": "string",
"floor": "string",
"naturalWidth": 1.0,
"naturalHeight": 1.0,
"markers": "string"
}
Пример ответа
{
"success": false,
"message": "string",
"data": {}
}
DELETE /access_control_plans/{id}
Раздел: Планы контроля доступа.
Удаляет план точек прохода по id
Назначение | URL запроса |
Удаляет план точек прохода по id | https://{IP_контроллера}/api/v1/access_control_plans/{id} |
Параметры запроса:
Наименование, * - обязательный | Описание |
id* string (path) | Уникальный идентификатор плана |
Варианты ответа:
Code 200 (Successfully deleted access control plans) - удачное выполнение запроса
Пример:
{
"success": false,
"message": "string",
"data": {}
}
Code 400 (Bad request parameters) - запрос не выполнен, неверно указаны параметры запроса
Code 404 (Access control plan does not exist) - запрос не выполнен, указанный в {id} план не найден
Code 500 (Unexpected server error) - запрос не выполнен, получено сообщение об ошибке
Параметры и ответы по OpenAPI
{
"description": "Delete access control plan",
"parameters": [
{
"in": "path",
"name": "id",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "Successfully deleted access control plans",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"400": {
"description": "Bad request",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"404": {
"description": "access control plan does not exist",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
},
"500": {
"description": "Something went wrong. It seems there is a bug on server",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"success"
],
"properties": {
"success": {
"type": "boolean",
"example": false
},
"message": {
"type": "string"
},
"data": {
"type": "object"
}
}
}
}
}
}
}
}
Примеры по OpenAPI
Сформированы по схеме контроллера; значения полей необходимо заменить.
Пример запроса
curl -k -X DELETE "https://{IP_контроллера}/api/v1/access_control_plans/{id}" \
-H "Authorization: Bearer <token>"
Пример ответа
{
"success": false,
"message": "string",
"data": {}
}