weather-mcp-server
by MichealLewis
README.md
# Weather MCP Server
Real-time weather query MCP server based on the [HelloAgents](https://github.com/jjyaoao/HelloAgents) framework and [wttr.in](https://wttr.in).
## Features
- `get_weather` — current weather for a city (Chinese mapped names + English names)
- `list_supported_cities` — list built-in Chinese city mappings (80+)
- `get_server_info` — server metadata
## Quick start (local stdio)
```bash
pip install -r requirements.txt
MCP_TRANSPORT=stdio python server.py
```
Connect with HelloAgents:
```python
from hello_agents.tools import MCPTool
tool = MCPTool(
name="weather",
server_command=["python", "server.py"],
# set MCP_TRANSPORT=stdio in env when launching, or:
)
```
Or:
```python
import os
os.environ["MCP_TRANSPORT"] = "stdio"
from hello_agents.protocols import MCPClient
# MCPClient(["python", "server.py"])
```
## Docker / Smithery (HTTP on :8081)
```bash
docker build -t weather-mcp-server .
docker run --rm -p 8081:8081 weather-mcp-server
```
Endpoint: `http://localhost:8081/mcp`
## Publish to Smithery
1. Create a GitHub repo named `weather-mcp-server` under **MichealLewis**
2. Push this folder to the repo
3. Open [https://smithery.ai/](https://smithery.ai/), sign in with GitHub
4. Click **Publish Server** and paste:
`https://github.com/MichealLewis/weather-mcp-server`
## License
MIT
This server cannot be deployed
Maintenance
ActivitySlowing
ResponsivenessNo issues