MCP Control
Расписание · Чтение

Расписание · Сравнение · Посещаемость

schedule_compare_attendance
Часы и календарь у стойки записи

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

Получить данные
  1. Вы указываетеРасписание
  2. ПомощникЧтение
  3. Вы получаетеПоля ответа
Запрос в чат
Для задачи «Расписание / Сравнение / Посещаемость» выполни чтение по выбранной записи (расписание). Выведи кратко: расписание, date.
Что искать в ответе
scheduleId
Расписание
date
Поле ответа
employeeId
Сотрудник
Задать параметры
  1. Вы указываетеРасписание
  2. ПомощникСверка выбора
  3. Вы получаетеТочный объект
Запрос в чат
Покажи, как получить «Расписание / Сравнение / Посещаемость» на учебном примере с scheduleId = DEMO-101. Объясни, какие ещё данные нужны и как будет выглядеть ответ.
Фрагмент учебных параметров
scheduleId
DEMO-101
Разобрать ответ
  1. Вы указываетеПолученный ответ
  2. ПомощникРазбор значений
  3. Вы получаетеКраткое пояснение
Запрос в чат
На основании уже полученного ответа «Расписание / Сравнение / Посещаемость» объясни расписание, date. Отметь отсутствующие значения.
Поля для проверки
scheduleId
Расписание
date
Поле ответа
employeeId
Сотрудник
Как работает действие

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

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

Compare one day of a Schedule type=smena with actual clock-in/out from existing Supabase emplyy_time. Uses the establishment time zone, inclusive Schedule date range and daily timestart/timefinish. A canceled shift retains its historical plan and actual entries but assignmentActive is false and lateness/early departure are null. Missing or open attendance stays unknown; this read does not create time entries.

Параметры запроса
scheduleId
Assigned Schedule ID to compare with attendance. обязательно по схеме · string · до символов 128
date
One local calendar day within the assigned Schedule date range. обязательно по схеме · string
Что вернёт команда
scheduleId
Assigned Schedule ID. обязательно по схеме · string · до символов 128
date
Compared local calendar date. обязательно по схеме · string
employeeId
Employee assigned to the shift and present on the recorded entries. обязательно по схеме · string · до символов 128
locationId
Establishment shared by the assignment and recorded entries. обязательно по схеме · string · до символов 128
assignmentStatus
Stored Schedule status. Canceled retains the historical plan but is not an active assignment. обязательно по схеме · string
assignmentActive
True only for published or confirmed shifts; canceled and unknown legacy statuses are not current attendance obligations. обязательно по схеме · boolean
timeZone
Configured establishment time zone used for daily schedule and local attendance timestamps. обязательно по схеме · string
plannedStartAt
Absolute instant of the stored daily plan, including a canceled historical plan. обязательно по схеме · string
plannedFinishAt
Absolute finish of the stored daily plan, including a canceled historical plan. обязательно по схеме · string
plannedMinutes
Minutes in the stored daily plan before any planned break; inspect assignmentActive before treating it as an obligation. обязательно по схеме · integer · минимум -9007199254740991 · максимум 9007199254740991
actualStartAt
Earliest actual clock-in, or null when no entry exists. обязательно по схеме · null
actualFinishAt
Latest actual clock-out, or null when absent or an entry is open. обязательно по схеме · null
actualMinutes
Recorded closed interval minutes after known breaks, or null when an entry is open or breaks cannot be interpreted. обязательно по схеме · integer / null
lateMinutes
Minutes after planned start until first clock-in; null for canceled or unknown-status shifts and when no entry exists. обязательно по схеме · integer / null
earlyLeaveMinutes
Minutes from last clock-out to planned finish; null for canceled or unknown-status shifts and when open or absent. обязательно по схеме · integer / null
timeEntryIds
Native attendance entries used for this comparison. обязательно по схеме · array
attendanceSource
Existing Supabase attendance collection; Schedule remains planning only. обязательно по схеме · string
matchBasis
Attendance is matched by employee, location and interval overlap; emplyy_time has no Schedule foreign key. обязательно по схеме · string
Поля и технические схемы
Входные поля и поля ответа schedule_compare_attendance
Вход · JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "scheduleId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Assigned Schedule ID to compare with attendance."
    },
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "One local calendar day within the assigned Schedule date range."
    }
  },
  "required": [
    "scheduleId",
    "date"
  ],
  "additionalProperties": false
}
Выход · JSON Schema
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "scheduleId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Assigned Schedule ID."
    },
    "date": {
      "type": "string",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "description": "Compared local calendar date."
    },
    "employeeId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Employee assigned to the shift and present on the recorded entries."
    },
    "locationId": {
      "type": "string",
      "minLength": 1,
      "maxLength": 128,
      "pattern": "^[A-Za-z0-9_~:@+.-]+$",
      "description": "Establishment shared by the assignment and recorded entries."
    },
    "assignmentStatus": {
      "type": "string",
      "description": "Stored Schedule status. Canceled retains the historical plan but is not an active assignment."
    },
    "assignmentActive": {
      "type": "boolean",
      "description": "True only for published or confirmed shifts; canceled and unknown legacy statuses are not current attendance obligations."
    },
    "timeZone": {
      "type": "string",
      "description": "Configured establishment time zone used for daily schedule and local attendance timestamps."
    },
    "plannedStartAt": {
      "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))$",
      "description": "Absolute instant of the stored daily plan, including a canceled historical plan."
    },
    "plannedFinishAt": {
      "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))$",
      "description": "Absolute finish of the stored daily plan, including a canceled historical plan."
    },
    "plannedMinutes": {
      "type": "integer",
      "minimum": -9007199254740991,
      "maximum": 9007199254740991,
      "description": "Minutes in the stored daily plan before any planned break; inspect assignmentActive before treating it as an obligation."
    },
    "actualStartAt": {
      "anyOf": [
        {
          "$ref": "#/$defs/_mcp0"
        },
        {
          "type": "null"
        }
      ],
      "description": "Earliest actual clock-in, or null when no entry exists."
    },
    "actualFinishAt": {
      "anyOf": [
        {
          "$ref": "#/$defs/_mcp0"
        },
        {
          "type": "null"
        }
      ],
      "description": "Latest actual clock-out, or null when absent or an entry is open."
    },
    "actualMinutes": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": -9007199254740991,
          "maximum": 9007199254740991
        },
        {
          "type": "null"
        }
      ],
      "description": "Recorded closed interval minutes after known breaks, or null when an entry is open or breaks cannot be interpreted."
    },
    "lateMinutes": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": -9007199254740991,
          "maximum": 9007199254740991
        },
        {
          "type": "null"
        }
      ],
      "description": "Minutes after planned start until first clock-in; null for canceled or unknown-status shifts and when no entry exists."
    },
    "earlyLeaveMinutes": {
      "anyOf": [
        {
          "type": "integer",
          "minimum": -9007199254740991,
          "maximum": 9007199254740991
        },
        {
          "type": "null"
        }
      ],
      "description": "Minutes from last clock-out to planned finish; null for canceled or unknown-status shifts and when open or absent."
    },
    "timeEntryIds": {
      "type": "array",
      "items": {
        "type": "string",
        "minLength": 1,
        "maxLength": 128,
        "pattern": "^[A-Za-z0-9_~:@+.-]+$",
        "description": "Matching native emplyy_time record ID."
      },
      "description": "Native attendance entries used for this comparison."
    },
    "attendanceSource": {
      "type": "string",
      "const": "emplyy_time",
      "description": "Existing Supabase attendance collection; Schedule remains planning only."
    },
    "matchBasis": {
      "type": "string",
      "const": "employee_location_time_overlap",
      "description": "Attendance is matched by employee, location and interval overlap; emplyy_time has no Schedule foreign key."
    }
  },
  "required": [
    "scheduleId",
    "date",
    "employeeId",
    "locationId",
    "assignmentStatus",
    "assignmentActive",
    "timeZone",
    "plannedStartAt",
    "plannedFinishAt",
    "plannedMinutes",
    "actualStartAt",
    "actualFinishAt",
    "actualMinutes",
    "lateMinutes",
    "earlyLeaveMinutes",
    "timeEntryIds",
    "attendanceSource",
    "matchBasis"
  ],
  "additionalProperties": false,
  "$defs": {
    "_mcp0": {
      "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))$"
    }
  }
}