v1

latestOpenAPI 3.0.02026-08-065741.5 KB
Objects list

Method returns suggestions for search term closest to the selected point optionally filtered by parameters. Only basic information is include in response: xid, name, kinds, osm, wikidata of each object. Depending on the chosen format, the response is either a simple array of objects (with a smaller volume) or an object in GeoJSON format.

get/{lang}/places/autosuggest

Path parameters

langstring required

Language code (2 characters, ISO639-1). The following values are available: en (english), ru (russian)

Query parameters

namestring required

The query term on which to search. The minimum number of characters for name is 3

radiusnumber double required

Maximum distance from selected point in meters

lonnumber double required

Longitude of selected point

latnumber double required

Latitude of selected point

src_geom'osm' | 'wikidata' | 'snow' | 'cultura.ru' | 'rosnedra'

The source of the object geometry. Objects from all sources are returned by default.

src_attr'osm' | 'wikidata' | 'snow' | 'cultura.ru' | 'rosnedra' | 'user'

The source of the object attributes. It is allowed to point multiple sources separated by commas. Objects from all sources are returned by default.

kindsstring

Object category. Several comma-separated categories may be stated with OR logic. see List of categories. Objects from all categories are returned by default.

rate'1' | '2' | '3' | '1h' | '2h' | '3h'

Minimum rating of the object popularity, 1 - minimum, 3- maximum, h - object is referred to the cultural heritage. Objects from all categories are returned by default.

format'json' | 'geojson' | 'count'

The output format (GeoJSON is set by default). Specify “count” to get the number of obtained objects

props'base' | 'address'

Specify “base” to search only in the objects titles (set by default), specify “address” to search in the objects addresses too

limitinteger

Maximum number of returned objects. 10 is set by default.

Response

Returns a list of objects

xidstring required

Unique identifier of the object in OpenTripMap

namestring required

The name of the object

highlighted_namestring required

The name of the object with highlighted search term

kindsstring required

Comma-separated list of categories. see List of categories

osmstring

OpenStreetMap identifier of the object

wikidatastring

Wikidata identifier of the object

distnumber double

Distance in meters from selected point (for radius query)

Example response

[
  {
    "xid": "N890538405",
    "rate": 1,
    "highlighted_name": "<b>Don</b> Este",
    "name": "Don Este",
    "osm": "node/890538405",
    "dist": 456.55705702,
    "kinds": "foods,fast_food,tourist_facilities",
    "point": {
      "lon": -70.645576,
      "lat": -33.438782
    }
  }
]