broker: notification/insert
Notifies the user about new device notification.
Subscription Topic and Payload
Topic
dh/notification/{network-id}/{devicetype-id}/{device-id}/{notification-name}
Where:
- network-id - DeviceHive Network ID
- devicetype-id - DeviceHive DeviceType ID
- device-id - DeviceHive Device ID
- notification-name - Notification name
Payload Representation
{
"action": {string},
"subscriptionId": {guid},
"notification": {
"id": {integer},
"notification": {string},
"deviceId": {string},
"timestamp": {datetime},
"parameters": {object}
}
}
Payload Parameters
Property Name | Type | Description |
---|---|---|
action | string | Action name: notification/insert |
subscriptionId | guid | Identifier of the associated subscription. |
notification | object | A DeviceNotification resource representing the notification. |
notification.id | integer | Notification identifier. |
notification.notification | string | Notification name. |
notification.deviceId | string | Device unique identifier. |
notification.timestamp | datetime | Notification timestamp (UTC). |
notification.parameters | object | Notification parameters, a JSON object with an arbitrary structure. |
Updated almost 7 years ago