- Category: developer tools
- Auth: API_KEY
- Composio-managed OAuth available? N/A
- Tools: 7
- Triggers: 0
- Slug:
OPENCAGE - Version: 20261101_00
Tools
Forward Geocode Address
Forward Geocode Address
Slug:
OPENCAGE_GEOCODE_FORWARDGeocode an address or place name to find geographic coordinates and related location details. Forward searches can return multiple matches; optionally restrict results by country or bounding box, bias them toward a location, or choose a preferred language and result limit.Input Parameters
Output
Geocode to GeoJSON
Geocode to GeoJSON
Slug:
OPENCAGE_GEOCODE_GEOJSONGeocode addresses or coordinates and return results in GeoJSON FeatureCollection format. Use this tool when you need: - Geographic data in standard GeoJSON format for mapping applications - Forward geocoding: convert addresses to coordinates - Reverse geocoding: convert coordinates to addresses The response includes coordinates, formatted addresses, and optional annotations like timezone, currency, and sun times for each location.Input Parameters
Query string: either an address/placename for forward geocoding, or ‘lat,lng’ coordinates for reverse geocoding.
Restrict results to specific countries. Comma-separated ISO 3166-1 alpha-2 codes (e.g., ‘us’, ‘de,fr’).
Minimum confidence level for results (1-10). Only results with confidence >= this value are returned.
Output
Geocode with JSONP
Geocode with JSONP
Slug:
OPENCAGE_GEOCODE_GEOJSONPGeocode an address and return results wrapped in a JavaScript callback function (JSONP format). Use this tool when you need geocoding results that can be directly consumed by JavaScript through a callback function, typically for cross-domain AJAX requests in browser environments. The response wraps standard geocoding JSON with your specified callback function name. Example response: myCallback({“results”:[{“geometry”:{“lat”:52.5,“lng”:13.4},“formatted”:“Berlin, Germany”,…}],…})Input Parameters
The address or location query to geocode (e.g., ‘Berlin, Germany’ or ‘1600 Pennsylvania Ave, Washington DC’)
Abbreviate place names in results. Set to 1 to abbreviate (e.g., ‘NYC’ instead of ‘New York City’), 0 for full names.
Restrict results to a geographic bounding box, specified as ‘minLng,minLat,maxLng,maxLat’ (west,south,east,north). Example: ‘-0.563,51.280,0.278,51.686’ for Greater London.
Preferred language for results using ISO 639-1 language code (e.g., ‘en’ for English, ‘de’ for German).
Bias results towards a specific location, specified as ‘lat,lng’. Example: ‘51.952,-1.162’ for near Oxford, UK.
Limit results to a specific country using ISO 3166-1 alpha-2 country code (e.g., ‘US’, ‘DE’, ‘GB’).
Exclude supplementary annotations (timezone, currency, etc.) from results. Set to 1 to exclude.
Output
Geocode Google v3 JSON
Geocode Google v3 JSON
Slug:
OPENCAGE_GEOCODE_GOOGLE_V3_JSONRequest forward geocoding in OpenCage’s Google v3-compatible JSON format for legacy integrations. This format may be discontinued; OpenCage recommends using its standard JSON format instead.Input Parameters
The query string to be geocoded. Either latitude,longitude for reverse geocoding or a placename/address for forward geocoding. Must be URL encoded.
Maximum number of results to return. Default is 10, max is 100. Only applies to forward geocoding.
When set to 1, attempt to match the nearest road and fill additional roadinfo annotation
When set to 1, the various request parameters are added to the response for debugging
Restrict forward geocoding results to specific countries. ISO 3166-1 Alpha 2 codes, comma-separated for multiple
When set to 1, include only the address (excluding POI names) in the formatted string
Output
Reverse Geocode Coordinates
Reverse Geocode Coordinates
Slug:
OPENCAGE_GEOCODE_REVERSEReverse geocode a latitude and longitude to find a readable location and address details. The response contains at most one match and may include its distance from the requested coordinates. You can choose a preferred language or request a match to the nearest road.Input Parameters
Output
Geocode XML
Geocode XML
Slug:
OPENCAGE_GEOCODE_XMLGeocode a location query and return results in XML format. Supports both forward geocoding (address to coordinates) and reverse geocoding (coordinates to address). Use this when you need XML-formatted output instead of JSON.Input Parameters
Location query: use an address or place name for forward geocoding, or ‘lat,lng’ coordinates for reverse geocoding
Set to 1 to return abbreviated address components (e.g., ‘CA’ instead of ‘California’)
Restrict results to specific countries using comma-separated ISO 3166-1 alpha-2 codes (e.g., ‘us,ca’ for USA and Canada)
Filter results to only include those with confidence score at or above this value (1-10, where 10 is highest)
Set to 1 to exclude supplementary annotations (timezone, currency, etc.), 0 or omit to include