geolens-mcp

對自架 GeoLens 地理空間目錄的唯讀存取:資料集搜尋、結構描述、GeoJSON 圖徵、已儲存地圖,以及透過 PostGIS 的沙盒唯讀 SQL。

文件

geolens-mcp

Apache-2.0 read-only Model Context Protocol server for GeoLens.

Point a coding agent (Claude Code, Cursor, Codex, …) at a GeoLens instance so it can discover datasets, inspect schemas, read features and maps, and run read-only SQL from inside a dev session. It has no write, ingest or admin tools, and every call is scoped to the caller's access.

Install

pip install geolens-mcp        # or: uvx geolens-mcp

The server reads GEOLENS_INSTANCE and, for non-public data, GEOLENS_API_KEY from the environment. Client setup, the tool list and the credential rules are in the MCP guide.

Develop

cd mcp
uv run --extra dev python -m pytest -v