Omniplex Docs
PopplioProduction

Alerts

These API endpoints are related to user alerts on IBL

GET
/users/{id}/alerts

Get User Alerts

Gets a users alerts.

All alerts are also sent via push notifications if the user has subscribed to them.

/users/{id}/alerts

The Authorization access token

Authorization

User-Auth<token>

Requires a user token. Should be prefixed with User in Authorization header.

In: header

Path Parameters

id
Required
string

User ID

Query Parameters

pagestring

The page number

curl -X GET "https://spider.omniplex.gg/users/string/alerts?page=string" \
  -H "User-Auth: <token>"

Success

{
  "count": 18446744073709552000,
  "per_page": 18446744073709552000,
  "results": {
    "alerts": [
      {
        "acked": true,
        "alert_data": {
          "property1": null,
          "property2": null
        },
        "created_at": "2019-08-24T14:15:22Z",
        "icon": "string",
        "itag": "6b5f8e7b-1e8c-4611-b693-ee8faa950c62",
        "message": "string",
        "priority": "1",
        "title": "string",
        "type": "success",
        "url": "string"
      }
    ],
    "unacked_count": 18446744073709552000
  }
}

PATCH
/users/{id}/alerts

Patch User Alerts

Updates a set of user alerts with a given 'patch' to apply to the alert. Returns 204 on success

/users/{id}/alerts

The Authorization access token

Authorization

User-Auth<token>

Requires a user token. Should be prefixed with User in Authorization header.

In: header

Request Body

application/jsonRequired

patchesarray<object>

List of patches to apply to alerts

Path Parameters

id
Required
string

User ID

curl -X PATCH "https://spider.omniplex.gg/users/string/alerts" \
  -H "User-Auth: <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "patches": [
      {
        "itag": "string",
        "patch": "ack"
      }
    ]
  }'

Success

{
  "context": {
    "property1": "string",
    "property2": "string"
  },
  "message": "string"
}

DELETE
/users/{id}/alerts

Delete All User Alerts

Deletes all user alerts. Returns 204 on success

/users/{id}/alerts

The Authorization access token

Authorization

User-Auth<token>

Requires a user token. Should be prefixed with User in Authorization header.

In: header

Path Parameters

id
Required
string

User ID

curl -X DELETE "https://spider.omniplex.gg/users/string/alerts" \
  -H "User-Auth: <token>"

Success

{
  "context": {
    "property1": "string",
    "property2": "string"
  },
  "message": "string"
}

GET
/users/{id}/alerts/@featured

Gets the featured user alerts of the user.

/users/{id}/alerts/@featured

The Authorization access token

Authorization

User-Auth<token>

Requires a user token. Should be prefixed with User in Authorization header.

In: header

Path Parameters

id
Required
string

User ID

Query Parameters

acked_count
Required
string

The number of alerts to return that have been acknowledged.

unacked_count
Required
string

The number of alerts to return that have not been acknowledged.

curl -X GET "https://spider.omniplex.gg/users/string/alerts/@featured?acked_count=string&unacked_count=string" \
  -H "User-Auth: <token>"

Success

{
  "acked": [
    {
      "acked": true,
      "alert_data": {
        "property1": null,
        "property2": null
      },
      "created_at": "2019-08-24T14:15:22Z",
      "icon": "string",
      "itag": "6b5f8e7b-1e8c-4611-b693-ee8faa950c62",
      "message": "string",
      "priority": "1",
      "title": "string",
      "type": "success",
      "url": "string"
    }
  ],
  "unacked": [
    {
      "acked": true,
      "alert_data": {
        "property1": null,
        "property2": null
      },
      "created_at": "2019-08-24T14:15:22Z",
      "icon": "string",
      "itag": "6b5f8e7b-1e8c-4611-b693-ee8faa950c62",
      "message": "string",
      "priority": "1",
      "title": "string",
      "type": "success",
      "url": "string"
    }
  ],
  "unacked_count": 18446744073709552000
}

GET
/users/{id}/alerts/{itag}

Get User Alert By Itag

Gets a single user alert based on its itag. This returns an alertlist to aid with consistency.

/users/{id}/alerts/{itag}

The Authorization access token

Authorization

User-Auth<token>

Requires a user token. Should be prefixed with User in Authorization header.

In: header

Path Parameters

id
Required
string

User ID

itag
Required
string

The itag of the alert

curl -X GET "https://spider.omniplex.gg/users/string/alerts/string" \
  -H "User-Auth: <token>"

Success

{
  "alerts": [
    {
      "acked": true,
      "alert_data": {
        "property1": null,
        "property2": null
      },
      "created_at": "2019-08-24T14:15:22Z",
      "icon": "string",
      "itag": "6b5f8e7b-1e8c-4611-b693-ee8faa950c62",
      "message": "string",
      "priority": "1",
      "title": "string",
      "type": "success",
      "url": "string"
    }
  ],
  "unacked_count": 18446744073709552000
}