More from every route.
Send a GPX, KML or GeoJSON track and get back what people want to know about it: the elevation profile, the ground underfoot, how long it takes and the directions.
One track in, the details out.
A line of coordinates goes in, recorded on the way or drawn with a few clicks. The answer adds what people want to know. It combines the Routing, Elevation and Map Matching APIs in one request.
Your track
Enhanced
Salzburg to Hallein by bike along the Salzach: a Routing API line enhanced by the Route Enhancement API.
Four answers for every route.
Ask for what you need. Each one is a single switch in the request:
Elevation profile
Heights about every 100 m, plus the meters up and down and the highest point.
Way type and surface
Which parts run on roads, streets, cycle paths or trails, and whether they are asphalt, paved or unpaved.
Travel times
Estimated times on foot and for three kinds of bike, from the distance and the climbs.
Turn-by-turn directions
Each turn as a short instruction with the street name, in the language you choose.
Keep people on your trail.
Some routes should follow a set trail, like a signposted cycle route. The Routing Enhancement API routes from any start to the nearest point of your trail, follows the trail and leaves it again close to the destination.
Here a ride from Fuschl am See joins the trail along the Wolfgangsee in St. Gilgen.
One request per track.
Send the track as a file address or as GeoJSON and switch on what you need. The answer is JSON, ready for your map and your tour pages. Available with the self-service plans on RapidAPI and with Maptoolkit Enterprise.
const res = await fetch("https://enhance.maptoolkit.net/route?api_key=YOUR_API_KEY", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
kml: "https://maptoolkit.net/export/ts_demo_tours/_1603292819.kml",
elevation: 1, surface: 1, timings: 1, mapmatch: 1, language: "en",
}),
});
const { elevation, surface, timings, mapmatch } = await res.json();
For this demo tour the answer says: 9.2 km, 824 m up, 3 h 55 min on foot.
GPX, KML or GeoJSON
A file address (gpx, kml) or a LineString or MultiLineString (geometry).
GET or POST
Short lines fit in the web address; long tracks go in the request body.
Heights every 100 m
Set the spacing down to 50 m (densifyGap), or keep your own points (densify=0).
Way type and surface
Positions along the route from 0 to 1; “other” means unknown. Tune the match (mapMatchingThreshold).
Directions in your language
Turn-by-turn instructions with street names (mapmatch, language).
API key and cache
Add your key to every request (api_key). Repeated requests are answered from the cache (cache).
Heights from Mapterhorn
The elevation data comes from Mapterhorn: Copernicus 30 m worldwide, plus national models such as 1 m for Austria and Germany and 0.5 m for Switzerland.
Yours to keep
You may save the results and show them on your own pages.
Where enhanced routes are used.
Wherever routes are shown to people who want to know what to expect. Three common examples:
Tour portals
Every hike and bike tour with its profile, climbs and walking time, without measuring by hand.
Mobile apps
Show riders what the way is like before they set off: roads, cycle paths or trails.
Backend integration
Editors upload a GPX file and the tour facts fill themselves in.
Routes in these examples are Routing API results enhanced by the Route Enhancement API.
Questions about route enhancement.
Short answers on recorded heights, surface and way types, travel modes and tracks in several parts.
Does the API keep the heights recorded by my GPS device?
Yes. If every point of your track already has a height, as most recorded GPS tracks do, the points the API adds in between get heights interpolated from your recorded values, so recorded and modeled heights are not mixed. Only when heights are missing, for example on a line drawn with a few clicks, do the added points take their heights from the terrain model.
Which surface and way types can the API tell apart?
Way types are motorways, primary roads, roads, streets, pedestrian ways, cycleways, paths, hiking trails and mountain hiking trails. Surfaces are asphalt, paved, unpaved, natural and alpine. Every part of the route gets one of each, together with its position along the route, so you can color the line by surface or filter your tours down to the ones a road bike can handle.
Does it matter whether the route is for walking, cycling or driving?
Yes. Set the travel mode to walking, bike or car, and the API matches your track to the paths and roads that mode can use. The turn-by-turn directions and the way types then fit how people actually travel. Always set the mode that matches your tour, for example walking for a hiking tour and car for a scenic drive.
Can I send a track that is split into several parts?
Yes. Send it as a GeoJSON MultiLineString, with one line for each part, for example a tour with a gap or several separate stages. The API keeps the parts apart: way types, surfaces and travel times come back once for each part, in the same order as you sent them. If you show totals for the whole tour, add up the results of all parts.
See your use case on a Maptoolkit map.
In the demo, one of our engineers walks you through the platform, your data and the move from your current provider.

