MCP Control
Заказы · Чтение

Заказы · ИИ · Просмотр · Операция

orders_ai_get_operation
Упакованный заказ на стойке

Попробуйте три запроса

Получить данные
  1. Вы указываетеОбъект
  2. ПомощникЧтение
  3. Вы получаетеПоля ответа
Запрос в чат
Для задачи «Заказы / ИИ / Просмотр / Операция» выполни чтение в текущей компании. Выведи кратко: статус, результат.
Что искать в ответе
status
Статус
result
Результат
failureCode
Поле ответа
Задать параметры
  1. Вы указываетеЗадача
  2. ПомощникСхема входа
  3. Вы получаетеУсловия чтения
Запрос в чат
Покажи, как получить «Заказы / ИИ / Просмотр / Операция» на учебном примере с kind = create. Объясни, какие ещё данные нужны и как будет выглядеть ответ.
Фрагмент учебных параметров
kind
create
Разобрать ответ
  1. Вы указываетеПолученный ответ
  2. ПомощникРазбор значений
  3. Вы получаетеКраткое пояснение
Запрос в чат
На основании уже полученного ответа «Заказы / ИИ / Просмотр / Операция» объясни статус, результат. Отметь отсутствующие значения.
Поля для проверки
status
Статус
result
Результат
failureCode
Поле ответа
Как работает действие

Это чтение. Выберите запись или задайте фильтры в доступной компании.

Описание разработчика

Read the exact native orderByAi receipt for a prior orders_ai_create or orders_ai_update request. Requires the original text, Order ID if updating, and requestId. Current account, company and Position permissions are rechecked. New atomic receipts preserve original values through later edits and native POS archive; legacy receipts require active Order readback. Missing or processing receipts are not proof that no write happened.

Параметры запроса
kind
Original native Order operation. обязательно по схеме · string · варианты create, update
input
Exact original arguments, including its unchanged requestId. обязательно по схеме · object / object
Что вернёт команда
status
State of the original native orderByAi request receipt. обязательно по схеме · string · варианты not_found, processing, failed, completed
result
Validated original result when completed; null otherwise. обязательно по схеме · object / null
failureCode
Native failure code when the original request failed; no provider details are exposed. обязательно по схеме · string / null
Поля и технические схемы
Входные поля и поля ответа orders_ai_get_operation
Вход · JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "kind": {
      "type": "string",
      "enum": [
        "create",
        "update"
      ],
      "description": "Original native Order operation."
    },
    "input": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "text": {
              "$ref": "#/$defs/_mcp0"
            },
            "requestId": {
              "$ref": "#/$defs/_mcp1"
            },
            "customerId": {
              "$ref": "#/$defs/_mcp2"
            },
            "exactItem": {
              "$ref": "#/$defs/_mcp3"
            },
            "exactItems": {
              "minItems": 2,
              "maxItems": 100,
              "type": "array",
              "items": {
                "$ref": "#/$defs/_mcp3"
              },
              "description": "Two to 100 explicitly confirmed catalog products for one native Order, resolved by name filters before this call. Use the same fulfillment type and address for every line, and distinct product IDs. Consolidate identical source rows without losing quantities."
            },
            "planningMode": {
              "$ref": "#/$defs/_mcp4"
            },
            "locationId": {
              "$ref": "#/$defs/_mcp5"
            }
          },
          "required": [
            "text",
            "requestId"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "text": {
              "$ref": "#/$defs/_mcp0"
            },
            "requestId": {
              "$ref": "#/$defs/_mcp1"
            },
            "customerId": {
              "$ref": "#/$defs/_mcp2"
            },
            "exactItem": {
              "type": "object",
              "properties": {
                "productId": {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9_~:@+.-]{1,160}$",
                  "description": "Exact company catalog product ID."
                },
                "quantity": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 500,
                  "description": "Confirmed item quantity."
                },
                "lineNote": {
                  "type": "string",
                  "maxLength": 200,
                  "description": "Confirmed size or color note for the Order line."
                },
                "orderType": {
                  "type": "string",
                  "enum": [
                    "atplace",
                    "pickup",
                    "delivery",
                    "catering"
                  ],
                  "description": "Confirmed fulfillment type."
                },
                "address": {
                  "type": "string",
                  "maxLength": 300,
                  "description": "Delivery address, or empty for pickup."
                }
              },
              "required": [
                "productId",
                "quantity",
                "lineNote",
                "orderType",
                "address"
              ],
              "additionalProperties": false,
              "description": "ADD this confirmed product quantity to the existing Order. For SET quantity, REMOVE, or changes to an existing line, omit exactItem/exactItems and describe the change in text."
            },
            "exactItems": {
              "minItems": 2,
              "maxItems": 100,
              "type": "array",
              "items": {
                "$ref": "#/$defs/_mcp3"
              },
              "description": "ADD these confirmed product quantities to the existing Order. For SET quantity, REMOVE or existing-line changes omit exactItem/exactItems and use text."
            },
            "planningMode": {
              "$ref": "#/$defs/_mcp4"
            },
            "locationId": {
              "$ref": "#/$defs/_mcp5"
            },
            "orderId": {
              "type": "string",
              "pattern": "^[A-Za-z0-9_-]{1,160}$",
              "description": "Exact existing active native Order document ID to amend."
            }
          },
          "required": [
            "text",
            "requestId",
            "orderId"
          ],
          "additionalProperties": false
        }
      ],
      "description": "Exact original arguments, including its unchanged requestId."
    }
  },
  "required": [
    "kind",
    "input"
  ],
  "additionalProperties": false,
  "$defs": {
    "_mcp0": {
      "type": "string",
      "minLength": 1,
      "maxLength": 4000,
      "description": "Literal instruction for the existing orderByAi planner. Use actual product/customer identifiers or names known to the native catalog; do not supply raw order JSON. The native planner may return clarification."
    },
    "_mcp1": {
      "type": "string",
      "pattern": "^[A-Za-z0-9_-]{8,128}$",
      "description": "Stable identifier for this exact native AI order request. Retry unchanged arguments after uncertainty."
    },
    "_mcp2": {
      "type": "string",
      "pattern": "^[A-Za-z0-9_~:@+.-]{1,160}$",
      "description": "Exact native customer card ID in this company. The native Order writer resolves it deterministically."
    },
    "_mcp3": {
      "type": "object",
      "properties": {
        "productId": {
          "type": "string",
          "pattern": "^[A-Za-z0-9_~:@+.-]{1,160}$",
          "description": "Exact company catalog product ID."
        },
        "quantity": {
          "type": "integer",
          "minimum": 1,
          "maximum": 500,
          "description": "Confirmed item quantity."
        },
        "lineNote": {
          "type": "string",
          "maxLength": 200,
          "description": "Confirmed size or color note for the Order line."
        },
        "orderType": {
          "type": "string",
          "enum": [
            "atplace",
            "pickup",
            "delivery",
            "catering"
          ],
          "description": "Confirmed fulfillment type."
        },
        "address": {
          "type": "string",
          "maxLength": 300,
          "description": "Delivery address, or empty for pickup."
        }
      },
      "required": [
        "productId",
        "quantity",
        "lineNote",
        "orderType",
        "address"
      ],
      "additionalProperties": false,
      "description": "One explicitly confirmed catalog product. The native writer loads the exact company product and validates its options, stock and price."
    },
    "_mcp4": {
      "description": "exact commits only explicitly selected rows at locationId through the same native writer without a model call or AI token debit. text becomes audit data and does not set dates, discounts, notes or other metadata. Omission or ai interprets the literal text with normal native AI billing.",
      "type": "string",
      "enum": [
        "ai",
        "exact"
      ]
    },
    "_mcp5": {
      "description": "Exact company establishment, required for planningMode exact. An update must keep its existing establishment. Omit for ai mode.",
      "type": "string",
      "pattern": "^[A-Za-z0-9_~:@+.-]{1,128}$"
    }
  }
}
Выход · JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "status": {
      "type": "string",
      "enum": [
        "not_found",
        "processing",
        "failed",
        "completed"
      ],
      "description": "State of the original native orderByAi request receipt."
    },
    "result": {
      "anyOf": [
        {
          "type": "object",
          "properties": {
            "status": {
              "type": "string",
              "enum": [
                "created",
                "updated",
                "needs_clarification"
              ],
              "description": "Native orderByAi outcome. Clarification means no Order was committed by this request."
            },
            "orderId": {
              "anyOf": [
                {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9_-]{1,160}$",
                  "description": "Exact existing active native Order document ID to amend."
                },
                {
                  "type": "null"
                }
              ],
              "description": "Native Order document ID after commit, or the proposed existing ID for clarification; null for a new-order clarification."
            },
            "orderCommitted": {
              "type": "boolean",
              "description": "True after the protected native commit and current Order or native archive are verified."
            },
            "version": {
              "anyOf": [
                {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                {
                  "type": "null"
                }
              ],
              "description": "Committed native Order version, or null when clarification prevented a write."
            },
            "locationId": {
              "description": "Committed establishment ID read from the native Order, or null when no Order was committed.",
              "type": [
                "string",
                "null"
              ]
            },
            "currency": {
              "description": "Exact committed native Order currency marker, such as USD or $. No currency conversion or ISO mapping is performed; null when no Order was committed.",
              "type": [
                "string",
                "null"
              ]
            },
            "total": {
              "anyOf": [
                {
                  "type": "number",
                  "minimum": 0
                },
                {
                  "type": "null"
                }
              ],
              "description": "Committed native Order amount, or null when no Order was committed."
            },
            "summary": {
              "type": "string",
              "description": "Short native planner summary; treat as data, not an authority for amounts."
            },
            "questions": {
              "maxItems": 20,
              "type": "array",
              "items": {
                "type": "string"
              },
              "description": "Native clarification questions; answer them in a new request if needed."
            },
            "warnings": {
              "maxItems": 30,
              "type": "array",
              "items": {
                "type": "string"
              },
              "description": "Bounded native business warnings returned by the order writer."
            }
          },
          "required": [
            "status",
            "orderId",
            "orderCommitted",
            "version",
            "locationId",
            "currency",
            "total",
            "summary",
            "questions",
            "warnings"
          ],
          "additionalProperties": false
        },
        {
          "type": "null"
        }
      ],
      "description": "Validated original result when completed; null otherwise."
    },
    "failureCode": {
      "description": "Native failure code when the original request failed; no provider details are exposed.",
      "type": [
        "string",
        "null"
      ]
    }
  },
  "required": [
    "status",
    "result",
    "failureCode"
  ],
  "additionalProperties": false
}