@amap/amap-maps-mcp-server
接入配置
选择客户端,复制配置,再按项目文档补齐环境变量。
claude mcp add zxypro1 --env AMAP_MAPS_API_KEY='<AMAP_MAPS_API_KEY>' -- npx -y @amap/amap-maps-mcp-server~/.codex/config.toml
[mcp_servers.zxypro1]
command = "npx"
args = ["-y", "@amap/amap-maps-mcp-server"]
env = { AMAP_MAPS_API_KEY = "<AMAP_MAPS_API_KEY>" }
# codex mcp add zxypro1 --env AMAP_MAPS_API_KEY='<AMAP_MAPS_API_KEY>' -- npx -y @amap/amap-maps-mcp-server~/.cursor/mcp.json
{
"mcpServers": {
"zxypro1": {
"command": "npx",
"args": [
"-y",
"@amap/amap-maps-mcp-server"
],
"env": {
"AMAP_MAPS_API_KEY": "<AMAP_MAPS_API_KEY>"
}
}
}
}.vscode/mcp.json
{
"servers": {
"zxypro1": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@amap/amap-maps-mcp-server"
],
"env": {
"AMAP_MAPS_API_KEY": "<AMAP_MAPS_API_KEY>"
}
}
}
}~/.gemini/settings.json
{
"mcpServers": {
"zxypro1": {
"command": "npx",
"args": [
"-y",
"@amap/amap-maps-mcp-server"
],
"env": {
"AMAP_MAPS_API_KEY": "<AMAP_MAPS_API_KEY>"
}
}
}
}claude_desktop_config.json
{
"mcpServers": {
"zxypro1": {
"command": "npx",
"args": [
"-y",
"@amap/amap-maps-mcp-server"
],
"env": {
"AMAP_MAPS_API_KEY": "<AMAP_MAPS_API_KEY>"
}
}
}
}.trae/mcp.json
{
"mcpServers": {
"zxypro1": {
"command": "npx",
"args": [
"-y",
"@amap/amap-maps-mcp-server"
],
"env": {
"AMAP_MAPS_API_KEY": "<AMAP_MAPS_API_KEY>"
}
}
}
}需要的环境变量
AMAP_MAPS_API_KEY
把占位值换成你自己的密钥;不要把密钥提交到代码仓库。