Доставка · Чтение
Доставка · Маршруты · Предпросмотр
delivery_route_preview
Попробуйте три запроса
Получить данные
- Вы указываетеCourierid
- ПомощникЧтение
- Вы получаетеПоля ответа
Запрос в чат
Для задачи «Доставка / Маршруты / Предпросмотр» выполни чтение по выбранной записи (courierId). Выведи кратко: результат.
- result
- Результат
Задать параметры
- Вы указываетеCourierid
- ПомощникСверка выбора
- Вы получаетеТочный объект
Запрос в чат
Покажи, как получить «Доставка / Маршруты / Предпросмотр» на учебном примере с mode = multi. Объясни, какие ещё данные нужны и как будет выглядеть ответ.
- mode
- multi
- courierId
- DEMO-101
- establishmentId
- DEMO-101
Разобрать ответ
- Вы указываетеПолученный ответ
- ПомощникРазбор значений
- Вы получаетеКраткое пояснение
Запрос в чат
На основании уже полученного ответа «Доставка / Маршруты / Предпросмотр» объясни результат. Отметь отсутствующие значения.
- result
- Результат
Как работает действие
Это чтение. Выберите запись или задайте фильтры в доступной компании. Прочитайте актуальную версию записи перед подготовкой запроса.
Описание разработчика
Calculate a manager or own-courier delivery route for up to 23 current delivery orders using the native Map service and directions provider. Supports optimized ordering, return to base and a custom finish. Returns a short-lived preview; no courier/order assignment is committed yet. Ordinary directions API usage may be billed by the existing integration.
Параметры запроса
- courierId
- Native courierId value; use the value and type returned by the corresponding service. обязательно по схеме · string
- establishmentId
- Native establishmentId value; use the value and type returned by the corresponding service. обязательно по схеме · string
- orderIds
- Native orderIds value; use the value and type returned by the corresponding service. обязательно по схеме · array · до элементов 23
- returnToBase
- Native returnToBase value; use the value and type returned by the corresponding service. обязательно по схеме · boolean · по умолчанию false
- mode
- Native mode value; use the value and type returned by the corresponding service. обязательно по схеме · string · по умолчанию "multi" · варианты multi, return, home
- finalPoint
- Native finalPoint value; use the value and type returned by the corresponding service. необязательно · object
- optimize
- Native optimize value; use the value and type returned by the corresponding service. обязательно по схеме · boolean · по умолчанию false
- routeId
- Native routeId value; use the value and type returned by the corresponding service. необязательно · string
- expectedRevision
- Версия, прочитанная перед изменением. необязательно · string · до символов 100
- startAt
- Native startAt value; use the value and type returned by the corresponding service. необязательно · integer · минимум -9007199254740991 · максимум 9007199254740991
- asCourier
- True uses your own courier workflow. It never permits acting as another courier; false uses the native manager workflow. обязательно по схеме · boolean · по умолчанию false
Что вернёт команда
- result
- Native result value; use the value and type returned by the corresponding service. обязательно по схеме · object
Поля и технические схемы

Вход · JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"courierId": {
"type": "string",
"pattern": "^[A-Za-z0-9_.:-]{1,120}$",
"description": "Native courierId value; use the value and type returned by the corresponding service."
},
"establishmentId": {
"type": "string",
"pattern": "^[A-Za-z0-9_.:-]{1,120}$",
"description": "Native establishmentId value; use the value and type returned by the corresponding service."
},
"orderIds": {
"minItems": 1,
"maxItems": 23,
"type": "array",
"items": {
"type": "string",
"pattern": "^[A-Za-z0-9_.:-]{1,120}$"
},
"description": "Native orderIds value; use the value and type returned by the corresponding service."
},
"returnToBase": {
"default": false,
"description": "Native returnToBase value; use the value and type returned by the corresponding service.",
"type": "boolean"
},
"mode": {
"default": "multi",
"description": "Native mode value; use the value and type returned by the corresponding service.",
"type": "string",
"enum": [
"multi",
"return",
"home"
]
},
"finalPoint": {
"description": "Native finalPoint value; use the value and type returned by the corresponding service.",
"type": "object",
"properties": {
"lat": {
"type": "number",
"minimum": -90,
"maximum": 90,
"description": "Native lat value; use the value and type returned by the corresponding service."
},
"lng": {
"type": "number",
"minimum": -180,
"maximum": 180,
"description": "Native lng value; use the value and type returned by the corresponding service."
}
},
"required": [
"lat",
"lng"
],
"additionalProperties": false
},
"optimize": {
"default": false,
"description": "Native optimize value; use the value and type returned by the corresponding service.",
"type": "boolean"
},
"routeId": {
"description": "Native routeId value; use the value and type returned by the corresponding service.",
"type": "string",
"pattern": "^[A-Za-z0-9_.:-]{1,120}$"
},
"expectedRevision": {
"description": "Native expectedRevision value; use the value and type returned by the corresponding service.",
"type": "string",
"minLength": 1,
"maxLength": 100
},
"startAt": {
"description": "Native startAt value; use the value and type returned by the corresponding service.",
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"asCourier": {
"default": false,
"description": "True uses your own courier workflow. It never permits acting as another courier; false uses the native manager workflow.",
"type": "boolean"
}
},
"required": [
"courierId",
"establishmentId",
"orderIds",
"returnToBase",
"mode",
"optimize",
"asCourier"
],
"additionalProperties": false
}Выход · JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"result": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"$ref": "#/$defs/__schema0"
},
"description": "Native result value; use the value and type returned by the corresponding service."
}
},
"required": [
"result"
],
"additionalProperties": false,
"$defs": {
"__schema0": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"items": {
"$ref": "#/$defs/__schema0"
}
},
{
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"$ref": "#/$defs/__schema0"
}
}
]
}
}
}