Skip to content
GuidesPlaygroundDashboard

Map Match

Match GPS coordinates to the road network
map_match.match(MapMatchMatchParams**kwargs) -> MapMatchResult
POST/api/v1/map-match
ModelsExpand Collapse
class MapMatchRequest:

GPS trace to match against the road network

GPS trace (GeoJSON LineString geometry)

coordinates: Union[List[float], List[List[float]], List[List[List[float]]], List[List[List[List[float]]]]]

GeoJSON coordinates array (nesting depth varies by geometry type)

One of the following:
List[float]
List[List[float]]
List[List[List[float]]]
List[List[List[List[float]]]]
type: Literal["Point", "LineString", "Polygon", 3 more]
One of the following:
"Point"
"LineString"
"Polygon"
"MultiPoint"
"MultiLineString"
"MultiPolygon"
radiuses: Optional[List[float]]

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

class MapMatchResult:

Map matching result with snapped geometry

geometry: GeoJsonGeometry
coordinates: Union[List[float], List[List[float]], List[List[List[float]]], List[List[List[List[float]]]]]

GeoJSON coordinates array (nesting depth varies by geometry type)

One of the following:
List[float]
List[List[float]]
List[List[List[float]]]
List[List[List[List[float]]]]
type: Literal["Point", "LineString", "Polygon", 3 more]
One of the following:
"Point"
"LineString"
"Polygon"
"MultiPoint"
"MultiLineString"
"MultiPolygon"
properties: Properties
confidence: Optional[float]

Match confidence score

distance: Optional[float]

Total matched distance in meters

duration: Optional[float]

Estimated duration in seconds

type: Literal["Feature"]
legs: Optional[List[Dict[str, object]]]

Matched route legs between consecutive trace points