Geoapify Map Generator MCP server

Generates map images from geographic coordinates using Python libraries for geocoding and visualization tasks.
Back to servers
Setup instructions
Provider
Kirk Kaiser
Release date
Jan 15, 2025
Language
Python
Stats
4 stars

This MCP server integrates with Geoapify to convert addresses to GPS coordinates and generate map images from the coordinates. It provides a simple interface for geocoding addresses and visualizing geographical data through Claude AI.

Installation Requirements

To use the Geoapify MCP server, you'll need to:

  1. Obtain an API key from Geoapify
  2. Set up the server in your Claude configuration

Setting Up Your API Key

Register for an API key from Geoapify and set it as an environment variable named GEO_APIKEY in your configuration.

Configuration Setup

Add the following entry to your claude_desktop_config.json file:

"MCP Map Demo": {
      "command": "uv",
      "args": [
        "--directory",
        "/PATH/TO/THIS/REPO",
        "run",
        "--with",
        "fastmcp",
        "--with",
        "requests",
        "--with",
        "folio",
        "--with",
        "selenium",
        "--with",
        "pillow",
        "fastmcp",
        "run",
        "/PATH/TO/THIS/REPO/server.py"
      ],
      "env": {
        "GEO_APIKEY": "YOURAPIKEY"
      }
    }

Make sure to:

  • Replace /PATH/TO/THIS/REPO with the actual path to the repository on your system
  • Replace YOURAPIKEY with your Geoapify API key

Using the Server

The MCP server provides two main tools:

Getting GPS Coordinates

Use the get_gps_coordinates tool to convert addresses into GPS coordinates in GeoJSON format.

Example:

can you create a geojson of the following locations including their gps coordinates:
179 avenue du Général Leclerc, côté Rive Gauche
158 avenue du Général Leclerc, côté Rive Droite à l'angle de la rue Jules Herbron
112 avenue du Général Leclerc, côté Rive Droite
...

This will return a GeoJSON file containing the coordinates of all provided addresses.

Creating Map Images

Use the create_map_from_geojson tool to generate a visual map from GeoJSON data.

Example:

can you create a map from my attached geojson file?

This will generate and display a map image with all the locations from your GeoJSON file plotted on it. Note that the map display feature currently only works on MacOS.

Workflow Example

A typical workflow might look like:

  1. Request GPS coordinates for addresses
  2. Receive the GeoJSON file with coordinates
  3. Ask Claude to create a map from the GeoJSON file
  4. View the resulting map image

This server makes it easy to quickly geocode addresses and visualize their locations on a map without leaving your Claude interface.

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "geoapify-map-generator" '{"command":"uv","args":["--directory","${workspaceRoot}","run","--with","fastmcp","--with","requests","--with","folio","--with","selenium","--with","pillow","fastmcp","run","${workspaceRoot}/server.py"],"env":{"GEO_APIKEY":""}}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "geoapify-map-generator": {
            "command": "uv",
            "args": [
                "--directory",
                "${workspaceRoot}",
                "run",
                "--with",
                "fastmcp",
                "--with",
                "requests",
                "--with",
                "folio",
                "--with",
                "selenium",
                "--with",
                "pillow",
                "fastmcp",
                "run",
                "${workspaceRoot}/server.py"
            ],
            "env": {
                "GEO_APIKEY": ""
            }
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "geoapify-map-generator": {
            "command": "uv",
            "args": [
                "--directory",
                "${workspaceRoot}",
                "run",
                "--with",
                "fastmcp",
                "--with",
                "requests",
                "--with",
                "folio",
                "--with",
                "selenium",
                "--with",
                "pillow",
                "fastmcp",
                "run",
                "${workspaceRoot}/server.py"
            ],
            "env": {
                "GEO_APIKEY": ""
            }
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later