AutoNavi (Amap) MCP server

Integrates with China's AutoNavi (Amap) mapping service to provide geocoding, reverse geocoding, place search, weather data, and multi-modal route planning for driving, walking, cycling, and public transit within China's geographic context.
Back to servers
Setup instructions
Provider
masx200
Release date
Aug 08, 2025
Language
Go
Stats
2 stars

AMap Maps MCP Server provides a Model Context Protocol server for the AMap Maps API, allowing you to integrate AMap's location-based services into compatible MCP clients like Cursor or Claude. It enables access to various location services including geocoding, routing, and POI search through a standardized protocol.

Installation

Prerequisites

Before setting up the AMap Maps MCP Server, you need to obtain an API key from AMap:

  1. Visit AMap developer platform
  2. Create a project and generate an API key

Setup with NPX

The simplest way to use the AMap Maps MCP Server is through NPX. Add the following configuration to your MCP client's settings:

{
  "mcpServers": {
    "amap-maps": {
      "command": "npx",
      "args": ["-y", "@masx200/amap-maps-mcp-server"],
      "env": {
        "AMAP_MAPS_API_KEY": "your-amap-api-key"
      }
    }
  }
}

Replace your-amap-api-key with the API key you obtained from the AMap developer platform.

Environment Variables

The AMap Maps MCP Server supports the following environment variables:

  • AMAP_MAPS_API_KEY: Your AMap API key (required)
  • HTTP_API_TOKEN: HTTP API access token (optional)
  • HTTP_API_PORT: HTTP server port number (optional, defaults to 3000)

Using the Server

Integration with Cursor

To use AMap Maps MCP Server with Cursor:

  1. Ensure you have the latest version of Cursor client
  2. Obtain your AMap API key from AMap's platform
  3. Add the configuration to Cursor's settings as shown in the installation section

Streamable-HTTP Protocol Server

The AMap Maps MCP Server can also run as a standalone streamable-HTTP protocol server:

Starting the Server Directly

node ./build/streamable-http.js

Configuring with Environment Variables

# Set port (default 3000)
export HTTP_API_PORT=3000

# Set access token (optional)
export HTTP_API_TOKEN=your-secret-token

# Set AMap API key
export AMAP_MAPS_API_KEY=your-amap-api-key

# Start the server
node ./build/streamable-http.js

Using the HTTP Server

Once started, the server runs at http://localhost:3000 and supports:

  • POST /mcp - MCP protocol communication endpoint
  • Streamable-HTTP protocol for real-time data streams

If you've set an HTTP_API_TOKEN, add the following header to your requests:

Authorization: Bearer your-secret-token

Features and Use Cases

Supported Services

The AMap Maps MCP Server provides access to various location-based services:

  • Geocoding (converting coordinates to addresses and vice versa)
  • Weather information
  • Distance measurement
  • Route planning for different transportation modes (walking, driving, public transit)
  • POI (points of interest) search based on keywords or location

Common Use Cases

  • Converting geographic coordinates to administrative addresses
  • Planning routes for cycling, walking, or driving
  • Searching for nearby points of interest based on specific criteria

Frequently Asked Questions

What types of location services does AMap Maps provide?

AMap Maps provides geocoding, weather information, distance measurement, and route planning for various transportation modes.

Is there a limit to the number of requests I can make?

The usage limits depend on your API key and the specific service being used. Please refer to the AMap documentation for details.

How do I obtain an API key?

You can obtain an API key by creating a project on the AMap developer platform.

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 "amap-maps" '{"command":"npx","args":["-y","@masx200/amap-maps-mcp-server"],"env":{"AMAP_MAPS_API_KEY":"\u60a8\u5728\u9ad8\u5fb7\u5b98\u7f51\u4e0a\u7533\u8bf7\u7684key"}}'

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": {
        "amap-maps": {
            "command": "npx",
            "args": [
                "-y",
                "@masx200/amap-maps-mcp-server"
            ],
            "env": {
                "AMAP_MAPS_API_KEY": "\u60a8\u5728\u9ad8\u5fb7\u5b98\u7f51\u4e0a\u7533\u8bf7\u7684key"
            }
        }
    }
}

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": {
        "amap-maps": {
            "command": "npx",
            "args": [
                "-y",
                "@masx200/amap-maps-mcp-server"
            ],
            "env": {
                "AMAP_MAPS_API_KEY": "\u60a8\u5728\u9ad8\u5fb7\u5b98\u7f51\u4e0a\u7533\u8bf7\u7684key"
            }
        }
    }
}

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