Reverse Geocoding

Prev Next

Available in VPC

Convert the entered coordinate values to address information (statutory dong, administrative dong, administrative building, land-lot name address, road name address).

Note

The Reverse Geocoding API supports some coordinate systems specified by the European Petroleum Survey Group (EPSG), as well as coordinate systems commonly used in Korea. For more information about the supported coordinate systems, see Coordinate system

Request

The following describes the request format for the endpoint. The request format is as follows:

Method URI
GET /gc

Request headers

For headers common to all Maps APIs, see Common Maps headers.

Request query parameters

The following describes the request query parameters.

Field Type Required Description
coords String Required Coordinates (X coordinate,Y coordinate)
  • <e.g.> coords=128.12345,37.98776
sourcecrs String Optional Input coordinate system code
  • EPSG:4326 (default) | EPSG:3857 | NHN:2048
    • EPSG:4326: WGS84 longitude and latitude
    • EPSG:3857: Google Maps
    • NHN:2048: UTM-K
  • For more information about the supported coordinate systems, see Coordinate system
targetcrs String Optional Output coordinate system code
  • EPSG:4326 (default) | EPSG:3857 | NHN:2048
    • EPSG:4326: WGS84 longitude and latitude
    • EPSG:3857: Google Maps
    • NHN:2048: UTM-K
  • For more information about the supported coordinate systems, see Coordinate system
orders String Optional Conversion type
  • legalcode (default) | admcode (default) | addr | roadaddr
    • legalcode: Convert to statutory dong
    • admcode: Convert to administrative dong
    • addr: Convert to land-lot name address
    • roadaddr: Convert to road name address
  • Multiple option values can be entered separated by "," and results are displayed in the order of entry
  • When converting coordinates for areas without detailed addresses, such as near coastlines or in new neighborhoods, requests with addr or roadaddr may not return results, but requests with legalcode or admcode can resolve addresses by statutory or administrative dong
  • <e.g.> orders=legalcode,addr
output String Optional Format type of the response result
  • xml (default) | json
callback String Optional Callback name
  • Use when processing callbacks for JSONP communication
  • Return JSON data wrapped in the entered name
  • Can only be entered if output is json
  • <e.g.> callback=abc

Coordinate system

The following describes the coordinate system.

Name Code Type GCS information PCS information
Google Maps EPSG:3857 PCS WGS_1984 WGS_1984 6378137 (Semi_Minor) 298.2572236 Greenwich Degree M 0 0 0 0 Meter 1
WGS 84 longitude and latitude EPSG:4326 GCS WGS_1984 WGS_1984 6378137 298.2572236 Greenwich Degree - - - - - - -
UTM-K NHN:2048 PCS D_ITRF_2000 GRS_1980 6378137 298.2572221 Greenwich Degree TM 127.5 38 2,000,000 1,000,000 Meter 0.9996

Request example

The following is a sample request.

curl --location --request GET 'https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?coords=127.585%2C34.9765&output=json&orders=legalcode%2Cadmcode%2Caddr%2Croadaddr' \
--header 'x-ncp-apigw-api-key-id: {API Key ID}' \
--header 'x-ncp-apigw-api-key: {API Key}'
Note

Depending on the coordinates you enter, different response results can be returned. See the following example requests.

  • General eup/myeon/dong
    • https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=126.9913201,37.5666936&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xml
    • https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=129.1133567,35.2982640&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xml
  • General ri: Coordinates in ri subdivisions of eup/myeon, which are statutory dong units, show codeType as L even in admcode results.
    • https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=128.2439084,36.4938906&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xml
  • If an administrative dong exists with the same name as a statutory dong but in a different area
    • https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=127.1114893,37.3614463&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xml
  • Sejong-si: No data exists for the si/gun/gu, and the statutory dong of all subordinate administrative dong is displayed the same, although the areas are different.
    • Eojin-dong, Sejong-si: https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=127.2654387,36.5008113&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xm
    • Jochiwon-eup, Sejong-si: https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=127.2923750,36.5929071&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xml
  • Coordinates over sea: No response results displayed.
    • https://naveropenapi.apigw.ntruss.com/map-reversegeocode/v2/gc?request=coordsToaddr&coords=125.9913201,37.5666936&sourcecrs=epsg:4326&orders=admcode,legalcode,addr,roadaddr&output=xml

Response

The following describes the response format.

Response body

The following describes the response body.

Field Type Required Description
status Object - Information about response status
status.code Integer - Response status codes
status.name String - Response status message
status.message String - Description of response status
results Array - Response result

results

The following describes results.

Field Type Required Description
name String - Conversion type
code Object - Code information
code.id String - Code ID
code.type String - Code type
  • L | A | S
    • L: statutory dong
    • A: administrative dong
    • S: administrative dong with the same name as a statutory dong but in a different area
code.mappingId String - ID of NAVER dong code mapped to statutory/administrative code
region Object - Address information
region.areaN Object - Administrative area information
  • Display converted addresses sequentially, starting with the largest administrative unit
region.areaN.name String - Administrative area unit name
  • region.area0.name: country code top-level domain, displaying kr
  • region.area1.name: name of si/do as published by the Ministry of the Interior and Safety
  • region.area2.name: name of si/gun/gu as published by the Ministry of the Interior and Safety
  • region.area3.name: name of eup/myeon/dong as published by the Ministry of the Interior and Safety
  • region.area4.name: name of ri as published by the Ministry of the Interior and Safety
region.areaN.coords Object - Administrative area location information
region.areaN.coords.center Object - Administrative area center coordinates
region.areaN.coords.center.crs String - Coordinate system code
region.areaN.coords.center.x Float - X coordinates
  • If land.coords.center.crs is EPSG:4326, longitude
region.areaN.coords.center.y Float - Y coordinates
  • If land.coords.center.crs is EPSG:4326, latitude
land Object - Detailed address information
land.type String - Cadastral type
  • Display the detailed value only if name is addr
  • 1 | 2
    • 1: general land
    • 2: mountain
land.name String - Road name
  • Display the detailed value only if name is roadaddr
land.number1 String - Detailed number
  • If name is addr, land original number
  • If name is roadaddr, detailed address
land.number2 String - Land sub name
  • Display the detailed value only if name is addr
land.coords Object - Detailed address location information
land.coords.center Object - Detailed address center coordinates
land.coords.center.crs String - Coordinate system code
land.coords.center.x Float - X coordinates
  • If land.coords.center.crs is EPSG:4326, longitude
land.coords.center.y Float - Y coordinates
  • If land.coords.center.crs is EPSG:4326, latitude
land.additionN Object - Additional information
  • Display the detailed value only if name is roadaddr
  • land.addition0: building information
  • land.addition1: postal code information
  • land.addition2: road code information
land.additionN.type String - Additional Information type
  • land.addition0.type: building
  • land.addition1.type: zipcode
  • land.addition2.type: roadGroupCode
land.additionN.value String - Additional information value
  • land.addition0.value: building name
  • land.addition1.value: postal code
  • land.addition2.value: road code (12 digits)

Response status codes

The following describes the response status codes.

HTTP status code Code Message Description
200 0 ok Request processing successful. Return response result
200 3 no results Request processing successful. Response result not returned
400 100 invalid request Request parameter error
500 900 unknown error / io error Undefined error
Note

For response status codes common to all Maps APIs, see Common Maps response status codes.

Response example

The following is a sample example.

{
    "status": {
        "code": 0,
        "name": "ok",
        "message": "done"
    },
    "results": [
        {
            "name": "legalcode",
            "code": {
                "id": "4623025024",
                "type": "L",
                "mappingId": "1223025024"
            },
            "region": {
                "area0": {
                    "name": "kr",
                    "coords": {
                        "center": {
                            "crs": "",
                            "x": 0.0,
                            "y": 0.0
                        }
                    }
                },
                "area1": {
                    "name": "Jeollanam-do",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 126.957167,
                            "y": 34.900727
                        }
                    },
                    "alias": "Jeonnam"
                },
                "area2": {
                    "name": "Gwangyang-si",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.695899,
                            "y": 34.940658
                        }
                    }
                },
                "area3": {
                    "name": "Gwangyang-eup",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.58105,
                            "y": 34.97341
                        }
                    }
                },
                "area4": {
                    "name": "Eupnae-ri",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.5863,
                            "y": 34.9751
                        }
                    }
                }
            }
        },
        {
            "name": "admcode",
            "code": {
                "id": "4623025000",
                "type": "L",
                "mappingId": "12230250"
            },
            "region": {
                "area0": {
                    "name": "kr",
                    "coords": {
                        "center": {
                            "crs": "",
                            "x": 0.0,
                            "y": 0.0
                        }
                    }
                },
                "area1": {
                    "name": "Jeollanam-do",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 126.957167,
                            "y": 34.900727
                        }
                    },
                    "alias": "Jeonnam"
                },
                "area2": {
                    "name": "Gwangyang-si",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.695899,
                            "y": 34.940658
                        }
                    }
                },
                "area3": {
                    "name": "Gwangyang-eup",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.58105,
                            "y": 34.97341
                        }
                    }
                },
                "area4": {
                    "name": "",
                    "coords": {
                        "center": {
                            "crs": "",
                            "x": 0.0,
                            "y": 0.0
                        }
                    }
                }
            }
        },
        {
            "name": "addr",
            "code": {
                "id": "4623025024",
                "type": "L",
                "mappingId": "1223025024"
            },
            "region": {
                "area0": {
                    "name": "kr",
                    "coords": {
                        "center": {
                            "crs": "",
                            "x": 0.0,
                            "y": 0.0
                        }
                    }
                },
                "area1": {
                    "name": "Jeollanam-do",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 126.957167,
                            "y": 34.900727
                        }
                    },
                    "alias": "Jeonnam"
                },
                "area2": {
                    "name": "Gwangyang-si",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.695899,
                            "y": 34.940658
                        }
                    }
                },
                "area3": {
                    "name": "Gwangyang-eup",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.58105,
                            "y": 34.97341
                        }
                    }
                },
                "area4": {
                    "name": "Eupnae-ri",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.5863,
                            "y": 34.9751
                        }
                    }
                }
            },
            "land": {
                "type": "1",
                "number1": "252",
                "number2": "1",
                "addition0": {
                    "type": "",
                    "value": ""
                },
                "addition1": {
                    "type": "",
                    "value": ""
                },
                "addition2": {
                    "type": "",
                    "value": ""
                },
                "addition3": {
                    "type": "",
                    "value": ""
                },
                "addition4": {
                    "type": "",
                    "value": ""
                },
                "coords": {
                    "center": {
                        "crs": "",
                        "x": 0.0,
                        "y": 0.0
                    }
                }
            }
        },
        {
            "name": "roadaddr",
            "code": {
                "id": "4623025024",
                "type": "L",
                "mappingId": "1223025024"
            },
            "region": {
                "area0": {
                    "name": "kr",
                    "coords": {
                        "center": {
                            "crs": "",
                            "x": 0.0,
                            "y": 0.0
                        }
                    }
                },
                "area1": {
                    "name": "Jeollanam-do",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 126.957167,
                            "y": 34.900727
                        }
                    },
                    "alias": "Jeonnam"
                },
                "area2": {
                    "name": "Gwangyang-si",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.695899,
                            "y": 34.940658
                        }
                    }
                },
                "area3": {
                    "name": "Gwangyang-eup",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.58105,
                            "y": 34.97341
                        }
                    }
                },
                "area4": {
                    "name": "Eupnae-ri",
                    "coords": {
                        "center": {
                            "crs": "EPSG:4326",
                            "x": 127.5863,
                            "y": 34.9751
                        }
                    }
                }
            },
            "land": {
                "type": "",
                "number1": "20",
                "number2": "",
                "addition0": {
                    "type": "building",
                    "value": ""
                },
                "addition1": {
                    "type": "zipcode",
                    "value": "57742"
                },
                "addition2": {
                    "type": "roadGroupCode",
                    "value": "462304655159"
                },
                "addition3": {
                    "type": "",
                    "value": ""
                },
                "addition4": {
                    "type": "",
                    "value": ""
                },
                "name": "Maeilsijang-gil",
                "coords": {
                    "center": {
                        "crs": "",
                        "x": 0.0,
                        "y": 0.0
                    }
                }
            }
        }
    ]
}