Weather API MCP Server
by yoyooyooo
A Model Context Protocol (MCP) server implementation for weather information, providing current weather data and forecasts using the 和风天气 (QWeather) API. It offers a simple way to integrate weather data into your MCP-based applications.
Last updated: N/A
What is Weather API MCP Server?
The Weather API MCP Server is a server that provides weather information using the Model Context Protocol (MCP). It integrates with the 和风天气 (QWeather) API to provide current weather data, forecasts, and city lookup functionalities.
How to use Weather API MCP Server?
To use the server, install it via npm or npx. Then, configure your MCP server to include the Weather API MCP Server. You can then call the provided weather tools (getWeather, getWeatherForecast, getHourlyWeather, lookupCity) through MCP with appropriate parameters like location and options (units, language, days, etc.). See the API Reference for details on the tool parameters and response formats.
Key features of Weather API MCP Server
Current Weather: Get current weather data for any location
Weather Forecast: Get 3-day to 30-day weather forecasts
Hourly Forecast: Get 24-hour weather forecasts
City Lookup: Look up city information and IDs for more precise weather data
Customizable Options: Configure units, language, and additional details
Powered by QWeather: Integrates with the 和风天气 (QWeather) API for accurate weather data
Use cases of Weather API MCP Server
Displaying current weather conditions in a user interface.
Providing weather forecasts for travel planning.
Integrating weather data into smart home applications.
Creating weather-aware applications for agriculture or outdoor activities.
FAQ from Weather API MCP Server
How do I specify the location?
How do I specify the location?
You can specify the location using a city name, coordinates (longitude,latitude), or a QWeather location ID.
How do I get a QWeather API key?
How do I get a QWeather API key?
You can obtain your own API key from the QWeather website: https://dev.qweather.com/.
What units are supported?
What units are supported?
The server supports both metric (Celsius) and imperial (Fahrenheit) units.
How do I configure the server?
How do I configure the server?
You can configure the server using environment variables or by setting the 'env' property in your MCP configuration.
Where can I find the list of Chinese city codes?
Where can I find the list of Chinese city codes?
The complete list of Chinese city codes can be found in the QWeather LocationList repository: https://github.com/qwd/LocationList/blob/master/China-City-List-latest.csv.