Simple Weather MCP Server example from Quickstart

Simple Weather MCP Server example from Quickstart

简易天气 MCP Server 示例

概述

此示例展示了一个简单的天气 MCP 服务器,详细说明请参考 MCP 快速入门

安装和构建

npm install
npm run build

Claude 桌面版配置

编辑配置文件:

cursor ~/Library/Application Support/Claude/claude_desktop_config.json

添加以下配置:

{
    "mcpServers": {
        "weather": {
            "command": "node",
            "args": [
                "/ABSOLUTE/PATH/TO/PARENT/FOLDER/weather/build/index.js"
            ]
        }
    }
}

注意:请将路径替换为您系统上的实际绝对路径。