Update user vehicles

This API assigns a user access only to the selected vehicles.

How to get data

Request address

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

Request method

 POST

Request parameters

  • cmd=update_user_vehicles — command to update the list of vehicles
  • vehicles — comma-separated list of vehicle IDs
  • user_id — ID of the user whose access is being updated
  • node— node number where the command should be executed
 

Example request

{
    "cmd": "update_user_vehicles",
    "vehicles": "2,18",
    "user_id": 19
}
Response
{
  "code": 0,
  "msg": "Success"
}
In response to the API request, the following is returned:
  • code — result code (0 = successful operation)
  • msg — server message