OpenStreetMap

Provides geocoding, routing, POI search, and area analysis using OpenStreetMap data via MCP
  • go

8

GitHub Stars

go

Language

6 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "nervsystems-osmmcp": {
      "command": "./osmmcp",
      "args": []
    }
  }
}

You can run and query the OpenStreetMap MCP Server to give large language models precise, fast access to geospatial data. It implements the Model Context Protocol, enabling LLMs to geocode, geosearch, route, and analyze OpenStreetMap data with reliable, composable tools. This guide shows practical usage, installation steps, and important considerations so you can start building location-aware applications and workflows.

How to use

You interact with the OpenStreetMap MCP Server through a client that supports the MCP protocol. Start the server in your environment, then issue requests via the client to perform geocoding, reverse geocoding, nearby search, routing, map retrieval, and more. You can compose multiple primitive tools to create powerful location workflows, such as finding points of interest along a route, computing optimal meeting points, or analyzing route characteristics.

How to install

Prerequisites: you need a Go toolchain installed to build from source, and you must have network access to geospatial data providers.

# 1) Install Go (if not already installed)
# Follow your OS-specific instructions from the Go website

# 2) Build the MCP server binary
go build -o osmmcp ./cmd/osmmcp

# 3) Run the server (in its own process)
./osmmcp

Configuration and running notes

When you run the server, you can enable debugging, generate a Claude Desktop Client configuration, and adjust rate limits for external services. Use the following commands to start, inspect, and configure the server as needed.

# Show version information
./osmmcp --version

# Enable debug logging
./osmmcp --debug

# Generate a Claude Desktop Client configuration
./osmmcp --generate-config /path/to/config.json

# Customize rate limits (examples)
./osmmcp --nominatim-rps 1.0 --nominatim-burst 1
./osmmcp --overpass-rps 0.033 --overpass-burst 2
./osmmcp --osrm-rps 1.67 --osrm-burst 5

# Set a custom User-Agent string
./osmmcp --user-agent "MyApp/1.0"

Using with a client and examples of workflows

You can connect via a client that supports MCP and use the server tools in sequence to perform complex tasks. The following patterns illustrate how primitive tools can be composed to achieve advanced goals.

# Example: Find Points of Interest Along a Path
{
  "name": "bbox_from_points",
  "arguments": {"points": [{"latitude": 37.7749, "longitude": -122.4194}, {"latitude": 37.8043, "longitude": -122.2711}]}
}
# Then feed into osm_query_bbox, filter_tags, sort_by_distance

Notes on security and reliability

The server uses structured logging and context-aware operations. Respect rate limits when querying external APIs, and ensure your client handles timeouts and cancellations properly to avoid long-running requests.

Available tools

bbox_from_points

Create a bounding box that encompasses all given geographic coordinates

centroid_points

Calculate the geographic centroid (mean center) of a set of coordinates

enrich_emissions

Enrich route options with CO2 emissions, calorie burn, and cost estimates

filter_tags

Filter OSM elements by specified tags

geocode_address

Convert an address or place name to geographic coordinates

geo_distance

Calculate the distance between two geographic coordinates

get_map_image

Retrieve and display an OpenStreetMap image for analysis

osm_query_bbox

Query OpenStreetMap data within a bounding box with tag filters

polyline_decode

Decode an encoded polyline string into a series of geographic coordinates

polyline_encode

Encode a series of geographic coordinates into a polyline string

reverse_geocode

Convert geographic coordinates to a human-readable address

route_fetch

Fetch a route between two points using OSRM routing service

route_sample

Sample points along a route at specified intervals

sort_by_distance

Sort OSM elements by distance from a reference point

find_nearby_places

Find points of interest near a specific location

get_route_directions

Get detailed turn-by-turn directions for a route between locations

suggest_meeting_point

Suggest an optimal meeting point for multiple people

explore_area

Explore an area and get comprehensive information about it

find_charging_stations

Find electric vehicle charging stations near a location

analyze_commute

Analyze transportation options between home and work locations

analyze_neighborhood

Evaluate neighborhood livability for real estate and relocation decisions

find_schools_nearby

Find educational institutions near a specific location

find_parking_facilities

Find parking facilities near a specific location

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational