Skip to main content

Notification stream

The notification stream sends you events and location updates as they happen. Use it when you need real-time alerts, such as a driver pressing the panic button, or when you want to keep every location and event in your own database.

Optional

Most integrations do not need the notification stream. We set it up only on request. See Access, limits and support.

How it works​

  1. Transit Technologies creates an Azure Storage Queue for your account.
  2. We send you a SAS URL for the queue. The SAS lets you read and delete messages only.
  3. VestigeView adds a message to the queue for each update.
  4. Your service reads each message, processes it, then deletes it.

You do not need an Azure account. Any Azure Storage Queue SDK, or a plain HTTPS client, can read the queue.

You choose what we publish: specific events, every new GPS fix, or both.

Message format​

Each message is a vestige.published.v2_1.RootMessage protobuf, Base64-encoded.

Download vestige.published.v2.proto

Every message carries one TimelineUpdate:

FieldMeaning
AssetIdVehicle ID, the same as in the gRPC API
DateTime of the update, UTC
SubscriptionIdYour account ID
AssetExternalIdYour own ID for the vehicle, if set up (see below)
SubscriptionExternalIdYour own ID for the account, if set up
EventThe event, when the update is an event
LocationLatest GPS fix: Lat, Lng, Speed (km/h), Heading (degrees)
IgnitionLatest ignition state
OdometerLatest odometer reading (km)
EngineHoursLatest engine hours (hours)
DiagnosticTroubleCodesLatest diagnostic trouble codes
BodyCamRecording…Body camera lifecycle, see below

Each of Location, Ignition, Odometer, EngineHours and DiagnosticTroubleCodes has its own Date: when the vehicle reported that value. It can be earlier than the update's Date.

Your own vehicle ID​

If you want your own ID for each vehicle in AssetExternalId, tell us which VestigeView field holds it. We can use the vehicle's VIN or its driver code.

Events​

FieldMeaning
DateWhen the event happened, UTC
NameEvent name as set up in VestigeView, for example "Panic"
RoleWhat the event means, see below
MediaUrlLink to the VestigeView page that shows the event media
RoleMeaning
UnspecifiedDefault
NoneThe event has no special role
PanicButtonThe driver pressed the panic button
WheelchairNoSeatbeltA passenger in the wheelchair position is not wearing a seatbelt
WheelchairNoSecurementA wheelchair is not secured in the vehicle

Match on Role, not Name. Names can differ between accounts.

Body camera recordings​

For vehicles with a body camera, we publish three messages as a recording goes on:

  1. BodyCamRecordingIntent: the officer pressed record. Footage is not available yet.
    • EventDate: when the button was pressed
    • GpsLocation (optional): GPS fix at that moment
  2. BodyCamRecordingEnded: the recording ended, and we have queued the footage for retrieval.
    • RecordingStartDate, RecordingEndDate
    • GpsLocations: GPS track of the recording, up to 100 evenly spaced points
    • MediaUrl: link to the VestigeView page for the recording
  3. BodyCamRecordingMediaAvailable: the footage is retrieved and you can download it.
    • The same fields as BodyCamRecordingEnded, plus
    • Mp4Urls: direct download links for the MP4 files

Reading the queue​

var queue = new QueueClient(new Uri(sasUrl),
new QueueClientOptions { MessageEncoding = QueueMessageEncoding.Base64 });

foreach (var msg in (await queue.ReceiveMessagesAsync(maxMessages: 32)).Value)
{
var update = RootMessage.Parser.ParseFrom(msg.Body.ToArray()).TimelineUpdate;
// ... store or act on the update ...
await queue.DeleteMessageAsync(msg.MessageId, msg.PopReceipt);
}

Delete a message only after you have processed it. If you do not delete it, it becomes visible again when its visibility timeout ends, and you receive it again.

Delivery is at-least-once

You can receive the same update more than once. Use AssetId + Date + message type to find duplicates and ignore them.

Retention​

A message stays in the queue for 7 days. After that, it is removed and you cannot get it back. Read the queue all the time.

The SAS URL​

The SAS URL has an expiry date. We send you a new one before it expires. Store it as a secret: anyone who has it can read and delete your messages.