openapi: 3.1.0 info: title: Open Trip Model version: v5.9.0 description: | ## Why OTM? In this day and age more and more information about logistics and traffic is shared over the Internet between various parties. To make this communication easier the _Open Trip Model_ specification was created. It is a lightweight data model used to exchange real-time logistic trip data on the web, and to make it easier for shippers, carriers, software vendors, OEMs, and truck manufacturers to create new multi-brand applications and services. To learn more about the what, the why and the how see the **[OTM documentation website](https://opentripmodel.org/)**. ## Changelog Found any bugs on this page? Or have any feature requests for OTM? Create a new ticket on the [OTM5 change requests Github page](https://github.com/opentripmodel/otm5-change-requests) **Unreleased changes** **Version 5.9 (released on 2026-10-02)** * Add `euralCode` to `goods[].items[].classificationLines[]` to support waste classification with EURAL. [See 64](https://github.com/opentripmodel/otm5-change-requests/issues/64) * Add `freightForwarder` to `actors[].roles`. [See 116](https://github.com/opentripmodel/otm5-change-requests/issues/116) * Define lifecycle as a shared enum schema and reference it from lifecycle properties. [See 122](https://github.com/opentripmodel/otm5-change-requests/issues/122) * Add `operationId` to all API endpoints. [See 125](https://github.com/opentripmodel/otm5-change-requests/issues/125) * Add `type` to `vehicles[].loadCapacities[]` to distinguish capacity meanings such as axle and combined masses. [See 127](https://github.com/opentripmodel/otm5-change-requests/issues/127) * Add `rejected` as a status enum value for consignment and trip. [See 128](https://github.com/opentripmodel/otm5-change-requests/issues/128) * Add `externalIdentifiers` to all schemas that currently expose `externalAttributes`. [See 130](https://github.com/opentripmodel/otm5-change-requests/issues/130) * Add `emissionClasses` to vehicle with support for `emissionStandard` and `emissionClassCO2`, and deprecate vehicle field `emissionStandard`. [See 131](https://github.com/opentripmodel/otm5-change-requests/issues/131) * Add `cargoHandler` to `actors[].roles`. [See 135](https://github.com/opentripmodel/otm5-change-requests/issues/135) * Add `closed` as a status enum value for all status fields. [See 137](https://github.com/opentripmodel/otm5-change-requests/issues/137) * Add `weigh` action and `weighEvent` event to model weighing a vehicle or transport equipment. [See 138](https://github.com/opentripmodel/otm5-change-requests/issues/138) * Add `references` array to `locationUpdateEvent` and `weighEvent` to reference other entities that are relevant for these events. [See 140](https://github.com/opentripmodel/otm5-change-requests/issues/140) * Add `format: date-time` to date/time fields such as `startTime`, `endTime`, `startDateTime`, and `endDateTime`. [See 120](https://github.com/opentripmodel/otm5-change-requests/issues/120) **Version 5.8 (released on 2026-03-13)** * Remove several duplicate definitions of the same entity or fields e.g. unit of measure * Add actions property for vehicle entity. This allows to relate actions to a vehicle without the need to relate them to a trip. E.g. to indicate that a vehicle has a trailer (i.e. transport equipment) attached. [See 108](https://github.com/opentripmodel/otm5-change-requests/issues/108) * Better explain the difference between fields `actors[].entity.role` and `actors[].roles` [See 109](https://github.com/opentripmodel/otm5-change-requests/issues/109) * Fix inconsistencies in the specification of use of actor entity. [See 110](https://github.com/opentripmodel/otm5-change-requests/issues/110) * Add volume property to transport equipment and goods items. This can be provided by means of value and unit (e.g. 120 m3). [See 111](https://github.com/opentripmodel/otm5-change-requests/issues/111) * Add support for multiple vehicle fuel types. This deprecated the fields: 'fuel', 'otherFuelType' and 'averageFuelConsumption' on the vehicle entity, and replaces it with a new field 'fuels' that allows for multiple fuel types, each with their own average fuel consumption. [See 112](https://github.com/opentripmodel/otm5-change-requests/issues/112) * Extend list of possible fuel types [See 113](https://github.com/opentripmodel/otm5-change-requests/issues/113) * Add the possibility to reference entities in the action result and specificy sub results. For example the unload action can be succeeded for certain goods and failed for others, in which case the overall result would be partially succeeded and the sub results would indicate which goods were unloaded successfully and which were not. [See 115](https://github.com/opentripmodel/otm5-change-requests/issues/115) * Extend list of possible emission standards with value Z [See 117](https://github.com/opentripmodel/otm5-change-requests/issues/117) * Fix missing entityType property for goods sub types items and transport equipment. [See 118](https://github.com/opentripmodel/otm5-change-requests/issues/118) * Fix circular polymorphic pattern for actor, person and company. [See 119](https://github.com/opentripmodel/otm5-change-requests/issues/119) * Add missing actions property in consignment entity. [See 121](https://github.com/opentripmodel/otm5-change-requests/issues/121) **Version 5.7 (released on 2025-05-23)** * Fix broken link to goods packaging type codes. [See 87](https://github.com/opentripmodel/otm5-change-requests/issues/87). * Fix inconsistent use of plural name 'geoReferences' for non array property in route definitions. Add new property 'geoReference' and deprecate 'geoReferences'. First one is now required. [See 86](https://github.com/opentripmodel/otm5-change-requests/issues/86). * Add enums for location types 'fuelStation', 'serviceStation' and 'other'. Add new property 'otherLocationType' to specify the location type in case of 'other'. [See 73](https://github.com/opentripmodel/otm5-change-requests/issues/73). * Add eight new action result reasons, including 'deliveredElsewhere', 'deliveredToWrongReceiver' and 'other'. In case of 'other' the result reason can be provided as free text in the existing remark property. [See 89](https://github.com/opentripmodel/otm5-change-requests/issues/89). * Add distance property in move action. This can be provided by means of value and unit (e.g. 120 km) [See 90](https://github.com/opentripmodel/otm5-change-requests/issues/90) * Add two specializations of actor, i.e. 'peron' and 'company'. Each with an additional set of properties. [See 100](https://github.com/opentripmodel/otm5-change-requests/issues/100) **Version 5.6 (released on 2023-11-17)** * Add loading and unloading consignment in and from transport equipment. [See 63](https://github.com/opentripmodel/otm5-change-requests/issues/63). * Add enforceability of a constraint. [See 75](https://github.com/opentripmodel/otm5-change-requests/issues/75). * Add recurring date times & durations on actions & events. [See 75](https://github.com/opentripmodel/otm5-change-requests/issues/75). * Add sub-locations as optional field on a location. [See 77](https://github.com/opentripmodel/otm5-change-requests/issues/77). * Add `owner` as a new type of actor role. [See 78](https://github.com/opentripmodel/otm5-change-requests/issues/78). * Add `routeEntityConstraint` and deprecate `routeConstraint`. [See 80](https://github.com/opentripmodel/otm5-change-requests/issues/80). **Version 5.5 (released on 2023-02-07)** * Explain when to use `Consignment` vs `Goods` constraints. [See 42](https://github.com/opentripmodel/otm5-change-requests/issues/42). * Make `fuel` on vehicle an enum instead of a free string. [See 51](https://github.com/opentripmodel/otm5-change-requests/issues/51). * Add `emissionStandardConstraint` as a possible constraint. [See 52](https://github.com/opentripmodel/otm5-change-requests/issues/52). * Add `transportOrder` as a field on `Consignment` to enable the two-way relationship. [See 59](https://github.com/opentripmodel/otm5-change-requests/issues/59). * Add `eori` as a possible contact detail option. [See 60](https://github.com/opentripmodel/otm5-change-requests/issues/60). * Add `valueBoundConstraint` as a possible constraint. [See 61](https://github.com/opentripmodel/otm5-change-requests/issues/61). * Add `refuel` as a possible action. [See 62](https://github.com/opentripmodel/otm5-change-requests/issues/62). * Add `accessConstraint` as possible constraint. [See 69](https://github.com/opentripmodel/otm5-change-requests/issues/69). **Version 5.4 (released on 2022-05-09)** * _Add a `TransportEquipmentConstraint`. [See 46](https://github.com/opentripmodel/otm5-change-requests/issues/46). * _Add `averageFuelConsumption` to vehicle. [See 48](https://github.com/opentripmodel/otm5-change-requests/issues/48). * _Add fuel consumption and emission events. [See 49](https://github.com/opentripmodel/otm5-change-requests/issues/49). * _Add `contextEvents` on entities. [See 49](https://github.com/opentripmodel/otm5-change-requests/issues/49). * _Add `sequenceNr` to all action types. [See 50](https://github.com/opentripmodel/otm5-change-requests/issues/50). * _Add `cancelled` on action results and `receiverAbsent` as 'reason' type. [See 53](https://github.com/opentripmodel/otm5-change-requests/issues/53). * _Add `actors` to all event types. [See 55](https://github.com/opentripmodel/otm5-change-requests/issues/55). * _Add `description` to all constraint types. [See 56](https://github.com/opentripmodel/otm5-change-requests/issues/56). **Version 5.3 (released on 2021-12-16)** * Support 204 (No Content) for delete requests. [See 23](https://github.com/opentripmodel/otm5-change-requests/issues/23). * Add classification lines to goods. [See 26](https://github.com/opentripmodel/otm5-change-requests/issues/26). * Add a result to actions. [See 30](https://github.com/opentripmodel/otm5-change-requests/issues/30). * Extend ADR with points and transport category. [See 31](https://github.com/opentripmodel/otm5-change-requests/issues/31). * Support `relatedConsignments` in consignments. [See 32](https://github.com/opentripmodel/otm5-change-requests/issues/32). * Support UNCode and GLN in locations. [See 36](https://github.com/opentripmodel/otm5-change-requests/issues/36). * Support `temperatureConstraint` as a possible constraint type. [See 37](https://github.com/opentripmodel/otm5-change-requests/issues/37). * Add some references to existing code lists. [See 27](https://github.com/opentripmodel/otm5-change-requests/issues/27). - Using ISO country codes in the country field in addresses. - Using ISO currency codes in 'value-with-unit' fields. - Using the metric system as recommend and default system for dealing with mass, velocity, weight and sizes. - Using the package material codes from the GS1 standard. **Version 5.2 (released on 2021-09-09)** * _Add `transportEquipmentSubType` for example to indicate what type of pallets you use. [See 19](https://github.com/opentripmodel/otm5-change-requests/issues/19). * _Add `timeWindowConstraint` to replace `startDateTimeConstraint` and `endDateTimeConstraint`. [See 6](https://github.com/opentripmodel/otm5-change-requests/issues/6). * _Add `operationalBase` as a location type. [See 22](https://github.com/opentripmodel/otm5-change-requests/issues/22). * _Add more actor role types. [See 20](https://github.com/opentripmodel/otm5-change-requests/issues/20). * _Add new break and wait actions. [See 17](https://github.com/opentripmodel/otm5-change-requests/issues/17). * _Allow for server side UUID generation. [See 16](https://github.com/opentripmodel/otm5-change-requests/issues/16). **Version 5.1 (released on 2021-06-01)** * Add an optional `emission` to Vehicle. [See 13](https://github.com/opentripmodel/otm5-change-requests/issues/13). * Add an optional `transportMode` to Trip and Move. [See 12](https://github.com/opentripmodel/otm5-change-requests/issues/12). * Add optional `grossWeight` to Goods. [See 11](https://github.com/opentripmodel/otm5-change-requests/issues/11). * Add`mobilePhone` as contact detail option. [See 5](https://github.com/opentripmodel/otm5-change-requests/issues/5). * Add an optional `lastModified` field to each entity. [See 2](https://github.com/opentripmodel/otm5-change-requests/issues/2). * Add an optional language to contact details. [See 9](https://github.com/opentripmodel/otm5-change-requests/issues/9). * Add a new entity Document to deal with information about files that can be shared. [See 7](https://github.com/opentripmodel/otm5-change-requests/issues/7). * Add new statuses to Trip and Consignment. [See 4](https://github.com/opentripmodel/otm5-change-requests/issues/4). * Add an optional sensors association to vehicle. [See 2](https://github.com/opentripmodel/otm5-change-requests/issues/2). **Version 5.0 (only documentation changes)** * Add documentation about validation endpoints. * Add reference to the otm5-change-requests github. * Fix the broken checkbox for actions when choosing the `Stop` action. * Document the license plate on a `TransportEquipment` (i.e. a trailer). servers: - url: https://example.com tags: - name: Vehicle description: |- 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). - name: Route description: A route models the path going from one location to at least one other location. - name: Sensor description: A sensor is a device that is able to measure a quantity in a certain unit, such as measuring the speed in km/h. - name: Location description: Object describing a geographic location. A location can either be a point or an area. - name: Actor description: | An `Actor` models a legal entity. A legal entity is an individual, company, or organization that has legal rights and obligations. The use of `Actors` is optional, and is not necessary to use OpenTripModel. Actors can be used e.g. to group all locations that belong to an organisation, or to address an OpenTripModel message to a specific person or organisation. - name: Consignment description: |- A consignment is a description of an identifiable collection of goods items to be transported between the consignor and the consignee. This information may be defined within a transport contract. - name: Trip description: | A Trip is an aggregate entity that combines various entities to model visiting various locations, potentially doing one or multiple actions on each location, such as loading or unloading consignments. It is optionally coupled to a `Vehicle` that is/was driving this trip. - name: Event description: |- Events - like actions - model _dynamic_ entities that couple various _static_ entities at a certain moment in time. Events are used for either real-time updates, or updates on earlier provided data. Notice that in both event types these are _updates_ on earlier provided data, whereas actions are usually used together with the entities they dynamically couple. There are various kinds of events that fall into the two earlier mentioned kinds. **Real-time updates**: - The **LocationUpdateEvent** that provides location data received from some GPS. - The **SensorUpdateEvent** that provides sensor value updates (such as temperature or speed measurements) received from a sensor. - The **StartMovingEvent**, **StopMovingEvent**, **StartEngineEvent**, **StopEngineEvent** that indicate events provided by Fleet Management Systems. **Both real-time and projected/realized events** - The **EmissionEvent** that contains information about how much emission has been produced during a move / on a trip / per consignment. Can be provided as an actual value, projected based on some calculation, or realized as measured by some sensor. - The **FuelConsumedEvent** that contains information about how much fuel was consumed during a move / on a trip / per consignment. Can be provided as an actual value, projected based on some calculation, or realized as measured by some sensor. - The **WeighEvent** that contains information about the weights of the vehicle or transport equipment. This can be from a weighbridge, tare weight, manual or from a sensor. **Updates on earlier provided data**: - The **UpdateEvent** that is used to update an earlier provided entity with new information. Note that only the changed data has to be provided. - The **AssociationCreatedEvent** and **AssociationRemovedEvent** that allow for _static_ entities to be coupled after the fact. Such as coupling a Vehicle to a Trip. - name: Action description: |- Actions are _dynamic_ entities that are able to couple together various _static_ entities at a certain moment in time. For instance a Load action couples together a Consignment and a Vehicle at the moment the Loading happens. There are various types of Actions: - The **Stop** that models visiting a certain location at a certain time and potentially doing several other actions at that location. - The **Load** action, that models loading in one or multiple Consignments into a vehicle or some sort of container. - The **Unload** action, that models unloading one or multiple Consignments from a vehicle or some other sort of container. - The **HandOver** that indicates transferring a consignment from one Actor to another. - The **Move** that models moving between two or more locations, potentially with detailed route information on _how_ to move between these locations. - The **AttachTransportEquipment** that allows you to attach some equipment to the associated vehicle. Note that you can both load/unload and attach/detach TransportEquipments. For instance loading a container on a ship, or attach a trailer to a truck. So choose the one that is most appropriate. - The **DetachTransportEquipment** that allows you to detach some previously attached equipment from the associated vehicle. - The **Break** action that models a mandatory resting period for the driver of the vehicle. During this period the driver is prohibited from doing any driving activities or other work. - The **Wait** action that models waiting at a particular location during the trip. This can be due to various circumstances such as waiting for the vehicle to be transported by a ferry or train. Or because of waiting at frontiers or docks (e.g. the dock of the loading/unload location is occupied) or traffic prohibitions. The driver is allowed to leave the vehicle during this period. An important aspect distinguishing this from the _break_ action is that waiting times can be shortened because of changing circumstances. For example, if the original waiting time was expected to be 15 minutes because of an occupied dock, but the driver is 10 minutes late, the waiting time can be shortened to 5 minutes until the dock is free. - The **GenericAction** for whenever any of the above actions cannot model the situation appropriately. - The **Weigh** action for whenever a vehicle is weighed at a certain location. This can be used to indicate that the vehicle is weighed at a weigh station, or at a loading/unloading location. - name: Goods description: |- Goods are the items to be transported as part of a consignment. Goods can be divided into two sub-types of goods, depending on the use case and the level of detail. Goods either consists of items, describing the actual goods to be transported. Or a transport equipment, which is equipment used to carry the actual goods to be transported. Transport equipment is (usually) a means to an end, not something that needs to be transported on itself, such as pallets. Note that goods can either be or contain dangerous goods. OTM uses the official specification of [ADR](https://unece.org/transportdangerous-goods/adr-2021-files) to describe in what manner and how dangerous those goods are. The used descriptions in the OTM documentation are extracted from document [ADR2021_Vol1e_0.pdf](https://unece.org/sites/default/files/2021-01/ADR2021_Vol1e_0.pdf). The official documentation is always leading and should be consulted. - name: TransportOrder description: |- The TransportOrder is the top-level entity to model a group of related consignments that might be transported separately, but need to be administered together. For consistency, even if there is only one consignment, it is still required to use a transport order. - name: Document description: | In many logistic operations documents are an important part of the data flow. Documents can serve multiple purposes, such as proving some package was delivered with help of a photo, or some scanned document that establishes that the transferred goods are accepted on handover. Documents in OTM come in two flavors, either you provide the content of the document directly as a base64 encoded string, or you provide a link to the document where it can be accessed online. - name: Constraint description: |2 `Constraints` can do different things, depending on the context they're used in: - In the context of a `Location`, access to the location is only allowed if the given constraint applies. - In the context of a `Trip`, constraints can be used to define constraints that have to be met during the trip, e.g. if the temperature in a refrigerated trailer has to stay below a given maximum during the trip. - In the context of a `Shipment`, constraints can be used to e.g. define minimum or maximum temperatures for shipments, or date time constraints for delivery. Since OTM5.2 the _timeWindowConstraint_ is supported which allows you to give (optionally) both the start and end time of the window between which something needs to occur. This replaces the old style where you had to use an _and_ constraint in combination with the _startDateTimeConstraint_ and _endDateTimeConstraint_. Since the new solution is shorter and simpler the _startDateTimeConstraint_ and _endDateTimeConstraint_ are **deprecated**. Note that constraints can be nested and combined using the `andConstraint`, `orConstraint` and `notConstraint`. paths: /api/v5/actors/{UUID}: get: operationId: getActorByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/actor' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Actor by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Actor required: true tags: - Actor security: - BearerToken: [] delete: operationId: deleteActorByUuid responses: '204': description: Deleted actor with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Actor parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Actor to be deleted required: true tags: - Actor security: - BearerToken: [] /api/v5/actors: put: operationId: createActor responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/actor' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Actor requestBody: content: application/json: schema: $ref: '#/components/schemas/actor' tags: - Actor security: - BearerToken: [] /api/v5/constraints/{UUID}: get: operationId: getConstraintByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/constraint' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Constraint by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Constraint required: true tags: - Constraint security: - BearerToken: [] delete: operationId: deleteConstraintByUuid responses: '204': description: Deleted constraint with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Constraint parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Constraint to be deleted required: true tags: - Constraint security: - BearerToken: [] /api/v5/constraints: put: operationId: createConstraint responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/constraint' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Constraint requestBody: content: application/json: schema: $ref: '#/components/schemas/constraint' tags: - Constraint security: - BearerToken: [] /api/v5/locations/{UUID}: get: operationId: getLocationByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/location' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Location by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Location required: true tags: - Location security: - BearerToken: [] delete: operationId: deleteLocationByUuid responses: '204': description: Deleted location with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Location parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Location to be deleted required: true tags: - Location security: - BearerToken: [] /api/v5/locations: put: operationId: createLocation responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/location' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Location requestBody: content: application/json: schema: $ref: '#/components/schemas/location' tags: - Location security: - BearerToken: [] /api/v5/routes/{UUID}: get: operationId: getRouteByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/route' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Route by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Route required: true tags: - Route security: - BearerToken: [] delete: operationId: deleteRouteByUuid responses: '204': description: Deleted route with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Route parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Route to be deleted required: true tags: - Route security: - BearerToken: [] /api/v5/routes: put: operationId: createRoute responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/route' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Route requestBody: content: application/json: schema: $ref: '#/components/schemas/route' tags: - Route security: - BearerToken: [] /api/v5/sensors/{UUID}: get: operationId: getSensorByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/sensor' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Sensor by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Sensor required: true tags: - Sensor security: - BearerToken: [] delete: operationId: deleteSensorByUuid responses: '204': description: Deleted sensor with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Sensor parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Sensor to be deleted required: true tags: - Sensor security: - BearerToken: [] /api/v5/sensors: put: operationId: createSensor responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/sensor' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Sensor requestBody: content: application/json: schema: $ref: '#/components/schemas/sensor' tags: - Sensor security: - BearerToken: [] /api/v5/consignments/{UUID}: get: operationId: getConsignmentByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/consignment' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Consignment by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Consignment required: true tags: - Consignment security: - BearerToken: [] delete: operationId: deleteConsignmentByUuid responses: '204': description: Deleted consignment with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Consignment parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Consignment to be deleted required: true tags: - Consignment security: - BearerToken: [] /api/v5/consignments: put: operationId: createConsignment responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/consignment' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Consignment requestBody: content: application/json: schema: $ref: '#/components/schemas/consignment' tags: - Consignment security: - BearerToken: [] /api/v5/goods/{UUID}: get: operationId: getGoodsByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: oneOf: - $ref: '#/components/schemas/items' - $ref: '#/components/schemas/transportEquipment' discriminator: propertyName: type mapping: items: '#/components/schemas/items' transportEquipment: '#/components/schemas/transportEquipment' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Goods by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Goods required: true tags: - Goods security: - BearerToken: [] delete: operationId: deleteGoodsByUuid responses: '204': description: Deleted goods with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Goods parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Goods to be deleted required: true tags: - Goods security: - BearerToken: [] /api/v5/goods: put: operationId: createGoods responses: '200': description: The same entity content: application/json: schema: oneOf: - $ref: '#/components/schemas/items' - $ref: '#/components/schemas/transportEquipment' discriminator: propertyName: type mapping: items: '#/components/schemas/items' transportEquipment: '#/components/schemas/transportEquipment' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Goods requestBody: content: application/json: schema: oneOf: - $ref: '#/components/schemas/items' - $ref: '#/components/schemas/transportEquipment' discriminator: propertyName: type mapping: items: '#/components/schemas/items' transportEquipment: '#/components/schemas/transportEquipment' tags: - Goods security: - BearerToken: [] /api/v5/transportOrders/{UUID}: get: operationId: getTransportOrderByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/transportOrder' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific TransportOrder by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this TransportOrder required: true tags: - TransportOrder security: - BearerToken: [] delete: operationId: deleteTransportOrderByUuid responses: '204': description: Deleted transportOrder with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a TransportOrder parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the TransportOrder to be deleted required: true tags: - TransportOrder security: - BearerToken: [] /api/v5/transportOrders: put: operationId: createTransportOrder responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/transportOrder' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new TransportOrder requestBody: content: application/json: schema: $ref: '#/components/schemas/transportOrder' tags: - TransportOrder security: - BearerToken: [] /api/v5/trips/{UUID}: get: operationId: getTripByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/trip' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Trip by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Trip required: true tags: - Trip security: - BearerToken: [] delete: operationId: deleteTripByUuid responses: '204': description: Deleted trip with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Trip parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Trip to be deleted required: true tags: - Trip security: - BearerToken: [] /api/v5/trips: put: operationId: createTrip responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/trip' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Trip requestBody: content: application/json: schema: $ref: '#/components/schemas/trip' tags: - Trip security: - BearerToken: [] /api/v5/vehicles/{UUID}: get: operationId: getVehicleByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/vehicle' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Vehicle by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Vehicle required: true tags: - Vehicle security: - BearerToken: [] delete: operationId: deleteVehicleByUuid responses: '204': description: Deleted vehicle with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Vehicle parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Vehicle to be deleted required: true tags: - Vehicle security: - BearerToken: [] /api/v5/vehicles: put: operationId: createVehicle responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/vehicle' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Vehicle requestBody: content: application/json: schema: $ref: '#/components/schemas/vehicle' tags: - Vehicle security: - BearerToken: [] /api/v5/documents/{UUID}: get: operationId: getDocumentByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/document' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Document by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Document required: true tags: - Document security: - BearerToken: [] delete: operationId: deleteDocumentByUuid responses: '204': description: Deleted document with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Document parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Document to be deleted required: true tags: - Document security: - BearerToken: [] /api/v5/documents: put: operationId: createDocument responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/document' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Document requestBody: content: application/json: schema: $ref: '#/components/schemas/document' tags: - Document security: - BearerToken: [] /api/v5/actions/{UUID}: get: operationId: getActionByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/action' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Action by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Action required: true tags: - Action security: - BearerToken: [] delete: operationId: deleteActionByUuid responses: '204': description: Deleted action with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Action parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Action to be deleted required: true tags: - Action security: - BearerToken: [] /api/v5/actions: put: operationId: createAction responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/action' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Action requestBody: content: application/json: schema: $ref: '#/components/schemas/action' tags: - Action security: - BearerToken: [] /api/v5/events/{UUID}: get: operationId: getEventByUuid responses: '200': description: Returned the entity with the provided UUID content: application/json: schema: $ref: '#/components/schemas/event' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '404': description: '' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Get a specific Event by its UUID parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of this Event required: true tags: - Event security: - BearerToken: [] delete: operationId: deleteEventByUuid responses: '204': description: Deleted event with the provided UUID '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Deletes a Event parameters: - name: UUID in: path schema: type: string format: uuid description: The unique UUID of the Event to be deleted required: true tags: - Event security: - BearerToken: [] /api/v5/events: put: operationId: createEvent responses: '200': description: The same entity content: application/json: schema: $ref: '#/components/schemas/event' '400': description: Client error content: application/json: schema: $ref: '#/components/schemas/clientError' '500': description: Server error content: application/json: schema: $ref: '#/components/schemas/serverError' summary: Adds a new Event requestBody: content: application/json: schema: $ref: '#/components/schemas/event' tags: - Event security: - BearerToken: [] components: securitySchemes: BearerToken: type: http description: |- The scope of OTM currently does not include authentication requirements. Though the recommended approach is to use Bearer authentication (also known as token authentication). scheme: bearer schemas: event: oneOf: - $ref: '#/components/schemas/associationCreatedEvent' - $ref: '#/components/schemas/associationRemovedEvent' - $ref: '#/components/schemas/emissionEvent' - $ref: '#/components/schemas/fuelConsumedEvent' - $ref: '#/components/schemas/locationUpdateEvent' - $ref: '#/components/schemas/sensorUpdateEvent' - $ref: '#/components/schemas/startEngineEvent' - $ref: '#/components/schemas/startMovingEvent' - $ref: '#/components/schemas/startWaitingEvent' - $ref: '#/components/schemas/stopEngineEvent' - $ref: '#/components/schemas/stopMovingEvent' - $ref: '#/components/schemas/updateEvent' - $ref: '#/components/schemas/weighEvent' discriminator: propertyName: eventType mapping: associationCreatedEvent: '#/components/schemas/associationCreatedEvent' associationRemovedEvent: '#/components/schemas/associationRemovedEvent' emissionEvent: '#/components/schemas/emissionEvent' fuelConsumedEvent: '#/components/schemas/fuelConsumedEvent' locationUpdateEvent: '#/components/schemas/locationUpdateEvent' sensorUpdateEvent: '#/components/schemas/sensorUpdateEvent' startEngineEvent: '#/components/schemas/startEngineEvent' startMovingEvent: '#/components/schemas/startMovingEvent' startWaitingEvent: '#/components/schemas/startWaitingEvent' stopEngineEvent: '#/components/schemas/stopEngineEvent' stopMovingEvent: '#/components/schemas/stopMovingEvent' updateEvent: '#/components/schemas/updateEvent' weighEvent: '#/components/schemas/weighEvent' unrestricted_json: description: Space for any (nested) properties that do not fit into OTM5 type: object properties: {} externalIdentifier: example: id: AAA scheme: CAS type: object properties: id: description: The identifier value as known in the external system. type: string scheme: description: |- The identifier scheme or external system reference. Values should come from an externally maintained OTM code list that defines the business meaning or issuing system of the identifier, for example a partner code, account number type, or operational code set. The codelist is maintained here: https://sutc.semantic-treehouse.nl/codelist-spec/CodelistSpec_f8567db9-d2fb-42b5-846e-cfdc4734add7 type: string required: - id - scheme externalIdentifiers: type: array description: Standardized identifiers of this entity as known in external systems. Use this to exchange repeatable partner or system specific identifiers without overloading `externalAttributes`. items: $ref: '#/components/schemas/externalIdentifier' lifecycle: description: A lifecycle models _when_ the data in the action is taking place. You can provide the same action in multiple lifecycles to model how it changes over time. For example the planned and realized time of an action taking place can differ because of unforseen circumstances (such as traffic jams). type: string enum: - requested - planned - projected - actual - realized status: description: |- Status defines whether this entity (e.g. trip or consignment) is a draft, requested, confirmed, in transit, completed, closed, rejected or cancelled. Status `closed` is about administrative closure, while `completed` is about the realization of e.g. a trip or consignment. A trip or consignment can be completed but not closed yet, e.g. when the invoice has not been paid yet. The values accepted (replaced by confirmed) and modified (replaced the lastModified field on every entity) are deprecated since OTM5.1, but will be supported for the whole OTM5.X line. type: string enum: - draft - requested - rejected - confirmed - inTransit - completed - closed - cancelled - accepted - modified uom: type: string description: |- Measurement unit of this value. OTM5 currently does not enforce any units of measure. So you are free to use any unit necessary. However to ensure parties use OTM5 consistently there are a few rules: * For **currencies** use the [ISO_4217 standard](https://en.wikipedia.org/wiki/ISO_4217) * For **mass**, **volume** and **length** the [SI system (International System of Units)](https://en.wikipedia.org/wiki/International_System_of_Units) is recommended. To avoid problems with symbols, square and cubic units of measure are simply communicated using the proper number. Thus a square meter is `m2` and a cubic meter is `m3`. * For degrees the recommend approach is Celsius, but Fahrenheit and Kelvin are also supported. To again avoid problems with symbols, the degree symbol (° in °C) is left off, thus only the single capital letter remains (C, F, or K). * For velocity use the metric system. The required format would then be \/\