Engine hours
How long a tracker's engine ran over a period, counted per day.
Engine hours are the time a tracker's engine spent running over a period.
The count comes from the device's ignition input, so a model without one answers error 214.
Date and time values follow the platform formats.
API actions
API base path: /tracker/stats/engine_hours.
Get the engine hours counted for a period, meaning the time the engine was on.
The device needs an ignition input; models without one answer error 214.
Either a user session hash or an API key, with the "NVX " prefix, for example "NVX 22eac1c27af4be7b9d04da2ce1af111b". Obtain a session hash from the userAuth operation, or create an API key from the API keys operations. A small number of operations accept a session hash only and reject an API key with error code 4; each says so in its description.
ID of the tracker, also known as the object ID. Must belong to the current account and not be blocked.
123456Start of the period, YYYY-MM-DD HH:MM:SS, in the account timezone.
2020-09-24 03:24:00End of the period. Must be after from.
2020-09-24 06:24:00The engine hours
true if request finished successfully.
trueEngine hours counted for the period.
42Bad request. The response body carries the API-level error code in status.code. Validation failures also include an errors array naming each offending parameter.
Error 204: no tracker with this ID belongs to the account. Error 208: the tracker exists but is blocked, normally because its tariff ended. Error 211: the period is longer than the platform allows. Error 214: the device has no ignition input. Error 219: the tracker is a clone.
Error response object
POST /v2/tracker/stats/engine_hours/read HTTP/1.1
Host: api.eu.navixy.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 77
{
"tracker_id": 123456,
"from": "2020-09-24 03:24:00",
"to": "2020-09-24 06:24:00"
}{
"success": true,
"value": 42
}Errors
These errors come in addition to the general error codes:
204 - No tracker with this ID belongs to the account.
208 - The tracker exists but is blocked, normally because its tariff ended.
211 - The period is longer than the Navixy platform allows.
214 - The device has no ignition input.
219 - The tracker is a clone.
Last updated
Was this helpful?