Dears, could you please inform me if there are an Api that can give us the distance between A and B using API? Like Google Distance Matrix API.

Thanks.

asked 22 Oct '14, 12:27

Danil%20Rudakov's gravatar image

Danil Rudakov
31113
accept rate: 0%


Yes, OSRM (Open Source Routing Machine) provides this feature - both for point-to-point queries and for matrices.

See https://github.com/Project-OSRM/osrm-backend/wiki/Server-api. There is a public instance at router.project-osrm.org which is available for light usage within the terms of use (see the OSRM wiki). An example matrix call would be:

http://router.project-osrm.org/table?loc=29.94,-90.11&loc=30.44,-91.18&loc=30.45,-91.22&loc=30.42,-91.15

If you have more significant needs, you can set up your own instance of OSRM.

permanent link

answered 22 Oct '14, 12:48

Richard's gravatar image

Richard ♦
26.1k38232346
accept rate: 19%

edited 22 Oct '14, 12:49

There is also the GraphHopper Directions API based on OSM data with a Matrix API providing times and distances. (Note: I'm the author of GraphHopper)

permanent link

answered 26 Mar '15, 21:50

peatar's gravatar image

peatar
3512312
accept rate: 8%

edited 29 Jun '16, 09:15

Dislaimer: I work for iGeolise

The TravelTime API can be used to calculate the true distance from A to B (rather than as the crow flies) as well as calculating the travel time between the two points (plus lots more). Sign up for an API key here.

permanent link

answered 16 Jun '16, 10:37

Louisa-maps's gravatar image

Louisa-maps
311
accept rate: 0%

Is the map data based on OSM?

(16 Jun '16, 11:37) scai ♦

as far as i found OSRM only provides a travel-time-matrix (although they call it distance matrix). if i am wrong, please post, because i am looking for distance matrices

permanent link

answered 29 Jun '16, 08:30

gemerden's gravatar image

gemerden
1
accept rate: 0%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×214
×38
×4

question asked: 22 Oct '14, 12:27

question was seen: 29,040 times

last updated: 29 Jun '16, 09:15

powered by OSQA