A Simple MCP Weather Server written in Go

May 16, 2026 ยท View on GitHub

See the Build an MCP server tutorial for more information.

Building

go build -o weather

Running

./weather

The server will communicate via stdio and expose two MCP tools:

  • get_forecast - Get weather forecast for a location (requires latitude and longitude)
  • get_alerts - Get weather alerts for a US state (requires two-letter state code)