← clify home · catalogue

openstreetmap API for agents (unofficial) — JSON over curl | clify

OpenStreetMap (openstreetmap.org), the free editable world map. This CLI searches places, reads map elements, their history and raw data, gets routes, exports map data for a bounding box, and reads changesets, user profiles, diaries and communities.

Host: openstreetmap.org. Call these verified read commands with plain curl; no install, key, or account. Use the public JSON API with plain curl. No install, key, account, or browser is needed. Example: curl 'https://clify-dev.netlify.app/sites.json'. Start with /search?q=weather, then call /abc/COMMAND. Responses are one JSON object. The hosted MCP and GitHub repo are also available.

Commands

search-places

Geocode a place name or address with Nominatim, the search engine openstreetmap.org uses. Returns OSM type/id, coordinates and display name. Params: q*, api_limit, viewbox, exclude_place_ids

curl 'https://clify-dev.netlify.app/openstreetmap/search-places?q=Central+Park%2C+New+York&api_limit=5&viewbox=-74.0204%2C40.7563%2C-73.9106%2C40.8086&exclude_place_ids=359156228'

get-element

Get the detail page of an OSM node, way or relation: name, current version, last editor, changeset, edit comment and tags (as text). Params: element_type*, id*

curl 'https://clify-dev.netlify.app/openstreetmap/get-element'

get-element-history

List every version of an OSM node, way or relation, with version number, editor, timestamp, changeset and comment. Params: element_type*, id*

curl 'https://clify-dev.netlify.app/openstreetmap/get-element-history'

get-element-full

Get raw OSM data as JSON for a way or relation together with all its member nodes (coordinates, tags, versions, editors). Params: element_type*, id*

curl 'https://clify-dev.netlify.app/openstreetmap/get-element-full'

export-map-data

Download all raw OSM data (nodes, ways, relations) in a small bounding box as JSON. This is what the Export button returns. Params: bbox*

curl 'https://clify-dev.netlify.app/openstreetmap/export-map-data?bbox=-73.9740%2C40.7645%2C-73.9720%2C40.7660'

get-route

Get turn-by-turn directions between two coordinates with the OSRM engine (FOSSGIS) for car, bike or foot. Returns distance in meters and duration in seconds. Params: profile, from_lon*, from_lat*, to_lon*, to_lat*, steps

curl 'https://clify-dev.netlify.app/openstreetmap/get-route?steps=true'

get-route-valhalla

Get directions with the Valhalla engine (FOSSGIS). Returns human-readable maneuvers, length and time. Params: json*

curl 'https://clify-dev.netlify.app/openstreetmap/get-route-valhalla?json=%7B%22locations%22%3A%5B%7B%22lat%22%3A40.7570095%2C%22lon%22%3A-73.9859724%2C%22radius%22%3A5%7D%2C%7B%22lat%22%3A40.7827725%2C%22lon%22%3A-73.9653627%2C%22radius%22%3A5%7D%5D%2C%22costing%22%3A%22pedestrian%22%2C%22directions_options%22%3A%7B%22units%22%3A%22kilometers%22%7D%7D'

list-area-changesets

List recent changesets (edit sessions) in a bounding box, newest first. Use --before for older ones. Params: bbox*, before

curl 'https://clify-dev.netlify.app/openstreetmap/list-area-changesets?bbox=-74.01540756225587%2C40.74361546275168%2C-73.93558502197267%2C40.79594285648614&before=190661217'

list-user-changesets

List a user's changesets (edits), newest first. Use --before for older ones. Params: username*, before

curl 'https://clify-dev.netlify.app/openstreetmap/list-user-changesets?before=176923031'

get-user

Get a mapper's public profile: edit count, mapper-since date, last edit date and description. Params: username*

curl 'https://clify-dev.netlify.app/openstreetmap/get-user'

get-user-contributions

Get a user's contribution count for the last year (from the activity heatmap). Params: username*

curl 'https://clify-dev.netlify.app/openstreetmap/get-user-contributions'

list-diary-entries

List the latest user diary entries from all languages, newest first. Use --before for older ones. Params: before

curl 'https://clify-dev.netlify.app/openstreetmap/list-diary-entries?before=409471'

list-diary-entries-by-language

List the latest diary entries written in one language (e.g. en, de, fr), newest first. Params: language*, before

curl 'https://clify-dev.netlify.app/openstreetmap/list-diary-entries-by-language?before=409471'

get-diary-entry

Read one diary entry: title, author, date, full text, location and the comment discussion. Params: username*, id*

curl 'https://clify-dev.netlify.app/openstreetmap/get-diary-entry'

list-communities

List the official OpenStreetMap Local Chapters (country or regional organisations) with their websites. Params: none

curl 'https://clify-dev.netlify.app/openstreetmap/list-communities'