I want to filter the osm data such that k value under <tag> equals to highway, right now i am downloading whole data using bbox(GET /api/0.6/map?bbox=left,bottom,right,top) API checking whether value of k equals to "highway" or not, Is there any short method such that i can fetch the data where k value equals to "highway" . Thanks in advance

asked 17 Aug '13, 11:25

Mawa's gravatar image

Mawa
1111
accept rate: 0%

edited 17 Aug '13, 11:26


It's much better to use Overpass for this type of query. It offloads a big bbox GET request from the API and you can filter by tags. See the wiki page for details, or use the xapi syntax as follows (example is for mapquest version, there are others, for instance on Overpass Turbo):

http://open.mapquestapi.com/xapi/api/0.6/way[highway=*][bbox=lon_low,lat_low,lon_hi,lat_hi]
permanent link

answered 17 Aug '13, 13:35

SK53's gravatar image

SK53 ♦
22.5k46229351
accept rate: 20%

1

Please note that the MapQuest XAPI endpoint is not associated to the Overpass API, and that MapQuest currently uses an outdated data base. For this reason I strongly recommend to use one of the other instances instead.

I, as maintainer of the Overpass XAPI instances, get from time to time bug reports that the MapQuest instance is out of date, but I cannot do more than anybody else on that problem.

(19 Aug '13, 06:47) Roland Olbricht
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:

×132
×82
×79
×43

question asked: 17 Aug '13, 11:25

question was seen: 2,011 times

last updated: 19 Aug '13, 06:47

powered by OSQA