Reverse Geocoding
Find places or addresses near a location
Description
Reverse geocoding is used for finding places or addresses near a latitude, longitude pair—like clicking on a map to see what's there when the map doesn't show it otherwise. For example, picture a map showing building outlines but no labels, then clicking on a building and being shown the name of the business. That's reverse geocoding.
tip
When using that, just use our Enterprise Dashboard or guild API Key to create your API Key try for free!
Base URL
The base URL for all API requests is:
https://mapapis.openmap.vn/v1
Endpoint
GET /geocode/reverse
Google format
API references
Parameter | Type | Required | Default | Example |
---|---|---|---|---|
latlng | string | yes | none | 21.03431,105.78823 |
Example
Request:
GET /geocode/reverse?latlng=21.075951,105.812662&apikey=YOUR_API_KEY
Response
{
"results": [
{
"address": "272 Đường Võ Chí Công, phường Phú Thượng, quận Tây Hồ, thành phố Hà Nội",
"address_components": [
{
"long_name": "Lotte Mall Tây Hồ",
"short_name": "Lotte Mall Tây Hồ"
},
{
"long_name": "272 Đường Võ Chí Công",
"short_name": "272 Đường Võ Chí Công"
},
{
"long_name": "phường Phú Thượng",
"short_name": "Phú Thượng"
},
{
"long_name": "quận Tây Hồ",
"short_name": "Tây Hồ"
},
{
"long_name": "thành phố Hà Nội",
"short_name": "Hà Nội"
}
],
"formatted_address": "Lotte Mall Tây Hồ, 272 Đường Võ Chí Công, phường Phú Thượng, quận Tây Hồ, thành phố Hà Nội",
"geometry": {
"location": {
"lat": 21.075951,
"lng": 105.812662
}
},
"name": "Lotte Mall Tây Hồ",
"place_id": "aQA0KHmLGXVtbpFgpMqFfA0OjpRAAVFgTGaOYDTSgKXVbpiV-A6xZXkuPZgc",
"types": ["business_center"]
}
],
"status": "OK"
}
OSM Format
API references
Parameter | Type | Required | Default | Example |
---|---|---|---|---|
point.lat | floating point number | yes | none | 21.03431 |
point.lon | floating point number | yes | none | 105.78823 |
boundary.circle.radius | floating point number in km | no | 1 | 1 |
size | integer | no | 1 | 1 |
Example
Request:
GET /geocode/reverse?point.lat=21.075951&point.lon=105.812662&size=1&boundary.circle.radius=1
Response:
{
"errors": null,
"features": [
{
"type": "Feature",
"geometry": {
"coordinates": [105.812662, 21.075951],
"type": "Point"
},
"properties": {
"name": "Lotte Mall Tây Hồ",
"housenumber": null,
"street": null,
"short_address": "272 Đường Võ Chí Công",
"postalcode": null,
"label": "Lotte Mall Tây Hồ, 272 Đường Võ Chí Công, phường Phú Thượng, quận Tây Hồ, thành phố Hà Nội",
"country": "Việt Nam",
"country_code": "VN",
"category": ["business_center"],
"website": "https://lottemallwestlakehanoi.vn/",
"opening_hours": [
[
[0, 9, 30],
[0, 22, 0]
],
[
[1, 9, 30],
[1, 22, 0]
],
[
[2, 9, 30],
[2, 22, 0]
],
[
[3, 9, 30],
[3, 22, 0]
],
[
[4, 9, 30],
[4, 22, 0]
],
[
[5, 9, 30],
[5, 22, 0]
],
[
[6, 9, 30],
[6, 22, 0]
]
],
"phone": "+842433338000",
"region": "thành phố Hà Nội",
"county": "quận Tây Hồ",
"locality": "phường Phú Thượng",
"distance": 0,
"id": "aQA0KHmLGXVtbpFgpMqFfA0OjpRAAVFgTGaOYDTSgKXVbpiV-A6xZXkuPZgc",
"continent": "Asia",
"source": "openmapvn"
}
}
],
"bbox": [],
"type": "FeatureCollection"
}