Skip to main content

Vehicle type model

Vehicle type model is used to create and reference vehicles to. Vehicle type contains shared configruations and settings that will be applied on vehicle creation from the vehicle type. In addition, when a vehicle is created, an automatic label with vehicle_type.name will be applied as a union to the vehicle. This is specifically usedfull for implementation of vehicle type for the location (or location type) constraint.

Ve

assigned_nodes_protection_intervalnull
assigned_nodes_protection_max_locationsnull
capacity objectrequired

Vehicle type capacity definiton

property name*integer
characteristics object

Vehicle characteristics required to perform the booking.

property name* object
anyOf
number

Value of the characteristic, for example:

{
"manpower": 3
}
dynamic_break_avg_time_between_breaksnull

In case of multibreak configuration, average driving time between breaks in seconds

dynamic_break_durationnull

Driver break duration in seconds

dynamic_break_max_latencynull
dynamic_break_min_path_durationnull
efficiency vehicle_efficiency (object,null)

Efficiency constraints for the vehicle type

constraints object[]

This feature enables efficiency constraints for vehicles, managing how much capacity they utilize. It works by defining a list of constraints for various demand types. These constraints focus on two optional checks during a vehicle's trip:

Minimum Load: Ensures the vehicle is loaded with at least a specified minimum capacity throughout the trip. This promotes efficient vehicle usage. Maximum Remaining Load: Ensures the vehicle's remaining load at the end of a trip doesn't exceed a specified maximum. This discourages returns to the depot with significant unused capacity. Each check can be either strict or weak:

Strict: These constraints must be met. Failing a strict constraint is unacceptable, even if it means no solution is found. Weak: These constraints are preferred but not mandatory. If a weak constraint is violated, a penalty is added to the overall objective value. The penalty for violating a weak constraint is calculated as the sum of two components:

Fixed Penalty: A pre-defined penalty value. Linear Penalty: Calculated by multiplying the cost of over/under capacity by the amount of over/under capacity.

  • Array [
  • demand_namestring

    Demand name to apply the constraint. This demand type must be present in at least one full booking. If the demand set here is not present in any of the booking as a set demand type, the optimizer will fail the validation.

    loaded_min_capacitynumber | nullnullable

    Minimum capacity after a series of consecutive pickups before dropoffs. If check is not strict then penalty is added to cost if capacity is less than minimum. If check is strict then route with too small capacity is invalid.

    loaded_min_capacity_percentagenumber | nullnullable

    The same as loaded_min_capacity but represented as percentage.

    loaded_undercapacity_penaltyinteger

    Fixed penalty of undercapacity.

    Default value: 0
    loaded_undercapacity_costinteger

    Cost of undercapacity. The additional penalty is calculated as the product of undercapacity_cost and the undercapacity value.

    Default value: 0
    loaded_undercapacity_check_strictboolean

    Flag indicates that check of undercapacity must be strict.

    Default value: false
    unloaded_max_capacitynumber | nullnullable

    Maximum capacity after a series of consecutive dropoffs before pickups. If check is not strict then penalty is added to cost if capacity is greater than maximum. If check is strict then route with too large capacity is invalid.

    unloaded_max_capacity_percentagenumber | nullnullable

    Same as unloaded_max_capacity but represented as percentage.

    unloaded_overcapacity_penaltyinteger

    Fixed penalty of overcapacity.

    Default value: 0
    unloaded_overcapacity_costinteger

    Cost of overcapacity. The additional penalty is calculated as the product of overcapacity_cost and the overcapacity value.

    Default value: 0
    unloaded_overcapacity_check_strictboolean

    Flag, indicates, that check for overcapacity must be strict.

    Default value: false
  • ]
  • geofence_idsinteger[]

    List of geofence IDs the vehicle type can be used for

    labelsstring[]

    List of labels to be applied to a vehicle. Note, that a defaul lable with vehicle type namew will be applied in addition to labels specified in this field (union of labels)

    lifo_order_checkboolean

    Enable LIFO loading\unloading orders constraint for a vehicle

    max_dropoff_locationsinteger | nullnullable

    Maximum number of drop offs for a vehicle constraint

    max_physical_stopsinteger | nullnullable

    Maximum number of stops the vehicle is allowed to do

    max_pickup_locationsinteger | nullnullable

    Maximum number of pikcup locations a vehicle is allowed to execute

    max_trip_durationinteger | nullnullable

    Maximum vehicle trip duration constriaint in seconds

    max_trip_lengthinteger | nullnullable

    Maximum trip length for a vehicle

    namestringrequired

    Name of the vehicle type

    number_of_tripsinteger | nullnullable

    Maximum number of trips for a vehicle

    projectstring<uri-reference>required

    Project URI the vehicle type belongs to

    routing_engine_settings objectrequired

    Routing settings for the vehicle type

    routing_engine_namestringrequired

    Name of the engine to be used.

    Possible values: [euclidian, euclidian_geo, asteria, graphhopper, mapbox, valhalla, osrm, osrme, google, here, spheroid, spheriodtd, tomtom]

    Default value: asteria
    road_networkstringrequired

    Road network to be used by the routing engine (routing profile)

    Default value: osrme
    keystringrequired

    API key for the mapping service

    Default value: null
    urlstringrequired

    URL of the routing engine to request the data from

    Default value: http://mapbox-osrm-proxy
    curbboolean

    Sets approacch values in the resuts to unrestricted with false, and curb with true value. The approaches are set only for the first and the last stop in the trip

    Default value: null
    intermediate_curbboolean

    Sets approacch values in the resuts to unrestricted with false, and curb with true value. The approaches are set for all waypoints in a trip except for the first and the last stop

    Default value: null
    continue_straightboolean

    Applies continue_straight flag to the routing request. WHen set to null default map setting is applied.

    Default value: null
    speednumber | nullnullable

    Speed value used by the routing engine if fiexed speed is enabled with use_speed_in_routing flga

    Default value: 0
    time_factornumber

    Can be used to manually adjust the time needed to move between waypoints compared to what the routing engine provides based on the vehicle profile.

    Default value: 1
    make_depot_zeroboolean
    Default value: true
    batch_matrix_sizeinteger

    Defines size of the matix to request from the routing engine with a single request for optimization purposes

    Default value: 250
    osrme_timestamp_modestring

    Defines default timestamp type to be used for requesting the route

    Default value: start_time
    use_speed_in_routingboolean

    If enabled, forces the routing engine to use fixed speed and disregard speeds from the map

    Default value: false
    vehicle_costinteger | nullnullable

    Vehicle cost to be used as a part of the cost function during optimization

    zero_cost_if_only_partial_routesboolean | nullnullable

    Sets vehicle cost zero if only partial routes are assigned (for example, when travelling from and to depot)

    created_atstring<date-time>

    Creation timestamp of an object

    id object

    Identifier of the object

    anyOf
    integer

    Can be integer

    modified_atstring<date-time>

    Last modification timestampo of the object

    resource_uristring<uri-reference>

    URI of the object instance

    Vehicle type model
    {
    "assigned_nodes_protection_interval": "null",
    "assigned_nodes_protection_max_locations": "null",
    "capacity": {},
    "characteristics": {},
    "dynamic_break_avg_time_between_breaks": "null",
    "dynamic_break_duration": "null",
    "dynamic_break_max_latency": "null",
    "dynamic_break_min_path_duration": "null",
    "efficiency": "Unknown Type: object,null",
    "geofence_ids": [
    0
    ],
    "labels": [
    "string"
    ],
    "lifo_order_check": true,
    "max_dropoff_locations": 0,
    "max_physical_stops": 0,
    "max_pickup_locations": 0,
    "max_trip_duration": 0,
    "max_trip_length": 0,
    "name": "string",
    "number_of_trips": 0,
    "project": "string",
    "routing_engine_settings": {
    "routing_engine_name": "asteria",
    "road_network": "osrme",
    "key": null,
    "url": "http://mapbox-osrm-proxy",
    "curb": null,
    "intermediate_curb": null,
    "continue_straight": null,
    "speed": 0,
    "time_factor": 1,
    "make_depot_zero": true,
    "batch_matrix_size": 250,
    "osrme_timestamp_mode": "start_time",
    "use_speed_in_routing": false
    },
    "vehicle_cost": 0,
    "zero_cost_if_only_partial_routes": true,
    "created_at": "2024-07-29T15:51:28.071Z",
    "id": 0,
    "modified_at": "2024-07-29T15:51:28.071Z",
    "resource_uri": "string"
    }