Routing API works via HTTP Get request and allows to build routes between two or multiple locations.
The typical request URL of Routing API looks like:
- waypoints - coordinates of locations separated with "|". Each coordinate is a pair of latitude and longitude, separated with a comma -
- mode - travel mode
- apiKey - your Geoapify key
The response returned contains a GeoJSON FeatureCollection object with a feature of "MultiLineString" type, which represents the route. Properties of the feature contain information about time in seconds, distance in meters, and route steps for each consecutive pair of locations.
NOTE! Routing requests for multiple locations (more than 1 pair of locations) are charges as multiple requests (1 pair of locations as 1 request).