天气 MCP 服务器
@qianyan
About 天气 MCP 服务器
这是一个基于 FastMCP 构建的天气查询 MCP 服务器
Basic information
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"weather-mcp-server": {
"command": "uvx",
"args": [
"weather-mcp-server"
],
"env": {
"OPENWEATHER_API_KEY": ""
}
}
}
}Tools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is 天气 MCP 服务器?
天气 MCP 服务器是一个基于 FastMCP 构建的天气查询服务器,提供全球城市天气信息查询服务。它返回温度、湿度和天气描述,并支持摄氏度和华氏度单位切换。适用于需要 AI 助手(如 Claude)通过自然语言获取天气数据的场景。
How to use 天气 MCP 服务器?
推荐使用 uvx 自动安装并运行,将配置添加到 Claude Desktop 的 claude_desktop_config.json 中,并设置 OPENWEATHER_API_KEY 环境变量。也可以克隆仓库通过本地开发模式运行。服务器提供 get_weather 工具,调用时传入城市名和可选的温度单位。
Key features of 天气 MCP 服务器
- 支持全球城市天气查询
- 提供温度、湿度和天气描述
- 支持摄氏度和华氏度温度单位切换
- 基于 Model Context Protocol (MCP) 实现
- 完整的日志记录
Use cases of 天气 MCP 服务器
- 通过自然语言询问任意城市的当前天气
- 将天气查询功能嵌入 Claude 等 MCP 客户端
- 基于天气数据开发智能助手技能
FAQ from 天气 MCP 服务器
运行需要哪些环境依赖?
需要 Python 3.8+、OpenWeatherMap API 密钥以及 uv 包管理工具。
如何配置 API 密钥?
在项目根目录创建 .env 文件并写入 OPENWEATHER_API_KEY=你的密钥,或在 Claude Desktop 配置文件的 env 字段中直接设置。
支持哪些温度单位?
支持两种单位:metric(摄氏度,默认)和 imperial(华氏度),通过 units 参数指定。
提供的 MCP 工具有哪些?
只有一个工具 get_weather,必填参数 city(城市名),可选参数 units(温度单位)。返回温度、湿度、天气描述和城市名。
Claude Desktop 的配置文件在哪里?
macOS:~/Library/Application Support/Claude/claude_desktop_config.json;Windows:%APPDATA%/Claude/claude_desktop_config.json。
More Media & Design MCP servers
MCP Google Map Server
cablateA powerful Model Context Protocol (MCP) server providing comprehensive Google Maps API integration with LLM processing capabilities.
Figma MCP Server
TimHoldenModel Context Protocol server implementation for Figma API
YouTube Transcript MCP Server
jkawamotoMCP server retrieving transcripts of YouTube videos
Framelink Figma MCP Server
GLipsMCP server to provide Figma layout information to AI coding agents like Cursor
NS Travel Information MCP Server
r-huijtsA Model Context Protocol (MCP) server that provides access to NS (Dutch Railways) travel information through Claude AI. This server enables Claude to fetch real-time train travel information and disruptions using the official Dutch NS API.
Comments