Response format

Search and reverse return the same flat format. Every result is a Place with a ready-made label, address parts and coordinates.

Envelope

JSON
{
  "results": [ { "id": "…", "label": "…" } ],
  "attribution": "© OpenStreetMap contributors, ODbL"
}
FieldTypeDescription
resultslist of PlaceMatches, best first. May be empty.
attributiontextData source notice. Show it wherever you show results, see attribution.

Place

FieldTypeDescription
idtextOpenStreetMap type and ID: N for node, W for way, R for relation, for example W254958900. Usually stable, but it can change when someone remodels the data. Official Swiss addresses have CHA or LIA plus the federal address ID (EGAID), for example CHA101002312; this ID is permanent.
labeltextReady-made one-line label for display, like Bundesplatz 3, 3011 Bern
nametextName of the place. For addresses without a name, "street housenumber".
typetextOne of the types
categorytextOpenStreetMap feature as key:value, see category
addressobjectAddress parts, see address
locationobject{ "lat": 46.94649, "lon": 7.44433 }, rounded to six decimals (about 10 cm)
bboxlist, optionalExtent as [minLon, minLat, maxLon, maxLat]. Only for places with an area, such as buildings, streets or cities.

Fields without a value are left out instead of being null. Check for presence.

Address

FieldExampleDescription
streetBundesplatzStreet
housenumber3House number, as text (there are 12a and 3-5)
postcode3011Postal code, as text
localityWankdorfNeighbourhood, hamlet or named area
districtStadtteil ICity district
cityBernCity, town or municipality
countyVerwaltungskreis Bern-MittellandCounty, administrative district
stateBernCanton, state, region
countrySwitzerlandCountry, in the language from lang
countryCodeCHISO 3166 code, always upper case

Types

type has exactly one of these values. The types parameter takes the same values.

TypeWhatHow label is built
addressBuilding or entrance with a house number and no name of its ownStreet No, Postcode City
poiNamed place: shop, restaurant, stop, named buildingName, Street No, Postcode City
streetStreet, path, squareName, Postcode City
localityNeighbourhood, hamlet, named areaName, City, State
districtCity districtName, City, State
cityCity, town, villageName, State, Country
countyCounty, districtName, Country
stateCanton, stateName, Country
countryCountryName

Missing parts are left out of the label. Repeated parts (such as the city and canton of Bern) appear only once.

Category

category is the place's main OpenStreetMap feature in the form key:value. Examples:

CategoryMeaning
place:houseAddress without further details
building:yesBuilding
amenity:restaurantRestaurant
shop:bakeryBakery
tourism:attractionAttraction
highway:residentialResidential street
public_transport:stationStation, stop
place:cityCity
boundary:administrativeAdministrative boundary (municipality, canton, country)

The list is open, there are hundreds of values. Their meaning is documented in the OpenStreetMap wiki. If Findort knows nothing more specific, the value is place:yes.

Coordinates and bbox

  • location is a point in the WGS 84 coordinate system, as used by GPS and every web map.
  • Mind the order: location is an object with lat and lon. bbox is a list and starts with the longitude: [minLon, minLat, maxLon, maxLat]. That is the same order as the bbox parameter and GeoJSON.
  • Many map libraries want bounds as [[minLat, minLon], [maxLat, maxLon]]. Swap the values accordingly.

Attribution

The data comes from OpenStreetMap and is licensed under the Open Database License (ODbL). Wherever you show results, the notice "© OpenStreetMap contributors" must be visible, ideally as a link to https://www.openstreetmap.org/copyright.

Addresses in Switzerland and Liechtenstein come from the official building address register by swisstopo. When such an address is included, attribution also contains «Gebäudeadressen © swisstopo».

The Web Component already shows the notice in its suggestion list. If you build your own interface, use the text from attribution. More in limits.