Skip to content

Notifications⚓︎

Path⚓︎

/v1/notifications

The notifications resource contains information about data thresholds.

Note

By default, this feature is not available. It must be enabled by Expeto.

 


Resource Attributes⚓︎

The attributes for the notifications resource are detailed below:

Attribute Type Required? Description
issued String YES The timestamp when the notification was issued (ISO 8601 format).
type String YES The type of notification, such as ThresholdReached.
hash String YES A unique hash identifying the notification.
payload Object YES Contains details about the notification.
payload.imsi String YES The IMSI (International Mobile Subscriber Identity) of the subscriber.
payload.dataLimit Integer YES Defines the data limit usage for a subscriber in bytes.
payload.dataLimitPeriod String YES Defines the period for calculating data limit usage. Can be absolute or monthly.
payload.dataLimitCustomDate Integer NO Day of the month (1–31) for data-limit reset if dataLimitPeriod is monthly.
payload.totalUsage Integer YES The total data usage of the subscriber in bytes.
payload.thresholdValue Integer YES Threshold defined as a percentage of data usage reached, e.g., 90 for 90%.
consumed Boolean YES Indicates whether the notification has been consumed.

Example⚓︎

{
  "issued": "2020-01-30T14:03:02.231Z",
  "type": "ThresholdReached",
  "hash": "AB1230A01ABC51DDB00A19126143A12319ECAB02C2FDC446CD7C16E42A0E8FB6",
  "payload": {
    "imsi": "123470101231123",
    "dataLimitPeriod": "monthly",
    "dataLimitCustomDate": 1,
    "dataLimit": 1073741824,
    "totalUsage": 966367641,
    "thresholdValue": 90
  },
  "consumed": false
}

 


Endpoints⚓︎

Request Examples⚓︎

Get all available notifications:⚓︎

{baseUrl}/v1/notifications

You can filter your response using any of the following search options:

  • findByHash
  • findByConsumed
  • findBySystem
  • findBySystemAndConsumed
  • findBySubscriber
  • findBySubscriberAndConsumed
  • findByDeepSearch

Get all notifications for a specific system:⚓︎

{baseUrl}/v1/notifications/search/findBySystem?system=<systemID>

Get all notifications for a specific subscriber:⚓︎

{baseUrl}/v1/notifications/search/findBySubscriber?subscriber=<IMSI>