weather-mcp-server
Verified Safeby ShaySarussiElshten
Overview
Provides current weather conditions and 5-day forecasts for any city using the OpenWeatherMap API via a Model Context Protocol (MCP) server.
Installation
python src/server.pyEnvironment Variables
- OPENWEATHER_API_KEY
Security Notes
The server correctly retrieves the API key from environment variables, preventing hardcoding in the main application logic. It uses `httpx` for secure asynchronous HTTP requests. Input parameters are handled as API request parameters, minimizing injection risks. Error handling is present. A minor note is that the `test_server.py` script hardcodes an API key, which is acceptable for a local test but would be a risk if included in a public configuration or production deployment.
Similar Servers
mcp-weather
A Model Context Protocol (MCP) server for retrieving weather alerts and forecasts for US locations using the National Weather Service (NWS) API.
mcp-weather-server
Standalone MCP server providing weather information, task management, and local document processing capabilities for an AI client.
weather-mcp-server
Provides live weather forecasts for any city in the world via a tool-enabled API, designed to be integrated with AI agents or LLMs.
mcp-server-weather
Provides real-time weather alerts and forecasts for specified US locations and states.