Skip to main content
Glama
weather

weather

by qurioskill

mcp-python

A Model Context Protocol (MCP) server that exposes US weather data — via the National Weather Service API — as tools, resources, and prompts for MCP-compatible clients like Claude Desktop.

Features

Tools

  • get_alerts(state) — active weather alerts for a two-letter US state code (e.g. CA, NY)

  • get_forecast(latitude, longitude) — forecast for the next 5 periods at a given location

Resources

  • weather://states — list of valid two-letter US state codes

  • weather://alerts/{state} — alerts for any state, as a readable resource

  • Static alert resources for CA, NY, TX, FL (so they're attachable from Claude Desktop's picker, which only lists static resources)

Prompts

  • weather_briefing(state) — concise severe weather briefing for a state

  • trip_packing_advice(latitude, longitude) — packing advice based on the forecast for a location

Related MCP server: Context Weather

Requirements

  • Python >= 3.11

  • uv

Setup

uv sync

Running the server

uv run weather.py

The server communicates over stdio, so it's meant to be launched by an MCP client rather than run standalone.

Using with Claude Desktop

Add to your Claude Desktop config (claude_desktop_config.json):

{
  "mcpServers": {
    "weather": {
      "command": "uv",
      "args": [
        "--directory",
        "/absolute/path/to/mcp-python",
        "run",
        "weather.py"
      ]
    }
  }
}

Restart Claude Desktop and the weather tools, resources, and prompts will be available.

Project structure

  • weather.py — the MCP server (tools, resources, prompts)

  • main.py — placeholder entrypoint from the project template

  • pyproject.toml / uv.lock — dependencies, managed with uv

Available Tools

2 tools
get_alertsB

Get weather alerts for a US state.

Args:
    state: Two-letter US state code (e.g. CA, NY)

Inputs: state (required). Returns: result

get_forecastC

Get weather forecast for a location.

Args:
    latitude: Latitude of the location
    longitude: Longitude of the location

Inputs: latitude (required), longitude (required). Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.9/5.0

    Scored across 2 tools

    Disambiguation5/5

    The two tools are clearly distinct: get_alerts handles weather alerts for a US state, while get_forecast provides forecasts for specific coordinates. There is no ambiguity about which tool to use for which purpose.

    Naming Consistency5/5

    Both tools follow a consistent verb_noun pattern (get_alerts, get_forecast) using the same verb 'get' and snake_case convention. The naming is perfectly consistent.

    Tool Count2/5

    With only 2 tools for a weather domain, the surface feels very thin. Weather servers typically need additional operations like current conditions, radar, air quality, or reverse geocoding to be genuinely useful.

    Completeness2/5

    The domain of weather covers more than alerts and forecasts. There are notable gaps: no current conditions, no historical data, no multi-day/hourly breakdown details, and no reverse geocoding for the coordinate-based forecast.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers