38. Find Nearest Address (reverse geocode)
Returns the nearest address to a given point of interest (specified as latitude/longitude)
38.1 Request Data
The following is a list of parameters that are required for this request.
| Required Information | |
|---|---|
| Name | Description |
| action | showposition |
| operation | revgeocode |
| format | xml |
| long | the longitude of the point of interest |
| lat | the latitude of the point of interest |
38.2 Data Returned
The address nearest to the given point of interest is returned in XML format. If no nearby address is found a standard error XML document is returned.
DTD:
<!ELEMENT addresses (address*)>
<!ATTLIST addresses count CDATA #REQUIRED>
<!ATTLIST addresses lat CDATA #REQUIRED>
<!ATTLIST addresses long CDATA #REQUIRED>
<!ELEMENT address (long, lat, distance, road, number, zip, county, state, country)>
<!ELEMENT long (#PCDATA)>
<!ELEMENT lat (#PCDATA)>
<!ELEMENT distance (#PCDATA)>
<!ELEMENT road (#PCDATA)>
<!ELEMENT number (#PCDATA)>
<!ELEMENT zip (#PCDATA)>
<!ELEMENT county (#PCDATA)>
<!ELEMENT state (#PCDATA)>
<!ELEMENT country (#PCDATA)>
| Reply Data | |
|---|---|
| Name | Description |
| long | the longitude of the returned point |
| lat | the latitude of the returned point |
| distance | distance between point of interest and the returned matching address. |
| distance_unit | unit that distance is specified in |
| road | the road name |
| number | the building number |
| zip | the zip code |
| county | the county |
| state | the state |
| country | the country |
Example Request:
https://zonarsystems.net/interface.php?operation=revgeocode&action=showposition&long=-122.17286&lat=47.49497&format=xml
Example Success Reply (XML):
Reply
*LOI means Location of Interest; called "Zone" in GPS tools and reports in Ground Traffic Control web application.