Skip to main content
Glama
KNMI Weather MCP

KNMI Weather MCP

by wolkwork

KNMI天気MCP

KNMI(オランダ王立気象研究所)の気象観測所からリアルタイムの気象データを提供するFastMCPサーバー。このアプリケーションは、オランダ国内の任意の場所に最も近い気象観測所から最新の10分間の測定値を取得します。

特徴

  • オランダのあらゆる場所の天気データを入手

  • 最寄りのKNMI気象観測所を自動的に検索します

  • 以下を含むリアルタイム測定を提供します:

    • 温度

    • 湿度

    • 風速と風向

    • 降水量

    • 可視性

    • 空気圧

  • 気象状況の自然言語解釈

  • 場所検索機能

  • 詳細なログ記録

Related MCP server: mcp-server-weather-cuhksz

前提条件

インストール

  1. リポジトリをクローンします。

    git clone <repository-url>
    cd knmi-mcp
  2. プロジェクト ルートに.envファイルを作成します。

    KNMI_API_KEY=your_api_key_here

サーバーの実行

クロードAIの使用

このアプリケーションを Claude AI で使用するには、プロジェクトのフォルダーで次のコマンドを実行します。

uv run fastmcp install src/knmi_weather_mcp/server.py

これにより、Claude 構成ファイル (通常は~/Library/Application Support/Claude/claude_desktop_config.jsonにあります) に次の構成が追加されます。

{
    "KNMI Weather": {
      "command": "uv",
      "args": [
        "run",
        "--with",
        "fastmcp",
        "--with",
        "httpx",
        "--with",
        "netCDF4",
        "--with",
        "numpy",
        "--with",
        "pandas",
        "--with",
        "pydantic",
        "--with",
        "python-dotenv",
        "--with",
        "xarray",
        "fastmcp",
        "run",
        "/Users/<username>/<git location>/knmi-mcp/src/knmi_weather_mcp/server.py"
      ]
    }
}

注: 次のようなエラーが表示された場合:

spawn uv ENOENT

uvコマンドをuvコマンドのフルパスに置き換えます。*nix システムでは、 which uvコマンドで確認できます。

手動実行

開発またはスタンドアロン使用の場合:

uv run fastmcp run src/knmi_weather_mcp/server.py

利用可能なツール

1. の天気はどうですか

オランダのあらゆる場所の現在の気象状況を自然言語で解釈します。

例:

await what_is_the_weather_like_in("Amsterdam")

2. get_location_weather

特定の場所の生の天気データを取得します。

例:

await get_location_weather("Rotterdam")

3. 検索場所

オランダの場所を検索します。

例:

await search_location("Utrecht")

4. 最寄り駅を取得する

指定された座標に最も近い KNMI 気象観測所を見つけます。

例:

await get_nearest_station(52.3676, 4.9041)

ログ記録

アプリケーション ログはlogs/knmi_weather.logファイルに保存され、次の詳細情報が提供されます。

  • APIリクエストとレスポンス

  • 気象データ処理

  • エラーメッセージ

  • デバッグ情報

データソース

このアプリケーションは、KNMI データ プラットフォーム API を使用して、「Actuele10mindataKNMIstations」データセットからデータを取得します。このデータセットは、オランダのすべての KNMI 気象観測所からの 10 分間隔の測定値を提供します。

エラー処理

アプリケーションには、次の堅牢なエラー処理が含まれています。

  • 無効な場所

  • API認証の問題

  • ネットワークの問題

  • データ解析エラー

  • 測定値が不足しています

Available Tools

4 tools
get_location_weatherC

Get current weather data for a location

Inputs: location (required).

get_nearest_stationB
Find the nearest KNMI weather station to given coordinates

Args:
    latitude: Latitude in degrees
    longitude: Longitude in degrees

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

search_locationC
Search for locations in the Netherlands

Args:
    query: Search term for location

Inputs: query (required).

what_is_the_weather_like_inB
Get and interpret weather data for a location in the Netherlands

Args:
    location: City or place name in the Netherlands
Returns:
    A natural language interpretation of the current weather conditions

Inputs: location (required).

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    B3/5.0

    Scored across 4 tools

    Disambiguation4/5

    Tools are mostly distinct: search_location and get_nearest_station are clearly supporting, but get_location_weather and what_is_the_weather_like_in both provide current weather, albeit in different formats (data vs. natural language). This overlap could cause misselection.

    Naming Consistency3/5

    Three tools follow verb_noun pattern (get_location_weather, get_nearest_station, search_location), but what_is_the_weather_like_in deviates entirely into a conversational question, breaking consistency.

    Tool Count5/5

    With 4 tools, the server is well-scoped for a focused weather service covering location search, station lookup, and current conditions. Each tool serves a clear purpose without being excessive.

    Completeness3/5

    The tool set covers location search and current weather but lacks forecast, historical data, or station metadata. The domain of weather for the Netherlands has notable gaps that could hinder some agent tasks.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      An MCP server that provides real-time weather data, hourly forecasts, and daily summaries using the free Open-Meteo API with no API key required. It enables users to search for weather conditions by specific coordinates or city names across multiple measurement units.
      2
      MIT