Vehicle Parameters
Action: "get_parameters"
Use this API to fetch vehicle parameters.
The response include the last value and time for each parameter.
Request Parameters:
Parameter Name | Type | Mandatory/Optional/Conditional | Description |
---|---|---|---|
vehicle_id | bigint | Conditional | Traffilog unique vehicle id. Either vehicle_id or license_number need to be provided. |
license_number | string | Conditional | Either vehicle_id or license_number need to be provided. |
Request Example:
{
"action": {
"name": "get\_parameters",
"parameters": \[{
"vehicle\_id": "17333522",
"license\_nmbr": ""
}\],
"session\_token": "<<session token>>"
}
}
Response Parameters:
Parameter Name | Type | Occurrences | Description |
---|---|---|---|
vehicle_id | big integer | 1..1 | vehicle id as was provided in the request |
license_number | string | 1..1 | Vehicle license number |
parameter_type | big integer | 1..1 | Parameter unique id |
parameter_type_description | String | 1..1 | Parameter Name |
last_input_value | Float | 1..1 | Parameter Value |
last_input_time | DateTime | 1..1 | Parameter Time. YYYY-MM-DDTHH:MM:SS |
Response Example:
{
"response": {
"properties": {
"action\_name": "get\_parameters",
"data": \[{
"vehicle\_id": "17333522",
"license\_number": "405-L87-B",
"parameter\_type": "496",
"parameter\_type\_description": "Unit Time",
"last\_input\_value": "10662.0000000",
"last\_input\_time": "2017-01-11T12:24:16"
}, {
"vehicle\_id": "173522",
"license\_number": "1017119",
"parameter\_type": "516",
"parameter\_type\_description": "OBD Malfunction Indicator Lamp \(MIL\)",
"last\_input\_value": "00.0000000",
"last\_input\_time": "2017-01-10T13:34:17"
}\],
"action\_value": "0",
"description": "",
"session\_token": "dedb739bf9ac45649922b9c8930d09b44274477308"
}
}
}
Action Values:
action_value | description |
---|---|
0 | success |
1 | Inputs parameters are not valid. one of the mandatory/conditional inputs was not provided. |
2 | The User not allowed for the vehicle/driver or no such vehicle/driver. the trip vehicle is not allowed for the user. |
999 | general error. |