Weather MCP Server

Weather MCP Server

Enables users to get real-time weather alerts for US states and echo messages through both MCP server tools and a modern web interface. Provides weather information access with multiple deployment options for different use cases.

Category
Visit Server

README

Weather MCP Server

A powerful weather information server built with FastMCP that provides weather alerts and tools through multiple interfaces.

Features

  • 🌤️ Weather Alerts: Get real-time weather alerts for any US state
  • 🔊 Echo Resource: Simple message echoing functionality
  • 🖥️ Multiple Interfaces: Choose between MCP server or web interface
  • 🎨 Beautiful UI: Modern, responsive web interface

Quick Start

Option 1: Interactive Launcher (Recommended)

python run_server.py

This will present you with options to run either the MCP server or web interface.

Option 2: Direct Web Interface

python server/web_interface.py

Then open your browser to: http://localhost:8000

Option 3: MCP Server Only

python main.py

Installation

  1. Install dependencies:

    uv sync
    
  2. Run the server:

    python run_server.py
    

Usage

Web Interface

  1. Start the web interface
  2. Open http://localhost:8000 in your browser
  3. Use the forms to:
    • Get weather alerts for a US state (e.g., CA, NY, TX)
    • Echo messages through the resource system

MCP Server

The MCP server provides these tools:

  • get_alerts(state): Get weather alerts for a US state

    • state: Two-letter US state code (e.g., "CA", "NY")
  • echo_resource(message): Echo a message as a resource

    • message: Any text message to echo

API Endpoints

  • GET /: Main web interface
  • POST /api/alerts: Get weather alerts (form data: state)
  • POST /api/echo: Echo a message (form data: message)

Dependencies

  • mcp[cli]>=1.13.0: MCP server framework
  • fastapi>=0.104.0: Web framework
  • uvicorn[standard]>=0.24.0: ASGI server
  • httpx>=0.25.0: HTTP client
  • python-multipart>=0.0.6: Form data handling

Project Structure

secondproject/
├── main.py                 # MCP server entry point
├── run_server.py          # Interactive launcher
├── server/
│   ├── weather.py         # MCP server implementation
│   └── web_interface.py   # Web interface
├── pyproject.toml         # Project configuration
└── README.md              # This file

Troubleshooting

Common Issues

  1. Port already in use: Change the port in web_interface.py or stop other services
  2. Dependencies missing: Run uv sync to install all dependencies
  3. API errors: Check your internet connection for weather data

Getting Help

  • Check the console output for error messages
  • Ensure all dependencies are installed
  • Verify Python version (requires 3.12+)

License

This project is open source and available under the MIT License.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured