π€οΈ Weather Microservice with MCP + UV
LocalAbout π€οΈ Weather Microservice with MCP + UV
This project is a Python weather API service set up for MCP, using `uv` for dependency management and Docker for deployment. It is intended for local development and Claude Desktop integration, with secrets supplied through environment variables or `.env`.
Key features
- 01MCP server development with live reload
- 02Docker container deployment
- 03Claude Desktop integration setup
- 04Secrets from `.env` or environment variables
Use cases
- 01Develop an MCP service with live reload
- 02Run the service in a Docker container
- 03Connect the service to Claude Desktop
MCP support
It presents the weather API as an MCP server for MCP clients, including Claude Desktop. The README describes server development, installation, and execution, but does not specify the weather tools exposed.
Configuration
Local server config is the same for every client. Copy it into your clientβs MCP config file.
We havenβt collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMEπ€οΈ Weather Microservice with MCP + UV
A lightweight, MCP-powered weather API service using uv for Python dependency management and Docker for containerized deployment. Built for seamless local development, Claude Desktop integration, and scalable deployment.
π Features
- π§ͺ Fast local dev with live reload using
uvandmcp - π³ Dockerized for production or staging environments
- π§ Claude Desktop integration-ready
- π Loads secrets securely from
.envor environment variables
βοΈ Running Your Server
π§ͺ Development Mode (with MCP Inspector)
Start your server in development mode with hot reloading:
uv run mcp dev server.py
Add dependencies on-the-fly:
uv run mcp dev server.py --with pandas --with numpy
Mount your local code as editable:
uv run mcp dev server.py --with-editable .
π§ Claude Desktop Integration
Install your server to Claude Desktop:
uv run mcp install server.py
Custom name:
uv run mcp install server.py --name "My Analytics Server"
Inject environment variables:
uv run mcp install server.py -v API_KEY=abc123 -v DB_URL=postgres://...
uv run mcp install server.py -f .env
π§ Direct Execution
For more control or advanced deployments:
from mcp.server.fastmcp import FastMCP
mcp = FastMCP("My App")
if __name__ == "__main__":
mcp.run()
Run it manually:
uv run python server.py
# or
uv run mcp run server.py
π³ Docker Support
π¨ Build Image
docker build -t weather-service .
βΆοΈ Run Container
docker run --env-file .env -p 6274:6274 weather-service
π Project Structure
.
βββ server.py
βββ .env
βββ pyproject.toml
βββ uv.lock
βββ Dockerfile
βββ README.md
π Environment Variables
Create a .env file:
API_KEY=your_api_key_here
DB_URL=your_database_url_here
π¦ Dependency Management
Use uv to manage and sync dependencies:
uv pip install mcp
uv pip install pandas numpy
uv sync # sync dependencies based on uv.lock
π License
MIT License β use freely, modify responsibly.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.