Ресурс

Incident User Owner

Add users as owners to your incidents.

Модель Incident User Owner

Свойства

  • Имя
    _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

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

    User that is the owner. This user will receive notifications.

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

    ID of your User in which this object belongs

  • Имя
    incident
    Тип
    Incident
    Описание

    Relation to Incident Resource in which this object belongs

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

    ID of your Incident in which this object 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)

  • Имя
    isOwnerNotified
    Тип
    BooleanОбязательно
    Описание

    Are owners notified of this resource ownership?

GETorPOST/api/incident-owner-user/get-list

Список

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

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

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

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

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

POST
/api/incident-owner-user/get-list?skip=0&limit=10
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "select": {
    "incidentId": true,
    "isOwnerNotified": true,
    "projectId": true,
    "userId": true,
    "createdByUser": true
  },
  "query": {},
  "sort": {
    "createdAt": -1
  }
}

Ответ

{
  "count": 10,
  "limit": 10,
  "skip": 0,
  "data": [
    {
      "_id": "37731850-28fe-11f1-b591-3fdcef396aba",
      "incidentId": "f6a7b8c9-d0e1-2345-fabc-456789012345",
      "isOwnerNotified": false,
      "projectId": "5f8b9c0d-e1a2-4b3c-8d5e-6f7a8b9c0d1e",
      "userId": "e5f6a7b8-c9d0-1234-efab-345678901234",
      "createdByUser": "c3d4e5f6-a7b8-9012-cdef-123456789012"
    },
    {
      "_id": "37731851-28fe-11f1-b591-3fdcef396aba",
      "incidentId": "f6a7b8c9-d0e1-2345-fabc-456789012345",
      "isOwnerNotified": false,
      "projectId": "5f8b9c0d-e1a2-4b3c-8d5e-6f7a8b9c0d1e",
      "userId": "e5f6a7b8-c9d0-1234-efab-345678901234",
      "createdByUser": "c3d4e5f6-a7b8-9012-cdef-123456789012"
    },
    {
      "_id": "37731852-28fe-11f1-b591-3fdcef396aba",
      "incidentId": "f6a7b8c9-d0e1-2345-fabc-456789012345",
      "isOwnerNotified": false,
      "projectId": "5f8b9c0d-e1a2-4b3c-8d5e-6f7a8b9c0d1e",
      "userId": "e5f6a7b8-c9d0-1234-efab-345678901234",
      "createdByUser": "c3d4e5f6-a7b8-9012-cdef-123456789012"
    }
  ]
}
GETorPOST/api/incident-owner-user/:id/get-item

Получить по ID

Возвращает объект «Incident User Owner» по идентификатору.

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

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

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

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

POST
/api/incident-owner-user/:id/get-item
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "select": {
    "incidentId": true,
    "isOwnerNotified": true,
    "projectId": true,
    "userId": true,
    "createdByUser": true
  }
}

Ответ

{
  "_id": "37731850-28fe-11f1-b591-3fdcef396aba",
  "incidentId": "f6a7b8c9-d0e1-2345-fabc-456789012345",
  "isOwnerNotified": false,
  "projectId": "5f8b9c0d-e1a2-4b3c-8d5e-6f7a8b9c0d1e",
  "userId": "e5f6a7b8-c9d0-1234-efab-345678901234",
  "createdByUser": "c3d4e5f6-a7b8-9012-cdef-123456789012"
}
POST/api/incident-owner-user/count

Количество

Возвращает количество ваших объектов «Incident User Owner».

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

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

POST
/api/incident-owner-user/count
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "query": {}
}

Ответ

{
  "count": 107
}
POST/api/incident-owner-user

Создать Incident User Owner

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

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

POST
/api/incident-owner-user
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "data": {
    "incidentId": "f6a7b8c9-d0e1-2345-fabc-456789012345",
    "isOwnerNotified": false,
    "projectId": "5f8b9c0d-e1a2-4b3c-8d5e-6f7a8b9c0d1e",
    "userId": "e5f6a7b8-c9d0-1234-efab-345678901234",
    "createdByUser": "c3d4e5f6-a7b8-9012-cdef-123456789012"
  }
}

Ответ

{
  "_id": "37731850-28fe-11f1-b591-3fdcef396aba",
  "incidentId": "f6a7b8c9-d0e1-2345-fabc-456789012345",
  "isOwnerNotified": false,
  "projectId": "5f8b9c0d-e1a2-4b3c-8d5e-6f7a8b9c0d1e",
  "userId": "e5f6a7b8-c9d0-1234-efab-345678901234",
  "createdByUser": "c3d4e5f6-a7b8-9012-cdef-123456789012"
}
PUT/api/incident-owner-user/:id

Обновить по ID

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

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

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

POST/api/incident-owner-user/:id/update-item
GET/api/incident-owner-user/:id/update-item

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

PUT
/api/incident-owner-user/:id
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY
Тело
{
  "data": {}
}

Ответ

{}
DELETE/api/incident-owner-user/:id

Удалить по ID

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

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

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

POST/api/incident-owner-user/:id/delete-item
GET/api/incident-owner-user/:id/delete-item

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

DELETE
/api/incident-owner-user/:id
Заголовки
Content-Type: application/json
ApiKey: YOUR_API_KEY

Ответ

{}

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

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

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

Нужны для чтения Incident User Owner

  • Project Owner
  • Project Admin
  • Project Member
  • Read Incident User Owner
  • Read All Project Resources

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

Нужны для создания Incident User Owner

  • Project Owner
  • Project Admin
  • Project Member
  • Create Incident User Owner

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

Нужны для обновления Incident User Owner

  • Project Owner
  • Project Admin
  • Project Member
  • Edit Incident User Owner

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

Нужны для удаления Incident User Owner

  • Project Owner
  • Project Admin
  • Project Member
  • Delete Incident User Owner