curl --request POST \
--url https://routing.solvice.io/route \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"coordinates": [
[
123
]
],
"bearings": [
[
123
]
],
"radiuses": [
123
],
"hints": [
"<string>"
],
"generate_hints": true,
"alternatives": 5,
"steps": true,
"annotations": [
"<string>"
],
"geometries": "<string>",
"overview": "<string>",
"continue_straight": true,
"approaches": [
"<string>"
],
"waypoints": [
123
],
"snapping": "<string>",
"vehicleType": "CAR",
"routingEngine": "OSM",
"departureTime": "2024-03-15T08:30:00.000Z",
"interpolate": true,
"exclude": [
"TOLL"
],
"slice": 123
}
'{
"routes": [
{
"distance": 123,
"duration": 123,
"geometry": "<string>",
"legs": [
{
"summary": "<string>",
"distance": 123,
"duration": 123,
"weight": 123
}
]
}
],
"waypoints": [
{
"hint": "<string>",
"distance": 123,
"name": "<string>",
"location": [
123
]
}
]
}Request a route for 2 or more coordinates. Returns total distance, travel time, and the geometry to plot the route on a map.
curl --request POST \
--url https://routing.solvice.io/route \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"coordinates": [
[
123
]
],
"bearings": [
[
123
]
],
"radiuses": [
123
],
"hints": [
"<string>"
],
"generate_hints": true,
"alternatives": 5,
"steps": true,
"annotations": [
"<string>"
],
"geometries": "<string>",
"overview": "<string>",
"continue_straight": true,
"approaches": [
"<string>"
],
"waypoints": [
123
],
"snapping": "<string>",
"vehicleType": "CAR",
"routingEngine": "OSM",
"departureTime": "2024-03-15T08:30:00.000Z",
"interpolate": true,
"exclude": [
"TOLL"
],
"slice": 123
}
'{
"routes": [
{
"distance": 123,
"duration": 123,
"geometry": "<string>",
"legs": [
{
"summary": "<string>",
"distance": 123,
"duration": 123,
"weight": 123
}
]
}
],
"waypoints": [
{
"hint": "<string>",
"distance": 123,
"name": "<string>",
"location": [
123
]
}
]
}Documentation Index
Fetch the complete documentation index at: https://maps.solvice.io/llms.txt
Use this file to discover all available pages before exploring further.
API key authentication. Include your API key in the Authorization header.
Route Dto
The coordinates this request will use, coordinates as [{lon},{lat}] values, in decimal degrees.
2Limits the search to segments with given bearing in degrees towards true north in clockwise direction. Can be null or an array of [{value},{range}] with integer 0 .. 360,integer 0 .. 180.
Limits the coordinate snapping to streets in the given radius in meters. Can be null double >= 0.
Hints for the coordinate snapping. Array of base64 encoded strings.
Whether or not adds a Hint to the response which can be used in subsequent requests. (optional, default true)
Search for up to this many alternative routes. Please note that even if alternative routes are requested, a result cannot be guaranteed. (optional, default 0)
0 <= x <= 10Return route steps for each route leg. (optional, default false)
An array with strings of duration, nodes, distance, weight, datasources, speed (optional)
Returned route geometry format (influences overview and per step). Can also be geojson. (optional, default polyline)
polyline|geojson|polyline6Add overview geometry either full, simplified according to highest zoom level it could be display on, or not at all (false). (optional, default simplified)
full|simplified|falseForces the route to keep going straight at waypoints and don't do a uturn even if it would be faster. Default value depends on the profile.
Keep waypoints on curb side. Can be null (unrestricted, default) or curb.
Indices to coordinates to treat as waypoints. If not supplied, all coordinates are waypoints. Must include first and last coordinate index
default|anyThe vehicle type for which the table is requested
CAR, BIKE, TRUCK, ELECTRIC_CAR, ELECTRIC_BIKE Routing data engine used to calculate distances/durations.
OSM: Open Street Map, traffic-unaware (default).TOMTOM: TomTom map data with predictive traffic patterns. Use with departureTime and optionally interpolate.TOMTOM_REAL_TIME: TomTom map data with real-time traffic. The departureTime field is ignored — every request uses the current time. Available on POST /route and POST /table/sync only (not on async /table or /route/batch).GOOGLE: Google routing data (contact sales).ANYMAP: Solvice's proprietary engine with advanced traffic modeling.CUSTOM: Bring-your-own engine via custom integration.OSM, TOMTOM, GOOGLE, ANYMAP, CUSTOM, TOMTOM_REAL_TIME The departure time for which you want to calculate the route. This will take into account predictive travel time based on TomTom data.
"2024-03-15T08:30:00.000Z"
Enable linear interpolation between time slices for more accurate results based on departure time
Exclude certain road types from routing
TOLL, MOTORWAY, FERRY, TUNNEL, BRIDGE Time slice override for routing. Can be decimal for interpolation (e.g., 2.5 for halfway between slice 2 and 3). If not specified, slice will be determined from departure time.