Skip to main content
Glama

🌦️ Weather Israel MCP

Proyecto MCP (Model Context Protocol) que permite al LLM obtener el pronóstico del tiempo para ciudades de Israel — directamente desde el navegador, sin API, mediante Playwright.


🎯 Objetivo del proyecto

En lugar de depender de una API integrada, el agente abre un navegador Chrome, navega al sitio weather2day.co.il, busca una ciudad, la selecciona de la lista — y luego lee el contenido de la página y proporciona un pronóstico completo.


Related MCP server: Israeli Weather MCP

🛠️ Stack tecnológico

Herramienta

Función

MCP SDK

Definición de Tools y ejecución del servidor MCP

Playwright

Control del navegador — navegación, escritura, clic

OpenAI API

Modelo de lenguaje que gestiona la conversación

uv

Gestión del entorno y dependencias


📁 Estructura del proyecto

project-template/
├── client.py          # MCP Client גנרי — מתחבר לשרתי MCP
├── host.py            # צ'אט טרמינל שמחבר את הכל יחד
├── weather_USA.py     # MCP Server לתחזית ארה"ב (דרך NWS API)
├── weather_Israel.py  # MCP Server לתחזית ישראל (דרך Playwright)
├── .env               # מפתח API (לא מועלה ל-Git)
└── pyproject.toml     # תלויות הפרויקט

🚀 Ejecución del proyecto

1. Instalación de dependencias

uv sync

2. Instalación del navegador Chrome para Playwright

uv run playwright install chromium

3. Configuración de la clave API

Crea un archivo .env en la carpeta:

OPENAI_API_KEY=your_openai_api_key_here

4. Ejecución

uv run host.py

💬 Ejemplos de preguntas

Query: what is the weather in Jerusalem?
Query: מה התחזית לתל אביב?
Query: האם גשום היום בחיפה?
Query: what is the weather forecast for Bnei Brak?
Query: what are the weather alerts in NY?
Query: what is the forecast for latitude 40.7, longitude -74.0?

🧩 Las Tools de weather_Israel MCP

Tool

Descripción

open_weather_forecast_israel

Abre el navegador y navega al sitio del clima

enter_weather_forecast_city_israel

Escribe el nombre de una ciudad en el campo de búsqueda

select_weather_forecast_city_israel

Selecciona la ciudad adecuada de la lista desplegable

extract_weather_data_from_page

Lee el contenido de la página y devuelve el pronóstico al LLM (RAG)


🧩 Las Tools de weather_USA MCP

Tool

Descripción

get_alerts_in_USA

Devuelve alertas meteorológicas según el código de estado (p. ej. CA, NY)

get_forecast_in_USA

Devuelve el pronóstico según coordenadas geográficas

Available Tools

4 tools
enter_weather_forecast_city_israelC

הזנת שם העיר בשדה החיפוש.

Inputs: city_name (required).

extract_weather_data_from_pageA

מחלץ את תוכן הטקסט מהדף הנוכחי כדי שה-LLM יוכל לקרוא את התחזית. זהו שלב ה-RAG שמספק קונטקסט למודל.

Inputs: no named parameters.

open_weather_forecast_israelA

פתיחת האתר וניווט לדף התחזית.

Inputs: no named parameters.

select_weather_forecast_city_israelB

בחירת העיר מהרשימה הנפתחת.

Inputs: no named parameters.

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool represents a distinct step in a clear browser workflow: open the site, enter a city, select a city, and extract text. Even though enter and select both relate to city input, their descriptions clearly distinguish typing into a search field from choosing from a dropdown.

    Naming Consistency4/5

    All tool names use snake_case with a verb-noun structure, but the object naming is slightly inconsistent: three names end with 'city_israel' or 'israel', while the extract tool uses 'weather_data_from_page' and drops the location marker. Overall the pattern is readable and predictable.

    Tool Count5/5

    With only 4 tools, the server is tightly scoped to a single weather-forecast retrieval workflow. Each tool earns its place as a necessary step, and the count is well within the ideal range for a focused server.

    Completeness4/5

    The tools cover the core lifecycle of opening the forecast page, entering and selecting a city, and extracting the forecast text for the model. Minor gaps exist, such as no explicit retry, reset, or alternate navigation tool, but the primary user journey is fully supported.

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      C
      maintenance
      MCP server that lets users obtain current Israeli city weather forecasts. It uses Playwright to browse Weather2day, extract the forecast page, and feed the cleaned data back to the LLM for natural language responses.
      -
    • F
      license
      A
      quality
      D
      maintenance
      An MCP server that provides real-time weather data for Israel by automating browser searches via Playwright. It allows LLMs to get current forecasts for Israeli cities through natural language queries.
      4
      -
    • F
      license
      B
      quality
      D
      maintenance
      MCP server that enables LLMs to retrieve weather forecasts for Israeli cities by automating a browser with Playwright, and also provides US weather alerts and forecasts via NWS API.
      4
      -