Ресурс

On-Call Schedule Layer User

On-Call Schedule Layer Users

Модель On-Call Schedule Layer User

Свойства

  • Имя
    _id
    Тип
    Object ID
    Описание

    ID of this object

  • Имя
    createdAt
    Тип
    Date
    Описание

    Date and Time when the object was created.

  • Имя
    updatedAt
    Тип
    Date
    Описание

    Date and Time when the object was updated.

  • Имя
    project
    Тип
    Project
    Описание

    Relation to Project Resource in which this object belongs

  • Имя
    projectId
    Тип
    Object IDОбязательно
    Описание

    ID of your Project in which this object belongs

  • Имя
    onCallDutyPolicySchedule
    Тип
    On-Call Policy Schedule
    Описание

    Relation to On-Call Policy Schedule where this escalation rule belongs.

  • Имя
    onCallDutyPolicyScheduleId
    Тип
    Object IDОбязательно
    Описание

    ID of your On-Call Policy Schedule where this escalation rule belongs.

  • Имя
    onCallDutyPolicyScheduleLayer
    Тип
    On-Call Schedule Layer
    Описание

    Relation to On-Call Policy Schedule Layer where this belongs.

  • Имя
    onCallDutyPolicyScheduleLayerId
    Тип
    Object IDОбязательно
    Описание

    ID of your On-Call Policy Schedule Layer where this escalation rule belongs.

  • Имя
    createdByUser
    Тип
    User
    Описание

    Relation to User who created this object (if this object was created by a User)

  • Имя
    createdByUserId
    Тип
    Object ID
    Описание

    User ID who created this object (if this object was created by a User)

  • Имя
    order
    Тип
    Number
    Описание

    Order / Priority of this layer. Lower the number, higher the priority.

  • Имя
    user
    Тип
    User
    Описание

    User who belongs to this layer.

  • Имя
    userId
    Тип
    Object IDОбязательно
    Описание

    ID of User who belongs to this team

GETorPOST/api/on-call-duty-schedule-layer-user/get-list

Список

Этот метод возвращает постраничный список ваших объектов «On-Call Schedule Layer User». По умолчанию на странице до десяти записей.

Необязательные query-параметры

  • limit
    число
    Сколько объектов вернуть. По умолчанию 10, максимум 100
  • skip
    число
    Сколько объектов пропустить (для пагинации)

Необязательное тело запроса

Запрос списка

POST
/api/on-call-duty-schedule-layer-user/get-list?skip=0&limit=10
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "select": {
    "onCallDutyPolicyScheduleId": true,
    "onCallDutyPolicyScheduleLayerId": true,
    "projectId": true,
    "userId": true,
    "_id": true
  },
  "query": {},
  "sort": {
    "createdAt": -1
  }
}

Ответ

{
  "count": 10,
  "limit": 10,
  "skip": 0,
  "data": [
    {
      "_id": "37778520-28fe-11f1-b591-3fdcef396aba",
      "onCallDutyPolicyScheduleId": "550e8400-e29b-41d4-a716-446655440000",
      "onCallDutyPolicyScheduleLayerId": "550e8400-e29b-41d4-a716-446655440000",
      "projectId": "550e8400-e29b-41d4-a716-446655440000",
      "userId": "550e8400-e29b-41d4-a716-446655440000"
    },
    {
      "_id": "37778521-28fe-11f1-b591-3fdcef396aba",
      "onCallDutyPolicyScheduleId": "550e8400-e29b-41d4-a716-446655440000",
      "onCallDutyPolicyScheduleLayerId": "550e8400-e29b-41d4-a716-446655440000",
      "projectId": "550e8400-e29b-41d4-a716-446655440000",
      "userId": "550e8400-e29b-41d4-a716-446655440000"
    },
    {
      "_id": "37778522-28fe-11f1-b591-3fdcef396aba",
      "onCallDutyPolicyScheduleId": "550e8400-e29b-41d4-a716-446655440000",
      "onCallDutyPolicyScheduleLayerId": "550e8400-e29b-41d4-a716-446655440000",
      "projectId": "550e8400-e29b-41d4-a716-446655440000",
      "userId": "550e8400-e29b-41d4-a716-446655440000"
    }
  ]
}
GETorPOST/api/on-call-duty-schedule-layer-user/:id/get-item

Получить по ID

Возвращает объект «On-Call Schedule Layer User» по идентификатору.

  • id
    строка
    ID объекта

Необязательное тело запроса

  • select
    По умолчанию возвращается только ID; для других полей используйте select. Подробнее: как выбирать поля.

Запрос одного объекта

POST
/api/on-call-duty-schedule-layer-user/:id/get-item
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "select": {
    "onCallDutyPolicyScheduleId": true,
    "onCallDutyPolicyScheduleLayerId": true,
    "projectId": true,
    "userId": true,
    "_id": true
  }
}

Ответ

{
  "_id": "550e8400-e29b-41d4-a716-446655440000",
  "onCallDutyPolicyScheduleId": "550e8400-e29b-41d4-a716-446655440000",
  "onCallDutyPolicyScheduleLayerId": "550e8400-e29b-41d4-a716-446655440000",
  "projectId": "550e8400-e29b-41d4-a716-446655440000",
  "userId": "550e8400-e29b-41d4-a716-446655440000"
}
POST/api/on-call-duty-schedule-layer-user/count

Количество

Возвращает количество ваших объектов «On-Call Schedule Layer User».

Необязательное тело запроса

Запрос количества

POST
/api/on-call-duty-schedule-layer-user/count
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "query": {}
}

Ответ

{
  "count": 107
}
POST/api/on-call-duty-schedule-layer-user

Создать On-Call Schedule Layer User

Создаёт новый объект.

Запрос создания

POST
/api/on-call-duty-schedule-layer-user
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "data": {
    "onCallDutyPolicyScheduleId": "550e8400-e29b-41d4-a716-446655440000",
    "onCallDutyPolicyScheduleLayerId": "550e8400-e29b-41d4-a716-446655440000",
    "projectId": "550e8400-e29b-41d4-a716-446655440000",
    "userId": "550e8400-e29b-41d4-a716-446655440000",
    "createdByUser": "Example created by user"
  }
}

Ответ

{
  "_id": "550e8400-e29b-41d4-a716-446655440000",
  "onCallDutyPolicyScheduleId": "550e8400-e29b-41d4-a716-446655440000",
  "onCallDutyPolicyScheduleLayerId": "550e8400-e29b-41d4-a716-446655440000",
  "projectId": "550e8400-e29b-41d4-a716-446655440000",
  "userId": "550e8400-e29b-41d4-a716-446655440000"
}
PUT/api/on-call-duty-schedule-layer-user/:id

Обновить по ID

Обновляет объект по ID.

Альтернативные методы

Если клиент не поддерживает PUT, используйте POST или GET с теми же заголовками и телом:

POST/api/on-call-duty-schedule-layer-user/:id/update-item
GET/api/on-call-duty-schedule-layer-user/:id/update-item

Запрос обновления

PUT
/api/on-call-duty-schedule-layer-user/:id
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "data": {
    "userId": "550e8400-e29b-41d4-a716-446655440000",
    "order": 100,
    "user": "Example user"
  }
}

Ответ

{}
DELETE/api/on-call-duty-schedule-layer-user/:id

Удалить по ID

Удаляет объект по ID.

Альтернативные методы

Если клиент не поддерживает DELETE, используйте POST или GET с теми же заголовками и телом:

POST/api/on-call-duty-schedule-layer-user/:id/delete-item
GET/api/on-call-duty-schedule-layer-user/:id/delete-item

Запрос удаления

DELETE
/api/on-call-duty-schedule-layer-user/:id
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY

Ответ

{}

Права доступа

Для операций с ресурсом у ключа API должны быть права. При их отсутствии вернётся ответ 4xx.

Права на чтение

Нужны для чтения On-Call Schedule Layer User

  • Project Owner
  • Project Admin
  • Project Member
  • Read On-Call Schedule Layer
  • Read All Project Resources

Права на создание

Нужны для создания On-Call Schedule Layer User

  • Project Owner
  • Project Admin
  • Project Member
  • Create On-Call Schedule Layer

Права на обновление

Нужны для обновления On-Call Schedule Layer User

  • Project Owner
  • Project Admin
  • Edit On-Call Schedule Layer

Права на удаление

Нужны для удаления On-Call Schedule Layer User

  • Project Owner
  • Project Admin
  • Delete On-Call Schedule Layer