Associations Users
Create Vehicles Associations Users
POST /v2/vehicles/associations/users
Payload
{
"body": {
"data": [
{
"vehicle_id": "ABC1234567890DEF",
"user_id": "GHI9876543210JKL"
},
{
"vehicle_id": "MNO4567890123PQR",
"user_id": "STU2109876543VWX"
}
]
}
}
Field | Description | Required |
---|---|---|
data | Object | true |
vehicle_id | String named after the ID of the vehicle associated with the user. Must be alphanumeric and 15 characters long. | true |
user_id | String named after the ID of the user associated with the vehicle. Must be alphanumeric and 15 characters long. | true |
Responses
Status | Meaning | Description |
---|---|---|
200 | OK | Default Response |
400 | Bad Request | One of 'Bad Request' or 'Vehicle And User Are in Different Enterprises' |
This operation does not require authentication
Delete Vehicles Associations Users
DELETE /v2/vehicles/associations/users
Payload
{
"body": {
"data": [
{
"type": "user_permission",
"id": "ABC1234567890DEF"
},
{
"type": "user_permission",
"id": "GHI9876543210JKL"
}
]
}
}
Field | Description | Required |
---|---|---|
data | Object | |
type | String named after the type of permission, which must be equal to 'user_permission'. | true |
id | String named after the ID of the permission. Must be alphanumeric and 15 characters long. | true |
Responses
Status | Meaning | Description |
---|---|---|
200 | OK | Default Response |
400 | Bad Request | Bad Request |
404 | Not Found | Association Not Found |
This operation does not require authentication
List Vehicles Associations Users
GET /v2/vehicles/{vehicle_id}/associations/users
Parameter | Description |
---|---|
attributes | Specifies which attributes to retrieve. Can include values like 'serial', 'number', 'carrier', 'service_provider', and 'batch'. If null, retrieves all information. |
includes | Specifies related entities to include in the query. Contains arrays for 'device' and 'enterprise', each with its own set of possible values, such as 'name', 'imei', 'code' for the 'device' array, and 'name', 'cnpj' for the 'enterprise' array. |
filters | Specifies filters for various fields such as 'chips.serial', 'chips.number', 'chips.carrier', 'chips.service_provider', 'chips.batch', 'device.name', 'device.imei', 'device.code', 'enterprise.name', 'enterprise.cnpj'. Each filter field supports conditions like 'eq', 'neq', 'ilk', 'ew', 'sw'. |
search | Specifies the search query with a maximum length of 100 characters. |
limit | Specifies the maximum number of results to return. Must be a number between 1 and 100. |
page | Specifies the page number for paginated results. Must be a number greater than or equal to 0. |
count | Indicates whether to include the total count of results in the response. |
sort | Specifies sorting criteria for 'number' and 'serial' fields. Values can be -1 (descending order) or 1 (ascending order). |
Responses
Status | Meaning | Description |
---|---|---|
200 | OK | Default Response |
400 | Bad Request | Bad Request |
This operation does not require authentication