Заказы · Изменение
Текущие · Заказы · Изменение · Заметки
active_order_update_notes
Попробуйте три запроса
Подготовить
- Вы указываетеЗаказ
- ПомощникПодготовка
- Вы получаетеПредпросмотр
Запрос в чат
Подготовь «Текущие / Заказы / Изменение / Заметки». Для изменения нужны заказ, изменяемые поля. Покажи объект и ожидаемый эффект до выполнения.
- orderId
- Заказ
- values
- Изменяемые поля
Применить
- Вы указываетеСогласованные значения
- ПомощникОдин вызов
- Вы получаетеОтвет операции
Запрос в чат
На учебной записи подготовь «Текущие / Заказы / Изменение / Заметки» с параметром values.comment = Проверено на учебной записи. Покажи остальные обязательные значения и выполни действие, когда согласованы все поля.
- values.comment
- Проверено на учебной записи
- orderId
- DEMO-101
Проверить итог
- Вы указываетеИсходный ответ
- ПомощникСверка результата
- Вы получаетеПодтверждение
Запрос в чат
Проверь результат «Текущие / Заказы / Изменение / Заметки» по исходному ответу. Покажи заказ, appliedFromRevision. Объясни, чем подтвердить эффект для выбранного объекта.
- До измененияПрочитать версию
- При записиПередать выбранную версию
- После ответаПеречитать объект
Как работает действие
Этот вызов может изменить рабочие данные. Согласуйте точный объект, новые значения и ожидаемый результат. Присвойте операции стабильный requestId. При повторе той же операции используйте прежний ключ и те же значения. Прочитайте актуальную версию записи перед подготовкой запроса.
Описание разработчика
Partially update native Comment, CommentClient and CommentForProduction atomically with version, LastUpdate, History and an idempotency receipt. Preserves every item, price, discount, tax, payment, reservation, writeoff and status field. Submitted orders require orders.submitted.update. This is not a create/order-items/fulfillment operation.
Параметры запроса
- orderId
- Идентификатор выбранного заказа. обязательно по схеме · string
- expectedRevision
- Версия, прочитанная перед изменением. обязательно по схеме · string
- values
- Значения для записи. Состав и вложенность указаны в схеме. обязательно по схеме · object
- requestId
- Ключ этой операции. Для повтора с теми же аргументами сохраните исходное значение. обязательно по схеме · string
Что вернёт команда
- orderId
- Canonical active Firestore order ID from active_orders_search/get, not a display number. обязательно по схеме · string
- appliedFromRevision
- Exact Firestore revision from active_order_notes_context; detects changes even if a native writer did not increment version. обязательно по схеме · string
- version
- Native version after this exact commit. Read notes context again before another edit. обязательно по схеме · integer · минимум 0 · максимум 9007199254740991
- values
- Exact committed patch; omitted comments were preserved. обязательно по схеме · object
Поля и технические схемы

Вход · JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"orderId": {
"type": "string",
"pattern": "^[A-Za-z0-9_~:@+.-]{1,128}$",
"description": "Canonical active Firestore order ID from active_orders_search/get, not a display number."
},
"expectedRevision": {
"type": "string",
"pattern": "^fsv1:\\d{1,12}:\\d{1,9}$",
"description": "Exact Firestore revision from active_order_notes_context; detects changes even if a native writer did not increment version."
},
"values": {
"type": "object",
"properties": {
"comment": {
"description": "Native order.Comment. Empty string explicitly clears this field.",
"type": "string",
"maxLength": 4000
},
"customerComment": {
"description": "Native order.CommentClient. Omission preserves the existing customer note.",
"type": "string",
"maxLength": 4000
},
"productionComment": {
"description": "Native order.CommentForProduction. This stores text; it does not submit to production or send a message.",
"type": "string",
"maxLength": 4000
}
},
"additionalProperties": false,
"description": "Only explicitly supplied native comment fields change. Null, items, prices, payments, status and inventory fields are not accepted."
},
"requestId": {
"type": "string",
"pattern": "^[A-Za-z0-9_-]{8,128}$",
"description": "Stable request ID for exactly this patch; reuse unchanged after a lost response."
}
},
"required": [
"orderId",
"expectedRevision",
"values",
"requestId"
],
"additionalProperties": false
}Выход · JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"orderId": {
"type": "string",
"pattern": "^[A-Za-z0-9_~:@+.-]{1,128}$",
"description": "Canonical active Firestore order ID from active_orders_search/get, not a display number."
},
"appliedFromRevision": {
"type": "string",
"pattern": "^fsv1:\\d{1,12}:\\d{1,9}$",
"description": "Exact Firestore revision from active_order_notes_context; detects changes even if a native writer did not increment version."
},
"version": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Native version after this exact commit. Read notes context again before another edit."
},
"values": {
"type": "object",
"properties": {
"comment": {
"description": "Native order.Comment. Empty string explicitly clears this field.",
"type": "string",
"maxLength": 4000
},
"customerComment": {
"description": "Native order.CommentClient. Omission preserves the existing customer note.",
"type": "string",
"maxLength": 4000
},
"productionComment": {
"description": "Native order.CommentForProduction. This stores text; it does not submit to production or send a message.",
"type": "string",
"maxLength": 4000
}
},
"additionalProperties": false,
"description": "Exact committed patch; omitted comments were preserved."
}
},
"required": [
"orderId",
"appliedFromRevision",
"version",
"values"
],
"additionalProperties": false
}