Search for geographical features
This section provides an example of a request and the service response when searching for geographical features.
Request
https://search-maps.yandex.ru/v1/?text=Rai,Russia&type=geo&lang=en_US&apikey=<
API key>
Response format
The response from the service is shown below (for reverse geocoding, the response format is the same).
{
"type": "FeatureCollection",
"properties": {
"ResponseMetaData": {
"SearchRequest": {
"request": "Rai,Russia",
"results": 10,
"skip": 0,
"boundedBy": [
[
37.04842675,
55.43644829
],
[
38.17590226,
56.04690124
]
]
},
"SearchResponse": {
"found": 24,
"Point": {
"type": "Point",
"coordinates": [
32.01884032,
54.70408144
]
},
"boundedBy": [
[
32.00759341,
54.70136583
],
[
32.03008723,
54.70679686
]
],
"display": "single"
}
}
},
"features": [
{
"type": "Feature",
"properties": {
"GeocoderMetaData": {
"kind": "locality",
"text": "Russia, Smolensk oblast, Smolensk region, village of Rai",
"precision": "other"
},
"description": "Smolensk region, Smolensk oblast, Russia",
"name": "village of Rai",
"boundedBy": [
[
32.007593,
54.701366
],
[
32.030087,
54.706797
]
]
},
"geometry": {
"type": "Point",
"coordinates": [
32.024464,
54.704602
]
}
}
]
}
Response parameters
type
*Required field.
properties
*ResponseMetaData
*SearchRequest
*request
*results
skip
boundedBy
Boundaries of the area that the objects to search for are presumably located in.
Set as the coordinates of the upper-left and lower-right corners of the area. Coordinates are set in the order “latitude, longitude”.
The boundaries of the area are automatically defined by the service.
SearchResponse
*Metadata describing the response. Required field.
found
*Point
*This element is used for compatibility with GeoJSON format. Required field.
type
*coordinates
*boundedBy
Boundaries of the viewport for found objects. Contains the coordinates of the lower-left and upper-right corners of the area. Coordinates are set in the order “longitude, latitude”.
display
Recommendations for displaying search results. Possible values:
- "single" — Recommends displaying the first object found.
- "multiple" — Recommends displaying all objects found.
features
*type
*properties
*GeocoderMetaData
*kind
*Kind of toponym. Possible values:
- "house" — building
- "street" — street
- "metro" — metro (subway) station
- "district" — city district
- "locality" — populated locality (city/village/town/...).
Required field.
text
*precision
*description
name
boundedBy
* Required