Skip to content
GuidesPlaygroundDashboard

Map Match

Match GPS coordinates to the road network
mapMatch().match(MapMatchMatchParamsparams, RequestOptionsrequestOptions = RequestOptions.none()) : MapMatchResult
POST/api/v1/map-match
ModelsExpand Collapse
class MapMatchRequest:

GPS trace to match against the road network

GPS trace (GeoJSON LineString geometry)

coordinates: Coordinates

GeoJSON coordinates array (nesting depth varies by geometry type)

One of the following:
List<Double>
List<List<Double>>
List<List<List<Double>>>
List<List<List<List<Double>>>>
type: Type
One of the following:
POINT("Point")
LINE_STRING("LineString")
POLYGON("Polygon")
MULTI_POINT("MultiPoint")
MULTI_LINE_STRING("MultiLineString")
MULTI_POLYGON("MultiPolygon")
radiuses: Optional<List<Double>>

Search radius per coordinate in meters (optional, default 50)

class MapMatchResult:

Map matching result with snapped geometry

geometry: GeoJsonGeometry
coordinates: Coordinates

GeoJSON coordinates array (nesting depth varies by geometry type)

One of the following:
List<Double>
List<List<Double>>
List<List<List<Double>>>
List<List<List<List<Double>>>>
type: Type
One of the following:
POINT("Point")
LINE_STRING("LineString")
POLYGON("Polygon")
MULTI_POINT("MultiPoint")
MULTI_LINE_STRING("MultiLineString")
MULTI_POLYGON("MultiPolygon")
properties: Properties
confidence: Optional<Double>

Match confidence score

distance: Optional<Double>

Total matched distance in meters

duration: Optional<Double>

Estimated duration in seconds

type: Type
legs: Optional<List<Leg>>

Matched route legs between consecutive trace points