AI Weather MCP Server
Click on "Install 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., "@AI Weather MCP Serverwhat's the weather in Paris and suggest an outfit?"
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.
๐ฆ๏ธ AI Weather MCP Server
A production-grade Model Context Protocol (MCP) server that combines real-time weather data with LLM-powered reasoning to deliver intelligent weather insights instead of raw numbers.
Built to demonstrate production backend engineering, clean architecture, MCP development, external API integration, asynchronous programming, Dockerization, testing, and AI reasoning.
โจ Features
๐ค Weather Tools
Current Weather
Weather Forecast
Air Quality
UV Index
Sunrise & Sunset
Related MCP server: Ingrids Reisetjenester
๐ค AI Tools
Clothing Recommendation
Weather Summary
Travel Advice
Outdoor Activity Recommendation
AI Weather Advisory
The guiding principle is:
Weather APIs provide facts. The LLM provides reasoning.
The model never invents weather information.
๐ Architecture
MCP Client
โ
โผ
MCP Tools
โ
โผ
Services
โ
โผ
Clients
โโโ Weather APIs
โโโ LLM ProviderEach layer has a single responsibility.
๐ Project Structure
src/weather_mcp/
โโโ server.py
โโโ config.py
โโโ logging_config.py
โโโ exceptions.py
โโโ models/
โโโ clients/
โโโ services/
โโโ tools/๐ง Design Decisions
Two Weather Providers
The project combines OpenWeatherMap with Open-Meteo.
OpenWeatherMap supplies current weather, forecast and air-quality data.
Open-Meteo is used for UV Index because it remains free without requiring a paid One Call subscription.
AI Weather Advisory
get_weather_alerts() intentionally produces an AI-generated advisory.
It is not an official government weather warning.
Instead, the LLM reasons over forecast information to identify potentially concerning conditions such as:
Heavy rain
Strong winds
High temperatures
Thunderstorms
Swappable LLM
The LLM layer is isolated.
Changing from Groq to OpenAI only requires configuration rather than application changes.
โ๏ธ Installation
git clone <repository-url>
cd weather-mcp-server
python3 -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"๐ Configuration
Copy:
cp .env.example .envConfigure your API keys.
Variable | Description |
WEATHER_API_KEY | OpenWeatherMap key |
LLM_API_KEY | Groq/OpenAI key |
LLM_PROVIDER | groq/openai |
LLM_MODEL | Model name |
โถ Running
python3 -m weather_mcp.server๐ณ Docker
docker build -t weather-mcp-server .
docker run -i --env-file .env weather-mcp-serverPull the pre-built image directly:
```bash docker pull amankhan1009/weather-mcp-server:latest docker run -i --env-file .env amankhan1009/weather-mcp-server:latest ```
Or build it yourself:
```bash docker build -t weather-mcp-server . docker run -i --env-file .env weather-mcp-server ```
๐งช Testing
pytestThe suite uses mocked external services for deterministic tests.
๐ MCP Clients
Compatible with:
Claude Desktop
MCP Inspector
Any MCP-compatible client
๐ Future Improvements
Official severe weather alerts
Additional LLM providers
Response caching
Streaming responses
Structured JSON outputs
๐จโ๐ป Author
Md Aman Alam
LinkedIn: Md Aman Alam
If you found this project useful, consider giving it a โญ on GitHub.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Amankhan1009/weather-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server