GeoServer MCP Server
A Model Context Protocol (MCP) server implementation that connects Large Language Models (LLMs) to the GeoServer REST API, enabling AI assistants to interact with geospatial data and services.
🚀 Features
- 🔍 Query and manipulate GeoServer workspaces, layers, and styles
- 🗺️ Execute spatial queries on vector data
- 🎨 Generate map visualizations
- 🌐 Access OGC-compliant web services (WMS, WFS)
📋 Prerequisites
- Python 3.10+
- Running GeoServer instance with REST API enabled
- MCP-compatible client (like Claude Desktop)
geoserver-rest
package
🛠️ Installation
- Install the package:
- Configure GeoServer connection:
Linux/Mac:
Windows PowerShell:
- Start the server:
🔧 Configuration
Command-line Arguments
MCP Client Integration
Claude Desktop
Edit claude_desktop_config.json
:
Cursor
Create .cursor/mcp.json
:
🛠️ Available Tools
Catalog Management
list_workspaces
- Get available workspacescreate_workspace
- Create a new workspaceget_layer_info
- Get detailed layer metadatalist_layers
- List layers in a workspacecreate_layer
- Create a new layerdelete_resource
- Remove resources
Data Operations
query_features
- Execute CQL queries on vector data
Visualization
generate_map
- Create styled map imagescreate_style
- Define new SLD styles
📚 Example Usage
List Workspaces
Here's how the workspaces appear in the MCP client:
The screenshot shows the actual workspaces available in the GeoServer instance, including: mahdi, demo-workspace, cite, tiger, nurc, sde, it.geosolutions, topp, and sf. These workspaces serve as containers for organizing your GeoServer resources.
Get Layer Information
Query Features
Generate Map
🔮 Planned Features
- Coverage and raster data management
- Security and access control
- Advanced styling capabilities
- WPS processing operations
- GeoWebCache integration
🤝 Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🔗 Related Projects
You must be authenticated.
Tools
A Model Context Protocol server that connects Large Language Models to the GeoServer REST API, enabling AI assistants to query and manipulate geospatial data through natural language.
- 🚀 Features
- 📋 Prerequisites
- 🛠️ Installation
- 🔧 Configuration
- 🛠️ Available Tools
- 📚 Example Usage
- 🔮 Planned Features
- 🤝 Contributing
- 📄 License
- 🔗 Related Projects