curl --request POST \
--url https://api.footstep.ai/v1/routing/locate \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"locations": [
{
"lat": 51.5322,
"lon": -0.124
},
{
"lat": 51.5055,
"lon": -0.0754
}
]
}
'{
"locations": [
{
"input": {
"lat": 0,
"lon": 0
},
"distance_meters": 123,
"on_road": true,
"snapped": {
"lat": 0,
"lon": 0
},
"edges": [
{
"names": [
"<string>"
],
"road_class": "motorway",
"speed_kph": 123,
"surface": "paved_smooth",
"elevation_meters": 123
}
]
}
]
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}Routing
Locate on Road
Check if coordinates are on a routable road and get the nearest snapped position. Returns distance, on-road status, and optionally edge metadata (road class, surface, speed).
POST
/
v1
/
routing
/
locate
curl --request POST \
--url https://api.footstep.ai/v1/routing/locate \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"locations": [
{
"lat": 51.5322,
"lon": -0.124
},
{
"lat": 51.5055,
"lon": -0.0754
}
]
}
'{
"locations": [
{
"input": {
"lat": 0,
"lon": 0
},
"distance_meters": 123,
"on_road": true,
"snapped": {
"lat": 0,
"lon": 0
},
"edges": [
{
"names": [
"<string>"
],
"road_class": "motorway",
"speed_kph": 123,
"surface": "paved_smooth",
"elevation_meters": 123
}
]
}
]
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}Authorizations
Your Footstep API key
Body
application/json
Required array length:
1 - 100 elementsShow child attributes
Show child attributes
Filter edges by travel type
Available options:
auto, bicycle, pedestrian, bus, truck Include edge metadata
Response format. footstep = optimised for app developers (encoded polyline, flat structure). geojson = standard GeoJSON FeatureCollection (decoded coordinates, immediately usable in Leaflet/Mapbox GL/deck.gl).
Available options:
footstep, geojson Response
Locate results
Show child attributes
Show child attributes