Skip to content

Vehicle

A Vehicle is a means to transport consignments from one location to potentially multiple other locations. There are various types of vehicles, each with their own unique properties like size, dimensions, fuel type and means of tranport (by air, on land, over sea).

Get a specific Vehicle by its UUID

Request

Security
BearerToken
Path
UUIDstring, (uuid)required

The unique UUID of this Vehicle

curl -i -X GET \
  'https://otm-api-spec.redocly.app/_mock/api/5.9/otm/api/v5/vehicles/{UUID}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Returned the entity with the provided UUID

Bodyapplication/json
entityTypestring
Value:"vehicle"
Example:"vehicle"
idstring

Uniquely identifies this entity. A URI can be assigned by the client to indicate where more information can be retrieved. Note that every entity always has a unique EntityId. However since, OTM5.2 it is not required to send it in the request. One can be generated for you by the server.

Example:"b9bb914d-845e-46f2-91ff-31fa4bac2fbe"
namestring

Name of the entity. For display purposes and search only.

Example:"Bob's Boxtruck"
creationDatestring, (date-time)

The creation date of this entity.

lastModifiedstring, (date-time)

The last modified date of this entity. If none is given the creation date is used instead.

contextEventsArray of any(event)

The context events provides some optional information about the events that can provide additional information on the current state of this entity.

For example: your system might send ETA information for the arrival of a vehicle on a location. To make it clear what caused this ETA to be updated, we can include some information about what caused this ETA update by including an event as context. If your ETA update was caused by a location update, this event can be included as context. If the ETA was caused by a traffic accident on the route of the vehicle, you can include that event in the context.

externalAttributesobject
externalIdentifiersArray of objects(externalIdentifiers)

Standardized identifiers of this entity as known in external systems. Use this to exchange repeatable partner or system specific identifiers without overloading externalAttributes.

Example:
[ { "id": "AAA", "scheme": "CAS" } ]
vehicleTypestring

The type of vehicle

Example:"boxtruck"
fuelsArray of objects(fuel)

The types of fuel the vehicle runs on.

Example:
[ { "fuelType": "electricity", "averageConsumption": { … } }, { "fuelType": "petrol", "averageConsumption": { … } } ]
emissionClassesArray of any(emissionClass)

Classification labels that can be used to indicate regulatory classes for this vehicle, such as Euro emission standard and CO2 emission class.

Example:
[ { "type": "emissionClassCO2", "value": "1" }, { "type": "emissionStandard", "value": "euro6" } ]
loadCapacitiesArray of objects

The load capacities of the Vehicle. This can be an array of values, for several reasons:

  • The Vehicle might be split up in multiple compartments.
  • You might want to express the load capacities in different quantities. E.g. in square meters or litres as well as in number of pallets.
Example:
[ { "value": 1000, "unit": "kg" } ]
lengthobject

The length of the Vehicle.

Example:
{ "value": 8, "unit": "m" }
heightobject

The height of the Vehicle.

Example:
{ "value": 2.8, "unit": "m" }
widthobject

The width of the Vehicle.

Example:
{ "value": 2, "unit": "m" }
licensePlatestring

The license plate of the vehicle.

Example:"AB-12-CD"
emptyWeightobject

The weight of the Vehicle when empty.

Example:
{ "value": 2000, "unit": "kg" }
actorsArray of any

There are multiple roles in which actors can be associated with a vehicle, such as the owner or the driver of the vehicle.

actionsArray of any(action-association)

All actions that are/were related to this vehicle, such as attaching or detaching transport equipment.

sensorsArray of any

Vehicles might have some sensors that are permanently attached, these can be described using the sensors field. If one works with detachable sensors the recommend approach is to use associationCreated and associationRemoved events instead.

fuelstring(fuelTypes)deprecated

The type of fuel the vehicle runs on. For vehicle without an engine of their own, such as a trailer, you may choose not-applicable. For trailers with cooling capabilities, choose the fuel type of the cooling engine.

Enum:"petrol""diesel""electricity""hydrogen""lng""bioLng""cng""bioCng""adBlue""ethanol"
otherFuelTypestringdeprecated

Type of fuel, only to be used when the fuel field is set to other.

averageFuelConsumptionobjectdeprecated

The average fuel consumption for this vehicle. Usually measured in distance per 100l

emissionStandardstring(emissionStandard)deprecated

Deprecated: use emissionClasses with type emissionStandard instead.

Enum:"euro0""euro1""euro2""euro3""euro4""euro5""euro6""Z"
Response
{ "id": "b9bb914d-845e-46f2-91ff-31fa4bac2fbe", "name": "Bob's Boxtruck", "vehicleType": "boxtruck", "fuels": [ { … }, { … } ], "loadCapacities": [ { … } ], "length": { "value": 8, "unit": "m" }, "height": { "value": 2.8, "unit": "m" }, "width": { "value": 2, "unit": "m" }, "licensePlate": "AB-12-CD", "emptyWeight": { "value": 2000, "unit": "kg" }, "emissionClasses": [ { … }, { … } ] }