Check for road nearby

Is there a way to check if a location is within X km of a road? I know I can try to use the Directions endpoint and set a start location and radius to X km but I would like to do that without “wasting” requests.
Thanks in advance.


no, the openrouteservice does not provide an endpoint for that.
You can probably re-purpose the reverse geocode endpoint for something like this, but you’d need to use your own logic to figure out if the reply means whether your point is within X km of a road.

Out of curiosity, what is the application for this, where does this question come from?

Best regards

1 Like

I was trying to create some routes within an expected range but sometimes I would generate points in the wilderness and my distances were higher than expected. So to counter this I’m trying to figure a way to always have start and end points within X meters from a road.