Get alerts and events of devices for company
GET
/partners/companies/{company_name}/devices/alertsReturns an response that contains events and alerts sent by the devices for a company in the time window specified.
Roles with endpoint access
Role | Permission |
---|---|
Partner | |
Partner View | |
Custom Partner | |
Fleet Manager | |
Group Manager | |
User | |
Custom User |
Request
Path Params
company_name
string
required
Name of company in RoscoLive
Query Params
start_ts
string <date-time>
required
Start datetime for response data. YYYYmmddHHMMSS
>= 14 characters<= 14 characters
Example:
20240101000000
end_ts
string <date-time>
optional
End datetime for response data. YYYYmmddHHMMSS
>= 14 characters<= 14 characters
Example:
20240107235959
ids
string
required
Comma-separated values of device IDs to pass into request
page_number
integer
optional
Page number for pagination
page_size
integer
optional
Number of records returned per page for pagination
alert_type
string
optional
Comma-separated list values of alerts to pass into request
event_type
string
optional
Comma-separated list of events to pass into the request
Request samples
Responses
Success(200)
HTTP Code: 200
Content Type : JSONapplication/json
Data Schema
meta
object
required
Request metadata object
code
integer
required
HTTP status code returned by server
response
array [object {4}]
required
Contains response data
alarms
array [object {5}]
optional
List of alarms for device
device_id
integer
optional
Unique ID of device
events
array [object {4}]
optional
vehicle_name
string
optional
Name of device
result
string
required
"OK" if request successful, otherwise "Failed"
Example
{
"meta": {
"code": 200
},
"response": [
{
"alarms": [
{
"alert_type": "UncleanShutdown",
"event_id": null,
"id": 4422724,
"timestamp": "2024-11-14 15:51:04",
"type": "UncleanShutdown"
}
],
"device_id": 51794261,
"events": [
{
"event_display_type": "",
"event_type": "CameraBlock",
"id": 2614875,
"timestamp": "2024-11-18 15:27:28"
},
{
"event_display_type": "",
"event_type": "Max Speed",
"id": 2614877,
"timestamp": "2024-11-18 16:06:47"
},
{
"event_display_type": "",
"event_type": "CameraBlock",
"id": 2614888,
"timestamp": "2024-11-18 17:05:12"
},
{
"event_display_type": "",
"event_type": "CameraBlock",
"id": 2614889,
"timestamp": "2024-11-18 17:59:50"
}
],
"vehicle_name": "Truck A"
}
],
"result": "OK"
}
Last modified: a month ago