get_drive_rank_settings
To get the eco driving criteria of a unit, use the unit/get_drive_rank_settings method.
Endpoint
svc=unit/get_drive_rank_settings¶ms={
"itemId": <long>
}
Parameters
The request must contain the following parameter:
| Parameter | Description |
|---|---|
itemId |
Unit ID. |
Response
If the request is completed successfully, the response contains the eco driving criteria of the unit and their parameters:
{
"acceleration": [...],
"brake": [...],
"turn": [...],
"sensor": [...],
"speeding": [...],
"harsh": [...],
"idling": [...],
"global": {...}
}
The response contains only the criterion types configured for the unit. For all eco driving criteria and parameters, see update_drive_rank_settings.
If the eco driving settings have never been saved for the unit, the response is {"error":0}. If the settings were saved without criteria, the response contains only the global object, or it’s an empty object.
The accel_mode value is returned in the type in which it was saved. Settings saved in the interface contain it as a string, for example, "0".
If the request fails, an error code is returned.
Error codes
| Error code | Description |
|---|---|
| 4 | Wrong input parameters. |
| 7 | The unit doesn’t exist, or the user doesn’t have the View detailed object properties access right to it. |