Robodelivery API
version: 0.0.2
Описание
Асинхронная природа API
API robot разработан как асинхронный, что означает, что операции не завершаются немедленно. Вместо этого они инициируют процессы, завершение которых может занять некоторое время. Такая конструкция обеспечивает лучшую масштабируемость и отзывчивость системы.
Работа с API
POST /claims/createдля создания новой заявки- Назначение робота (автоматически)
- Отслеживание хода выполнения и управление процессом доставки:
- Отслеживание хода выполнения
POST /claims/infoдля текущего статуса заказаPOST /claims/journalдля подробного списка событий- Управление процессом доставки:
POST /claims/open_hatchдля открытия люка роботаPOST /claims/close_hatchдля закрытия люка роботаPOST /claims/confirm_exchangeдля подтверждения погрузки/выгрузкиPOST /claims/cancelдля отмены заказаPOST /claims/returnдля инициирования возврата заказа
Важные статусы заказов
new: заказ создан, но робот еще не назначен.accepted: робот назначен для заказа.pickup_arrived,delivery_arrived: робот прибы. Вы можете открыть люк и погрузить/выгрузить товар.ready_for_pickup_confirmation,ready_for_delivery_confirmation: Люк был открыт как минимум один раз. Закрытие люка не изменит статус. Вам необходимо подтвердить обмен.picked_up,delivered: Обмен подтвержден.
Распространенные паттерны
Ключ идемпотентности
idempotency_key используется для того, чтобы одно и то же действие не выполнялось несколько раз из-за проблем с сетью или случайных дублирующихся запросов. Это обеспечивает согласованность и надежность.
Рекомендации:
- Сгенерируйте ключ идемпотентности для каждого семантически уникального запроса
- Повторите запрос с тем же ключом идемпотентности в случае сбоя сети.
Обработка событий
Мы не предоставляем веб-хуки. Вам следует опросить конечные точки /claims/info или /claims/journal, чтобы получить последний статус претензии и ответить на него в соответствии с вашей бизнес-логикой. Такой подход позволяет вам оставаться в курсе статуса претензии, не полагаясь на push-уведомления.
Обработка ошибок
Внедрите соответствующую обработку ошибок и логику повторных попыток в вашей интеграции, чтобы обеспечить надежную связь с API. Для разных типов ошибок требуются разные политики.
Sections
Specification
Open API
{
"openapi": "3.1.0",
"info": {
"title": "Robodelivery API",
"summary": "\nAPI обеспечивает интеграцию для роботизированных систем доставки. Оно является асинхронным и событийно-ориентированным. Основными возможностями являются:\n- Назначение заказов робота\n- Мониторинг хода доставки в реальном времени\n- Управление роботом\n",
"description": "\n# Описание\n## Асинхронная природа API\nAPI robot разработан как асинхронный, что означает, что операции не завершаются немедленно. Вместо этого они инициируют процессы, завершение которых может занять некоторое время. Такая конструкция обеспечивает лучшую масштабируемость и отзывчивость системы.\n\n## Работа с API\n1. `POST /claims/create` для создания новой заявки\n1. Назначение робота (автоматически)\n1. Отслеживание хода выполнения и управление процессом доставки:\n- Отслеживание хода выполнения\n- `POST /claims/info` для текущего статуса заказа\n- `POST /claims/journal` для подробного списка событий\n- Управление процессом доставки:\n- `POST /claims/open_hatch` для открытия люка робота\n- `POST /claims/close_hatch` для закрытия люка робота\n- `POST /claims/confirm_exchange` для подтверждения погрузки/выгрузки\n- `POST /claims/cancel` для отмены заказа\n- `POST /claims/return` для инициирования возврата заказа\n\n## Важные статусы заказов\n- `new`: заказ создан, но робот еще не назначен.\n- `accepted`: робот назначен для заказа.\n- `pickup_arrived`, `delivery_arrived`: робот прибы. Вы можете открыть люк и погрузить/выгрузить товар.\n- `ready_for_pickup_confirmation`, `ready_for_delivery_confirmation`: Люк был открыт как минимум один раз. Закрытие люка *не* изменит статус. Вам необходимо подтвердить обмен.\n- `picked_up`, `delivered`: Обмен подтвержден.\n\n## Распространенные паттерны\n### Ключ идемпотентности\n`idempotency_key` используется для того, чтобы одно и то же действие не выполнялось несколько раз из-за проблем с сетью или случайных дублирующихся запросов. Это обеспечивает согласованность и надежность.\n\nРекомендации:\n1. Сгенерируйте ключ идемпотентности для каждого семантически уникального запроса\n1. Повторите запрос с тем же ключом идемпотентности в случае сбоя сети.\n\n### Обработка событий\nМы не предоставляем веб-хуки. Вам следует опросить конечные точки `/claims/info` или `/claims/journal`, чтобы получить последний статус претензии и ответить на него в соответствии с вашей бизнес-логикой. Такой подход позволяет вам оставаться в курсе статуса претензии, не полагаясь на push-уведомления.\n\n### Обработка ошибок\nВнедрите соответствующую обработку ошибок и логику повторных попыток в вашей интеграции, чтобы обеспечить надежную связь с API. Для разных типов ошибок требуются разные политики.\n",
"version": "0.0.2"
},
"paths": {
"/claims/create": {
"post": {
"tags": [
"Заказы"
],
"operationId": "create_handler_claims_create_post",
"parameters": [
{
"name": "idempotency_key",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Idempotency key",
"description": "A string used to ensure idempotency of the request."
},
"description": "A string used to ensure idempotency of the request."
}
],
"requestBody": {
"required": true,
"content": {
"application/json": {
"schema": {
"properties": {
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"point_id": {
"type": "string",
"title": "Point Id"
},
"type": {
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
}
},
"type": "object",
"required": [
"address",
"point_id",
"type",
"visit_order"
],
"title": "ClaimRequestPoint"
},
"type": "array",
"maxItems": 3,
"minItems": 2,
"title": "Route Points"
},
"external_order_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Order Id"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"conditions": {
"default": {},
"properties": {
"maximum_first_point_eta": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Maximum First Point Eta",
"description": "Поиск будет ограничен курьерами, которые смогут прибыть в исходную точку до разрешенного расчетного времени прибытия.\n\nСервис ожидает дату и время с указанием часового пояса. Примеры форматов:\n- 2026-01-11 17:26:27.704301+00:00\n- 2026-01-11T19:18:43Z\n\nЕсли часовой пояс не указан, сервис считает, что это UTC+0.\n"
},
"search_until": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Search Until",
"description": "Поиск прекратится по истечении указанного времени и завершится неудачей.\n\nСервис ожидает дату и время с указанием часового пояса. Примеры форматов:\n- 2026-01-11 17:26:27.704301+00:00\n- 2026-01-11T19:18:43Z\n\nЕсли часовой пояс не указан, сервис считает, что это UTC+0.\n"
},
"robot_vins": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "null"
}
],
"title": "Robot Vins",
"description": "Список VIN роботов для рассмотрения для этой заявки. Если указано, только эти роботы будут рассматриваться для назначения"
}
},
"type": "object",
"title": "CreateRequestConditions"
}
},
"type": "object",
"required": [
"route_points"
],
"title": "CreateRequestBody"
}
}
}
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Создать заявку",
"description": "\nСоздаёт новую заявку в системе Robodelivery\n\n`external_order_id` может быть использован для связывания заявки с заказом в внешней системе.\n\nВы можете указать условия для ограничения поиска робота.\n"
}
},
"/claims/info": {
"post": {
"tags": [
"Заказы"
],
"operationId": "info_handler_claims_info_post",
"parameters": [
{
"name": "claim_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Claim ID",
"description": "Claim ID received from `/claims/create`"
},
"description": "Claim ID received from `/claims/create`"
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"courier": {
"oneOf": [
{
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level"
],
"title": "CourierInfo"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision",
"courier"
],
"title": "ClaimWithCourier"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"title": "NotFound",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "NOT_FOUND",
"default": "NOT_FOUND",
"enum": [
"NOT_FOUND"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Получить информацию о заявке",
"description": "Возвращает подробную информацию о конкретной заявке"
}
},
"/claims/journal": {
"post": {
"tags": [
"Заказы"
],
"operationId": "journal_handler_claims_journal_post",
"parameters": [
{
"name": "claim_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Claim ID",
"description": "Claim ID received from `/claims/create`"
},
"description": "Claim ID received from `/claims/create`"
},
{
"name": "date_from",
"in": "query",
"required": false,
"schema": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Date From",
"description": "Начальная дата (включительно)"
},
"description": "Начальная дата (включительно)"
},
{
"name": "date_to",
"in": "query",
"required": false,
"schema": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Date To",
"description": "Конечная дата (исключительно)"
},
"description": "Конечная дата (исключительно)"
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"default": {},
"properties": {
"cursor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Cursor"
}
},
"type": "object",
"title": "JournalRequestBody"
}
}
}
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"cursor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Cursor"
},
"events": {
"items": {
"properties": {
"event_id": {
"type": "string",
"title": "Event Id"
},
"change_type": {
"type": "string",
"title": "Change Type",
"description": "Тип произошедшего изменения. Возможные значения:\n - `order_created`: Заказ был создан\n - `order_changed`: Заказ был изменен\n - `order_completed`: Заказ был завершен\n - `order_cancel_requested`: Запрошена отмена заказа\n - `shift_initialized`: Смена инициализирована\n - `shift_created`: Смена создана\n - `shift_changed`: Смена изменена\n - `shift_completed`: Смена завершена\n - `open_hatch_requested`: Запрошено открытие крышки\n - `close_hatch_requested`: Запрошено закрытие крышки\n - `closed_hatch_detected`: Обнаружена закрытая крышка\n - `battery_change_started`: Начата замена батареи\n - `battery_change_updated`: Обновлена замена батареи\n - `battery_change_finished`: Завершена замена батареи\n - `move_to_base_point`: Перемещение в базовую точку\n - `arrived_to_base_point`: Прибытие в базовую точку\n - `product_detection`: Обнаружение продукта\n - `terminate`: Завершение\n - `abort`: Прерывание\n"
},
"claim_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Claim Id"
},
"courier_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier Id"
},
"shift_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shift Id"
},
"timestamp": {
"type": "string",
"format": "date-time",
"title": "Timestamp"
},
"new_value": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "New Value",
"description": "Возможные значения:\n - `new`: Заказ создан, но робот еще не назначен\n - `picking_up`: Робот назначен и движется к точке получения\n - `pickup_arrived`: Робот прибыл в точку получения\n - `delivering`: Робот движется к точке доставки\n - `delivery_arrived`: Робот прибыл в точку доставки\n - `delivered`: Робот завершил доставку\n - `returning`: Робот возвращается\n - `return_arrived`: Робот прибыл в точку возврата\n - `returned`: Робот завершил возврат\n - `cancelled`: Заказ отменен\n"
},
"courier_coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"event_id",
"change_type",
"claim_id",
"courier_id",
"shift_id",
"timestamp",
"new_value"
],
"title": "JournalEvent"
},
"type": "array",
"title": "Events"
}
},
"type": "object",
"required": [
"cursor",
"events"
],
"title": "JournalListWithCursor"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"title": "NotFound",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "NOT_FOUND",
"default": "NOT_FOUND",
"enum": [
"NOT_FOUND"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Получить журнал событий",
"description": "Возвращает список событий, связанных с заявкой, с использованием пагинации по курсору\n\nПринцип работы курсора:\nКурсор в системе журналов событий работает как указатель на последнее обработанное событие.\n\nПри запросе журнала событий для конкретного claim_id:\n- Система возвращает список событий в обратном хронологическом порядке\n- В ответе содержится cursor - идентификатор последнего события\n- При следующем запросе клиент передает этот курсор, и система возвращает только новые события, произошедшие после указанного\n- Курсор индивидуальный для каждого claim_id - вы можете безопасно сохранять и использовать курсор для конкретной заявки без риска потери событий.\n"
}
},
"/claims/open_hatch": {
"post": {
"tags": [
"Заказы"
],
"operationId": "open_hatch_handler_claims_open_hatch_post",
"parameters": [
{
"name": "claim_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Claim ID",
"description": "Claim ID received from `/claims/create`"
},
"description": "Claim ID received from `/claims/create`"
},
{
"name": "idempotency_key",
"in": "query",
"required": false,
"schema": {
"oneOf": [
{
"type": "string",
"title": "Idempotency key",
"description": "A string used to ensure idempotency of the request."
},
{
"type": "null"
}
],
"title": "Idempotency Key"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Открыть крышку",
"description": "Инициирует процесс открытия крышки робота"
}
},
"/claims/close_hatch": {
"post": {
"tags": [
"Заказы"
],
"operationId": "close_hatch_handler_claims_close_hatch_post",
"parameters": [
{
"name": "claim_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Claim ID",
"description": "Claim ID received from `/claims/create`"
},
"description": "Claim ID received from `/claims/create`"
},
{
"name": "idempotency_key",
"in": "query",
"required": false,
"schema": {
"oneOf": [
{
"type": "string",
"title": "Idempotency key",
"description": "A string used to ensure idempotency of the request."
},
{
"type": "null"
}
],
"title": "Idempotency Key"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"title": "NotFound",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "NOT_FOUND",
"default": "NOT_FOUND",
"enum": [
"NOT_FOUND"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"409": {
"description": "Conflict",
"content": {
"application/json": {
"schema": {
"title": "Conflict",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "CONFLICT",
"default": "CONFLICT",
"enum": [
"CONFLICT"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Закрыть крышку",
"description": "Инициирует процесс закрытия крышки робота"
}
},
"/claims/confirm_exchange": {
"post": {
"tags": [
"Заказы"
],
"operationId": "confirm_exchange_handler_claims_confirm_exchange_post",
"parameters": [
{
"name": "claim_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Claim ID",
"description": "Claim ID received from `/claims/create`"
},
"description": "Claim ID received from `/claims/create`"
},
{
"name": "idempotency_key",
"in": "query",
"required": false,
"schema": {
"oneOf": [
{
"type": "string",
"title": "Idempotency key",
"description": "A string used to ensure idempotency of the request."
},
{
"type": "null"
}
],
"title": "Idempotency Key"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"title": "NotFound",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "NOT_FOUND",
"default": "NOT_FOUND",
"enum": [
"NOT_FOUND"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"409": {
"description": "Conflict",
"content": {
"application/json": {
"schema": {
"title": "Conflict",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "CONFLICT",
"default": "CONFLICT",
"enum": [
"CONFLICT"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Подтвердить обмен",
"description": "Подтверждает обмен (погрузка или выгрузка)"
}
},
"/claims/cancel": {
"post": {
"tags": [
"Заказы"
],
"operationId": "cancel_handler_claims_cancel_post",
"parameters": [
{
"name": "claim_id",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Claim ID",
"description": "Claim ID received from `/claims/create`"
},
"description": "Claim ID received from `/claims/create`"
},
{
"name": "idempotency_key",
"in": "query",
"required": false,
"schema": {
"oneOf": [
{
"type": "string",
"title": "Idempotency key",
"description": "A string used to ensure idempotency of the request."
},
{
"type": "null"
}
],
"title": "Idempotency Key"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"title": "NotFound",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "NOT_FOUND",
"default": "NOT_FOUND",
"enum": [
"NOT_FOUND"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"409": {
"description": "Conflict",
"content": {
"application/json": {
"schema": {
"title": "Conflict",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "CONFLICT",
"default": "CONFLICT",
"enum": [
"CONFLICT"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Отменить заявку",
"description": "Отменяет существующую заявку"
}
},
"/claims/search": {
"post": {
"tags": [
"Заказы"
],
"operationId": "search_handler_claims_search_post",
"requestBody": {
"content": {
"application/json": {
"schema": {
"default": {
"limit": 1000,
"offset": 0,
"filters": {},
"order": [],
"include_totals": true
},
"properties": {
"limit": {
"type": "integer",
"maximum": 1000,
"minimum": 1,
"title": "Limit",
"default": 1000
},
"offset": {
"type": "integer",
"minimum": 0,
"title": "Offset",
"default": 0
},
"created_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created From"
},
"created_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created To"
},
"external_order_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Order Id"
},
"filters": {
"default": {},
"properties": {
"status_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Status In"
},
"status_not_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Status Not In"
},
"id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"created_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created From"
},
"created_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created To"
},
"updated_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Updated From"
},
"updated_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Updated To"
},
"finished_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished From"
},
"finished_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished To"
},
"courier": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier"
}
},
"type": "object",
"title": "SearchRequestFilters"
},
"order": {
"type": "array",
"items": {
"type": "string"
},
"maxItems": 2,
"minItems": 2,
"title": "Order",
"default": [],
"description": "В первом элементе массива нужно передать названия полей сортировки через запятую. Во втором элементе - направление сортировки `asc` или `desc`."
},
"include_totals": {
"type": "boolean",
"title": "Include Totals",
"default": true
}
},
"type": "object",
"title": "SearchRequestBody"
}
}
}
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"meta": {
"properties": {
"totals": {
"oneOf": [
{
"additionalProperties": {
"type": "integer"
},
"propertyNames": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "object"
},
{
"type": "null"
}
],
"title": "Totals"
}
},
"type": "object",
"title": "SearchResponseBodyMeta"
},
"claims": {
"items": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"courier": {
"oneOf": [
{
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level"
],
"title": "CourierInfo"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision",
"courier"
],
"title": "ClaimWithCourier"
},
"type": "array",
"title": "Claims"
}
},
"type": "object",
"required": [
"meta",
"claims"
],
"title": "SearchResponseBody"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"UNAUTHORIZED"
],
"const": "UNAUTHORIZED",
"title": "Error code",
"default": "UNAUTHORIZED"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "Unauthorized"
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"FORBIDDEN"
],
"const": "FORBIDDEN",
"title": "Error code",
"default": "FORBIDDEN"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "Forbidden"
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"NOT_FOUND"
],
"const": "NOT_FOUND",
"title": "Error code",
"default": "NOT_FOUND"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "NotFound"
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Поиск заявок",
"description": "Ищет заявки по фильтрам"
}
},
"/couriers/search": {
"post": {
"tags": [
"Роботы"
],
"operationId": "search_handler_couriers_search_post",
"requestBody": {
"content": {
"application/json": {
"schema": {
"properties": {
"limit": {
"type": "integer",
"maximum": 1000,
"minimum": 1,
"title": "Limit",
"default": 1000
},
"offset": {
"type": "integer",
"minimum": 0,
"title": "Offset",
"default": 0
},
"filters": {
"default": {},
"properties": {
"shift_status_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Shift Status In"
},
"shift_status_not_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Shift Status Not In"
},
"identifier": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Identifier"
}
},
"type": "object",
"title": "SearchRequestFilters"
},
"order": {
"items": {
"type": "string"
},
"type": "array",
"maxItems": 2,
"minItems": 2,
"title": "Order",
"default": [],
"description": "В первом элементе массива нужно передать названия полей сортировки через запятую. Во втором элементе - направление сортировки `asc` или `desc`."
}
},
"type": "object",
"title": "SearchRequestBody"
}
}
},
"required": true
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"couriers": {
"items": {
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
},
"claim": {
"oneOf": [
{
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level",
"claim"
],
"title": "CourierInfoWithClaim"
},
"type": "array",
"title": "Couriers"
}
},
"type": "object",
"required": [
"couriers"
],
"title": "SearchResponseBody"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"UNAUTHORIZED"
],
"const": "UNAUTHORIZED",
"title": "Error code",
"default": "UNAUTHORIZED"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "Unauthorized"
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"FORBIDDEN"
],
"const": "FORBIDDEN",
"title": "Error code",
"default": "FORBIDDEN"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "Forbidden"
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Поиск роботов",
"description": "Ищет роботов по фильтрам"
}
},
"/couriers/journal": {
"post": {
"tags": [
"Роботы"
],
"operationId": "journal_handler_couriers_journal_post",
"parameters": [
{
"name": "vin",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "VIN",
"description": "Vehicle Identification Number that uniquely identifies robot",
"x-i18n-ru-description": "Идентификатор робота"
},
"description": "Vehicle Identification Number that uniquely identifies robot"
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"default": {},
"properties": {
"cursor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Cursor"
}
},
"type": "object",
"title": "JournalRequestBody"
}
}
}
},
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"properties": {
"cursor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Cursor"
},
"events": {
"items": {
"properties": {
"event_id": {
"type": "string",
"title": "Event Id"
},
"change_type": {
"type": "string",
"title": "Change Type",
"description": "Тип произошедшего изменения. Возможные значения:\n - `order_created`: Заказ был создан\n - `order_changed`: Заказ был изменен\n - `order_completed`: Заказ был завершен\n - `order_cancel_requested`: Запрошена отмена заказа\n - `shift_initialized`: Смена инициализирована\n - `shift_created`: Смена создана\n - `shift_changed`: Смена изменена\n - `shift_completed`: Смена завершена\n - `open_hatch_requested`: Запрошено открытие крышки\n - `close_hatch_requested`: Запрошено закрытие крышки\n - `closed_hatch_detected`: Обнаружена закрытая крышка\n - `battery_change_started`: Начата замена батареи\n - `battery_change_updated`: Обновлена замена батареи\n - `battery_change_finished`: Завершена замена батареи\n - `move_to_base_point`: Перемещение в базовую точку\n - `arrived_to_base_point`: Прибытие в базовую точку\n - `product_detection`: Обнаружение продукта\n - `terminate`: Завершение\n - `abort`: Прерывание\n"
},
"claim_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Claim Id"
},
"courier_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier Id"
},
"shift_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shift Id"
},
"timestamp": {
"type": "string",
"format": "date-time",
"title": "Timestamp"
},
"new_value": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "New Value",
"description": "Возможные значения:\n - `new`: Заказ создан, но робот еще не назначен\n - `picking_up`: Робот назначен и движется к точке получения\n - `pickup_arrived`: Робот прибыл в точку получения\n - `delivering`: Робот движется к точке доставки\n - `delivery_arrived`: Робот прибыл в точку доставки\n - `delivered`: Робот завершил доставку\n - `returning`: Робот возвращается\n - `return_arrived`: Робот прибыл в точку возврата\n - `returned`: Робот завершил возврат\n - `cancelled`: Заказ отменен\n"
},
"courier_coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"event_id",
"change_type",
"claim_id",
"courier_id",
"shift_id",
"timestamp",
"new_value"
],
"title": "JournalEvent"
},
"type": "array",
"title": "Events"
}
},
"type": "object",
"required": [
"cursor",
"events"
],
"title": "JournalListWithCursor"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"title": "Unauthorized",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "UNAUTHORIZED",
"default": "UNAUTHORIZED",
"enum": [
"UNAUTHORIZED"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"title": "Forbidden",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "FORBIDDEN",
"default": "FORBIDDEN",
"enum": [
"FORBIDDEN"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"404": {
"description": "Not Found",
"content": {
"application/json": {
"schema": {
"title": "NotFound",
"type": "object",
"properties": {
"code": {
"title": "Error code",
"type": "string",
"const": "NOT_FOUND",
"default": "NOT_FOUND",
"enum": [
"NOT_FOUND"
]
},
"message": {
"title": "Error Message",
"type": "string"
}
},
"required": [
"message",
"code"
]
}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
}
}
}
}
},
"summary": "Получить журнал событий",
"description": "Возвращает список событий, связанных с курьером, с использованием пагинации по курсору"
}
},
"/geo/points/list": {
"post": {
"tags": [
"Гео"
],
"operationId": "list_points_geo_points_list_post",
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {
"items": {
"properties": {
"id": {
"type": "string",
"title": "Id"
},
"name": {
"type": "string",
"title": "Name"
},
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
}
},
"type": "object",
"required": [
"id",
"name",
"coordinates"
],
"title": "PointInfo"
},
"type": "array",
"title": "Response List Points Geo Points List Post"
}
}
}
},
"401": {
"description": "Unauthorized",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"UNAUTHORIZED"
],
"const": "UNAUTHORIZED",
"title": "Error code",
"default": "UNAUTHORIZED"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "Unauthorized"
}
}
}
},
"403": {
"description": "Forbidden",
"content": {
"application/json": {
"schema": {
"properties": {
"code": {
"type": "string",
"enum": [
"FORBIDDEN"
],
"const": "FORBIDDEN",
"title": "Error code",
"default": "FORBIDDEN"
},
"message": {
"type": "string",
"title": "Error Message"
}
},
"type": "object",
"required": [
"message",
"code"
],
"title": "Forbidden"
}
}
}
}
},
"summary": "Доступные точки",
"description": "Получить список доступных точек"
}
}
},
"components": {
"schemas": {
"Claim": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
},
"ClaimPoint": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"ClaimPointAddress": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"ClaimPointType": {
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
"ClaimPointVisitStatus": {
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
"ClaimRequestPoint": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"point_id": {
"type": "string",
"title": "Point Id"
},
"type": {
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
}
},
"type": "object",
"required": [
"address",
"point_id",
"type",
"visit_order"
],
"title": "ClaimRequestPoint"
},
"ClaimStatus": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"ClaimWithCourier": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"courier": {
"oneOf": [
{
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level"
],
"title": "CourierInfo"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision",
"courier"
],
"title": "ClaimWithCourier"
},
"CourierInfo": {
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level"
],
"title": "CourierInfo"
},
"CourierInfoWithClaim": {
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
},
"claim": {
"oneOf": [
{
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level",
"claim"
],
"title": "CourierInfoWithClaim"
},
"CourierShiftStatus": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"CreateRequestBody": {
"properties": {
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"point_id": {
"type": "string",
"title": "Point Id"
},
"type": {
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
}
},
"type": "object",
"required": [
"address",
"point_id",
"type",
"visit_order"
],
"title": "ClaimRequestPoint"
},
"type": "array",
"maxItems": 3,
"minItems": 2,
"title": "Route Points"
},
"external_order_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Order Id"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"conditions": {
"default": {},
"properties": {
"maximum_first_point_eta": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Maximum First Point Eta",
"description": "Поиск будет ограничен курьерами, которые смогут прибыть в исходную точку до разрешенного расчетного времени прибытия.\n\nСервис ожидает дату и время с указанием часового пояса. Примеры форматов:\n- 2026-01-11 17:26:27.704301+00:00\n- 2026-01-11T19:18:43Z\n\nЕсли часовой пояс не указан, сервис считает, что это UTC+0.\n"
},
"search_until": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Search Until",
"description": "Поиск прекратится по истечении указанного времени и завершится неудачей.\n\nСервис ожидает дату и время с указанием часового пояса. Примеры форматов:\n- 2026-01-11 17:26:27.704301+00:00\n- 2026-01-11T19:18:43Z\n\nЕсли часовой пояс не указан, сервис считает, что это UTC+0.\n"
},
"robot_vins": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "null"
}
],
"title": "Robot Vins",
"description": "Список VIN роботов для рассмотрения для этой заявки. Если указано, только эти роботы будут рассматриваться для назначения"
}
},
"type": "object",
"title": "CreateRequestConditions"
}
},
"type": "object",
"required": [
"route_points"
],
"title": "CreateRequestBody"
},
"CreateRequestConditions": {
"properties": {
"maximum_first_point_eta": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Maximum First Point Eta",
"description": "Поиск будет ограничен курьерами, которые смогут прибыть в исходную точку до разрешенного расчетного времени прибытия.\n\nСервис ожидает дату и время с указанием часового пояса. Примеры форматов:\n- 2026-01-11 17:26:27.704301+00:00\n- 2026-01-11T19:18:43Z\n\nЕсли часовой пояс не указан, сервис считает, что это UTC+0.\n"
},
"search_until": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Search Until",
"description": "Поиск прекратится по истечении указанного времени и завершится неудачей.\n\nСервис ожидает дату и время с указанием часового пояса. Примеры форматов:\n- 2026-01-11 17:26:27.704301+00:00\n- 2026-01-11T19:18:43Z\n\nЕсли часовой пояс не указан, сервис считает, что это UTC+0.\n"
},
"robot_vins": {
"oneOf": [
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "null"
}
],
"title": "Robot Vins",
"description": "Список VIN роботов для рассмотрения для этой заявки. Если указано, только эти роботы будут рассматриваться для назначения"
}
},
"type": "object",
"title": "CreateRequestConditions"
},
"HTTPValidationError": {
"properties": {
"detail": {
"items": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"type": "array",
"title": "Detail"
}
},
"type": "object",
"title": "HTTPValidationError"
},
"HatchStatus": {
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
"JournalEvent": {
"properties": {
"event_id": {
"type": "string",
"title": "Event Id"
},
"change_type": {
"type": "string",
"title": "Change Type",
"description": "Тип произошедшего изменения. Возможные значения:\n - `order_created`: Заказ был создан\n - `order_changed`: Заказ был изменен\n - `order_completed`: Заказ был завершен\n - `order_cancel_requested`: Запрошена отмена заказа\n - `shift_initialized`: Смена инициализирована\n - `shift_created`: Смена создана\n - `shift_changed`: Смена изменена\n - `shift_completed`: Смена завершена\n - `open_hatch_requested`: Запрошено открытие крышки\n - `close_hatch_requested`: Запрошено закрытие крышки\n - `closed_hatch_detected`: Обнаружена закрытая крышка\n - `battery_change_started`: Начата замена батареи\n - `battery_change_updated`: Обновлена замена батареи\n - `battery_change_finished`: Завершена замена батареи\n - `move_to_base_point`: Перемещение в базовую точку\n - `arrived_to_base_point`: Прибытие в базовую точку\n - `product_detection`: Обнаружение продукта\n - `terminate`: Завершение\n - `abort`: Прерывание\n"
},
"claim_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Claim Id"
},
"courier_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier Id"
},
"shift_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shift Id"
},
"timestamp": {
"type": "string",
"format": "date-time",
"title": "Timestamp"
},
"new_value": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "New Value",
"description": "Возможные значения:\n - `new`: Заказ создан, но робот еще не назначен\n - `picking_up`: Робот назначен и движется к точке получения\n - `pickup_arrived`: Робот прибыл в точку получения\n - `delivering`: Робот движется к точке доставки\n - `delivery_arrived`: Робот прибыл в точку доставки\n - `delivered`: Робот завершил доставку\n - `returning`: Робот возвращается\n - `return_arrived`: Робот прибыл в точку возврата\n - `returned`: Робот завершил возврат\n - `cancelled`: Заказ отменен\n"
},
"courier_coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"event_id",
"change_type",
"claim_id",
"courier_id",
"shift_id",
"timestamp",
"new_value"
],
"title": "JournalEvent"
},
"JournalListWithCursor": {
"properties": {
"cursor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Cursor"
},
"events": {
"items": {
"properties": {
"event_id": {
"type": "string",
"title": "Event Id"
},
"change_type": {
"type": "string",
"title": "Change Type",
"description": "Тип произошедшего изменения. Возможные значения:\n - `order_created`: Заказ был создан\n - `order_changed`: Заказ был изменен\n - `order_completed`: Заказ был завершен\n - `order_cancel_requested`: Запрошена отмена заказа\n - `shift_initialized`: Смена инициализирована\n - `shift_created`: Смена создана\n - `shift_changed`: Смена изменена\n - `shift_completed`: Смена завершена\n - `open_hatch_requested`: Запрошено открытие крышки\n - `close_hatch_requested`: Запрошено закрытие крышки\n - `closed_hatch_detected`: Обнаружена закрытая крышка\n - `battery_change_started`: Начата замена батареи\n - `battery_change_updated`: Обновлена замена батареи\n - `battery_change_finished`: Завершена замена батареи\n - `move_to_base_point`: Перемещение в базовую точку\n - `arrived_to_base_point`: Прибытие в базовую точку\n - `product_detection`: Обнаружение продукта\n - `terminate`: Завершение\n - `abort`: Прерывание\n"
},
"claim_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Claim Id"
},
"courier_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier Id"
},
"shift_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shift Id"
},
"timestamp": {
"type": "string",
"format": "date-time",
"title": "Timestamp"
},
"new_value": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "New Value",
"description": "Возможные значения:\n - `new`: Заказ создан, но робот еще не назначен\n - `picking_up`: Робот назначен и движется к точке получения\n - `pickup_arrived`: Робот прибыл в точку получения\n - `delivering`: Робот движется к точке доставки\n - `delivery_arrived`: Робот прибыл в точку доставки\n - `delivered`: Робот завершил доставку\n - `returning`: Робот возвращается\n - `return_arrived`: Робот прибыл в точку возврата\n - `returned`: Робот завершил возврат\n - `cancelled`: Заказ отменен\n"
},
"courier_coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"event_id",
"change_type",
"claim_id",
"courier_id",
"shift_id",
"timestamp",
"new_value"
],
"title": "JournalEvent"
},
"type": "array",
"title": "Events"
}
},
"type": "object",
"required": [
"cursor",
"events"
],
"title": "JournalListWithCursor"
},
"JournalRequestBody": {
"properties": {
"cursor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Cursor"
}
},
"type": "object",
"title": "JournalRequestBody"
},
"PointInfo": {
"properties": {
"id": {
"type": "string",
"title": "Id"
},
"name": {
"type": "string",
"title": "Name"
},
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
}
},
"type": "object",
"required": [
"id",
"name",
"coordinates"
],
"title": "PointInfo"
},
"SearchResponseBodyMeta": {
"properties": {
"totals": {
"oneOf": [
{
"additionalProperties": {
"type": "integer"
},
"propertyNames": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "object"
},
{
"type": "null"
}
],
"title": "Totals"
}
},
"type": "object",
"title": "SearchResponseBodyMeta"
},
"SortableClaimField": {
"type": "string",
"enum": [
"created_at"
],
"title": "SortableClaimField"
},
"SortableCourierField": {
"enum": [],
"title": "SortableCourierField"
},
"SortingDirection": {
"type": "string",
"enum": [
"desc",
"asc"
],
"title": "SortingDirection"
},
"TupleCoordinate": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"ValidationError": {
"properties": {
"loc": {
"items": {
"oneOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"type": "array",
"title": "Location"
},
"msg": {
"type": "string",
"title": "Message"
},
"type": {
"type": "string",
"title": "Error Type"
}
},
"type": "object",
"required": [
"loc",
"msg",
"type"
],
"title": "ValidationError"
},
"api__external__v2__claims__models__SearchRequestBody": {
"properties": {
"limit": {
"type": "integer",
"maximum": 1000,
"minimum": 1,
"title": "Limit",
"default": 1000
},
"offset": {
"type": "integer",
"minimum": 0,
"title": "Offset",
"default": 0
},
"created_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created From"
},
"created_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created To"
},
"external_order_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Order Id"
},
"filters": {
"default": {},
"properties": {
"status_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Status In"
},
"status_not_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Status Not In"
},
"id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"created_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created From"
},
"created_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created To"
},
"updated_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Updated From"
},
"updated_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Updated To"
},
"finished_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished From"
},
"finished_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished To"
},
"courier": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier"
}
},
"type": "object",
"title": "SearchRequestFilters"
},
"order": {
"type": "array",
"items": {
"type": "string"
},
"maxItems": 2,
"minItems": 2,
"title": "Order",
"default": [],
"description": "В первом элементе массива нужно передать названия полей сортировки через запятую. Во втором элементе - направление сортировки `asc` или `desc`."
},
"include_totals": {
"type": "boolean",
"title": "Include Totals",
"default": true
}
},
"type": "object",
"title": "SearchRequestBody"
},
"api__external__v2__claims__models__SearchRequestFilters": {
"properties": {
"status_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Status In"
},
"status_not_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Status Not In"
},
"id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"created_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created From"
},
"created_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Created To"
},
"updated_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Updated From"
},
"updated_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Updated To"
},
"finished_from": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished From"
},
"finished_to": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished To"
},
"courier": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Courier"
}
},
"type": "object",
"title": "SearchRequestFilters"
},
"api__external__v2__claims__models__SearchResponseBody": {
"properties": {
"meta": {
"properties": {
"totals": {
"oneOf": [
{
"additionalProperties": {
"type": "integer"
},
"propertyNames": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"type": "object"
},
{
"type": "null"
}
],
"title": "Totals"
}
},
"type": "object",
"title": "SearchResponseBodyMeta"
},
"claims": {
"items": {
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"courier": {
"oneOf": [
{
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level"
],
"title": "CourierInfo"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision",
"courier"
],
"title": "ClaimWithCourier"
},
"type": "array",
"title": "Claims"
}
},
"type": "object",
"required": [
"meta",
"claims"
],
"title": "SearchResponseBody"
},
"api__external__v2__couriers__models__SearchRequestBody": {
"properties": {
"limit": {
"type": "integer",
"maximum": 1000,
"minimum": 1,
"title": "Limit",
"default": 1000
},
"offset": {
"type": "integer",
"minimum": 0,
"title": "Offset",
"default": 0
},
"filters": {
"default": {},
"properties": {
"shift_status_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Shift Status In"
},
"shift_status_not_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Shift Status Not In"
},
"identifier": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Identifier"
}
},
"type": "object",
"title": "SearchRequestFilters"
},
"order": {
"items": {
"type": "string"
},
"type": "array",
"maxItems": 2,
"minItems": 2,
"title": "Order",
"default": [],
"description": "В первом элементе массива нужно передать названия полей сортировки через запятую. Во втором элементе - направление сортировки `asc` или `desc`."
}
},
"type": "object",
"title": "SearchRequestBody"
},
"api__external__v2__couriers__models__SearchRequestFilters": {
"properties": {
"shift_status_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Shift Status In"
},
"shift_status_not_in": {
"oneOf": [
{
"items": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Shift Status Not In"
},
"identifier": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Identifier"
}
},
"type": "object",
"title": "SearchRequestFilters"
},
"api__external__v2__couriers__models__SearchResponseBody": {
"properties": {
"couriers": {
"items": {
"properties": {
"name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Name"
},
"vin": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Vin"
},
"shift_status": {
"type": "string",
"enum": [
"off",
"free",
"on_delivery",
"on_battery_change",
"blocked"
],
"title": "CourierShiftStatus"
},
"hatch_status": {
"oneOf": [
{
"type": "string",
"enum": [
"opening",
"open",
"closing",
"closed"
],
"title": "HatchStatus"
},
{
"type": "null"
}
]
},
"coordinates": {
"oneOf": [
{
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
{
"type": "null"
}
]
},
"yaw": {
"oneOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"title": "Yaw"
},
"current_route": {
"oneOf": [
{
"items": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"type": "array"
},
{
"type": "null"
}
],
"title": "Current Route"
},
"fuel_level": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Fuel Level"
},
"claim": {
"oneOf": [
{
"properties": {
"created_at": {
"type": "string",
"format": "date-time",
"title": "Created At"
},
"updated_at": {
"type": "string",
"format": "date-time",
"title": "Updated At"
},
"finished_at": {
"oneOf": [
{
"type": "string",
"format": "date-time"
},
{
"type": "null"
}
],
"title": "Finished At"
},
"id": {
"type": "string",
"title": "Id"
},
"route_points": {
"items": {
"properties": {
"address": {
"properties": {
"coordinates": {
"type": "array",
"items": {
"type": "number"
},
"maxItems": 2,
"minItems": 2
},
"fullname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Fullname"
},
"building": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building"
},
"building_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Building Name"
},
"city": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "City"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
},
"country": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Country"
},
"description": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Description"
},
"door_code": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code"
},
"door_code_extra": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Door Code Extra"
},
"doorbell_name": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Doorbell Name"
},
"porch": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Porch"
},
"sflat": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sflat"
},
"sfloor": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Sfloor"
},
"shortname": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Shortname"
},
"street": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Street"
},
"uri": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Uri"
}
},
"type": "object",
"required": [
"coordinates"
],
"title": "ClaimPointAddress"
},
"id": {
"type": "string",
"title": "Id"
},
"type": {
"oneOf": [
{
"type": "string",
"enum": [
"source",
"destination",
"return"
],
"title": "ClaimPointType"
},
{
"type": "string"
}
],
"title": "Type"
},
"visit_order": {
"type": "integer",
"title": "Visit Order"
},
"visit_status": {
"oneOf": [
{
"type": "string",
"enum": [
"pending",
"on_the_way",
"arrived",
"in_exchange",
"completing",
"visited",
"skipping",
"skipped"
],
"title": "ClaimPointVisitStatus"
},
{
"type": "string"
}
],
"title": "Visit Status"
}
},
"type": "object",
"required": [
"address",
"id",
"type",
"visit_order",
"visit_status"
],
"title": "ClaimPoint"
},
"type": "array",
"title": "Route Points"
},
"current_route_point_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Current Route Point Id"
},
"external_id": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "External Id"
},
"status": {
"type": "string",
"enum": [
"new",
"estimating",
"estimating_failed",
"performer_lookup",
"performer_draft",
"performer_found",
"performer_not_found",
"ready_for_approval",
"accepted",
"picking_up",
"pickup_arrived",
"ready_for_pickup_confirmation",
"picked_up",
"delivering",
"delivery_arrived",
"ready_for_delivery_confirmation",
"delivered",
"returning",
"return_arrived",
"ready_for_return_confirmation",
"returned",
"cancelled"
],
"title": "ClaimStatus"
},
"version": {
"oneOf": [
{
"type": "integer"
},
{
"type": "string"
}
],
"title": "Version"
},
"user_request_revision": {
"type": "string",
"title": "User Request Revision"
},
"eta": {
"oneOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"title": "Eta",
"description": "В минутах"
},
"comment": {
"oneOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"title": "Comment"
}
},
"type": "object",
"required": [
"created_at",
"updated_at",
"id",
"route_points",
"status",
"version",
"user_request_revision"
],
"title": "Claim"
},
{
"type": "null"
}
]
}
},
"type": "object",
"required": [
"name",
"vin",
"shift_status",
"hatch_status",
"coordinates",
"yaw",
"current_route",
"fuel_level",
"claim"
],
"title": "CourierInfoWithClaim"
},
"type": "array",
"title": "Couriers"
}
},
"type": "object",
"required": [
"couriers"
],
"title": "SearchResponseBody"
}
}
}
}