APIHub
Back to Explore

OpenCage

Forward and reverse geocoding using open data

Geocoding
apiKey
HTTPS
CORS: Yes
Visit official documentation

Latency

Not monitored yet

Uptime

Not monitored yet

Playground

Verified

live

Endpoints

REST · JSON
GET

/v{version}/{format}

geocode a query

  • version (path, required) — API version.
  • format (path, required) — format of the response. One of 'json', 'xml' or 'map'.
  • q (query, required) — string or lat,lng to be geocoded.
  • key (query, required) — an application key.
  • abbrv (query) — when true we attempt to abbreviate the formatted field of results.
  • address_only (query) — when true we include only address details in the formatted field of results.
  • add_request (query) — if true the request is included in the response.
  • bounds (query) — four coordinate points forming the south-west and north-east corners of a bounding box (min long, min lat, max long, max lat).
  • countrycode (query) — two letter code ISO 3166-1 Alpha 2 code to limit results to that country.
  • jsonp (query) — wraps the returned JSON with a function name.
  • language (query) — an IETF format language code (ex: 'es' or 'pt-BR').
  • limit (query, limit) — maximum number of results to return. Default is 10. Maximum is 100.
  • min_confidence (query) — integer from 1-10. Only results with at least this confidence are returned.
  • no_annotations (query) — when true annotations are not added to results.
  • no_dedupe (query) — when true results are not deduplicated.
  • no_record (query) — when true query content is not logged.
  • pretty (query) — when true results are pretty printed. Useful for debugging.
  • proximity (query) — lat,lng to bias results.
  • roadinfo (query) — match nearest road, include roadinfo annotation

1 endpoint auto-detected

Authentication

This API requires authentication: apiKey.

curl -X GET \
  "https://opencagedata.com/v{version}/{format}"

opencagedata.com · HTTPS only