gRPC API
Connection
| Server | api.vestigeview.app:443 (gRPC over TLS) |
| Service | vestige.api.v1.ApiService |
| Service definition | Download vestige-api.proto |
| Reflection | Enabled |
| Auth | Bearer token, see Authentication |
There is no official SDK. Generate a client for your language from vestige-api.proto with the standard gRPC tools. You can also explore the API with Postman or grpcurl, which read the service definition through reflection:
grpcurl -H "authorization: Bearer $TOKEN" api.vestigeview.app:443 list vestige.api.v1.ApiService
grpcurl -H "authorization: Bearer $TOKEN" -d '{}' \
api.vestigeview.app:443 vestige.api.v1.ApiService/GetAssets
Every call sees only the vehicles and drivers of the account your credentials belong to.
Methods
| Method | Returns | Access |
|---|---|---|
GetAssets | All vehicles: ID and name | Read |
GetAssetStatuses | Latest odometer, ignition, location, engine hours, battery level of one vehicle | Read |
GetAssetExtendedProperties | VIN, year, make, model, colour of one vehicle | Read |
GetAssetDiagnosticTroubleCodeDailyBuckets | Diagnostic trouble codes per day, for a date range | Read |
GetDrivers | All drivers: ID and name | Read |
PushDriverAssignment | Records that a driver took a vehicle | Write |
UnassignVehicle | Records that a vehicle has no driver | Write |
UnassignDriver | Records that a driver has no vehicle | Write |
GetAssets
Takes no parameters. Returns every vehicle with its Id and Name. Drivers are not included; use GetDrivers for those.
GetAssetStatuses
Returns the latest known value of each status you ask for.
{
"AssetId": "0b7d9f3e-6a4c-4d8e-9a59-3d2f1c0e8b71",
"StatusTypes": ["LOCATION", "IGNITION", "ODOMETER"]
}
List every status you want in StatusTypes. A status you do not list is not returned.
| Status type | Value | Unit |
|---|---|---|
ODOMETER | Value | km |
IGNITION | Value | true = on |
LOCATION | Latitude, Longitude, Speed, Address, DisplayName | degrees, km/h |
ENGINEONDURATION | Value | hours |
ENGINEBATTERYLEVEL | Value | volts |
Each status has its own Date: the time the vehicle reported that value. A status the vehicle has never reported is missing from the reply.
GetAssetExtendedProperties
Returns the properties of one vehicle that you ask for by key:
| Key | Meaning |
|---|---|
Asset.Details.Vin | VIN |
Asset.Details.Year | Model year |
Asset.Details.Make | Make |
Asset.Details.Model | Model |
Asset.Details.Color | Colour |
GetAssetDiagnosticTroubleCodeDailyBuckets
Returns the diagnostic trouble codes of one vehicle, grouped by day. FromDate and ToDate use the format yyyy-MM-dd.
GetDrivers
Takes no parameters. Returns every driver with its Id and Name.
Driver assignment
These calls change data in VestigeView, so read-only credentials cannot use them. Credentials without write access receive PERMISSION_DENIED. Contact us if your integration needs to write.
PushDriverAssignmentrecords that a driver took a vehicle at a point in time.VehicleIdcomes fromGetAssets,DriverIdfromGetDrivers.UnassignVehiclerecords that a vehicle has no driver from a point in time. It does not say where the previous driver went.UnassignDriverrecords that a driver has no vehicle from a point in time. It does not say who now has the vehicle. Use it when you know the driver finished, not that the vehicle became empty.
For all three:
Dateis UTC with whole-second resolution. Sub-second values and future dates are rejected.- A reply of
Accepted: truemeans the change is queued. It is applied moments later, so a read straight after may not show it yet.
Errors
| Status code | Cause |
|---|---|
UNAUTHENTICATED | The token is missing, wrong or expired |
PERMISSION_DENIED | Your credentials cannot do this, for example a write with read-only access |
INVALID_ARGUMENT | A parameter is malformed, for example an ID that is not a GUID or a bad date |
NOT_FOUND | The vehicle or driver does not exist, or is not in your account |