REST API Reference
Geocoding
Forward Geocoding
Convert addresses or place names to coordinates.
GET /v1/geocode?q={query}&key={api_key}
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
q | string | Yes | Search query (address, city, etc.) |
limit | number | No | Max results (default: 5, max: 50) |
lang | string | No | Response language (ISO 639-1) |
bbox | string | No | Bounding box filter (minLng,minLat,maxLng,maxLat) |
Example:
curl "https://api.maps.guru/v1/geocode?q=Eiffel+Tower&limit=1&key=mapx_your_key"
Reverse Geocoding
Convert coordinates to addresses.
GET /v1/reverse?lat={latitude}&lng={longitude}&key={api_key}
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
lat | number | Yes | Latitude (-90 to 90) |
lng | number | Yes | Longitude (-180 to 180) |
lang | string | No | Response language (ISO 639-1) |
Routing
Directions
Calculate routes between two or more points.
GET /v1/directions?origin={lat,lng}&destination={lat,lng}&key={api_key}
Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
origin | string | Yes | Start point (lat,lng) |
destination | string | Yes | End point (lat,lng) |
waypoints | string | No | Intermediate points (lat,lng|lat,lng) |
mode | string | No | Travel mode: driving, walking, cycling |
Isochrones
Calculate reachable areas from a point within a given time.
GET /v1/isochrone?center={lat,lng}&time={minutes}&key={api_key}
Map Styles
Get Style JSON
Retrieve a MapLibre-compatible style document.
GET /v1/styles/{slug}/style.json?key={api_key}
Returns a complete MapLibre GL style JSON with tile sources, sprites, and glyphs URLs pre-configured with your API key.
Usage
Current Usage
Get current month's usage statistics for your organization.
GET /v1/usage/current
Requires session authentication (not API key).