curl --request POST \
--url https://api.footstep.ai/v1/routing/elevation \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"shape": [
{
"lat": 51.5322,
"lon": -0.124
},
{
"lat": 51.5007,
"lon": -0.1246
},
{
"lat": 51.5055,
"lon": -0.0754
}
]
}
'{
"shape": [
{
"lat": 0,
"lon": 0
}
],
"height": [
123
],
"range_height": [
[
123
]
],
"summary": {
"max_elevation_meters": 123,
"min_elevation_meters": 123,
"avg_elevation_meters": 123,
"total_ascent_meters": 123,
"total_descent_meters": 123
}
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}Get Elevation
Query elevation values for coordinates or an encoded polyline. Returns height values with a computed summary including ascent, descent, min/max/avg elevation.
curl --request POST \
--url https://api.footstep.ai/v1/routing/elevation \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"shape": [
{
"lat": 51.5322,
"lon": -0.124
},
{
"lat": 51.5007,
"lon": -0.1246
},
{
"lat": 51.5055,
"lon": -0.0754
}
]
}
'{
"shape": [
{
"lat": 0,
"lon": 0
}
],
"height": [
123
],
"range_height": [
[
123
]
],
"summary": {
"max_elevation_meters": 123,
"min_elevation_meters": 123,
"avg_elevation_meters": 123,
"total_ascent_meters": 123,
"total_descent_meters": 123
}
}{
"error": "<string>",
"message": "<string>"
}{
"error": "<string>",
"message": "<string>"
}Authorizations
Your Footstep API key
Body
Provide either shape or encoded_polyline
Coordinates (max 2000)
2000Show child attributes
Show child attributes
Encoded polyline alternative
Include cumulative distances
Resample interval in meters
1 <= x <= 1000Decimal places for heights
0 <= x <= 2Response format. footstep = optimised for app developers (encoded polyline, flat structure). geojson = standard GeoJSON FeatureCollection (decoded coordinates, immediately usable in Leaflet/Mapbox GL/deck.gl).
footstep, geojson Response
Elevation data with summary
Show child attributes
Show child attributes
Elevations (when range=false)
[distance_meters, elevation_meters] tuples (when range=true)
2 elementsElevation statistics for the requested points. total_ascent_meters and total_descent_meters are included only when range: true was requested.
Show child attributes
Show child attributes