Generate virtual event

Generate a virtual event. Optionally, media (a video or an image) may be uploaded to the cloud, or no media.

Important: For best results, when uploading media always use the quality and durationSeconds parameters.

To receive media from all lenses, leave out the cameraId parameter.
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.

Note: POST calls create new data, and do not affect existing data.

Request
Security:
path Parameters
imei
required
string (IMEI)

The IMEI of the device. The IMEI number can be found on a sticker on the device itself or on the back of the device box.

Example: 357660101000198
Request Body schema: application/json
time
required
string <date-time> (Time)

The time, in ISO 8601 format.

mediaType
string
Default: "video"

The type of media uploaded.

Enum: "none" "video" "snapshot"
durationSeconds
number [ 1 .. 86400 ]
Default: 10

The length of the video, in seconds. Half of the video is from before the event is triggered, and half is from after. The duration of the video may differ from the time requested, depending on the availability of the recordings. Only applies to the video mediaType. For video, include this parameter for best results.

quality
string
Default: "standard"

The quality of the video. This parameter is optional but should be included for best results.
If set to 'standard', the resulting recording will be 1 frame per second.
If set to 'high', the resulting recording will inherit its framerate from the data profile.
If this parameter is not set, the resulting recording will default to 1 frame per second.

Enum: "standard" "high"
cameraId
number

The ID of the in-cab or road-facing lens, or any paired auxiliary camera. Include this parameter for best results.

1 - road-facing lens, 2 - in-cab lens, 50+ - auxiliary cameras.

metadata
string

The metadata of the event.

visualAlert
boolean

Whether a visual alert is shown on the device screen when an event occurs.

audioAlert
boolean

Whether an audio alert is played when an event occurs.

Responses
200

Successful operation

400

Bad request error

401

Unauthorized error

403

Forbidden error

404

Not found error

417

Expectation failed error

423

Locked error

500

Internal server error

post/devices/{imei}/virtual-event
Request samples
application/json
{
  • "time": "2020-01-01T14:48:00.000Z",
  • "mediaType": "none",
  • "durationSeconds": 10,
  • "quality": "standard",
  • "cameraId": 1,
  • "metadata": "string",
  • "visualAlert": true,
  • "audioAlert": true
}
Response samples
application/json
{
  • "data": {
    },
  • "requestId": "df5fg-45fgfdsg-45fg-45454"
}