Conundra Vehicle API (0.0.1)

Download OpenAPI specification:Download

The Vehicle API provides endpoints for managing vehicles used in planning operations.

0.0.1

  • Initial BETA version of the Vehicle API

Health check

Miscellaneous endpoints for general API functionality

Health check

The ping-endpoint can be used for validating a connection with the application. It will authenticate the caller and respond pong if everything is set-up correctly.

SecurityclientCredentials
Responses
200

Returned when the application is responsive and you are authenticated.

401

Authentication required

get/ping
Response samples
text/plain
pong

Vehicle [EXPERIMENTAL]

Endpoints for managing vehicles.

Upsert Vehicle

Create or update a Vehicle. A unique ID (business_id) is required to identify the Vehicle. Calling this endpoint with an existing business_id will update the Vehicle.

Modifying (or retrieving) a Vehicle will provide the caller with a version number for this Vehicle. This version can be passed to the upsert endpoint as a weak ETag in the If-Match header. This allows the caller to ensure that the Vehicle has not been modified since the last time it was retrieved.

SecurityclientCredentials
Request
path Parameters
business_id
required
string <= 512 characters ^[a-zA-Z0-9.~\-_]+$

Unique identifier for this Vehicle. Should only contain characters which do not need URL encoding.

header Parameters
Prefer
Array of strings

The RFC7240 Prefer header indicates that a particular server behavior is preferred by the client but is not required for successful completion of the request (see RFC 7240).

The following behavior (see Examples) is supported by this API:

  • return=<minimal|representation> is used to suggest the server to return using 204 without resource (minimal) or using 200 or 201 with resource (representation) in the response body on success.
Examples:
Indicate no response is needed, can be omitted
return=minimal
Request the result of the operation as response
return=representation
If-Match
string

Weak Etag used for optimistic locking.

Example: W/"24"
Request Body schema: application/json
description
string [ 1 .. 999 ] characters

Description of the vehicle.

mandatory
boolean
Default: false

Whether OptiFlow must use this vehicle in a planning or not. If false, OptiFlow will only use this vehicle when it makes sense to do so.

object (Driver)
required
object (Start)
required
object (End)
required
object (Deployability)
capabilities
Array of strings unique
Default: []

Capabilities this vehicle provides. Used to make sure that orders requiring a specific capability, are only handled by vehicles with that capability.

object (TransportResource)
labels
Array of strings unique
Default: []

Labels for categorizing vehicles. Can be used for facility filtering or defining constraints.

object (Cost)
object (RouteSettings)
color
string

The color used to display this vehicle's route in the planning overview. Accepts CSS color names (e.g., "red", "blue") or hexadecimal color codes (e.g., "#FF5733", "#123DEF").

Responses
201

Vehicle created or updated

204

Vehicle created or updated

400

Bad request

401

Authentication required

404

Not found

409

Conflict

412

This status is returned when an trying to modify an entity with an outdated version in the If-Match header.

put/vehicles/{business_id}
Request samples
application/json
{
  • "description": "Horn plays La Cucaracha - use sparingly in residential areas",
  • "mandatory": true,
  • "driver": {
    },
  • "start": {
    },
  • "end": {
    },
  • "deployability": {
    },
  • "capabilities": [
    ],
  • "transport_resource": {
    },
  • "labels": [
    ],
  • "cost": {
    },
  • "route_settings": {
    },
  • "color": "#FF5733"
}
Response samples
application/json
{
  • "business_id": "truck-42",
  • "description": "Horn plays La Cucaracha - use sparingly in residential areas",
  • "mandatory": true,
  • "driver": {
    },
  • "start": {
    },
  • "end": {
    },
  • "deployability": {
    },
  • "capabilities": [
    ],
  • "transport_resource": {
    },
  • "labels": [
    ],
  • "cost": {
    },
  • "route_settings": {
    },
  • "color": "#FF5733"
}

Get Vehicle

Get an existing Vehicle, defined by their business_id.

SecurityclientCredentials
Request
path Parameters
business_id
required
string <= 512 characters ^[a-zA-Z0-9.~\-_]+$

The unique ID (business_id) used to create this Vehicle.

Responses
200

The Vehicle was successfully retrieved. Details are in the response body.

401

Authentication required

404

Not found

get/vehicles/{business_id}
Response samples
application/json
{
  • "business_id": "truck-42",
  • "description": "Horn plays La Cucaracha - use sparingly in residential areas",
  • "mandatory": true,
  • "driver": {
    },
  • "start": {
    },
  • "end": {
    },
  • "deployability": {
    },
  • "capabilities": [
    ],
  • "transport_resource": {
    },
  • "labels": [
    ],
  • "cost": {
    },
  • "route_settings": {
    },
  • "color": "#FF5733"
}

Delete Vehicle

Delete a Vehicle, defined by their business_id.

SecurityclientCredentials
Request
path Parameters
business_id
required
string <= 512 characters ^[a-zA-Z0-9.~\-_]+$

A unique identifier of an entity instance.

header Parameters
If-Match
string

Weak Etag used for optimistic locking.

Example: W/"24"
Responses
204

Deletion has succeeded and body is empty.

400

Bad request

401

Authentication required

404

Not found

412

This status is returned when an trying to modify an entity with an outdated version in the If-Match header.

delete/vehicles/{business_id}
Response samples
application/problem+json
{
  • "title": "Validation exception",
  • "detail": "The field contains invalid business formatting.",
  • "violations": [
    ]
}