API / Reverse Search
GET /search/reverse

Reverse Search API.

Finds the nearest indexed places or POIs to a coordinate.

Provide lat and lon, optionally filter by types=place,poi, set a result size, and choose a radius such as 2km or 500m.

Example request
curl "https://YOUR-RAPIDAPI-HOST/search/reverse?lat=-33.9249&lon=18.4241&size=5&types=place,poi&radius=2km" \
  -H "X-RapidAPI-Key: YOUR_RAPIDAPI_KEY" \
  -H "X-RapidAPI-Host: YOUR_RAPIDAPI_HOST"

Query Parameters

lat
number
Yes
Latitude.
lon
number
Yes
Longitude.
size
integer
No
Maximum number of results. Default: 5. Range: 1 to 10.
types
string
No
Comma-separated values, commonly place,poi.
radius
string
No
Search radius around the coordinate. Default: 2km. Examples: 1km, 500m, 2km.

Result Fields

id
string
Returned
Document ID.
score
number
Returned
Search relevance score.
index
string
Returned
Source index containing the result.
doc_type
string or null
Returned
Document type, commonly place or poi.
display_name
string or null
Returned
Full display name.
name
string or null
Returned
Primary name.
name_en
string or null
Returned
English name when available.
place_class
string or null
Returned
Place classification.
category
string or null
Returned
POI category when available.
importance
number or null
Returned
Ranking importance.
location
object or null
Returned
{ "lat": number, "lon": number }
canonical_id
string or null
Returned
Canonical document ID.
source
string or null
Returned
Data source such as osm or overture.
distance_m
number
Reverse only
Distance from the query point when available.
Example response
{
  "lat": -33.9249,
  "lon": 18.4241,
  "took_ms": 6,
  "results": [
    {
      "id": "osm:place:123",
      "score": 1.0,
      "index": "africa",
      "doc_type": "place",
      "display_name": "Cape Town, Western Cape, South Africa",
      "name": "Cape Town",
      "name_en": "Cape Town",
      "place_class": "city",
      "category": null,
      "importance": 80,
      "location": {"lat": -33.9249, "lon": 18.4241},
      "canonical_id": "osm:place:123",
      "source": "osm",
      "distance_m": 12.4
    }
  ]
}