Team: Timeoff

🔒 Обновление параметров или статуса отпуска / больничного.

Обновление параметров или статуса отпуска / больничного.

Access: authorized (10 ) · Scope: write

Allows: user:timeoff (все обязательны; проверка в команде по ресурсу из запроса)

TypeScript (copy-paste)

POST /team/timeoff/update

<details open><summary><b>Params</b></summary>
export interface TeamTimeoffUpdateParams {
  ID: string
}
</details> <details open><summary><b>Body (Partial)</b></summary>
// Patch-body: все поля опциональны (Valid.Patch)
export type TeamTimeoffUpdateBody = Partial<UserTimeOff>

export interface TeamTimeoffUpdateBodyFields {
  ID?: string
  cID?: string
  userID?: string
  roleID?: string
  type?: string
  paid?: boolean | null
  sickLeaveID?: string | null
  statementFID?: string | null
  statementOrgID?: string | null
  /** Unix timestamp in milliseconds */
  statementSentTS?: number | null
  year?: number
  /** Day key (YYYYMMDD or internal day index) */
  startDayKey?: number
  /** Day key (YYYYMMDD or internal day index) */
  endDayKey?: number | null
  daysCount?: number
  /** Day key (YYYYMMDD or internal day index) */
  startWorkDayKey?: number | null
  userNote?: string | null
  userAvailable?: boolean | null
  status?: string
  adminNote?: string | null
  adminUID?: string | null
  payment?: UserTimeOff_payment | null
  statement?: Record<string, any> | null
  /** Unix timestamp in milliseconds */
  updTS?: number
  updUID?: string
}
</details> <details open><summary><b>Response</b></summary>
export type TeamTimeoffUpdateResponse = IServerResponse<UserTimeOff>

export interface IServerResponse<T = any> {
  code: number
  data: T
  srvTS: number
  rkey: string
}
</details>

Полный файл типов: /docs/types · raw: /docs/api-types.ts

post/team/timeoff/update

Request

  • Base URL: http://localhost
  • URL: http://localhost/team/timeoff/update
  • Auth: one of:
    • API key in header sid and API key in header rts and API key in header sig
    • HTTP bearer

Query parameters

IDstring uuid required

Можно передать header ID (сервер мержит headers+query)

Headers

devIDstring uuid required

UUID устройства клиента

tzstring required
Example:Europe/Moscow

Таймзона клиента (IANA или offset)

appstring required
Example:kosmodrom-web

Имя клиентского приложения

appVerstring required
Example:1.0.0

Версия клиента

rKeystring

Уникальный ключ запроса для логов/саппорта

Request body

IDstring uuid
cIDstring uuid
userIDstring uuid
roleIDstring uuid
typestring
paidboolean nullable
sickLeaveIDstring nullable
statementFIDstring uuid nullable
statementOrgIDstring uuid nullable
statementSentTSinteger nullable

Unix timestamp in milliseconds

yearinteger
startDayKeyinteger

Day key (YYYYMMDD or internal day index)

endDayKeyinteger nullable

Day key (YYYYMMDD or internal day index)

daysCountinteger
startWorkDayKeyinteger nullable

Day key (YYYYMMDD or internal day index)

userNotestring nullable
userAvailableboolean nullable
statusstring
adminNotestring nullable
adminUIDstring uuid nullable
payment'created' | 'paid'

created = "created", paid = "paid"

statementobject nullable
updTSinteger

Unix timestamp in milliseconds

updUIDstring

Response

OK — IServerResponse<UserTimeOff>

codeinteger required
srvTSinteger required

Server timestamp (ms)

rkeystring required

Request key

Example response

{
  "code": 200
}

Changes

No recorded changes to this operation across all 1 revision of this API.