Device alerts

Alert objects

Alert objects consist of the following properties:

id
The alert’s unique identifier.
deviceId
The device that generated the alert.
socketId
If the alert applies to a specific socket, that socket.
message
The message from the charging station.
timeRaised
The timestamp when the alert was raised.
priority
Priority can have a value of 1 to 5: 1=critical, 2=major, 3=warning, 4=informational, 5=debug.
remark
Any remark added by the operator.
handled
Boolean flag that can be set by the operator.

Alert services

GET /abs/frontend/alert

Retrieve a list of charging station alerts. The returned list is ordered by timeRaised descending.

Role:

admin

Query Parameters:
 
  • limit? – The amount of alerts to return (default=100).
  • chargingStationId? – Limit the list of alerts to ones relating to the provided charging station.
  • timeFrom? – Don’t return alerts raised before this timestamp.
  • timeTo? – Don’t return alerts raised after this timestamp.
  • handled? – Only return alerts with the handled flag equal to this value.
  • priority? – Only return alerts with a priority less-or-equal to this value.
Status Codes:
  • 204 – Unknown charging station.

Example response

{ "statusCode": "100", "alerts": [ ...list of alert objects... ] }
GET /abs/frontend/alert/own

As above, but only return alerts associated with the current user’s account.

Role:host
GET /abs/frontend/alert/(id)

Return a specific alert.

Role:

host

Status Codes:
  • 210 – Unknown alert.

Example response

{ "statusCode": "100", "alert": { ... } }
PUT /abs/frontend/alert/(id)

Update an alert.

Role:

hostAdmin

Query Parameters:
 
  • remark? – The updated remark.
  • handled? – The updated handled flag.
Status Codes:
  • 210 – Unknown alert.