Subscriptions
Subscription Object
Water usage data is provided as a reading object with the following properties
- subscriptionId string
- subscription identifier
- locationId string
- location identifier
- endpoint string
- A secured Fully Qualified Domain Url endpoint that receives location alerts
- status string
- status of the subscription
{
"subscriptionId": "3bb2255b...2a48",
"locationId": "be926a02...dbc9",
"endpoint": "https://example-endpoint.com",
"status": "confirmed"
}
Alert Payload
- subscriptionId string
- Subscription identifier. This property is only available in the alert when the alert is sent to a subscribtion endpoint
- locationId string
- location identifier. This property is only available in the alert when the alert is sent to a subscribtion endpoint
- deviceId string
- device identifier
- type string
- Describes the alert type
- active boolean
true
if alert is alert is currently active- startTime number
- UTC timestamp in seconds of when the sensor reading first exceeded the threshold.
- stopTime number
- UTC timestamp in seconds of when the sensor reading no longer exceeded the threshold. This is the time when the active field changes to
false
. - detectedTime number
- UTC timestamp in seconds of when the sensor reading remained above or below the threshold for the dwellTime. This is the time when the activeactive field changes to
true
. - peakValue number
- The max or min value (depending on alert type) of the sensor reading between the startTime and stopTime
- peakStatus number | null
- Is null for leak alerts. For all other alerts it describes the value as being either too_high or too_low for the threshold
{
"subscriptionId": "3bb2255b...2a48",
"locationId": "ae926a02...dbc8",
"deviceId": "7a0f6726...97f8",
"type": "ambientTemp",
"active": true,
"startTime": 1514373460,
"detectedTime": 1514373760,
"stopTime": 0,
"peakValue": 35,
"peakStatus": null
}