Skip to main content
Glama
Sam-uvas

Weather Prediction MCP Server

by Sam-uvas

Weather Prediction MCP Server + Agent

Overview

This project implements a Weather Prediction MCP Server using FastMCP and integrates it with a Databricks Agent Bricks agent. The agent answers natural language weather questions by invoking external MCP tools that retrieve live weather data from the Open-Meteo API.

Related MCP server: Weather MCP Server

Weather API

  • API: Open-Meteo

  • Authentication: No API key required

MCP Tools

get_current_weather(location)

Returns the current weather conditions for a specified location.

get_forecast(location, days)

Returns a multi-day weather forecast.

predict_umbrella_needed(location)

Provides an umbrella recommendation based on the forecast precipitation probability.

System Prompt

You are a weather assistant that answers weather-related questions using the available MCP weather tools.

Use:
- get_current_weather() for current weather.
- get_forecast() for weather forecasts.
- predict_umbrella_needed() for weather recommendations.

Always use the appropriate tool before responding.
Never guess weather information.
If a location cannot be resolved or a tool fails, explain the issue instead of making assumptions.

Setup

Install dependencies:

pip install -r requirements.txt

Run the server:

python weather_mcp_server.py

Project Files

weather_mcp_server.py
weather_adapter.py
requirements.txt
app.yaml
README.md

Example Questions

  • What is the current weather in Johannesburg?

  • Give me a 7-day weather forecast for Hendrina.

  • Should I bring an umbrella to Durban tomorrow?

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    B
    maintenance
    Provides weather data including current conditions, forecasts, and summaries via Open-Meteo with no API key required, enabling natural language queries through an MCP interface.
    MIT
  • F
    license
    Not graded
    quality
    C
    maintenance
    Provides real-time weather forecasts, current conditions, and smart umbrella recommendations through MCP tools, backed by the Open-Meteo API.
    -