Retrieve a list of a device's events in a given time range. The retention period for events is thirty days.
If multiple events are generated with the same timestamp, to the second, and the same media type, the media file from the last request is used for all of them. To have different media files for each virtual event, use timestamps that differ by at least a second.
The maximum period between start and end must be less(or equal) than 31 days.
Successful operation
Bad request error
Unauthorized error
Forbidden error
Not found error
Internal server error
curl -i -X GET \ 'https://api-prod.surfsight.net/v2/devices/:imei/events?start=2020-01-01T14%3A48%3A00.000Z&end=2020-01-01T14%3A48%3A00.000Z&status=new&limit=199&offset=1' \ -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{- "data": [
- {
- "id": 3,
- "eventType": "cellPhoneUse",
- "imei": "357660101000198",
- "time": "2020-01-01T14:48:00.000Z",
- "lat": 32.0598671,
- "lon": 34.7827316,
- "uniqueness": "357660102858164_button_1697358575",
- "speed": 81.04,
- "accuracy": 4,
- "status": "new",
- "severity": 1,
- "eventComments": [
- {
- "id": 125,
- "comment": "string",
- "createdByAudienceName": "surfsight",
- "createdById": 625,
- "createdBy": {
- "id": 32,
- "email": "email@email.com"
}, - "createdAt": "2019-08-24T14:15:22Z"
}
], - "files": [
- {
- "cameraId": 1,
- "fileType": "video",
- "fileId": "1595077872",
- "mediaAvailable": true
}
], - "geoFenceId": 3,
- "metadata": "{type:'Test event', scope:'Some test scope'}"
}
], - "metadata": {
- "count": 56,
- "limit": 60,
- "offset": 10
}
}