Routing
Calculate a route between two points
Snap a coordinate to the nearest road
Snap a coordinate to the nearest road
Calculate an isochrone from a point
Calculate an isochrone from a point
Calculate a distance matrix between points
ModelsExpand Collapse
type MatrixRequest struct{…}Request body for distance matrix calculation. Computes travel durations (and optionally distances) between every origin-destination pair. Maximum 2,500 pairs (origins × destinations), each list capped at 50 coordinates.
Request body for distance matrix calculation. Computes travel durations (and optionally distances) between every origin-destination pair. Maximum 2,500 pairs (origins × destinations), each list capped at 50 coordinates.
Comma-separated list of annotations to include: duration (always included), distance. Example: duration,distance.
type NearestResult struct{…}GeoJSON Point Feature representing the nearest point on the road network to the input coordinate. Used for snapping GPS coordinates to roads.
GeoJSON Point Feature representing the nearest point on the road network to the input coordinate. Used for snapping GPS coordinates to roads.
Geometry GeoJsonGeometryGeoJSON Geometry object per RFC 7946. Coordinates use [longitude, latitude] order. 3D coordinates [lng, lat, elevation] are used for elevation endpoints.
GeoJSON Geometry object per RFC 7946. Coordinates use [longitude, latitude] order. 3D coordinates [lng, lat, elevation] are used for elevation endpoints.
Coordinates GeoJsonGeometryCoordinatesUnionCoordinates array. Nesting depth varies by geometry type: Point = [lng, lat], LineString = [[lng, lat], ...], Polygon = [[[lng, lat], ...], ...], etc.
Coordinates array. Nesting depth varies by geometry type: Point = [lng, lat], LineString = [[lng, lat], ...], Polygon = [[[lng, lat], ...], ...], etc.
type RouteRequest struct{…}Request body for route calculation. Origin and destination are lat/lng coordinate objects. Supports optional waypoints, alternative routes, turn-by-turn steps, and EV routing parameters.
Request body for route calculation. Origin and destination are lat/lng coordinate objects. Supports optional waypoints, alternative routes, turn-by-turn steps, and EV routing parameters.
Number of alternative routes to return (0-3, default 0). When > 0, response is a FeatureCollection of route Features.
Include per-edge annotations (speed, duration) on the route (default: false)
Ev RouteRequestEvoptionalElectric vehicle parameters for EV-aware routing
Electric vehicle parameters for EV-aware routing
Overview RouteRequestOverviewoptionalLevel of geometry detail: full (all points), simplified (Douglas-Peucker), false (no geometry). Default: full.
Level of geometry detail: full (all points), simplified (Douglas-Peucker), false (no geometry). Default: full.
type RouteResult struct{…}GeoJSON Feature representing a calculated route. The geometry is a LineString or MultiLineString of the route path. When alternatives > 0, the response is a FeatureCollection containing multiple route Features.
GeoJSON Feature representing a calculated route. The geometry is a LineString or MultiLineString of the route path. When alternatives > 0, the response is a FeatureCollection containing multiple route Features.
Geometry GeoJsonGeometryGeoJSON Geometry object per RFC 7946. Coordinates use [longitude, latitude] order. 3D coordinates [lng, lat, elevation] are used for elevation endpoints.
GeoJSON Geometry object per RFC 7946. Coordinates use [longitude, latitude] order. 3D coordinates [lng, lat, elevation] are used for elevation endpoints.
Coordinates GeoJsonGeometryCoordinatesUnionCoordinates array. Nesting depth varies by geometry type: Point = [lng, lat], LineString = [[lng, lat], ...], Polygon = [[[lng, lat], ...], ...], etc.
Coordinates array. Nesting depth varies by geometry type: Point = [lng, lat], LineString = [[lng, lat], ...], Polygon = [[[lng, lat], ...], ...], etc.
Properties RouteResultPropertiesRoute metadata
Route metadata
Per-edge annotations (present when annotations: true in request)
Battery charge level at route waypoints as [distance_fraction, charge_pct] pairs (EV routes only)