### API Overview: LatLng API Source: https://www.latlng.work/openapi.yaml LatLng provides affordable maps and location APIs for developers building location-aware apps. The API includes forward geocoding, reverse geocoding, places search, nearby places, place categories, static maps, and custom dataset map tiles powered by OpenStreetMap data. Developers can start free with a generous daily quota. LatLng also offers an MCP server so AI tools can use location APIs directly. Homepage: https://www.latlng.work Documentation: https://www.latlng.work/docs Get a free API key: https://dash.latlng.work MCP server: https://mcp.latlng.work/mcp ```yaml # LatLng API # Version: 1.0.0 LatLng provides affordable maps and location APIs for developers building location-aware apps. The API includes forward geocoding, reverse geocoding, places search, nearby places, place categories, static maps, and custom dataset map tiles powered by OpenStreetMap data. Developers can start free with a generous daily quota. LatLng also offers an MCP server so AI tools can use location APIs directly. Homepage: https://www.latlng.work Documentation: https://www.latlng.work/docs Get a free API key: https://dash.latlng.work MCP server: https://mcp.latlng.work/mcp # Base URL: https://api.latlng.work ``` -------------------------------- ### GET /v1/static Source: https://www.latlng.work/openapi.yaml Generate a static map image. API key can be sent as key or X-Api-Key. ```markdown ### Parameters - **key** (string, query, optional) - **center** (string, query, optional): Map center as latitude,longitude. - **zoom** (integer, query, optional) - **width** (integer, query, optional) - **height** (integer, query, optional) - **markers** (string, query, optional): Optional marker coordinates. ### Responses #### 200 - Static map image. #### 400 - response **Error** - **error** (string) - **message** (string) #### 429 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/v1/static?key=string¢er=string&zoom=0&width=0&height=0&markers=string" ``` ``` -------------------------------- ### GET /v1/places/categories Source: https://www.latlng.work/openapi.yaml List supported category filters. ```markdown ### Responses #### 200 - Available place categories. - **count** (integer) - **categories** (array (object)) Array items: - **category** (string) - **count** (integer) ### Example Usage ```bash curl -X GET "https://api.latlng.work/v1/places/categories" ``` ``` -------------------------------- ### GET /v1/datasets/{datasetId} Source: https://www.latlng.work/openapi.yaml API endpoint for GET /v1/datasets/{datasetId} ```markdown ### Parameters - **datasetId** (string, path, required) ### Responses #### 200 - Dataset details. #### 401 - response **Error** - **error** (string) - **message** (string) #### 404 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/v1/datasets/{datasetId}" ``` ``` -------------------------------- ### GET /v1/datasets Source: https://www.latlng.work/openapi.yaml List uploaded custom datasets for the authenticated key. ```markdown ### Responses #### 200 - Dataset list. #### 401 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/v1/datasets" ``` ``` -------------------------------- ### GET /health Source: https://www.latlng.work/openapi.yaml API endpoint for GET /health ```markdown ### Responses #### 200 - API is healthy. - **status** (string) (example: "ok") ### Example Usage ```bash curl -X GET "https://api.latlng.work/health" ``` ``` -------------------------------- ### GET /reverse Source: https://www.latlng.work/openapi.yaml Convert latitude and longitude to nearby address/place results. ```markdown ### Parameters - **api_key** (string, query, optional): API key alternative to the X-Api-Key header. - **lat** (number (double), query, required) - **lon** (number (double), query, required) - **limit** (integer, query, optional) - **lang** (string, query, optional) ### Responses #### 200 - GeoJSON feature collection. **GeoJsonFeatureCollection** - **type** (string (FeatureCollection)) (required) ("FeatureCollection") - **features** (array (GeoJsonFeature)) (required) Array items: - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) #### 400 - response **Error** - **error** (string) - **message** (string) #### 429 - response **Error** - **error** (string) - **message** (string) #### 503 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/reverse?api_key=string&lat=0&lon=0&limit=0&lang=string" ``` ``` -------------------------------- ### GET /api Source: https://www.latlng.work/openapi.yaml Convert an address or place name to GeoJSON coordinates. ```markdown ### Parameters - **api_key** (string, query, optional): API key alternative to the X-Api-Key header. - **q** (string, query, required): Address or place name to geocode. - **limit** (integer, query, optional) - **lang** (string, query, optional) - **lat** (number (double), query, optional): Bias results near this latitude. - **lon** (number (double), query, optional): Bias results near this longitude. ### Responses #### 200 - GeoJSON feature collection. **GeoJsonFeatureCollection** - **type** (string (FeatureCollection)) (required) ("FeatureCollection") - **features** (array (GeoJsonFeature)) (required) Array items: - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) #### 400 - response **Error** - **error** (string) - **message** (string) #### 429 - response **Error** - **error** (string) - **message** (string) #### 503 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/api?api_key=string&q=string&limit=0&lang=string&lat=0&lon=0" ``` ``` -------------------------------- ### GET /v1/places/nearby Source: https://www.latlng.work/openapi.yaml Find OpenStreetMap points of interest near a coordinate. ```markdown ### Parameters - **api_key** (string, query, optional): API key alternative to the X-Api-Key header. - **lat** (number (double), query, required) - **lon** (number (double), query, required) - **radius** (integer, query, optional): Search radius in meters. - **type** (string, query, optional): Optional category filter. Alias of category. - **category** (string, query, optional): Optional category filter. - **limit** (integer, query, optional) ### Responses #### 200 - Nearby places response. **PlacesResponse** - **type** (string) (example: "nearby") - **source** (string) (example: "latlng_places") - **query** (string) - **center** (object) - **lat** (number) - **lon** (number) - **radius_m** (integer) - **count** (integer) - **places** (array (Place)) Array items: - **id** (string) - **name** (string) - **category** (string) - **lat** (number) - **lon** (number) - **confidence** (number) - **country** (string) - **region** (string) - **locality** (string) - **brand** (string) - **distance_m** (number) #### 400 - response **Error** - **error** (string) - **message** (string) #### 429 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/v1/places/nearby?api_key=string&lat=0&lon=0&radius=1000&type=string&category=string&limit=20" ``` ``` -------------------------------- ### GET /v1/places/search Source: https://www.latlng.work/openapi.yaml Search for places by name with optional location and category filters. ```markdown ### Parameters - **api_key** (string, query, optional): API key alternative to the X-Api-Key header. - **q** (string, query, required) - **lat** (number (double), query, optional) - **lon** (number (double), query, optional) - **type** (string, query, optional) - **category** (string, query, optional) - **country** (string, query, optional) - **limit** (integer, query, optional) ### Responses #### 200 - Search places response. **PlacesResponse** - **type** (string) (example: "nearby") - **source** (string) (example: "latlng_places") - **query** (string) - **center** (object) - **lat** (number) - **lon** (number) - **radius_m** (integer) - **count** (integer) - **places** (array (Place)) Array items: - **id** (string) - **name** (string) - **category** (string) - **lat** (number) - **lon** (number) - **confidence** (number) - **country** (string) - **region** (string) - **locality** (string) - **brand** (string) - **distance_m** (number) #### 400 - response **Error** - **error** (string) - **message** (string) #### 429 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X GET "https://api.latlng.work/v1/places/search?api_key=string&q=string&lat=0&lon=0&type=string&category=string&country=string&limit=20" ``` ``` -------------------------------- ### POST /v1/static Source: https://www.latlng.work/openapi.yaml Generate a static map image using a GeoJSON body overlay. ```markdown ### Parameters - **key** (string, query, optional) ### Request Body **Content-Type:** application/geo+json - **type** (string (FeatureCollection)) (required) ("FeatureCollection") - **features** (array (GeoJsonFeature)) (required) Array items: - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) **Content-Type:** application/json - **type** (string (FeatureCollection)) (required) ("FeatureCollection") - **features** (array (GeoJsonFeature)) (required) Array items: - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) ### Responses #### 200 - Static map image. #### 400 - response **Error** - **error** (string) - **message** (string) #### 429 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X POST "https://api.latlng.work/v1/static?key=string" \ -H "Content-Type: application/json" \ -d '{ "type": "FeatureCollection", "features": [ "value" ] }' ``` ``` -------------------------------- ### Security: X-Api-Key Source: https://www.latlng.work/openapi.yaml Security scheme: ApiKeyAuth ```markdown ## Security: X-Api-Key **Description:** Security scheme: ApiKeyAuth **Type:** apiKey ``` -------------------------------- ### POST /v1/datasets Source: https://www.latlng.work/openapi.yaml Upload a custom geospatial dataset for tile generation. ```markdown ### Request Body **Content-Type:** application/octet-stream **Content-Type:** application/geo+json - **type** (string (FeatureCollection)) (required) ("FeatureCollection") - **features** (array (GeoJsonFeature)) (required) Array items: - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) ### Responses #### 200 - Dataset upload accepted. #### 401 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X POST "https://api.latlng.work/v1/datasets" \ -H "Content-Type: application/json" \ -d '"string"' ``` ``` -------------------------------- ### Schema: Place Source: https://www.latlng.work/openapi.yaml Schema definition for Place ```markdown ## Schema: Place Schema definition for Place **Type:** object - **id** (string) - **name** (string) - **category** (string) - **lat** (number) - **lon** (number) - **confidence** (number) - **country** (string) - **region** (string) - **locality** (string) - **brand** (string) - **distance_m** (number) ``` -------------------------------- ### Security: api_key Source: https://www.latlng.work/openapi.yaml Security scheme: ApiKeyQuery ```markdown ## Security: api_key **Description:** Security scheme: ApiKeyQuery **Type:** apiKey ``` -------------------------------- ### Schema: PlacesResponse Source: https://www.latlng.work/openapi.yaml Schema definition for PlacesResponse ```markdown ## Schema: PlacesResponse Schema definition for PlacesResponse **Type:** object - **type** (string) (example: "nearby") - **source** (string) (example: "latlng_places") - **query** (string) - **center** (object) - **lat** (number) - **lon** (number) - **radius_m** (integer) - **count** (integer) - **places** (array (Place)) Array items: - **id** (string) - **name** (string) - **category** (string) - **lat** (number) - **lon** (number) - **confidence** (number) - **country** (string) - **region** (string) - **locality** (string) - **brand** (string) - **distance_m** (number) ``` -------------------------------- ### DELETE /v1/datasets/{datasetId} Source: https://www.latlng.work/openapi.yaml API endpoint for DELETE /v1/datasets/{datasetId} ```markdown ### Parameters - **datasetId** (string, path, required) ### Responses #### 200 - Dataset deleted. #### 401 - response **Error** - **error** (string) - **message** (string) #### 404 - response **Error** - **error** (string) - **message** (string) ### Example Usage ```bash curl -X DELETE "https://api.latlng.work/v1/datasets/{datasetId}" ``` ``` -------------------------------- ### Schema: GeoJsonFeature Source: https://www.latlng.work/openapi.yaml Schema definition for GeoJsonFeature ```markdown ## Schema: GeoJsonFeature Schema definition for GeoJsonFeature **Type:** object - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) ``` -------------------------------- ### Schema: Error Source: https://www.latlng.work/openapi.yaml Schema definition for Error ```markdown ## Schema: Error Schema definition for Error **Type:** object - **error** (string) - **message** (string) ``` -------------------------------- ### Schema: GeoJsonFeatureCollection Source: https://www.latlng.work/openapi.yaml Schema definition for GeoJsonFeatureCollection ```markdown ## Schema: GeoJsonFeatureCollection Schema definition for GeoJsonFeatureCollection **Type:** object - **type** (string (FeatureCollection)) (required) ("FeatureCollection") - **features** (array (GeoJsonFeature)) (required) Array items: - **type** (string (Feature)) (required) ("Feature") - **geometry** (object) (required) - **type** (string) (required) (example: "Point") - **coordinates** (array (number)) (required) - **properties** (object) (required) ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.