A Model Context Protocol (MCP) server that connects to the Open-Meteo API through either streamable-http (default) or sse. This server provides weather data to AI clients using the MCP interface.
The following configuration can be set with env variables:
| Env var | Default value | Description |
|---|---|---|
HOST |
0.0.0.0 |
Address to listen to. |
PORT |
8080 |
Port to listen on. |
TRANSPORT |
streamable-http |
Transport used by the mcp server. Must be streamable-httpor sse. |
It is recommended to use the provided Dockerimage, which requires only Docker to be installed.
If you want to install from source the following packages are required:
- Python 3.13
- uv
docker run -p 8080:8080 ghcr.io/melvinkl/mcp-weather/server:latest- Clone the repository
git clone https://github.com/MelvinKl/mcp-weather.git- Install the dependencies
uv sync --dev- Runs the server
uv run python src/main.pyTo run all tests with coverage:
make testThis will:
- Run all tests using pytest
- Check for linting issues with flake8
- Format code with black
- Generate coverage reports in HTML and XML formats
Test coverage is maintained at 100% for all source code (exceeds 80% requirement).
Apache 2
- Built with the Model Context Protocol
- Uses data from the OpenMeteo API