Getting battery charge sensor data by VIN

Getting battery charge sensor data by VIN
If the VIN is filled in for the object and there is a battery charge sensor, use this API.
 
This API implements two requests, both at baseUrl/api/VTB/api_vtb.php, where baseUrl is the website address
 
1. Authorization
Type: POST
Body:
{ "login": "******", "password": "****" "cmd":"auth" }
Response:
{ "token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" }
 
2. Receiving data
In the request header, we use the token from the first request
Type: POST
Body:
{ "Number": ["<vin>"] "DateFrom": "2023-12-03T00:00:00", "DateTo": "2023-12-12T00:00:00" , "cmd":"vehicle" }
 
Response:
[
{ "Number": "456789123", "ApplicationNumber": null, "CurrentStatus": "ACTIVE", "CloseDateTime": "", "LastSyncDate": "2024-08-28 15:42:45", "AlarmDateTime": "2024-08-28 15:42:45", "Latitude": "55.578352", "Longitude": "38.125267", "BatteryCharge": "full charge", "LocationLinesID": "", "FullAddress": "Garnaeva street, Rynok, Zhukovsky, Zhukovsky urban district, Moscow region, RU-MOS, Central Federal District, 140180, Russia, ru", "Country": "Russia", "Region": "Moscow region", "Town": "Zhukovsky", "Street": "Garnaeva street", "House": null, "numberRegion": 10 }
]
To execute the request, the car must have the VIN field filled in.
 
You can specify several VIN numbers in the request, then in the response we will receive information on all requested objects.