HeFeng Weather MCP Server
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@HeFeng Weather MCP Server what's the weather in Shanghai this weekend?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Wttr.in MCP Server
一个基于 Model Context Protocol (MCP) 的天气服务器,通过 wttr.in 免费天气 API 提供天气查询和日期时间查询功能。
A Model Context Protocol server that provides weather forecast and datetime query features through the free wttr.in weather API.
功能特性 / Features
获取实时天气数据 / Get real-time weather data
获取三天天气预报 / Get 3-day weather forecast
支持多种位置格式(城市名、邮政编码、经纬度坐标)/ Support multiple location formats (city name, postal code, coordinates)
获取当前日期时间(支持自定义时区)/ Get current date and time (with timezone support)
完整的中文天气描述 / Full Chinese weather description
Related MCP server: Hefeng QWeather MCP Server
工具说明 / API Tools
此 MCP 服务器提供以下两个工具:
get_weather_wttr
获取指定地点的天气预报数据。
参数 / Parameters:
location(必填): 需要查询的城市名称、邮政编码或经纬度坐标示例:
'beijing','90210','40.71,-74.00'
days(可选): 预报类型,默认为'3d''now'- 获取实时天气'3d'- 获取三天天气预报
返回内容:
实时天气:温度、体感温度、风速、风向、湿度、气压、紫外线指数
三天预报:每日最高/最低温、平均温度、日出日落时间、降水概率等
get_datetime
获取当前日期和时间。
参数 / Parameters:
timezone(可选): 时区,默认为'Asia/Shanghai'示例:
'America/New_York','Europe/London'
返回内容:
指定时区的当前日期和时间
使用方法 / Usage with MCP Host
在 Claude Desktop 中使用 / With Claude Desktop
将以下配置添加到 claude_desktop_config.json:
{
"mcpServers": {
"wttr-mcp-server": {
"command": "npx",
"args": ["wttr-mcp-server@latest"]
}
}
}本地开发 / Local Development
# 安装依赖
npm install
# 构建项目
npm run build
# 在配置文件中使用本地路径
{
"mcpServers": {
"wttr-mcp-server": {
"command": "node",
"args": ["/path/to/wttr-mcp-server/dist/index.js"]
}
}
}技术栈 / Tech Stack
TypeScript
Model Context Protocol SDK
Zod (参数验证)
wttr.in API (免费天气服务)
许可证 / License
ISC
Available Tools
3 toolsget_datetimeB
获取当前的日期和时间。可以提供一个可选的时区参数,默认为 'Asia/Shanghai'。
Inputs: timezone.
get_location_idC
根据城市名称(拼音/英文)、经纬度、LocationID或Adcode获取其精确的位置ID和详细地理信息。
Inputs: city_name (required).
get_weatherC
获取指定地点的天气预报。请提供LocationID或经纬度坐标。
Inputs: location (required), days.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose: get_datetime retrieves time data, get_location_id finds location identifiers, and get_weather fetches weather forecasts. There is no overlap in functionality, and an agent can easily distinguish between them based on their specific objectives.
All tool names follow a consistent verb_noun pattern with 'get_' prefix: get_datetime, get_location_id, and get_weather. This uniformity makes the set predictable and easy to understand, adhering to a clear naming convention throughout.
With only 3 tools, the set feels thin for a weather server, as it lacks operations like historical weather data, alerts, or air quality. While the core functions are present, the scope is minimal and may limit agent capabilities in more complex scenarios.
The tools cover basic weather retrieval (get_weather) and location lookup (get_location_id), but there are notable gaps such as missing update/delete operations, historical data access, or weather alerts. The surface is functional for simple queries but incomplete for comprehensive weather domain coverage.
Maintenance
Related MCP Connectors
MCP server for China weather: current conditions and multi-day forecast by city name or adcode.
MCP server for current weather and multi-day forecasts worldwide, Chinese city names and output.
China MCP gateway hosting HTTP APIs for Doubao/Tongyi/Wenxin/Claude; weather, currency, holiday.
Global weather via Open-Meteo: forecast, historical, marine, air quality, geocoding, elevation.
Related MCP Servers
- AlicenseBqualityDmaintenanceProvides weather forecast data for locations in China using the HeFeng Weather API, with real-time, hourly, or daily forecasts and location-based queries.169 npm10ISC
- AlicenseNot gradedqualityCmaintenanceProvides comprehensive weather data including forecasts, air quality, weather alerts, historical data, and astronomical information through the Hefeng Weather API. Supports real-time weather, multi-day forecasts, hourly predictions, and specialized data like sunrise/sunset times and precipitation forecasts.32 PyPI4MIT
- AlicenseNot gradedqualityDmaintenanceEnables querying weather forecasts (1-7 days) and meteorological warnings for Chinese cities using the QWeather API. Supports detailed weather data including temperature, humidity, wind, precipitation, UV index, and real-time weather alerts.2MIT
- AlicenseBqualityDmaintenanceProvides Chinese city weather query and forecast functionality using Juhe Weather API.26 npmMIT