Skip to main content
Glama
ariz-ahmad

weather-mcp-server

by ariz-ahmad

Weather MCP Server

An MCP server wrapping the Open-Meteo geocoding and forecast APIs. No API key required.

Install

pip install -r requirements.txt

Related MCP server: Weather MCP

Run

Stdio (default, for local agent clients):

python server.py

SSE (for remote/hosted clients):

python server.py sse
# serves on http://localhost:8000/sse

Tool reference

Tool

Args

Returns

geocode_city

city: str

{name, country, latitude, longitude}

get_forecast

latitude: float, longitude: float, days: int = 3

{forecast: [{date, condition, temp_max_c, temp_min_c, precipitation_mm}, ...]}

get_weather_by_city

city: str, days: int = 3

{location, forecast} — geocode + forecast in one call

Resource

weather://{city} — read-only current-conditions summary for a city, e.g. weather://Tokyo.

Prompt

weather_report(city: str) — template that asks an agent to produce a short, friendly 3-day weather report for a city using get_weather_by_city.

Connect from an Agents SDK client

from agents import Agent, Runner
from agents.mcp import MCPServerStdio, MCPServerStdioParams

async with MCPServerStdio(
    name="Weather Tools",
    params=MCPServerStdioParams(command="python", args=["server.py"]),
) as weather_server:
    agent = Agent(
        name="Weather Assistant",
        instructions="Use the weather tools to answer the user's question.",
        mcp_servers=[weather_server],
    )
    result = await Runner.run(agent, "What's the weather in Tokyo this week?")
    print(result.final_output)

See client_stdio_test.py and client_sse_test.py for full runnable examples of each transport.

A
license - permissive license
-
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ariz-ahmad/weather-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server