Metadata-Version: 2.4
Name: geoedge-mcp
Version: 1.0.2
Summary: A Model Context Protocol (MCP) server implementation for GIS operations using GIS libraries
Author: Mahdi Nazari Ashani, Saba Kazemi, Shahab Esfandiar, Yasin Mohammadi, Homa Ganjali, GeoEDGE-MCP Contributors
License-Expression: LicenseRef-Proprietary
License-File: LICENSE
License-File: THIRD_PARTY_LICENCES.md
Keywords: agentic AI,cdsapi,fiona,geopandas,geospatial,gis,llm,mcp,ogc,pygadm,pygbif,pyproj,pysal,rasterio,shapely
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Requires-Python: >=3.10
Requires-Dist: esda<2.10,>=2.7.0
Requires-Dist: fastmcp<4,>=3.2.0
Requires-Dist: fiona>=1.10.1
Requires-Dist: geopandas>=1.1.2
Requires-Dist: giddy>=2.3.6
Requires-Dist: libpysal<4.15,>=4.13.0
Requires-Dist: numpy<2.0,>=1.23
Requires-Dist: openpyxl>=3.1
Requires-Dist: pandas>=2.0.0
Requires-Dist: pillow>=10.0.0
Requires-Dist: pyproj>=3.7.1
Requires-Dist: pyyaml>=6.0
Requires-Dist: rasterio==1.3.9
Requires-Dist: reportlab>=4.0.0
Requires-Dist: shapely>=2.1.0
Requires-Dist: spreg==1.8.3
Requires-Dist: tabulate>=0.9.0
Requires-Dist: websockets>=12.0
Provides-Extra: administrative-boundaries
Requires-Dist: pygadm>=0.5.0; extra == 'administrative-boundaries'
Provides-Extra: all
Requires-Dist: cdsapi==0.7.6; extra == 'all'
Requires-Dist: folium>=0.15.0; extra == 'all'
Requires-Dist: geoalchemy2>=0.15.0; extra == 'all'
Requires-Dist: mapclassify>=2.6.0; extra == 'all'
Requires-Dist: matplotlib>=3.7.0; extra == 'all'
Requires-Dist: osmnx>=2.0.0; extra == 'all'
Requires-Dist: planetary-computer>=1.0.0; extra == 'all'
Requires-Dist: psycopg2-binary>=2.9.9; extra == 'all'
Requires-Dist: pydeck>=0.9.0; extra == 'all'
Requires-Dist: pygadm>=0.5.0; extra == 'all'
Requires-Dist: pygbif>=0.6.4; extra == 'all'
Requires-Dist: pystac-client>=0.7.6; extra == 'all'
Requires-Dist: requests>=2.31; extra == 'all'
Requires-Dist: sqlalchemy>=2.0.0; extra == 'all'
Requires-Dist: stackstac>=0.5.0; extra == 'all'
Requires-Dist: xarray>=2023.1.0; extra == 'all'
Provides-Extra: arcgis
Requires-Dist: requests>=2.31; extra == 'arcgis'
Provides-Extra: climate
Requires-Dist: cdsapi==0.7.6; extra == 'climate'
Provides-Extra: desktop
Requires-Dist: cryptography>=41.0.0; extra == 'desktop'
Requires-Dist: requests>=2.31; extra == 'desktop'
Provides-Extra: ecology
Requires-Dist: pygbif>=0.6.4; extra == 'ecology'
Provides-Extra: land-cover
Requires-Dist: planetary-computer>=1.0.0; extra == 'land-cover'
Requires-Dist: pystac-client>=0.7.6; extra == 'land-cover'
Requires-Dist: requests>=2.31; extra == 'land-cover'
Requires-Dist: stackstac>=0.5.0; extra == 'land-cover'
Requires-Dist: xarray>=2023.1.0; extra == 'land-cover'
Provides-Extra: movement
Requires-Dist: osmnx>=2.0.0; extra == 'movement'
Provides-Extra: postgis
Requires-Dist: geoalchemy2>=0.15.0; extra == 'postgis'
Requires-Dist: psycopg2-binary>=2.9.9; extra == 'postgis'
Requires-Dist: sqlalchemy>=2.0.0; extra == 'postgis'
Provides-Extra: satellite-imagery
Requires-Dist: planetary-computer>=1.0.0; extra == 'satellite-imagery'
Requires-Dist: pystac-client>=0.7.6; extra == 'satellite-imagery'
Requires-Dist: requests>=2.31; extra == 'satellite-imagery'
Requires-Dist: stackstac>=0.5.0; extra == 'satellite-imagery'
Requires-Dist: xarray>=2023.1.0; extra == 'satellite-imagery'
Provides-Extra: test
Requires-Dist: pytest-asyncio>=0.21.0; extra == 'test'
Requires-Dist: pytest-cov>=4.1.0; extra == 'test'
Requires-Dist: pytest>=7.4.0; extra == 'test'
Provides-Extra: visualize
Requires-Dist: folium>=0.15.0; extra == 'visualize'
Requires-Dist: mapclassify>=2.6.0; extra == 'visualize'
Requires-Dist: matplotlib>=3.7.0; extra == 'visualize'
Requires-Dist: pydeck>=0.9.0; extra == 'visualize'
Description-Content-Type: text/markdown

# GeoEDGE-MCP

<div align="center">

| Category                     | Badges                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| ---------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| **Package**                  | [![PyPI version](https://img.shields.io/pypi/v/geoedge-mcp.svg)](https://pypi.org/project/geoedge-mcp/) [![PyPI downloads](https://static.pepy.tech/personalized-badge/geoedge-mcp?period=total&units=international_system&left_color=grey&right_color=blue&left_text=PyPI%20downloads)](https://pepy.tech/project/geoedge-mcp) [![Tests](https://github.com/GeoEDGE-git/geoedge-mcp/actions/workflows/test.yml/badge.svg)](https://github.com/GeoEDGE-git/geoedge-mcp/actions/workflows/test.yml)                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| **Installation & Transport** | [![Docker Installation](https://img.shields.io/badge/Docker-Installation-2496ED?logo=docker&logoColor=white)](https://gis-mcp.com/install/docker/) [![Transport](https://img.shields.io/badge/Transport-HTTP%20%7C%20stdio-blue)](https://github.com/GeoEDGE-git/geoedge-mcp) [![Storage](https://img.shields.io/badge/Storage-Supported-4CAF50?logo=files&logoColor=white)](https://gis-mcp.com/storage-configuration/)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| **Data Sources**             | [![Climate](https://img.shields.io/badge/Climate-Data-B91C1C?logo=weather&logoColor=white)](https://gis-mcp.com/data-gathering/climate/) [![Biodiversity](https://img.shields.io/badge/Biodiversity-Data-4CAF50?logo=leaf&logoColor=white)](https://gis-mcp.com/data-gathering/ecology/) [![LandCover](https://img.shields.io/badge/LandCover-Data-5D4037?logo=map&logoColor=white)](https://gis-mcp.com/data-gathering/land_cover/) [![Movement](https://img.shields.io/badge/Movement-Data-FF6B35?logo=person-walking&logoColor=white)](https://gis-mcp.com/data-gathering/movement/) [![Satellite](https://img.shields.io/badge/Satellite-Imagery-6C5CE7?logo=satellite&logoColor=white)](https://gis-mcp.com/data-gathering/satellite_imagery/) [![Administrative](https://img.shields.io/badge/Administrative-Boundaries-7289DA?logo=map&logoColor=white)](https://gis-mcp.com/data-gathering/administrative_boundaries/) |
| **Agentic AI**               | [![LangChain Agent Example](<https://img.shields.io/badge/LangChain-Agent%20Example%20(Python)-3776AB?logo=langchain&logoColor=white>)](https://gis-mcp.com/gis-ai-agent/langchain) [![OpenAI Agent Example](<https://img.shields.io/badge/OpenAI-Agent%20Example%20(Node.js)-111827?logo=openai&logoColor=white>)](https://gis-mcp.com/gis-ai-agent/openai-nodejs)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            |
| **Reference**                | [![DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/GeoEDGE-git/geoedge-mcp)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |

</div>

<div align="center">
  <h3>✨ Want to perform accurate geospatial analysis in your chatbot? ✨</h3>
  <p><strong>Install GeoEDGE-MCP and transform your AI's spatial capabilities!</strong></p>
  <br/>
  <img src="docs/Logo.png" alt="GeoEDGE-MCP Logo" width="300"/>

  <br/>
</div>

A Model Context Protocol (MCP) server implementation that connects Large Language Models (LLMs) to GIS operations using GIS libraries, enabling AI assistants to perform geospatial operations and transformations.

🌐 **Product:** [mcp.geoedge.com.au](https://mcp.geoedge.com.au/geo-mcp) · 📖 **Documentation:** [gis-mcp.com](https://gis-mcp.com)

> **GeoEDGE-MCP is commercial, subscription-licensed software.** GIS tools require a
> valid licence key — see [mcp.geoedge.com.au](https://mcp.geoedge.com.au). Use is
> governed by the [Terms of Service and EULA](https://mcp.geoedge.com.au/terms).
>
> **Attribution.** GeoEDGE-MCP is derived from, and still incorporates substantial
> portions of, the open-source [`gis-mcp`](https://github.com/mahdin75/gis-mcp)
> project (MIT, © 2025 Mahdi Nazari Ashani and contributors). Those portions remain
> licensed under the MIT License; see [`THIRD_PARTY_LICENCES.md`](THIRD_PARTY_LICENCES.md)
> and the [`LICENSE`](LICENSE) file. With thanks to the `gis-mcp` project and its
> contributors.

## 🎥 Demo

<div align="center">
  <img src="docs/demo.gif" alt="GeoEDGE-MCP Demo" width="800"/>
</div>

## 📋 Table of Contents

- [Features](#-features)
- [Prerequisites](#-prerequisites)
- [Vibe Coding](#vibe-coding)
- [Installation](#-installation)
  - [Docker Installation](#-docker-installation)
  - [pip Installation](#-pip-installation)
  - [Development Installation](#-development-installation)
- [Build Your First GIS AI Agent](#-build-your-first-gis-ai-agent)
- [Available Functions](#-available-functions)
  - [Shapely Functions](#-shapely-functions-29-total)
  - [PyProj Functions](#-pyproj-functions-13-total)
  - [GeoPandas Functions](#-geopandas-functions-13-total)
  - [Rasterio Functions](#-rasterio-functions-20-total)
  - [PySAL Functions](#-pysal-functions-18-total)
  - [Visualization Functions](#-visualization-functions-2-total)
    - [Static Map Functions](#-static-map-functions-1-total)
    - [Interactive Web Map Functions](#-interactive-web-map-functions-1-total)
  - [Administrative Boundaries Functions](#-administrative-boundaries-functions-1-total)
  - [Climate Data Functions](#-climate-data-functions-1-total)
  - [Ecology Data Functions](#-ecology-data-functions-2-total)
  - [Movement Data Functions](#-movement-data-functions-2-total)
  - [Land Cover Data Functions](#-land-cover-data-functions-2-total)
  - [Satellite Imagery Functions](#-satellite-imagery-functions-1-total)
- [Client Development](#-client-development)
- [Planned Features](#-planned-features)
- [Contributing](#-contributing)
- [Privacy Policy](#-privacy-policy)
- [License](#-license)
- [Related Projects](#-related-projects)
- [Support](#-support)
- [Badges](#-badges)

## 🚀 Features

GeoEDGE-MCP empowers AI assistants with advanced geospatial intelligence. Key features include:

- 🔹 **Comprehensive Geometry Operations** – Perform intersection, union, buffer, difference, and other geometric transformations with ease.
- 🔹 **Advanced Coordinate Transformations** – Effortlessly reproject and transform geometries between coordinate reference systems.
- 🔹 **Accurate Measurements** – Compute distances, areas, lengths, and centroids precisely.
- 🔹 **Spatial Analysis & Validation** – Validate geometries, run proximity checks, and perform spatial overlays or joins.
- 🔹 **Raster & Vector Support** – Process raster layers, compute indices like NDVI, clip, resample, and merge with vector data.
- 🔹 **Spatial Statistics & Modeling** – Leverage PySAL for spatial autocorrelation, clustering, and neighborhood analysis.
- 🔹 **Interactive Map Editor** – View, draw, edit and filter your spatial data in a real map in your browser. See [Map Editor](#-map-editor) below, including how it works and its security model.
- 🔹 **Easy Integration** – Connect seamlessly with MCP-compatible clients like Claude Desktop or Cursor IDE.
- 🔹 **HTTP/SSE Transport** – Run as HTTP service with RESTful storage endpoints for file upload/download operations.
- 🔹 **Flexible & Extensible** – Supports Python-based GIS libraries and is ready for custom tools or workflow extensions.

> 🌟 **Tip:** With GeoEDGE-MCP, your AI can now “think spatially,” unlocking new capabilities for environmental analysis, mapping, and location intelligence.

---

## 🗺 Map Editor

Ask Claude to *"open the map editor"* and GeoEDGE opens an interactive map in
your browser where you can see your data, draw and edit features, edit
attributes, and filter by attribute or location. Anything you save comes back
as a **named layer**, so you can then just say the name in chat —
*"buffer survey_sites by 100 m"* — with no file paths.

**Free, no licence required.** Viewing and editing your own data costs nothing;
the licence covers the analysis tools.

### How it works, and what it does with your data

To put an editable map in your browser, GeoEDGE runs a small web server **on
your own computer**. That is a real thing to be aware of, so here is exactly
what it does:

| | |
|---|---|
| **When does it run?** | Only after you ask. It starts the first time you ask to see something (`visualize_data`) and stops when you close the editor, after 30 minutes idle, or when Claude Desktop exits. It never starts on its own. |
| **Who can reach it?** | Only your computer. It binds to `127.0.0.1` (localhost) on a random port — never to a network address, and there is no setting to change that. Nothing on your network or the internet can connect to it. |
| **Is it protected?** | Yes. Every session mints a new random **session token**, and every request must present it. There is no "no token" mode. Requests are also pinned to this machine's own origin, which blocks the DNS-rebinding trick a malicious web page would otherwise use. |
| **Does any data leave?** | **No data leaves your machine.** Your spatial data is read from and written to your own storage folder and goes nowhere else. The page cannot send it anywhere — its content-security policy forbids it. |
| **What about background maps?** | The editor offers OpenStreetMap, aerial and satellite imagery, and you can add your own XYZ or WMS service. Your browser fetches map tiles from whichever one is selected, so that provider sees the map area you are looking at — nothing else is sent, and no tiles are fetched for a background you have not selected. |
| **How does it read files?** | By path. There is no upload endpoint. You tell Claude which file to import and it is read from disk, with the same path restrictions the rest of GeoEDGE uses. |
| **Hosted deployments** | The editor is disabled entirely when GeoEDGE runs as a hosted HTTP service. It only exists on your local desktop install. |

### What it can do

- **View** any registered layer or file over a real basemap, click for attributes
- **Draw and edit** points, lines and polygons; move and delete features
- **Edit attributes**, and add, rename or delete columns
- **Find features** by attribute (*"category is park and score is at least 5"*)
  and by location (*"inside the flood zone"*, *"within 500 m of the river"*)
- **Import** GeoJSON, GeoPackage, shapefiles (including zipped), KML, GPX and
  CSV with coordinates
- **Rename layers** to something you would actually say out loud

### Things it deliberately will not do

- **It will not quietly analyse the wrong version.** While you have unsaved
  edits, the layer's name resolves to what is on your screen, not the older file
  on disk — and Claude is told the layer has unsaved changes so it can offer to
  save first.
- **It will not overwrite your original by default.** Saving creates a new
  layer. Overwriting takes a separate confirmation that names the file, and is
  refused outright if something else changed that file while you were editing.
- **It will not silently shorten your data.** If a layer is too large to draw in
  full, it says so on screen and the count it reports is the true one.
- **It will not guess.** A CSV with no recognisable coordinate columns, or a
  file with no CRS, is reported rather than assumed.
- Raster editing is not supported — the editor is vector-only.

---

## 📋 Prerequisites

- Python 3.10 or higher
- MCP-compatible client (like Claude Desktop or Cursor)
- Internet connection for package installation

## Vibe Coding

If you’re building agents via vibe coding, use these context files in your editor so the LLM understands the GeoEDGE-MCP server:

- `llms.txt`: summarized context for smaller windows.
- `llms-full.txt`: full context when your model has a larger window.

## 🛠 Installation

Choose the installation method that best suits your needs:

### 🐳 Docker Installation

GeoEDGE-MCP can be run using Docker, which provides an isolated environment with all dependencies pre-installed.

**Important:** Both `Dockerfile` and `Dockerfile.local` have **HTTP transport mode enabled by default**. The server runs on port `9010` and is accessible at `http://localhost:9010/mcp`.

#### Using Dockerfile

The main `Dockerfile` installs the package from PyPI:

1. Build the Docker image:

```bash
docker build -t geoedge-mcp .
```

2. Run the container (HTTP mode is enabled by default):

```bash
docker run -p 9010:9010 geoedge-mcp
```

#### Using Dockerfile.local

The `Dockerfile.local` installs the package from local source files (useful for development or custom builds):

1. Build the Docker image:

```bash
docker build -f Dockerfile.local -t geoedge-mcp:local .
```

2. Run the container (HTTP mode is enabled by default):

```bash
docker run -p 9010:9010 geoedge-mcp:local
```

The server will be available at `http://localhost:9010/mcp` in HTTP transport mode.

For more details on Docker configuration and environment variables, see the [Docker installation guide](docs/install/docker.md).

### 📦 pip Installation

The pip installation is recommended for most users:

1. Install uv package manager:

```bash
pip install uv
```

2. Create the Virtual Environment (Python 3.10+):

```bash
uv venv --python=3.10
```

3. Activate the Virtual Environment:

On Windows (PowerShell):

```powershell
.\.venv\Scripts\Activate.ps1
```

On Linux:

```bash
source .venv/bin/activate
```

4. Install the package:

```bash
uv pip install geoedge-mcp
```

#### Install with Visualization Features

To install with visualization capabilities (Folium and PyDeck for interactive maps):

```bash
uv pip install geoedge-mcp[visualize]
```

This will install additional dependencies:

- `folium>=0.15.0` - For creating interactive web maps
- `pydeck>=0.9.0` - For advanced 3D visualizations

5. Start the server:

```bash
geoedge-mcp
```

By default, the server runs in **STDIO transport mode**, which is ideal for local development and integration with Claude Desktop or Cursor IDE.

You can also run the server in **HTTP transport mode** for network deployments:

```bash
export GEOEDGE_MCP_TRANSPORT=http
export GEOEDGE_MCP_PORT=8080
geoedge-mcp
```

When running in HTTP or SSE transport mode, the following endpoints are available:

- **MCP endpoint**: `http://host:port/mcp` (HTTP) or `http://host:port/sse` (SSE)
- **Storage endpoints**:
  - `POST /storage/upload` - Upload files to server storage
  - `GET /storage/download?path=<file>` - Download files from server storage
  - `GET /storage/list?path=<dir>` - List files in server storage

For more details on transport modes and complete endpoint documentation, see:

- [HTTP Transport Configuration](docs/http-transport.md)
- [Server Endpoints](docs/endpoints.md)

#### Default output packaging

Spatial-analysis tools that write a result file (vector ops, raster ops,
MCDA, topology checks) default to a **zipped GeoPackage** (vector) or
**zipped GeoTIFF** (raster) whenever the caller omits `output_path`/
`destination` or gives one without a recognized extension. The zip bundles
the data file plus a small `metadata.json`/`metadata.txt` (CRS, feature/band
count, source tool, timestamp) — a single portable artifact instead of
scattered Shapefile sidecars.

Passing an explicit, recognized extension (`.shp`, `.geojson`, `.gpkg`,
`.tif`, ...) is always honored as-is with no zip wrapping. Set
`GIS_MCP_DISABLE_AUTO_ZIP=1` to disable the smart default server-wide and
fall back to legacy raw-file behavior.

#### pip Configuration

To use the pip installation with Claude or Cursor, add the following configuration:

**Claude Desktop:**

**Windows:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "C:\\Users\\YourUsername\\.venv\\Scripts\\geoedge-mcp",
      "args": []
    }
  }
}
```

**Linux/Mac:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "/home/YourUsername/.venv/bin/geoedge-mcp",
      "args": []
    }
  }
}
```

**Cursor IDE** (create `.cursor/mcp.json`):

**Windows:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "C:\\Users\\YourUsername\\.venv\\Scripts\\geoedge-mcp",
      "args": []
    }
  }
}
```

**Linux/Mac:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "/home/YourUsername/.venv/bin/geoedge-mcp",
      "args": []
    }
  }
}
```

After configuration:

1. Make sure to replace `YourUsername` with your actual username
2. For development installation, replace `/path/to/geoedge-mcp` with the actual path to your project
3. Restart your IDE to apply the changes
4. You can now use all GIS operations through Claude or Cursor!

### 🛠 Development Installation

For contributors and developers:

1. Install uv package manager:

```bash
pip install uv
```

2. Create the Virtual Environment:

```bash
uv venv --python=3.10
```

3. Install the package in development mode:

```bash
uv pip install -e .
```

4. Start the server:

```bash
python -m geoedge_mcp
```

#### Development Configuration

To use the development installation with Claude or Cursor, add the following configuration:

**Claude Desktop:**

**Windows:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "C:\\path\\to\\geoedge-mcp\\.venv\\Scripts\\python",
      "args": ["-m", "geoedge_mcp"]
    }
  }
}
```

**Linux/Mac:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "/path/to/geoedge-mcp/.venv/bin/python",
      "args": ["-m", "geoedge_mcp"]
    }
  }
}
```

**Cursor IDE** (create `.cursor/mcp.json`):

**Windows:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "C:\\path\\to\\geoedge-mcp\\.venv\\Scripts\\python",
      "args": ["-m", "geoedge_mcp"]
    }
  }
}
```

**Linux/Mac:**

```json
{
  "mcpServers": {
    "geoedge-mcp": {
      "command": "/path/to/geoedge-mcp/.venv/bin/python",
      "args": ["-m", "geoedge_mcp"]
    }
  }
}
```

After configuration:

1. Make sure to replace `YourUsername` with your actual username
2. For development installation, replace `/path/to/geoedge-mcp` with the actual path to your project
3. Restart your IDE to apply the changes
4. You can now use all GIS operations through Claude or Cursor!

## 🤖 Build Your First GIS AI Agent

Ready to create your own AI agent that can perform geospatial operations? Our comprehensive tutorial will guide you from zero to hero!

### What You'll Learn

- ✅ How to set up the GeoEDGE-MCP server in HTTP mode
- ✅ How to build a LangChain agent from scratch
- ✅ How to connect your agent to GIS tools
- ✅ How to use OpenRouter to access multiple AI models (DeepSeek, Gemini, GPT-4, Claude, etc.)
- ✅ How to customize and extend your agent

### Get Started

👉 **[Follow the complete tutorial →](https://gis-mcp.com/gis-ai-agent/)**

The tutorial is beginner-friendly and requires no prior AI or GIS experience. You'll build a working agent that can:

- Calculate distances between points
- Transform coordinates between different systems
- Create buffers around locations
- Perform spatial analysis
- And much more!

**Perfect for**: Developers, data scientists, GIS professionals, and anyone interested in building AI-powered geospatial applications.

## 📚 Available Functions

This section provides a comprehensive list of all available functions organized by library.

### 🔷 Shapely Functions (29 total)

**Basic Geometric Operations:**

- `buffer` - Create buffer around geometry
- `intersection` - Find intersection of two geometries
- `union` - Combine two geometries
- `difference` - Find difference between geometries
- `symmetric_difference` - Find symmetric difference

**Geometric Properties:**

- `convex_hull` - Calculate convex hull
- `envelope` - Get bounding box
- `minimum_rotated_rectangle` - Get minimum rotated rectangle
- `get_centroid` - Get centroid point
- `get_bounds` - Get geometry bounds
- `get_coordinates` - Extract coordinate array
- `get_geometry_type` - Get geometry type name

**Transformations:**

- `rotate_geometry` - Rotate geometry by angle
- `scale_geometry` - Scale geometry by factors
- `translate_geometry` - Move geometry by offset

**Advanced Operations:**

- `triangulate_geometry` - Create triangulation
- `voronoi` - Create Voronoi diagram
- `unary_union_geometries` - Union multiple geometries

**Measurements:**

- `get_length` - Calculate geometry length
- `get_area` - Calculate geometry area

**Validation & Utilities:**

- `is_valid` - Check geometry validity
- `make_valid` - Fix invalid geometry
- `simplify` - Simplify geometry
- `snap_geometry` - Snap to reference geometry
- `nearest_point_on_geometry` - Find nearest point
- `normalize_geometry` - Normalize orientation
- `geometry_to_geojson` - Convert to GeoJSON
- `geojson_to_geometry` - Convert from GeoJSON

### 🔷 PyProj Functions (13 total)

**Coordinate Transformations:**

- `transform_coordinates` - Transform point coordinates
- `project_geometry` - Project geometry between CRS

**CRS Information:**

- `get_crs_info` - Get detailed CRS information
- `get_available_crs` - List available CRS systems
- `get_utm_zone` - Get UTM zone for coordinates
- `get_utm_crs` - Get UTM CRS for coordinates
- `get_geocentric_crs` - Get geocentric CRS

**Geodetic Calculations:**

- `get_geod_info` - Get ellipsoid information
- `calculate_geodetic_distance` - Calculate distance on ellipsoid
- `calculate_geodetic_point` - Calculate point at distance/azimuth
- `calculate_geodetic_area` - Calculate area on ellipsoid

### 🔷 GeoPandas Functions (13 total)

**I/O Operations:**

- `read_file_gpd` - Read geospatial file with preview
- `write_file_gpd` - Export GeoDataFrame to file

**Join & Merge Operations:**

- `append_gpd` - Concatenate GeoDataFrames vertically
- `merge_gpd` - Database-style attribute joins
- `overlay_gpd` - Spatial overlay operations
- `dissolve_gpd` - Dissolve by attribute
- `explode_gpd` - Split multi-part geometries

**Spatial Operations:**

- `clip_vector` - Clip geometries
- `sjoin_gpd` - Spatial joins
- `sjoin_nearest_gpd` - Nearest neighbor spatial joins
- `point_in_polygon` - Point-in-polygon tests

### 🔷 Rasterio Functions (20 total)

**Basic Raster Operations:**

- `metadata_raster` - Get raster metadata
- `get_raster_crs` - Get raster CRS
- `extract_band` - Extract single band
- `raster_band_statistics` - Calculate band statistics
- `raster_histogram` - Compute pixel histograms

**Raster Processing:**

- `clip_raster_with_shapefile` - Clip raster with polygons
- `resample_raster` - Resample by scale factor
- `reproject_raster` - Reproject to new CRS
- `tile_raster` - Split into tiles

**Raster Analysis:**

- `compute_ndvi` - Calculate vegetation index
- `raster_algebra` - Mathematical operations on bands
- `concat_bands` - Combine single-band rasters
- `weighted_band_sum` - Weighted band combination

**Advanced Analysis:**

- `zonal_statistics` - Statistics within polygons
- `reclassify_raster` - Reclassify pixel values
- `focal_statistics` - Moving window statistics
- `hillshade` - Generate hillshade from DEM
- `write_raster` - Write array to raster file

### 🔷 PySAL Functions (18 total)

**Spatial Autocorrelation:**

- `morans_i` - Global Moran's I statistic
- `gearys_c` - Global Geary's C statistic
- `gamma_statistic` - Gamma index
- `getis_ord_g` - Global Getis-Ord G statistic

**Local Statistics:**

- `moran_local` - Local Moran's I
- `getis_ord_g_local` - Local Getis-Ord G\*
- `join_counts_local` - Local join counts

**Global Statistics:**

- `join_counts` - Binary join counts test
- `adbscan` - Adaptive density-based clustering

**Spatial Weights:**

- `weights_from_shapefile` - Create weights from shapefile
- `distance_band_weights` - Distance-based weights
- `knn_weights` - K-nearest neighbors weights
- `build_transform_and_save_weights` - Build, transform, and save weights
- `ols_with_spatial_diagnostics_safe` - OLS regression with spatial diagnostics
- `build_and_transform_weights` - Build and transform weights

**Spatial-Temporal Analysis:**

- `spatial_markov` - Spatial Markov analysis for panel data
- `dynamic_lisa` - Dynamic LISA (directional LISA) analysis

**Spatial Regression:**

- `gm_lag` - GM_Lag spatial 2SLS/GMM-IV spatial lag model

### 🔷 Visualization Functions (2 total)

**Static Map Visualization (Matplotlib/GeoPandas):**

- `create_map` – Generate high-quality static maps (PNG, PDF, JPG) from multiple geospatial data sources including shapefiles, rasters, WKT geometries, and coordinate arrays. Supports multiple layers with individual styling options, legends, titles, and grid overlays.

**Interactive Web Map Visualization (Folium):**

- `create_web_map` – Generate interactive HTML maps using Folium with layer controls, legends, scale bars, dynamic titles, tooltips, and minimap. Supports vector layers (shapefile/GeoJSON/WKT/GeoDataFrame) **and raster layers** (GeoTIFF, auto-reprojected to WGS84, single-band+colormap by default or explicit RGB via `style={"bands": [r, g, b]}`), plus a registered layer name (see `register_layer`) in place of a raw path. Multiple basemap options and responsive design for web browsers.

#### Visualize your results

After a spatial-analysis tool finishes, its response includes a `visualize_hint` field suggesting you ask whether the user wants to see the result on a map, then call `create_web_map` with the output path or `layer_name` from that same response — e.g.:

```json
{"status": "success", "output_path": "...", "layer_name": "compute_ndvi_20260705_...", "visualize_hint": "Ask the user if they'd like to see this result on an interactive map..."}
```

```python
create_web_map(layers=[{"data": "compute_ndvi_20260705_...", "style": {"cmap": "RdYlGn", "vmin": -1, "vmax": 1}}])
```

### 🔷 Administrative Boundaries Functions (1 total)

**Boundary Download:**

- `download_boundaries` - Download GADM administrative boundaries and save as GeoJSON

### 🔷 Climate Data Functions (1 total)

**Climate Data Download:**

- `download_climate_data` - Download climate data (ERA5 or other CDS datasets)

### 🔷 Ecology Data Functions (2 total)

**Ecology Data Download and Info:**

- `get_species_info` – Retrieve taxonomic information for a given species name
- `download_species_occurrences` – Download occurrence records for a given species and save as JSON

### 🔷 Movement Data Functions (2 total)

**Movement Data Download and Routing (via [OSMnx](https://osmnx.readthedocs.io/en/stable/)):**

- `download_street_network` – Download a street network for a given place and save as GraphML
- `calculate_shortest_path` – Calculate the shortest path between two points using a saved street network

### 🔷 Land Cover Data Functions (2 total)

**Land Cover from Planetary Computer:**

- `download_worldcover` – Download ESA WorldCover for AOI/year; optional crop and reprojection
- `compute_s2_ndvi` – Compute NDVI from Sentinel-2 L2A; crop and reprojection supported

### 🔷 Satellite Imagery Functions (1 total)

**STAC-based Satellite Download:**

- `download_satellite_imagery` – Download and stack bands from STAC items (e.g., Sentinel-2, Landsat), with optional crop and reprojection

**Total Functions Available: 92**

## 🛠 Client Development

Example usage of the tools:

### Buffer Operation

```python
Tool: buffer
Parameters: {
    "geometry": "POINT(0 0)",
    "distance": 10,
    "resolution": 16,
    "join_style": 1,
    "mitre_limit": 5.0,
    "single_sided": false
}
```

### Coordinate Transformation

```python
Tool: transform_coordinates
Parameters: {
    "coordinates": [0, 0],
    "source_crs": "EPSG:4326",
    "target_crs": "EPSG:3857"
}
```

### Geodetic Distance

```python
Tool: calculate_geodetic_distance
Parameters: {
    "point1": [0, 0],
    "point2": [10, 10],
    "ellps": "WGS84"
}
```

### Static Map Creation

```python
Tool: create_map
Parameters: {
    "layers": [
        {
            "data": "buildings.shp",
            "style": {"label": "Buildings", "color": "red", "alpha": 0.7}
        },
        {
            "data": "roads.shp",
            "style": {"label": "Roads", "color": "black", "linewidth": 1}
        }
    ],
    "filename": "city_analysis",
    "filetype": "png",
    "title": "City Infrastructure Analysis",
    "show_grid": true,
    "add_legend": true
}
```

### Interactive Web Map Creation

```python
Tool: create_web_map
Parameters: {
    "layers": [
        {
            "data": "buildings.shp",
            "style": {"label": "Buildings", "color": "red"}
        },
        {
            "data": "parks.geojson",
            "style": {"label": "Parks", "color": "green"}
        }
    ],
    "filename": "city_interactive.html",
    "title": "City Infrastructure Map",
    "basemap": "CartoDB positron",
    "show_grid": true,
    "add_legend": true,
    "add_minimap": true
}
```

## 🔮 Planned Features

- Implement advanced spatial indexing
- Implement network analysis capabilities
- Add support for 3D geometries
- Implement performance optimizations
- Add support for more GIS libraries

## 🤝 Feedback and support

GeoEDGE-MCP is proprietary software and does not accept external pull requests.

- **Bugs, feature requests and support:** geoedge.au@gmail.com
- **Licensing and billing:** [mcp.geoedge.com.au](https://mcp.geoedge.com.au)

If you are looking to contribute to open-source GIS MCP tooling, the upstream
[`gis-mcp`](https://github.com/mahdin75/gis-mcp) project (MIT) welcomes contributions.

## 🔒 Privacy Policy

GeoEDGE-MCP collects only what is needed to validate your subscription — a
random device identifier and your licence key's activation history — never your
GIS data, your files, or your conversation content. Your tool-call history is
written to your own storage folder and is never transmitted to us. When a tool
fetches data on your behalf, that request goes directly from your machine to the
service you pointed it at.

Full policy: **<https://mcp.geoedge.com.au/privacy>**

## 📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

## 🔗 Related Projects

| Project Name                                                                                        | Category                   | Description                                                                                                   |
| --------------------------------------------------------------------------------------------------- | -------------------------- | ------------------------------------------------------------------------------------------------------------- |
| [Model Context Protocol](https://github.com/modelcontextprotocol/modelcontextprotocol)              | MCP Related                | The core MCP Specification                                                                                    |
| [FastMCP](https://github.com/jlowin/fastmcp)                                                        | MCP Related                | The fast, Pythonic way to build MCP servers and clients                                                       |
| [Shapely](https://github.com/shapely/shapely)                                                       | Geospatial Analysis        | Python package for manipulation and analysis of geometric objects                                             |
| [PyProj](https://github.com/pyproj4/pyproj)                                                         | Geospatial Analysis        | Python interface to PROJ library                                                                              |
| [GeoPandas](https://github.com/geopandas/geopandas)                                                 | Geospatial Analysis        | Python package for working with geospatial data                                                               |
| [Rasterio](https://github.com/rasterio/rasterio)                                                    | Geospatial Analysis        | Python package for reading and writing geospatial raster data                                                 |
| [Fiona](https://github.com/Toblerity/Fiona)                                                         | Geospatial Analysis        | Python interface to OGR library for reading and writing vector geospatial data formats                        |
| [PySAL](https://github.com/pysal/pysal)                                                             | Geospatial Analysis        | Python spatial analysis library for geospatial data science                                                   |
| [Folium](https://github.com/python-visualization/folium)                                            | Visualization              | Python library for creating interactive web maps using Leaflet.js                                             |
| [PyDeck](https://github.com/visgl/deck.gl)                                                          | Visualization              | Python library for creating advanced 3D visualizations and interactive maps                                   |
| [Matplotlib](https://github.com/matplotlib/matplotlib)                                              | Visualization              | Python plotting library for creating static maps and visualizations                                           |
| [cdsapi](https://github.com/ecmwf/cdsapi)                                                           | Geospatial Data Collecting | Python API to access the Copernicus Climate Data Store (CDS)                                                  |
| [pygadm](https://github.com/12rambau/pygadm)                                                        | Geospatial Data Collecting | Easy access to administrative boundary defined by GADM from Python scripts                                    |
| [pygbif](https://github.com/gbif/pygbif)                                                            | Geospatial Data Collecting | Python client for the GBIF API (ecology and biodiversity data)                                                |
| [OSMnx](https://osmnx.readthedocs.io/en/stable/)                                                    | Geospatial Data Collecting | Python package for downloading, modeling, and analyzing street networks and urban features from OpenStreetMap |
| [pystac-client](https://github.com/stac-utils/pystac-client)                                        | Geospatial Data Collecting | Python client for STAC catalogs; search and access spatiotemporal assets                                      |
| [Planetary Computer SDK for Python](https://github.com/microsoft/planetary-computer-sdk-for-python) | Geospatial Data Collecting | Python SDK for Microsoft Planetary Computer; auth and helpers for STAC/COGs                                   |

## 🔗 Related MCP Servers

| Server Name                                                 | Description                                                                                       |
| ----------------------------------------------------------- | ------------------------------------------------------------------------------------------------- |
| [GeoServer MCP](https://github.com/mahdin75/geoserver-mcp/) | A Model Context Protocol (MCP) server implementation that connects LLMs to the GeoServer REST API |

## 📞 Support

For support, please open an issue in the GitHub repository.

## 💬 Community

Join our Discord community for discussions, updates, and support:

[![Join our Discord](https://img.shields.io/badge/Discord-Join%20our%20community-7289DA?style=for-the-badge&logo=discord&logoColor=white)](https://discord.gg/SeVmVhVbk)

## 👥 Contributors

<a href="https://github.com/GeoEDGE-git/geoedge-mcp/graphs/contributors">
  <img src="https://contrib.rocks/image?repo=GeoEDGE-git/geoedge-mcp" />
</a>

Made with [contrib.rocks](https://contrib.rocks).

<br/>

## 🏆 Badges

<div align="center">

[![PyPI version](https://img.shields.io/pypi/v/geoedge-mcp.svg)](https://pypi.org/project/geoedge-mcp/)
[![PyPI downloads](https://img.shields.io/pypi/dm/geoedge-mcp.svg)](https://pypi.org/project/geoedge-mcp/)
<br/></br>

[![Trust Score](https://archestra.ai/mcp-catalog/api/badge/quality/GeoEDGE-git/geoedge-mcp)](https://archestra.ai/mcp-catalog/GeoEDGE-git__geoedge-mcp)
<br/></br>

  <a href="https://glama.ai/mcp/servers/@GeoEDGE-git/geoedge-mcp">
    <img width="380" height="200" src="https://glama.ai/mcp/servers/@GeoEDGE-git/geoedge-mcp/badge" alt="GeoEDGE-MCP" />
  </a>
  <br/><br/><br/>
  
</div>
