Reverse Geocoding
Attempt to match a latitude, longitude pair to an address.
Request Headers
-
string
-
stringRequired authentication header.For example:
X-Api-Key: rwyEPevhh54EqVqSyv7ovoDqYYYR5Z
-
BCP47 | optionalRequest geocoding results to be in specific language if it is available. If it is not - it will default to English. BCP47 spec.For example:
Accept-Language: en
orAccept-Language: fr-FR
Request GET parameters
-
floatLatitude of the point to reverse geocode
-
floatLongitude of the point to reverse geocode
-
ISO 3166-1 alpha-2 or alpha-3 | optionalOnly return the results that are within the specified country. Useful when performing reverse geocoding requests near a border.
-
experimental| string | optionalExclude location types from results. Available values:
country
.Example #1:exclude.location.types=country
.Example #2: This parameter can be used to exclude countries from the results after filtering down withwithin.country
parameter.search?query=Namibia&within.country=CH&exclude.location.types=country
will return empty result set, because Switzerland itself will be excluded.
Response Headers
-
BCP47Language tag in which results were returned.It will default to
Content-Language: en
if requested language was not available. BCP47 spec
Response Body Json Attributes
The returned response is inGeoJSON
format (check example below). Note that coordinates
elements are longitude, latitude, in that order.
The properties
object contains the following attributes:
-
stringA short description of the location, varies depending on what is returned
-
stringDetailed label of the result, intended to be returned to the end user
-
float | optionalResult confidence score, maximum value is
1
-
string | optional
-
string | optional
-
string | optional
-
string | optional
-
string | optional
-
string | optional
-
string | optional
-
string | optional
-
string | optional
-
ISO 3166-1 alpha-3 | optional
-
string | optional
-
string | optional
-
object | optionalTravel Time features that are supported for searches from this point. If the object is missing, it means that Travel Time searches from this point are not supported
-
object | optionalPublic transport support information. Public transport is not supported if this object is missing.
-
date in extended ISO-8601 format
-
date in extended ISO-8601 format
-
-
object | optionalFast time-filter support information. The
time-filter/fast
endpoint is not supported if this object is missing.-
array[object]Each entry in the array describes a time period and time filter modes that are available for this country.
-
stringThe arrival or departure time period for which this time filter fast endpoint is available. Possible values:
weekday_morning
-
array[object]Lists available transportation and time-filter modes for this time period.
-
stringPossible values
arrival.many_to_one
,arrival.one_to_many
. -
stringPossible values
public_transport
,driving
,driving+public_transport
.
-
-
-
-
booleanIndicates whether or not we have fare data
-
booleanIndicates whether or not postcode searches are supported
-
Example Request
GET /v4/geocoding/reverse?lat=51.507281&lng=-0.132120 HTTP/1.1
Host: api.traveltimeapp.com
Accept: application/json
X-Application-Id: ...
X-Api-Key: ...
Response Body
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132198,
51.50746
]
},
"properties": {
"name": "8 Pall Mall",
"label": "8 Pall Mall, London, England, United Kingdom",
"score": 0.8,
"house_number": "8",
"street": "Pall Mall",
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"postcode": "SW1Y 5NG",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132198,
51.50746
]
},
"properties": {
"name": "The Balcon",
"label": "The Balcon, London, England, United Kingdom",
"score": 0.8,
"house_number": "8",
"street": "Pall Mall",
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"postcode": "SW1Y 5NG",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132061,
51.507519
]
},
"properties": {
"name": "Wafers N Papers",
"label": "Wafers N Papers, London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132364,
51.507198
]
},
"properties": {
"name": "Waterloo Place",
"label": "Waterloo Place, London, England, United Kingdom",
"score": 0.8,
"street": "Waterloo Place",
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132144,
51.507549
]
},
"properties": {
"name": "Old London Gallery",
"label": "Old London Gallery, London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132398,
51.507206
]
},
"properties": {
"name": "Pall Mall Corporate Hospitality Ltd.",
"label": "Pall Mall Corporate Hospitality Ltd., London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.131975,
51.507533
]
},
"properties": {
"name": "Royal Opera Arcade Gallery",
"label": "Royal Opera Arcade Gallery, London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132034,
51.507612
]
},
"properties": {
"name": "Stephen Wiltshire Gallery",
"label": "Stephen Wiltshire Gallery, London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132456,
51.507187
]
},
"properties": {
"name": "The Hub Initiative",
"label": "The Hub Initiative, London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
},
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [
-0.132456,
51.507187
]
},
"properties": {
"name": "Institute of Directors",
"label": "Institute of Directors, London, England, United Kingdom",
"score": 0.8,
"neighbourhood": "St. James's",
"macroregion": "England",
"city": "London",
"country": "United Kingdom",
"country_code": "GBR",
"continent": "Europe",
"features": {
"public_transport": {
"date_start": "",
"date_end": ""
},
"fares": true,
"postcodes": true
}
}
}
]
}