OpenAddresses is by far the largest dataset by number of records used by Mapzen Search. Even though it only contains address data (as in no building names or other metadata), it's a great resource for global geocoding.
Many of the sources used in OpenAddresses require [attribution (LINK NOT LIVE)](https://www.mapzen.com/copyright/openaddresses). Mapzen Search _does not_ import OpenAddresses sources marked as Share-Alike by the OpenAddresses project.
Many of the sources used in OpenAddresses require [attribution](https://mapzen.com/rights/). Mapzen Search _does not_ import OpenAddresses sources marked as Share-Alike by the OpenAddresses project.
## Who's on First
@ -23,7 +23,9 @@ Many of the sources used in OpenAddresses require [attribution (LINK NOT LIVE)](
Layers:
- `country`
- `macroregion`
- `region`
- `macrocounty`
- `county`
- `locality`
- `localadmin`
@ -32,12 +34,14 @@ Layers:
[Who's on First](https://whosonfirst.mapzen.com) is an open-data directory of worldwide administrative places. Created by Mapzen, it is the primary provider of:
- Countries
- Macroregions (e.g. England is a Macroregion within the United Kingdom)
- Regions (for example: states, provinces)
- Macro-counties (e.g. [Departments of France](https://en.wikipedia.org/wiki/Departments_of_France))
- Counties
- Localities (cities, towns, hamlets)
- Neighbourhoods
Additionally, for addresses, venues, and points of interest coming from OpenStreetMap, Geonames, and OpenAddresses, Mapzen Search uses Who's on First to provide standardized fields for the country, region, locality, and neighbourhood. Other matching levels the place may fall within `macro-county` or `macro-region` taxonomy from Who's on Firsts.
Additionally, for addresses, venues, and points of interest coming from OpenStreetMap, Geonames, and OpenAddresses, Mapzen Search uses Who's on First to provide standardized fields for the country, region, locality, and neighbourhood.
[Mapzen Search](https://mapzen.com/projects/search) is a modern, geographic search service based entirely on open-source tools and powered entirely by open data. To start integrating Mapzen Search to your apps, you need a [developer API key](api-keys-rate-limits.md). You might use this functionality in any app that has a geographic element, including ones that deliver goods, locate hotels or venues, or even provide local weather forecasts.
[Mapzen Search](https://mapzen.com/projects/search) is a modern, geographic search service based entirely on open-source tools and powered entirely by open data. To start integrating Mapzen Search to your apps, you need a [Mapzen developer API key](api-keys-rate-limits.md). You might use this functionality in any app that has a geographic element, including ones that deliver goods, locate hotels or venues, or even provide local weather forecasts.
Through a process known as [geocoding](search.md), Mapzen Search allows you to use natural language to find a particular place by entering an address or the name of a landmark or business, and then translates the result in to the geographic coordinates used by computers. Mapzen Search accesses [global databases](data-sources.md) of place names and locations, but you can receive more locally relevant search results by limiting the search to a particular radius around a location (such as a cell phone), region, or country. With text [autocompletion capabilities](autocomplete.md), you can search for places and match against Mapzen Search data in real-time.
@ -21,42 +21,41 @@ The `features` property of the result is where you will find the list of results
Each item in this list will contain all the information needed to find it in human-readable format in the `properties` block, as well as computer friendly coordinates in the `geometry` property.
```json
```json
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-73.990425,
40.744131
]
},
"properties": {
"id": "way:265038872",
"gid": "openstreetmap:address:way:265038872",
"layer": "address",
"source": "openstreetmap",
"name": "30 West 26th Street",
"housenumber": "30",
"street": "West 26th Street",
"postalcode": "10010",
"confidence": 0.875,
"country": "United States",
"country_id": "85633793",
"country_a": "USA",
"region": "New York",
"region_id": "85688543",
"region_a": "NY",
"county": "New York County",
"county_id": "102081863",
"localadmin": "Manhattan",
"localadmin_id": "404522731",
"locality": "New York",
"locality_id": "85977539",
"neighbourhood": "Flatiron District",
"neighbourhood_id": "85869245",
"label": "30 West 26th Street, Manhattan, NY, USA"
Additionally, `/reverse` queries will have a `distance` parameter, which is the distance, in meters, from the query point.
@ -80,6 +79,9 @@ For the `/search` endpoint, it primarily takes into account how well properties
Additionally, the confidence score can optionally be biased along with other results, like test scores in a classroom might be graded on a curve. This takes into account both the property matches described above and the distance between results. This relative scoring is enabled on Mapzen Search, but can be turned off when hosting your own Pelias instance.
### `bbox`
`Feature`s coming from _Who's on First_ and OpenStreetMap ways will often have their own `"bbox"` elements. This `"bbox"` is at the same level as `"properties"`. If present, it describes the geographic extent of the feature (e.g. the screen size necessary to show all of California without needing to send the precise polygon geometry). This should be treated as separate from the `bbox` that describes the entire `FeatureCollection`.
## Result count
By default, Mapzen Search results 10 places, unless otherwise specified. If you want a different number of results, set the `size` parameter to the desired number. This example shows returning only the first result.