Equipment management

This API allows you to retrieve sensor activity data for a vehicle over a selected period. Using it, you can:
— track periods when sensors were active (e.g., ignition, equipment turned on)
— obtain location data when a sensor was triggered
— analyze vehicle behavior and equipment usage

How to get data

Method

GET

Request address

To get the data, use the address:  https://<server_address>/api/api.php?

Request parameters

  • cmd=sensors — command to get sensor data
  • imei — vehicle identifier in the system
  • start — start time of the period (Unix timestamp)
  • stop — end time of the period (Unix timestamp)
  • node — node number where the command is executed
 

Example request

https://<server_address>/api/api.php?cmd=sensors&imei=356307046690011&start=1404637430&stop=1404645198&node=1
Response
Each sensor is represented as an object where the key is the sensor ID in the system:
"sensors": {
    "9175": {
        "fieldname": "DIS1",
        "info": "Ignition sensor",
        "id": 9175,
        "work": {
            "1404637430": {
                "ts": 1404637430,
                "te": 1404637834,
                "lat": "46.3825",
                "lon": "48.0031",
                "place": "Russia, Astrakhan Region, Narimanovsky District, Nikolaevskoye Highway, 1b"
            },
            "1404638577": {
                "ts": 1404638577,
                "te": 1404639841,
                "lat": "46.3625",
                "lon": "48.0478",
                "place": "RU, Astrakhan, Savushkina Street"
            }
            // ... more sensor activity periods
        }
    }
}
 
In response to the API request, the following is returned:
  • fieldname — sensor field name in the system (e.g., DIS1)
  • info — sensor description in the system (e.g., "Ignition sensor")
  • id — sensor ID in the system
  • work — object containing sensor activity periods; keys are start times (ts)
  • ts — sensor activation time (Unix timestamp)
  • te — sensor deactivation time (Unix timestamp)
  • lat — latitude when the sensor was activated
  • lon — longitude when the sensor was activated
  • place — address or location when the sensor was triggered