MCP Weather Server

by aditi-joshi-usc

258 downloads
Not rated
GitHub

Description

# MCP Weather Server A lightweight **TypeScript + Node.js** server built using the [Model Context Protocol (MCP)](https://modelcontextprotocol.org/) to provide **real-time weather alerts** and **forecast data** using the [National Weather Service…

About

# MCP Weather Server A lightweight **TypeScript + Node.js** server built using the [Model Context Protocol (MCP)](https://modelcontextprotocol.org/) to provide **real-time weather alerts** and **forecast data** using the [National Weather Service API](https://www.weather.gov/documentation/services-web-api). This is my…

Details

Author
aditi-joshi-usc
Downloads
258
Categories
Media

- get-alerts: Returns current weather alerts for a US state code.
- get-forecast: Returns detailed weather forecast for given coordinates.
- Built with TypeScript, Node.js, and the MCP SDK.
- Uses Zod for input schema validation.
- Integrates the National Weather Service API.
- Designed for use with Claude Desktop and Cursor.

Configure and run the server as an MCP tool. It exposes two functions, get-alerts (for a US state code) and get-forecast (for geographic coordinates), which can be invoked by MCP-compatible clients like Claude Desktop and Cursor.

MCP Weather Server

A lightweight TypeScript + Node.js server built using the Model Context Protocol (MCP) to provide real-time weather alerts and forecast data using the National Weather Service API.

This is my first MCP tool, integrated with Claude Desktop and Cursor, and designed to demonstrate how AI tools can consume external APIs via tool invocation.

---

Features

get-alerts

Returns current weather alerts for a given US state code (e.g., "CA" for California).

get-forecast

Returns a detailed weather forecast based on geographic coordinates (latitude, longitude).

---

🛠️ Tech Stack

| Technology | Usage |
|----------------|--------------------------------------|
| TypeScript | Type-safe development |
| Node.js | Backend runtime |
| MCP SDK | Tool communication with Claude/Cursor|
| Zod | Input schema validation |
| NWS API | External weather data |

---

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.