Schemas
SolveRequest
userIdThe User ID
The Problem object embedded within the main solve request.
exampleSlugOptional. The slug of the published example scenario this solve was loaded from (as returned by /list_examples). Published examples legitimately exceed the free tier's size limits, so sending this grants a bounded allowance sized from that example's own row counts plus a small edit margin - enough to run and tweak the demo, and never more than the named example's real size. Omit it for a user's own scenarios; an unrecognised slug is ignored.
ProblemRequest
problemTypeThis schema defines the problem data for an optimization Problem. The particular data objects used will depend on the problemType.
This schema defines how to interpet the input time field settings. Optimiciti allows for input times to be specified as absolute numeric values (i.e 0, 12, 60, etc.) or as date/time values (i.e. 1/1/2024, 2:24pm).
coordinateSystemWhich coordinate family this problem's locations use. geographic (the default, and what every existing payload means) uses latitude/longitude on the Earth. cartesian uses unbounded x/y on an arbitrary plane, for scenarios with positions but no addresses. It describes the DATA, not the costing, so it is set once per request rather than per cost setting - and it decides which distance/duration methods are valid.
StandardResponse
successIndicates if the request was successful
dataThe main response payload. Can be an object, array, boolean, or string.
ResponseError
codeInternal error code
messageHuman readable error message
detailsAdditional error context
AddressRequest
latLatitude of the location
lngLongitude of the location
zoomZoom level for reverse geocoding
BugReportRequest
user_emailbug_messagebug_filesbug_filenamesJobApplicationRequest
full_nameApplicant's full name
emailApplicant's email address
resume_fileBase64-encoded contents of the resume file
resume_filenameOriginal resume filename, used to derive the file extension
cover_letterOptional cover letter message
SampleTableRequest
tableNameName of the table definition
columnsnum_rowsNumber of sample rows to generate
SampleTableWrapper
SaveCheckResponse
can_saveWhether the user is allowed to save more scenarios
remainingNumber of saves remaining; null when the plan is unlimited
SaveScenarioRequest
user_idinstance_idinput_objectinstance_nameoverwriteWhether an existing scenario with this instance_id may be replaced. When false (the default), saving onto an existing instance_id fails with 409 SCENARIO_ALREADY_EXISTS instead of silently replacing the stored scenario.
ScenarioRequest
scenarioIdThe unique Scenario ID
scenarioNameOptional name to lookup example scenarios
SubscribeRequest
emailnamesourcemessageorganizationUpdateScenarioRequest
instance_idnew_namestateUserRunsResponse
ProblemData
TimeSettings
timeUnitThe time unit to use for optimization. This time unit will apply, as applicable, to location open and close windows, trip open and close windows, vehicle operating times, and travel durations. Integer (default) indicates that all times are in absolute time units from an arbitrarily defined time 0. Clock indicates that times will be interpreted as literal clock times and calendar dates.
timeFormatThe format to expect all time fields in. This field is only relevant when timeUnit = "clock". Formattings should match the formats described by the python pandas.Period.strftime class. For example, if the format used matches 09:32pm, then '%I:%M%p'. If null is passed, then the pandas.to_datetime function will be used to detect the format.
multipleDaysA boolean field indicating whether to allow the optimization time period to extend multiple days. This field is relevant only when timeUnit = "datetime".
dateUnitThe date unit to use for optimization. This field is only relevant when timeUnit = "clock" and multipleDays = true. If this field is integer, then days will be measured as absolute days from an arbitrarily defined day 0. Calendar indidates that dates will be interpreted as literal calendar dates.
dateFormatThe format to expect all dates fields in. This field is only relevant when dateUnit = "calendar", multipleDays = true, and timeUnit = "clock". Formattings should match the formats described by the python pandas.Period.strftime class. For example, if the format used matches 2024-12-31, then '%Y-%m-%d' should be passed for this parameter. If null is passed, then the pandas.to_datetime function will be used to detect the format.
Location
locationIdA string that uniquely identifies this location.
locationNameA name for this location (optional).
demandThe amount of vehicle capacity this location consumes
latitudeThe latitude for this location. Required only if autoCalculateDuration or autoCalculateDistance is true.
longitudeThe longitude for this location. Required only if autoCalculateDuration or autoCalculateDistance is true.
xCartesian x position on an arbitrary plane (warehouse floor, factory layout, PCB). Unbounded - deliberately NOT range-validated, unlike longitude. Use with coordinateSystem=cartesian; x is the exact counterpart of longitude (x = longitude, y = latitude), so a scenario can migrate between the two families without reordering. Supply either latitude/longitude or x/y, never both.
yCartesian y position on an arbitrary plane. Unbounded - deliberately NOT range-validated, unlike latitude. Use with coordinateSystem=cartesian; y is the exact counterpart of latitude. Supply either latitude/longitude or x/y, never both.
isDepotWhether this location serves only as a depot for vehicles (true) or if this location should be serviced.
serviceDurationHow long service at this location takes.
minArrivalTimeIntAn integer value representing the earliest time this location can be serviced (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup.
minArrivalTimeStrA string value representing the earliest time this location can be serviced (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
minArrivalDayIntAn integer value representing the earliest day this location can be serviced. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on pickup.
maxArrivalTimeIntAn integer value representing the latest time this location can be serviced (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup.
maxArrivalTimeStrA string value representing the latest time this location can be serviced (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
maxArrivalDayIntAn integer value representing the latest day this location can be serviced. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on pickup.
exactArrivalTimeIntAn integer value representing the exact time this location must be serviced (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup. This is a HARD PIN: the solver must arrive at exactly this time, applied as an equal min/max window. A location may set EITHER the exact* fields OR the min*/max* window fields, never both — combining them returns 400 EXACT_ARRIVAL_CONFLICT. A pin no vehicle can reach returns 400 EXACT_ARRIVAL_INFEASIBLE naming the earliest feasible arrival; a pin that is reachable but unsatisfiable with the rest of the problem fails the run with 422 EXACT_ARRIVAL_UNSERVABLE rather than silently dropping the stop.
exactArrivalTimeStrA string value representing the exact time this location must be serviced (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup. The time format should correspond to the timeFormat field in ProblemData.timeSettings. This is a HARD PIN: the solver must arrive at exactly this time, applied as an equal min/max window. A location may set EITHER the exact* fields OR the min*/max* window fields, never both — combining them returns 400 EXACT_ARRIVAL_CONFLICT. A pin no vehicle can reach returns 400 EXACT_ARRIVAL_INFEASIBLE naming the earliest feasible arrival; a pin that is reachable but unsatisfiable with the rest of the problem fails the run with 422 EXACT_ARRIVAL_UNSERVABLE rather than silently dropping the stop.
exactArrivalDayIntAn integer value representing the exact day this location must be serviced. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on pickup. This is a HARD PIN: the solver must arrive at exactly this time, applied as an equal min/max window. A location may set EITHER the exact* fields OR the min*/max* window fields, never both — combining them returns 400 EXACT_ARRIVAL_CONFLICT. A pin no vehicle can reach returns 400 EXACT_ARRIVAL_INFEASIBLE naming the earliest feasible arrival; a pin that is reachable but unsatisfiable with the rest of the problem fails the run with 422 EXACT_ARRIVAL_UNSERVABLE rather than silently dropping the stop.
colorThe color to use for this location in the output. Accepts a hex code ("#FF0000") or a CSS color name ("crimson").
vehicleTypeIdsThe vehicleTypeIds that can service this location. These vehicleTypeIds must exist in the VehicleTypes passed in ProblemData for this problem. Leave empty if there are no restrictions on which vehicle types can service this location.
fixedVehicleIdOptional. Pin this location to a specific vehicle: the solve must use this vehicle to serve this stop. The vehicleId must exist in the Vehicles passed in ProblemData. If the pin cannot be satisfied - the vehicle does not exist, or its type is excluded by this location's vehicleTypeIds - the location is returned unassigned rather than served by a different vehicle. Leave null for no pin.
Trip
tripIdA unique identifier for this trip.
fromLocationIdThe locationId for the origin location of this trip. This locationId must exist in the Locations passed in ProblemData for this problem.
toLocationIdThe locationId for the destination location of this trip. This locationId must exist in the Locations passed in ProblemData for this problem.
tripNameA name for this trip (optional).
vehicleTypeIdsThe vehicleTypeIds that can be used to service this trip. These vehicleTypeIds must exist in the VehicleTypes passed in ProblemData for this problem.
fixedVehicleIdOptional. Pin this trip to a specific vehicle: the solve must use this vehicle for both the pickup and the delivery. The vehicleId must exist in the Vehicles passed in ProblemData. If the pin cannot be satisfied - the vehicle does not exist, or its type is excluded by this trip's vehicleTypeIds - the trip is returned unassigned rather than served by a different vehicle. Leave null for no pin.
minPickupTimeIntAn integer value representing the earliest time this trip can be picked up (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup.
minPickupTimeStrA string value representing the earliest time this trip can be picked up. Leave empty if there are no time restrictions on pickup. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
minPickupDayIntAn integer value representing the earliest day this trip can be picked up. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on pickup.
maxPickupTimeIntAn integer value representing the latest time this trip can be picked up (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup.
maxPickupTimeStrA string value representing the latest time this trip can be picked up. Leave empty if there are no time restrictions on pickup. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
maxPickupDayIntAn integer value representing the latest day this trip can be picked up. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on pickup.
exactPickupTimeIntAn integer value representing the exact time this trip must be picked up (time t=0 is the earliest start time). Leave empty if there are no time restrictions on pickup.
exactPickupTimeStrA string value representing the exact time this trip must be picked up. Leave empty if there are no time restrictions on pickup. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
exactPickupDayIntAn integer value representing the exact day this trip must be picked up. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on pickup.
minDeliveryTimeIntAn integer value representing the earliest time this trip can be delivered (time t=0 is the earliest start time). Leave empty if there are no time restrictions on delivery.
minDeliveryTimeStrA string value representing the earliest time this trip can be delivered. Leave empty if there are no time restrictions on delivery. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
minDeliveryDayIntAn integer value representing the earliest day this trip can be delivered. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on delivery.
maxDeliveryTimeIntAn integer value representing the latest time this trip can be delivered (time t=0 is the earliest start time). Leave empty if there are no time restrictions on delivery.
maxDeliveryTimeStrA string value representing the latest time this trip can be delivered. Leave empty if there are no time restrictions on delivery. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
maxDeliveryDayIntAn integer value representing the latest day this trip can be delivered. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on delivery.
exactDeliveryTimeIntAn integer value representing the exact time this trip must be delivered (time t=0 is the earliest start time). Leave empty if there are no time restrictions on delivery.
exactDeliveryTimeStrA string value representing the exact time this trip must be delivered. Leave empty if there are no time restrictions on delivery. The time format should correspond to the timeFormat field in ProblemData.timeSettings.
exactDeliveryDayIntAn integer value representing the exact day this trip must be delivered. Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on delivery.
demandThe amount of vehicle capacity this trip consumes.
excessTravelTimeMaximum minutes the actual pickup->delivery transit may exceed the direct travel time for this trip (caps detours from pooling). Null = no cap.
pickupServiceDurationMinutes to service the pickup (e.g. park and load) at the trip's origin. Charged at the pickup stop. Defaults to 0.
deliveryServiceDurationMinutes to service the drop-off (e.g. park and unload) at the trip's destination. Charged at the delivery stop. Defaults to 0.
Vehicle
vehicleIdA unique identifier for this vehicle, represented as a UUID.
vehicleTypeIdThe vehicleTypeId for this vehicle. This vehicleTypeId must exist in the VehicleTypes passed in ProblemData for this problem.
startLocationIdThe locationId of the depot for this vehicle type. This locationId must exist in the Locations passed in ProblemData for this problem.
vehicleNameA name for this vehicle (optional).
fixedCostThe fixed cost for using this vehicle.
minStartTimeIntAn integer value representing the earliest time this vehicle can depart from its depot to begin its route(s) (time t=0 is the earliest start time). Leave empty if there are no restrictions on when the vehicle can start.
minStartTimeStrA string value representing the earliest time this vehicle can depart from its depot to begin its route(s). Leave empty if there are no restrictions on when the vehicle can start. The time format should match the timeFormat field in ProblemData.timeSettings.
minStartDayIntAn integer value representing the earliest day this vehicle can depart from its depot to begin its route(s). Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on when the vehicle can start.
maxEndTimeIntAn integer value representing the latest time this vehicle must return to its depot after completing its route(s) (time t=0 is the earliest start time). Leave empty if there are no restrictions on when the vehicle must finish.
maxEndTimeStrA string value representing the latest time this vehicle must return to its depot after completing its route(s). Leave empty if there are no restrictions on when the vehicle must finish. The time format should match the timeFormat field in ProblemData.timeSettings.
maxEndDayIntAn integer value representing the latest day this vehicle must return to its depot after completing its route(s). Only relevant if ProblemData.timeSettings.multipleDays is true and ProblemData.timeSettings.timeUnit is "clock". Leave empty if there are no restrictions on when the vehicle must finish.
endLocationIdThe locationId of the depot for this vehicle type. If null, then the startLocationId will be used as the end location. This locationId must exist in the Locations passed in ProblemData for this problem.
colorThe color to use for this vehicle in the output. Accepts a hex code ("#FF0000") or a CSS color name ("crimson").
VehicleType
vehicleTypeIdA unique identifier for this vehicle type.
vehicleTypeA name for this vehicle type.
capacityThe maximum capacity of this vehicle type, in units of demand. Leave null if this vehicle type has no capacity limit.
allowResupplyWhether this vehicle type can be resupplied during an optimization run.
TravelCost
fromLocationIdThe locationId of the origin location for this travel cost. This locationId must exist in the Locations passed in ProblemData for this problem.
toLocationIdThe locationId of the destination location for this travel cost. This locationId must exist in the Locations passed in ProblemData for this problem.
vehicleTypeIdThe vehicleTypeId for this travel cost. This vehicleTypeId must exist in the VehicleTypes passed in ProblemData for this problem. If null, then the travel cost will apply to all vehicle types.
vehicleTypeThe name of the vehicle type for this travel cost. This field is optional and is provided for convenience only.
durationThe travel duration between these two locations. If using integer time, then this should be in integer time units. If using clock time, then this should provided in seconds. If null, then the travel duration will be calculated automatically based on the latitude and longitude of the locations.
distanceThe travel distance between these two locations. If null, then the travel distance will be calculated automatically based on the latitude and longitude of the locations. Any arbitrary unit can be used for distance, but the unit should be consistent across all entries.
costThe cost of travel between these two locations.
RequestAccepted
problemIdThe unique identifier for this optimization run. You will want to store this locally so that you can use in your GET request for /problem.
ProblemStatus
statusThe status of the optimization problem identified by the problemId parameter.
ProblemResult
problemIdThe unique identifier for this optimization run.
The status of the optimization problem identified by the problemId parameter.
Metadata about the optimization problem
A list of stops that were visited by vehicles during the optimization run. Each stop represents a location that was visited by a vehicle.
A list of stops that were visited by vehicles during the optimization run, along with additional details about the location and vehicle.
A list of locations that were not visited by any vehicle during the optimization run.
A list of locations that were not visited by any vehicle during the optimization run, along with additional details about the location.
A list of trips that were not serviced by any vehicle during the optimization run.
A list of trips that were not serviced by any vehicle during the optimization run, along with additional details about the trip.
pathsA list of paths taken by vehicles during the optimization run. Each path represents a sequence of stops made by a vehicle.
A list of vehicle usage summaries for the optimization run.
VehicleUsage
vehicleIdThe unique identifier of the vehicle.
usedWhether the vehicle was used (assigned at least one stop) during the optimization run.
fixedCostIncurredThe fixed cost incurred by this vehicle. This equals the vehicle's fixed cost if the vehicle was used, otherwise 0.
VehiclesAssigned
assignedThe number of vehicles assigned at least one stop.
availableThe total number of vehicles available in the problem.
LocationsAssigned
assignedThe number of locations assigned to a vehicle route.
totalThe total number of locations in the problem.
AssignmentSummary
Summary of vehicle assignment counts for an optimization run.
Summary of location assignment counts for an optimization run.
RouteSummary
totalDistanceTraveledTotal distance traveled across all vehicle routes, in the distance units specified by the problem settings.
totalMinutesTraveledTotal travel time in minutes across all vehicle routes.
totalTravelCostTotal travel cost across all vehicle routes.
CostSummary
fixedCostSum of fixed costs for all vehicles used in the solution.
travelCostSum of distance- or time-based travel costs across all routes.
TimingSummary
solveTimeWall-clock time in seconds taken by the solver to produce a solution.
ResultSummary
High-level counts of vehicles and locations that were assigned during the optimization run.
Aggregate travel metrics across all vehicle routes in the optimization run.
Breakdown of fixed and variable costs for the optimization run.
Timing information for the optimization run.
ProblemResponse
The full optimization result including routes, stops, and unassigned locations.
A high-level summary of key metrics from the optimization run.
CostMatrixResponse
A list of travel costs between pairs of locations. Each travel cost represents the duration, distance, and cost of travel between two locations.
A list of errors encountered during the cost matrix calculation. Each error represents a problem with calculating the travel cost between two locations.
TravelCostResponses
This schema defines the response for travel costs between pairs of locations.
fromLocationIdThe locationId of the origin location for this travel cost
toLocationIdThe locationId of the destination location for this travel cost.
fromLocationNameThe name of the origin location for this travel cost.
toLocationNameThe name of the destination location for this travel cost.
vehicleTypeIdThe vehicleTypeId for this travel cost. If null, then the travel cost will apply to all vehicle types.
vehicleTypeThe name of the vehicle type for this travel cost. If null, then the travel cost will apply to all vehicle types.
durationThe travel duration between these two locations.
distanceThe travel distance between these two locations.
costThe cost of travel between these two locations.
statusThe status of the travel cost calculation. This will be "s" for success, "e" for error, and "w" for warning (i.e. calculated with a fallback method).
errorMessageIf an error was encountered during the calculation of this travel cost, this field will contain a human-readable message describing the error. If no error was encountered, this field will be null.
TravelCostErrors
This schema defines an error encountered during the cost matrix calculation. Each error represents a problem with calculating the travel cost between two locations.
errorMessageA human-readable message describing the error encountered during the cost matrix calculation.
errorDescriptionA more detailed description of the error encountered during the cost matrix calculation.
RouteStop
stopIdA unique identifier for this stop, represented as a UUID.
locationIdThe locationId of the stop.
vehicleIdThe vehicleId of the vehicle that visited this stop.
travelCostToThe cost of stopping at this location, including the travel cost incurred to get to this location.
serviceDurationThe amount of time the vehicle spent servicing this stop.
stopNumberThe stop number for this stop in the route. This is a 1-based index.
capacityServedThe amount of capacity served at this stop.
tripIdThe tripId of the trip that visited this stop, if applicable for this problem type.
arrivalTimeIntThe time at which the vehicle arrived at this stop, in integer time units. This is the number of time units from the start of the optimization run.
arrivalTimeStrThe time at which the vehicle arrived at this stop, in the clock time format specified in the ProblemData.timeSettings.timeFormat field.
departureTimeIntThe time at which the vehicle departed from this stop, in integer time units. This is the number of time units from the start of the optimization run.
departureTimeStrThe time at which the vehicle departed from this stop, in the clock time format specified in the ProblemData.timeSettings.timeFormat field.
waitDurationStartThe amount of time the vehicle waited at this stop before servicing the location.
waitDurationEndThe amount of time the vehicle waited at this stop after servicing the location.
stopTypeThe type of stop. This indicates whether the stop is a location visit, pickup, delivery, route start, route end, break start, break end, or restock.
actionThe action taken at this stop. This is a human-readable description of the action taken at this stop, such as "Pickup 5 passengers at Chicago for Trip 1" or "Deliver 10 packages to New York".
travelDurationFromPreviousStopThe travel duration from the previous stop to this stop, in the time units specified by the problem settings.
travelDistanceFromPreviousStopThe travel distance from the previous stop to this stop, in the distance units specified by the problem settings.
RouteStopFull
stopIdA unique identifier for this stop, represented as a UUID.
locationIdThe locationId of the stop.
vehicleIdThe vehicleId of the vehicle that visited this stop.
travelCostToThe cost of stopping at this location, including the travel cost incurred to get to this location.
serviceDurationThe amount of time the vehicle spent servicing this stop.
stopNumberThe stop number for this stop in the route. This is a 1-based index.
capacityServedThe amount of capacity served at this stop.
locationNameThe name of the location for this stop.
colorThe color associated with this stop -- the serving vehicle's color, echoed back as supplied (hex code or CSS color name).
tripIdThe tripId of the trip that visited this stop, if applicable for this problem type.
arrivalTimeIntThe time at which the vehicle arrived at this stop, in integer time units. This is the number of time units from the start of the optimization run.
arrivalTimeStrThe time at which the vehicle arrived at this stop, in the clock time format specified in the ProblemData.timeSettings.timeFormat field.
departureTimeIntThe time at which the vehicle departed from this stop, in integer time units. This is the number of time units from the start of the optimization run.
departureTimeStrThe time at which the vehicle departed from this stop, in the clock time format specified in the ProblemData.timeSettings.timeFormat field.
waitDurationStartThe amount of time the vehicle waited at this stop before servicing the location.
waitDurationEndThe amount of time the vehicle waited at this stop after servicing the location.
stopTypeThe type of stop. This indicates whether the stop is a location visit, pickup, delivery, route start, route end, break start, break end, or restock.
actionThe action taken at this stop. This is a human-readable description of the action taken at this stop, such as "Pickup 5 passengers at Chicago for Trip 1" or "Deliver 10 packages to New York".
travelDurationFromPreviousStopThe travel duration from the previous stop to this stop, in the time units specified by the problem settings.
travelDistanceFromPreviousStopThe travel distance from the previous stop to this stop, in the distance units specified by the problem settings.
vehicleNameThe name of the vehicle serving this stop, when the user provided one. Denormalized from the submitted vehicle (like locationName) so a route sheet is readable without re-joining the input; null when the vehicle is unnamed.
fixedVehicleIdThe vehicleId this stop was pinned to via the input's fixedVehicleId, or null if it was not pinned. Lets a client tell 'this vehicle was chosen by the solver' from 'this vehicle was required', without re-joining against the request.
UnassignedLocation
locationIdThe locationId of the unassigned location.
demandDroppedThe amount of demand that was not served at this location.
UnassignedLocationFull
locationIdThe locationId of the unassigned location.
demandDroppedThe amount of demand that was not served at this location.
locationNameThe name of the unassigned location.
latitudeThe latitude of the unassigned location.
longitudeThe longitude of the unassigned location.
isDepotWhether this unassigned location serves only as a depot (true) or if this location should be serviced (false).
ProcessUploadedTravelCostRequest
An array of objects representing the uploaded travel cost data. Each object should contain the necessary fields to process the travel costs.
The locations to use for processing the uploaded travel cost data.
The travel costs to use for processing the uploaded travel cost data.
overwriteExistingEntriesWhether to overwrite existing travel cost entries with the uploaded data. If true, existing entries will be replaced with the new data. If false, new entries will be added without modifying existing ones.
The vehicle types to use for processing the uploaded travel cost data. Required only if the travel costs are dependent on vehicle types.
costSettingsThe settings to use for calculating travel costs between locations. This includes the cost metric (duration or distance), cost multiplier, cost adder, and methods for calculating distances and durations.
ProcessUploadedTravelCostResponse
A list of travel costs that were successfully processed from the uploaded data. Each travel cost represents the duration, distance, and cost of travel between two locations.
A list of notifications about the processing of the uploaded travel cost data. Each notification provides information about the processing status of each entry.
A list of new locations that were added to the system as a result of processing the uploaded travel cost data.
A list of new vehicle types that were added to the system as a result of processing the uploaded travel cost data.
UploadedTravelCostNotification
typeThe type of the processing notification for this travel cost entry.
messageA message providing additional information about the processing status, such as errors encountered or successful processing confirmation.
UnassignedTrip
tripIdThe tripId of the unassigned trip.
demandDroppedThe amount of demand that was not able to be served by any vehicle for this trip.
capacityServedThe amount of capacity that was served for this dropped trip. This will typically be 0, but in some cases (e.g. partial deliveries) it may be greater than 0.
UnassignedTripFull
tripIdThe tripId of the unassigned trip.
demandDroppedThe amount of demand that was not able to be served by any vehicle for this trip.
capacityServedThe amount of capacity that was served for this dropped trip. This will typically be 0, but in some cases (e.g. partial deliveries) it may be greater than 0.
tripNameThe name of the unassigned trip.
fromLocationNameThe name of the origin location for this trip.
toLocationNameThe name of the destination location for this trip.
fromLocationIdThe locationId of the origin location for this trip.
toLocationIdThe locationId of the destination location for this trip.
fromLatitudeThe latitude of the origin location for this trip.
fromLongitudeThe longitude of the origin location for this trip.
toLatitudeThe latitude of the destination location for this trip.
toLongitudeThe longitude of the destination location for this trip.
ProblemMetaData
problemTypeThe type of optimization problem that was run.
submissionTimestampThe date and time when the optimization problem was submitted, in unix timestamp in seconds
queueTimeThe time spent in the queue before the optimization run started, in seconds.
optimizationTimeThe time taken to run the optimization, in seconds.
CostMatrixRequest
The locations to use for calculating the cost matrix.
costSettingsThe settings to use for calculating travel costs between locations. This includes the cost metric (duration or distance), cost multiplier, cost adder, and methods for calculating distances and durations.
The travel costs to use for calculating the cost matrix. If not provided, the cost matrix will be calculated automatically based on the latitude and longitude of the locations. A partial cost matrix can be provided to avoid recalculating travel durations and distances between locations.
coordinateSystemWhich coordinate family this problem's locations use. geographic (the default, and what every existing payload means) uses latitude/longitude on the Earth. cartesian uses unbounded x/y on an arbitrary plane, for scenarios with positions but no addresses. It describes the DATA, not the costing, so it is set once per request rather than per cost setting - and it decides which distance/duration methods are valid.
CostSettings
costMetricThe metric to use as the base for calculating travel costs. A multiplier and/or adder can be applied to this metric to calculate the final travel cost. If duration is selected, then the travel cost will be calculated based on the travel duration between locations. If distance is selected, then the travel cost will be calculated based on the travel distance between locations.
The cost multiplier to apply to the base cost metric (duration or distance) to calculate the final travel cost.
The cost adder to apply to the base cost metric (duration or distance) to calculate the final travel cost.
autoCalculateDurationWhether to automatically calculate travel durations between locations based on their latitude and longitude.
autoCalculateDistanceWhether to automatically calculate travel distances between locations based on their latitude and longitude.
distanceMethodThe method to use for calculating distances between locations. Driving uses Open Route Service to calculate driving distances, geo uses the Haversine formula to calculate distances based on latitude and longitude, and Manhattan uses the Manhattan distance formula.
durationMethodThe method to use for calculating durations between locations. Driving uses Open Route Service to calculate driving durations, geo uses the Haversine formula to calculate durations based on latitude and longitude, and Manhattan uses the Manhattan distance formula.
averageSpeedAverage travel speed used to turn a computed DISTANCE into a DURATION for the non-driving methods (geo, manhattan, euclidean), in distance units per hour. Ignored when durationMethod is "driving", where the road network supplies real durations.
This exists because a straight-line distance is not a time. Before it, geo durations were the distance number itself, which meant every vehicle travelled at exactly 60 mph between adjacent stops. The default of 30 suits urban and suburban work; raise it for long inter-city legs, lower it for dense city centres or mountain roads.
roadCircuityFactorMultiplier applied to a straight-line distance when deriving DURATION, to account for roads not running as the crow flies. Affects duration only - the reported distance stays the true geodesic value the method name promises. 1.25 is a common urban rule of thumb; use 1.0 to model travel that really is direct.
CostMultiplier
vehicleTypeDependenceWhether the cost multiplier should depend on the vehicle type. If true, then the cost multiplier will be applied separately for each vehicle type. If false, then the cost multiplier will be applied based on the first vehicle type in the VehicleTypes list.
baseMultiplierThe multiplier to apply to the base cost metric (duration or distance) to calculate the final travel cost.
CostAdder
vehicleTypeDependenceWhether the cost adder should depend on the vehicle type. If true, then the cost adder will be applied separately for each vehicle type. If false, then the cost adder will be applied based on the first vehicle type in the VehicleTypes list.
baseAdderThe adder to apply to the base cost metric (duration or distance) to calculate the final travel cost.
PlanLimits
Limits for locations table
Limits for trips table
Limits for vehicles table
Limits for vehicle types table
saved_scenariosMaximum saved scenarios (null for unlimited)
run_history_daysDays of run history retention (null for unlimited)
max_concurrent_solvesMaximum number of solves (queued + running) the user may have in flight at once
UserPlanObject
planThe name of this user's plan
Structured plan limits for the user
Capability flags for this plan, keyed by feature (e.g. "resupply", "multi_day", "heterogeneous_travel_costs"). Only keys the plan overrides are listed; anything absent is allowed by default. The backend enforces these on /problem regardless, so treat them as a hint for disabling UI affordances up front rather than as the authority.
PublicPlan
tierStable internal tier key (never changes), e.g. "free" or "professional".
planNameCustomer-facing display name as configured in the Clerk dashboard, e.g. "Professional".
Resolved per-tier limits.
Capability flags keyed by feature; absent keys default to allowed.
ExampleScenarioCard
instance_idUnique id of the saved scenario; pass as scenarioId to /saved_scenario.
slugStable, URL-safe unique key ([a-z0-9-]).
scenario_nameFull display name of the scenario.
model_typeModel type, e.g. "pickup-delivery" or "vehicle-routing".
titleShort card heading (may be empty).
brief_description1-3 sentence blurb shown under the title.
banner_imageCard image URL; empty when none is set.
constraintsKey constraints shown as bullets.
tagsTags for gallery filtering and card chips.
Small stat objects, e.g. [{"Locations":17},{"Trips":12}].
industryIndustry/vertical for gallery filtering, e.g. "healthcare", "transportation" (empty when not set).
secondary_industriesAdditional industries this example also belongs to, beside the primary industry. A gallery filter should treat an example as matching if the requested industry is the primary OR appears here. Optional and additive: an absent or empty array behaves exactly as a card with only industry set, so clients that ignore it are unaffected. Exists because some scenarios genuinely sit in two verticals - special-needs school transport is education and healthcare; roll-off container swaps are public-works and logistics - and forcing one label makes an industry page look emptier than the library actually is.
Where an example scenario is set, for gallery filtering.
scaleDerived instance size bucket: "small", "medium", or "large" (empty when not set).
constraints_tagsConstraint-shape tags for gallery filtering (e.g. "time windows", "vehicle types"), distinct from industry.
colorDimensionWhich fact this example's per-location colours encode. The same light-to-dark ramp means time of day on one example and demand on another, so a legend must read this rather than infer meaning from the swatches. "none" means the example's stops are uniform and are deliberately left uncoloured.
colorDimensionLabelDisplay name for colorDimension, rendered verbatim as a legend title. Null when colorDimension is "none".
colorScaleHow to render the legend: "categorical" for a swatch per group, "ramp" for an ordered light-to-dark strip. Null when colorDimension is "none".
colorBucketsOnly the colours this example actually uses, in scale order, so a legend shows the two steps in play rather than every step of the scale. Empty when colorDimension is "none".
ExampleGeography
cityregioncountryScenarioTables
CoordinateSystem
Which coordinate family this problem's locations use. geographic (the default, and what every existing payload means) uses latitude/longitude on the Earth. cartesian uses unbounded x/y on an arbitrary plane, for scenarios with positions but no addresses. It describes the DATA, not the costing, so it is set once per request rather than per cost setting - and it decides which distance/duration methods are valid.
