Using the MCP server
Connect OpenPlaces to Claude Code and other MCP clients through a single search tool.
@openplaces/mcp packages OpenPlaces as a Model Context Protocol server, so tools like Claude Code can look up real places and work with the results directly. It runs over stdio and requires no API key or configuration — the server constructs a plain new OpenPlaces() client internally.
Installation
For Claude Code, register the server with a single command:
claude mcp add openplaces -- npx -y @openplaces/mcp@latestFor other MCP clients, add the equivalent entry to the client's server configuration:
{
"mcpServers": {
"openplaces": {
"command": "npx",
"args": ["-y", "@openplaces/mcp@latest"]
}
}
}The package ships an openplaces-mcp binary, so any client that can spawn a stdio subprocess can run it — under the hood it drives the same Playwright-managed headless Chromium as the openplaces library.
What to expect
The server exposes exactly one tool, search, described to the model as a way to look up real places by name, category, or address. Each call runs to completion and responds once with the full result set of Place objects — no partial streaming, and up to 100 places when no limit is given. If the search throws, the response carries the error message instead, so the model can see what went wrong and adjust the query.
The library's where option is not exposed through the
tool. Models can narrow results by writing more specific queries, or you can
post-process the returned places yourself.