SDK Reference
Routes, Sensors, and Cameras Vehicle route history, temperature/humidity reports, sensor inventory, and camera event helpers.
GET
Get vehicle route history /vehicles/{vehicleId}/routeslinxio.routes.getVehicleRoutes(vehicleId, params)
Fetches route history for one vehicle. Request coordinates only when
you need every recorded point.
Important
Vehicle route history can return large payloads. Use date ranges and field projection deliberately. If your tenant has many vehicles and/or vehicles with long route histories, avoid using routes.getVehicleRoutes() in production implementations.
Input vehicleIdLinxioId
required Object parameter. Expand to see child parameters.
Show child parameters dateFromISODateString
optional dateToISODateString
optional fieldsRouteField[]
optional Route fields to include in the response projection.
Possible enum values
coordinatesRoute coordinate points. This can produce large responses.
driverDriver summary for each route.
vehicleVehicle summary for each route.
addressResolved start/finish addresses.
Limit accepted by the route endpoint.
Page accepted by the route endpoint.
Returns Route groups by vehicle/driver, each with route segments.
Show child fields driverIdLinxioId | null
optional Route segments for the group.
vehicleIdLinxioId
required Typed SDK error when routes cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
const routes = await linxio.routes. getVehicleRoutes (vehicleId, {
dateFrom: "2026-06-01T00:00:00+08:00" ,
dateTo: "2026-06-08T00:00:00+08:00" ,
fields: [ "address" ],
});
if (routes.error) {
throw routes.error;
} Include coordinates only when needed const routesWithPoints = await linxio.routes. getVehicleRoutes (vehicleId, {
dateFrom,
dateTo,
fields: [ "coordinates" ],
}); {
"data" : [
{
"driverId" : "36541" ,
"routes" : [
{
"address" : "string" ,
"avgSpeed" : 0 ,
"comment" : "string" ,
"coordinates" : [
{ }
] ,
"deviceId" : 124210 ,
"distance" : 0 ,
"driverId" : "36541" ,
"duration" : 0 ,
"id" : 64553 ,
"maxSpeed" : 123 ,
"pointFinish" : { } ,
"pointStart" : { } ,
"scope" : { } ,
"type" : "Truck" ,
"vehicleId" : 64553
}
] ,
"vehicleId" : 64553
}
] ,
"error" : null
}
Input Object parameter. Expand to see child parameters.
Show child parameters Number of sensors to request.
Page number to request.
Default: 1
fieldsSensorField[]
optional Sensor fields to include in the response projection.
Possible enum values
labelSensor display label.
sensorIdHardware sensor identifier.
systemStatusSensor system status.
Returns Sensor records for the requested page.
Show child fields createdAtISODateString | null
optional Sensor creation timestamp.
deviceIdLinxioId | null
optional labelstring | null
optional sensorIdstring | null
optional Hardware sensor identifier.
systemStatusstring | null
optional teamLinxioRecord | null
optional typestring | null
optional updatedAtISODateString | null
optional vehicleIdLinxioId | null
optional Pagination metadata.
Show child fields Total matching record count.
Typed SDK error when sensors cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
const sensors = await linxio.sensors. list ({
limit: 25 ,
page: 1 ,
});
if (sensors.error) {
throw sensors.error;
} {
"data" : [
{
"createdAt" : "2026-01-15T04:07:48+00:00" ,
"deviceId" : 124210 ,
"id" : 64553 ,
"label" : "Example Label" ,
"sensorId" : "string" ,
"systemStatus" : "active" ,
"team" : {
"id" : 5932 ,
"type" : "client" ,
"clientId" : 5598 ,
"resellerId" : null ,
"resellerName" : null ,
"clientName" : "EXAMPLE CLIENT"
} ,
"type" : "Truck" ,
"updatedAt" : "2026-05-30T00:35:15+00:00" ,
"vehicleId" : 64553
}
] ,
"meta" : {
"limit" : 100 ,
"page" : 1 ,
"total" : 2
} ,
"error" : null
}
Returns Sensor record.
Show child fields createdAtISODateString | null
optional Sensor creation timestamp.
deviceIdLinxioId | null
optional labelstring | null
optional sensorIdstring | null
optional Hardware sensor identifier.
systemStatusstring | null
optional teamLinxioRecord | null
optional typestring | null
optional updatedAtISODateString | null
optional vehicleIdLinxioId | null
optional Typed SDK error when the sensor cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
const sensor = await linxio.sensors. get (sensorId);
if (sensor.error) {
throw sensor.error;
} {
"data" : {
"createdAt" : "2026-01-15T04:07:48+00:00" ,
"deviceId" : 124210 ,
"id" : 64553 ,
"label" : "Example Label" ,
"sensorId" : "string" ,
"systemStatus" : "active" ,
"team" : {
"id" : 5932 ,
"type" : "client" ,
"clientId" : 5598 ,
"resellerId" : null ,
"resellerName" : null ,
"clientName" : "EXAMPLE CLIENT"
} ,
"type" : "Truck" ,
"updatedAt" : "2026-05-30T00:35:15+00:00" ,
"vehicleId" : 64553
} ,
"error" : null
}
Returns Updated sensor record.
Show child fields createdAtISODateString | null
optional Sensor creation timestamp.
deviceIdLinxioId | null
optional labelstring | null
optional sensorIdstring | null
optional Hardware sensor identifier.
systemStatusstring | null
optional teamLinxioRecord | null
optional typestring | null
optional updatedAtISODateString | null
optional vehicleIdLinxioId | null
optional Typed SDK error when install fails.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
const installed = await linxio.sensors. install (sensorId, deviceId);
if (installed.error) {
throw installed.error;
} {
"data" : {
"createdAt" : "2026-01-15T04:07:48+00:00" ,
"deviceId" : 124210 ,
"id" : 64553 ,
"label" : "Example Label" ,
"sensorId" : "string" ,
"systemStatus" : "active" ,
"team" : {
"id" : 5932 ,
"type" : "client" ,
"clientId" : 5598 ,
"resellerId" : null ,
"resellerName" : null ,
"clientName" : "EXAMPLE CLIENT"
} ,
"type" : "Truck" ,
"updatedAt" : "2026-05-30T00:35:15+00:00" ,
"vehicleId" : 64553
} ,
"error" : null
}
Input Object parameter. Expand to see child parameters.
Show child parameters startDate / params.endDateISODateString
optional Optional report date range.
dateFrom / params.dateToISODateString
optional Alternative date range names accepted by some Linxio report flows.
vehicleIdLinxioId
optional Number of readings to request.
Returns Temperature/humidity readings for the requested page.
Show child fields humiditynumber | null
optional occurredAtISODateString
optional temperaturenumber | null
optional vehicleIdLinxioId
optional Pagination metadata.
Show child fields Total matching record count.
Typed SDK error when readings cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
Device temp/humidity report const report = await linxio.sensors. deviceTemperatureHumidityReport ({
startDate: "2026-06-01T00:00:00+08:00" ,
endDate: "2026-06-08T00:00:00+08:00" ,
limit: 100 ,
});
if (report.error) {
throw report.error;
} {
"data" : [
{
"humidity" : 123 ,
"occurredAt" : "2026-06-08T12:00:00+08:00" ,
"sensorId" : 64553 ,
"temperature" : 123 ,
"vehicleId" : 64553
}
] ,
"meta" : {
"limit" : 100 ,
"page" : 1 ,
"total" : 2
} ,
"error" : null
}
Input Date range, pagination, sensorId, vehicleId, and other report filters.
Show child parameters fieldsFieldSelector<TField>
optional Field projection sent as repeated fields[] query parameters.
Maximum records to request per page.
Page number to request.
Default: 1
Sort expression accepted by Linxio for that endpoint.
[filter]QueryValue
optional Additional endpoint-specific filters forwarded as query parameters.
Sensor identifier filter.
vehicleIdLinxioId
optional Vehicle identifier filter.
dateFrom / dateToISODateString
optional Date range for the sensor report.
Returns Temperature/humidity readings for the requested page.
Show child fields humiditynumber | null
optional occurredAtISODateString
optional temperaturenumber | null
optional vehicleIdLinxioId
optional Pagination metadata.
Show child fields Total matching record count.
Typed SDK error when readings cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
Vehicle temp/humidity report const report = await linxio.sensors. vehicleTemperatureHumidityReport ({
vehicleId,
startDate,
endDate,
limit: 100 ,
});
if (report.error) {
throw report.error;
} {
"data" : [
{
"humidity" : 123 ,
"occurredAt" : "2026-06-08T12:00:00+08:00" ,
"sensorId" : 64553 ,
"temperature" : 123 ,
"vehicleId" : 64553
}
] ,
"meta" : {
"limit" : 100 ,
"page" : 1 ,
"total" : 2
} ,
"error" : null
}
Important
Device temperature and humidity reports can return large payloads, especially when using the iterate method. Use pagination, date ranges, and field projection deliberately. Avoid using iterate() in production implementations. It is better to use sensors.streamDeviceTemperatureHumidityReport() for lazy async iteration where possible.
Input Same parameters as deviceTemperatureHumidityReport().
Show child parameters fieldsFieldSelector<TField>
optional Field projection sent as repeated fields[] query parameters.
Maximum records to request per page.
Page number to request.
Default: 1
Sort expression accepted by Linxio for that endpoint.
[filter]QueryValue
optional Additional endpoint-specific filters forwarded as query parameters.
Sensor identifier filter.
vehicleIdLinxioId
optional Vehicle identifier filter.
dateFrom / dateToISODateString
optional Date range for the sensor report.
Returns Flat array containing every loaded reading.
Show child fields humiditynumber | null
optional occurredAtISODateString
optional temperaturenumber | null
optional vehicleIdLinxioId
optional Typed SDK error if any page fails.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
const { data : readings , error } =
await linxio.sensors. iterateDeviceTemperatureHumidityReport ({
startDate,
endDate,
limit: 100 ,
});
if (error) {
throw error;
} {
"data" : [
{
"humidity" : 123 ,
"occurredAt" : "2026-06-08T12:00:00+08:00" ,
"sensorId" : 64553 ,
"temperature" : 123 ,
"vehicleId" : 64553
}
] ,
"error" : null
}
Input Same parameters as deviceTemperatureHumidityReport().
Show child parameters fieldsFieldSelector<TField>
optional Field projection sent as repeated fields[] query parameters.
Maximum records to request per page.
Page number to request.
Default: 1
Sort expression accepted by Linxio for that endpoint.
[filter]QueryValue
optional Additional endpoint-specific filters forwarded as query parameters.
Sensor identifier filter.
vehicleIdLinxioId
optional Vehicle identifier filter.
dateFrom / dateToISODateString
optional Date range for the sensor report.
Returns One reading at a time.
Show child fields humiditynumber | null
optional occurredAtISODateString
optional temperaturenumber | null
optional vehicleIdLinxioId
optional Thrown if a page request fails.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
for await ( const reading of linxio.sensors. streamDeviceTemperatureHumidityReport ({
startDate,
endDate,
limit: 100 ,
})) {
console. log (reading.occurredAt, reading.temperature, reading.humidity);
} {
"yield" : {
"humidity" : 123 ,
"occurredAt" : "2026-06-08T12:00:00+08:00" ,
"sensorId" : 64553 ,
"temperature" : 123 ,
"vehicleId" : 64553
}
}
Input Pagination, field projection, sorting, and camera-event filters.
Returns dataLinxioRecord[] | null
optional Pagination metadata.
Show child fields Total matching record count.
Typed SDK error when camera events cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.
const events = await linxio.cameras. events ({
limit: 100 ,
page: 1 ,
});
if (events.error) {
throw events.error;
} {
"data" : [
{ }
] ,
"meta" : {
"limit" : 100 ,
"page" : 1 ,
"total" : 2
} ,
"error" : null
}
Input eventTypes() does not take parameters.
Returns dataLinxioRecord[] | null
optional Camera event type records.
Typed SDK error when event types cannot be loaded.
Show child fields Original cause when available.
HTTP method when the error came from a request.
API path when the error came from a request.
Request identifier from X-Request-Id when supplied.