MCP Control
Финансы · Чувствительное действие

Касса · Сессии · Открытие

cash_sessions_open
Кассовый чек, калькулятор и монеты

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

Подготовить
  1. Вы указываетеФилиал
  2. ПомощникПодготовка
  3. Вы получаетеПредпросмотр
Запрос в чат
Подготовь «Касса / Сессии / Открытие». Для изменения нужны филиал, openingCount. Покажи объект и ожидаемый эффект до выполнения.
Что входит в подготовку
locationId
Филиал
openingCount
Параметр
comment
Комментарий
Применить
  1. Вы указываетеСогласованные значения
  2. ПомощникОдин вызов
  3. Вы получаетеОтвет операции
Запрос в чат
На учебной записи подготовь «Касса / Сессии / Открытие» с параметром locationId = DEMO-101. Покажи остальные обязательные значения и выполни действие, когда согласованы все поля.
Фрагмент учебных параметров
locationId
DEMO-101
comment
Проверено на учебной записи
Проверить итог
  1. Вы указываетеИсходный ответ
  2. ПомощникСверка результата
  3. Вы получаетеПодтверждение
Запрос в чат
Проверь результат «Касса / Сессии / Открытие» по исходному ответу. Покажи cashShiftId, филиал. Объясни, чем подтвердить эффект для выбранного объекта.
Как проследить одну попытку
  1. ЗапросСохранить исходный ключ
  2. ОтветПроверить статус
  3. ПроверкаСверить эффект операции
Как работает действие

Этот вызов может изменить рабочие данные. Согласуйте точный объект, новые значения и ожидаемый результат. Присвойте операции стабильный requestId. При повторе той же операции используйте прежний ключ и те же значения.

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

Open a native cash session with a physical opening count, server actor, timestamp and display number. Requires current OAuth and employee permissions plus access to its establishment. Does not read Orders, infer cash receipts, post transactions or enforce a one-till-per-location assumption. Existing cash collection/difference text fields are left untouched. After an uncertain response use cash_sessions_get_open_result with the exact original arguments.

Параметры запроса
locationId
Идентификатор точки из текущего подключения. обязательно по схеме · string · до символов 128
openingCount
Cash physically counted by the operator at the start, in the configured cash account’s units. This records an observation; it does not calculate or change a financial balance. обязательно по схеме · number · минимум 0 · максимум 1000000000000
comment
Optional note about the observed opening count. Do not include credentials. обязательно по схеме · string · по умолчанию "" · до символов 1000
requestId
Ключ этой операции. Для повтора с теми же аргументами сохраните исходное значение. обязательно по схеме · string · до символов 128
Что вернёт команда
cashShiftId
Canonical native cash-shift ID. Use cash_shifts_get with key.id to inspect its current record. обязательно по схеме · string · до символов 128
locationId
Establishment verified by the server against current company and location permissions. обязательно по схеме · string · до символов 128
number
Server-assigned native display number. Legacy clients may have their own numbering, so use cashShiftId as identity. обязательно по схеме · integer · максимум 9007199254740991
state
Whether this observed cash session is open or has a recorded closing count. This is not financial reconciliation or settlement. обязательно по схеме · string · варианты open, closed
currency
Currency marker verified from the cash account at opening and checked again before closing. No conversion occurs. обязательно по схеме · string · до символов 32
openingCount
Operator-declared opening cash count preserved from the opening request. обязательно по схеме · number · минимум 0 · максимум 1000000000000
closingCount
Operator-declared closing count, or null while open. обязательно по схеме · number / null
openedAt
Server-assigned native opening timestamp. обязательно по схеме · string
closedAt
Server-assigned closing timestamp, or null while open. обязательно по схеме · string / null
revision
Exact native cash-shift revision returned by this Action or cash_shifts_get. Concurrent changes are rejected rather than overwritten. обязательно по схеме · string
Поля и технические схемы
Входные поля и поля ответа cash_sessions_open
Вход · JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "locationId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Authorized establishment ID from company location discovery. It must have a company-owned cash account with a configured currency."
    },
    "openingCount": {
      "type": "number",
      "minimum": 0,
      "maximum": 1000000000000,
      "description": "Cash physically counted by the operator at the start, in the configured cash account’s units. This records an observation; it does not calculate or change a financial balance."
    },
    "comment": {
      "default": "",
      "description": "Optional note about the observed opening count. Do not include credentials.",
      "type": "string",
      "maxLength": 1000
    },
    "requestId": {
      "type": "string",
      "minLength": 8,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_-]+$",
      "description": "Stable identifier for this exact operation. Preserve it and every argument for retries and recovery."
    }
  },
  "required": [
    "locationId",
    "openingCount",
    "comment",
    "requestId"
  ],
  "additionalProperties": false
}
Выход · JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "cashShiftId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Canonical native cash-shift ID. Use cash_shifts_get with key.id to inspect its current record."
    },
    "locationId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Establishment verified by the server against current company and location permissions."
    },
    "number": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991,
      "description": "Server-assigned native display number. Legacy clients may have their own numbering, so use cashShiftId as identity."
    },
    "state": {
      "type": "string",
      "enum": [
        "open",
        "closed"
      ],
      "description": "Whether this observed cash session is open or has a recorded closing count. This is not financial reconciliation or settlement."
    },
    "currency": {
      "type": "string",
      "minLength": 1,
      "maxLength": 32,
      "description": "Currency marker verified from the cash account at opening and checked again before closing. No conversion occurs."
    },
    "openingCount": {
      "type": "number",
      "minimum": 0,
      "maximum": 1000000000000,
      "description": "Operator-declared opening cash count preserved from the opening request."
    },
    "closingCount": {
      "anyOf": [
        {
          "type": "number",
          "minimum": 0,
          "maximum": 1000000000000
        },
        {
          "type": "null"
        }
      ],
      "description": "Operator-declared closing count, or null while open."
    },
    "openedAt": {
      "type": "string",
      "format": "date-time",
      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
      "description": "Server-assigned native opening timestamp."
    },
    "closedAt": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time",
          "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
        },
        {
          "type": "null"
        }
      ],
      "description": "Server-assigned closing timestamp, or null while open."
    },
    "revision": {
      "type": "string",
      "pattern": "^[a-f0-9]{32}$",
      "description": "Exact native cash-shift revision returned by this Action or cash_shifts_get. Concurrent changes are rejected rather than overwritten."
    }
  },
  "required": [
    "cashShiftId",
    "locationId",
    "number",
    "state",
    "currency",
    "openingCount",
    "closingCount",
    "openedAt",
    "closedAt",
    "revision"
  ],
  "additionalProperties": false
}