Endpoints
Solve
Submit a vehicle routing problem and receive optimized routes
POST
/
v3
/
routing
/
solve
curl -X POST https://api.solvice.io/v3/routing/solve \
-H "Authorization: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"vehicles": [
{
"id": "truck-1",
"start": [4.3517, 50.8503],
"end": [4.3517, 50.8503],
"shifts": [
{
"from": "2026-04-01T08:00:00+02:00",
"to": "2026-04-01T17:00:00+02:00"
}
],
"capacity": [100],
"skills": ["refrigerated"],
"max_duration": 28800
}
],
"jobs": [
{
"id": "delivery-1",
"location": [4.7005, 50.8798],
"demand": [10],
"time_windows": [
{
"from": "2026-04-01T09:00:00+02:00",
"to": "2026-04-01T12:00:00+02:00"
}
],
"service_duration": 300,
"skills": ["refrigerated"]
},
{
"id": "delivery-2",
"location": [3.7303, 51.05],
"demand": [20],
"time_windows": [
{
"from": "2026-04-01T10:00:00+02:00",
"to": "2026-04-01T15:00:00+02:00"
}
],
"service_duration": 600
}
],
"options": {
"time_limit_ms": 5000,
"seed": 42,
"minimize": "time"
}
}'
{
"summary": {
"status": "completed",
"total_distance": 142000,
"total_duration": 7200,
"vehicles_used": 1,
"jobs_assigned": 2,
"jobs_unassigned": 0,
"elapsed_ms": 850,
"iterations": 1200
},
"routes": [
{
"vehicle_id": "truck-1",
"shift_from": "2026-04-01T08:00:00+02:00",
"shift_to": "2026-04-01T17:00:00+02:00",
"stops": [
{
"job_id": "delivery-2",
"location": [3.7303, 51.05],
"arrival": "2026-04-01T08:40:00+02:00",
"departure": "2026-04-01T08:50:00+02:00",
"wait_time": 0,
"travel_time": 2400,
"service_time": 600,
"load_after": [20]
},
{
"job_id": "delivery-1",
"location": [4.7005, 50.8798],
"arrival": "2026-04-01T09:50:00+02:00",
"departure": "2026-04-01T09:55:00+02:00",
"wait_time": 0,
"travel_time": 3600,
"service_time": 300,
"load_after": [30]
}
],
"distance": 142000,
"duration": 7200,
"load": 30,
"n_stops": 2,
"start_time": "2026-04-01T08:00:00+02:00",
"end_time": "2026-04-01T10:30:00+02:00"
}
],
"unassigned": []
}
Documentation Index
Fetch the complete documentation index at: https://docs.solvice.io/llms.txt
Use this file to discover all available pages before exploring further.
Request body
List of available vehicles with start/end locations, capacity, and time windows.
Show Vehicle object
Show Vehicle object
Unique vehicle identifier
Start location as
[longitude, latitude]End location as
[longitude, latitude]. Defaults to start if omitted.Working shifts. Each shift has
from and to (ISO 8601), and can optionally override start, end, and capacity.Capacity per dimension, e.g.
[100] for weight or [50, 30] for weight + volumeList of skill strings this vehicle provides
Maximum route distance in metres
Maximum route duration in seconds
List of jobs (deliveries, pickups, service visits) to assign to vehicles.
Show Job object
Show Job object
Unique job identifier
Location as
[longitude, latitude]Capacity consumed per dimension, e.g.
[10]Service duration in seconds
Allowed service windows, each with
from and to (ISO 8601)Required vehicle skills
Lock this job to a specific vehicle ID
Ordering constraints between jobs. Each relation has
type ("SEQUENCE" or "FIRST_JOB") and jobs (ordered list of job IDs).Solver options.
Show Options
Show Options
Wall-clock budget in milliseconds (default: 1000). Time spent fetching the distance matrix is deducted before solving.
Random seed for reproducible results (default: 42)
Primary objective:
"time" (default) or "distance"Custom pre-computed distance/duration matrix. When provided, no call to Solvice Maps is made. Must have
distances and durations as square N×N arrays.Radius in meters for classifying nearby jobs as proximity neighbors
Soft penalty per proximity violation (0–100,000)
Response
Aggregate statistics for the solve run.
Show Summary
Show Summary
"completed" or "partial"Sum of all route distances in metres
Sum of all route durations in seconds
Number of routes with at least one job
Jobs placed in a route
Jobs that could not be assigned
Wall-clock time of the entire request
Solver iterations completed
Optimized routes, one per used vehicle.
Show Route object
Show Route object
Vehicle identifier
Shift start (ISO 8601)
Shift end (ISO 8601)
Ordered list of job stops with
job_id, location, arrival, departure, wait_time, travel_time, service_time, load_afterTotal route distance in metres
Total route duration in seconds
Total load consumed on this route
Number of job stops
Route departure time (ISO 8601)
Route return time (ISO 8601)
Jobs that could not be assigned, each with
job_id and reasoncurl -X POST https://api.solvice.io/v3/routing/solve \
-H "Authorization: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"vehicles": [
{
"id": "truck-1",
"start": [4.3517, 50.8503],
"end": [4.3517, 50.8503],
"shifts": [
{
"from": "2026-04-01T08:00:00+02:00",
"to": "2026-04-01T17:00:00+02:00"
}
],
"capacity": [100],
"skills": ["refrigerated"],
"max_duration": 28800
}
],
"jobs": [
{
"id": "delivery-1",
"location": [4.7005, 50.8798],
"demand": [10],
"time_windows": [
{
"from": "2026-04-01T09:00:00+02:00",
"to": "2026-04-01T12:00:00+02:00"
}
],
"service_duration": 300,
"skills": ["refrigerated"]
},
{
"id": "delivery-2",
"location": [3.7303, 51.05],
"demand": [20],
"time_windows": [
{
"from": "2026-04-01T10:00:00+02:00",
"to": "2026-04-01T15:00:00+02:00"
}
],
"service_duration": 600
}
],
"options": {
"time_limit_ms": 5000,
"seed": 42,
"minimize": "time"
}
}'
{
"summary": {
"status": "completed",
"total_distance": 142000,
"total_duration": 7200,
"vehicles_used": 1,
"jobs_assigned": 2,
"jobs_unassigned": 0,
"elapsed_ms": 850,
"iterations": 1200
},
"routes": [
{
"vehicle_id": "truck-1",
"shift_from": "2026-04-01T08:00:00+02:00",
"shift_to": "2026-04-01T17:00:00+02:00",
"stops": [
{
"job_id": "delivery-2",
"location": [3.7303, 51.05],
"arrival": "2026-04-01T08:40:00+02:00",
"departure": "2026-04-01T08:50:00+02:00",
"wait_time": 0,
"travel_time": 2400,
"service_time": 600,
"load_after": [20]
},
{
"job_id": "delivery-1",
"location": [4.7005, 50.8798],
"arrival": "2026-04-01T09:50:00+02:00",
"departure": "2026-04-01T09:55:00+02:00",
"wait_time": 0,
"travel_time": 3600,
"service_time": 300,
"load_after": [30]
}
],
"distance": 142000,
"duration": 7200,
"load": 30,
"n_stops": 2,
"start_time": "2026-04-01T08:00:00+02:00",
"end_time": "2026-04-01T10:30:00+02:00"
}
],
"unassigned": []
}
Was this page helpful?
⌘I
curl -X POST https://api.solvice.io/v3/routing/solve \
-H "Authorization: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"vehicles": [
{
"id": "truck-1",
"start": [4.3517, 50.8503],
"end": [4.3517, 50.8503],
"shifts": [
{
"from": "2026-04-01T08:00:00+02:00",
"to": "2026-04-01T17:00:00+02:00"
}
],
"capacity": [100],
"skills": ["refrigerated"],
"max_duration": 28800
}
],
"jobs": [
{
"id": "delivery-1",
"location": [4.7005, 50.8798],
"demand": [10],
"time_windows": [
{
"from": "2026-04-01T09:00:00+02:00",
"to": "2026-04-01T12:00:00+02:00"
}
],
"service_duration": 300,
"skills": ["refrigerated"]
},
{
"id": "delivery-2",
"location": [3.7303, 51.05],
"demand": [20],
"time_windows": [
{
"from": "2026-04-01T10:00:00+02:00",
"to": "2026-04-01T15:00:00+02:00"
}
],
"service_duration": 600
}
],
"options": {
"time_limit_ms": 5000,
"seed": 42,
"minimize": "time"
}
}'
{
"summary": {
"status": "completed",
"total_distance": 142000,
"total_duration": 7200,
"vehicles_used": 1,
"jobs_assigned": 2,
"jobs_unassigned": 0,
"elapsed_ms": 850,
"iterations": 1200
},
"routes": [
{
"vehicle_id": "truck-1",
"shift_from": "2026-04-01T08:00:00+02:00",
"shift_to": "2026-04-01T17:00:00+02:00",
"stops": [
{
"job_id": "delivery-2",
"location": [3.7303, 51.05],
"arrival": "2026-04-01T08:40:00+02:00",
"departure": "2026-04-01T08:50:00+02:00",
"wait_time": 0,
"travel_time": 2400,
"service_time": 600,
"load_after": [20]
},
{
"job_id": "delivery-1",
"location": [4.7005, 50.8798],
"arrival": "2026-04-01T09:50:00+02:00",
"departure": "2026-04-01T09:55:00+02:00",
"wait_time": 0,
"travel_time": 3600,
"service_time": 300,
"load_after": [30]
}
],
"distance": 142000,
"duration": 7200,
"load": 30,
"n_stops": 2,
"start_time": "2026-04-01T08:00:00+02:00",
"end_time": "2026-04-01T10:30:00+02:00"
}
],
"unassigned": []
}