Creating-Weather-MCP-Server

Creating-Weather-MCP-Server

0

The Weather MCP Server implements a Model Context Protocol server to provide weather alerts for US states. It utilizes the National Weather Service API and offers features like Docker containerization, LLM-powered clients, and integration with various development environments.

Weather MCP Server

A Model Context Protocol (MCP) server providing weather alerts for US states, showcasing tools, Docker integration, and LLM-powered clients.

Features

  • Weather alerts using the National Weather Service API
  • Support for stdio and SSE transport
  • Docker containerization
  • Integration with Claude Desktop and Cursor IDE
  • LLM-powered CLI client using Groq
  • Built-in conversation memory support

Installation

Local Setup

  1. Clone the repository
  2. Install dependencies

Docker Setup

Pull the image or build locally.

Usage

Running the Server

  • Local: Use weather.py
  • Docker: Use pre-built Docker image

Client Examples

  • CLI client with LLM Integration
  • Standard I/O Client
  • SSE Client

Available Tools

get_alerts

Retrieve weather alerts for a US state by entering its code.

Integration with Claude Desktop

Install the server and optionally specify a custom name.

Development

Prerequisites

  • Python 3.11 or higher
  • Docker (optional)

Environment Variables

Create a .env file with the GROQ_API_KEY.

Documentation

  • Model Context Protocol SDK Documentation
  • MCP Use Documentation

Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Open a Pull Request

License

MIT License.

Acknowledgments

Model Context Protocol team, National Weather Service API, Groq LLM API.