Skip to main content
Glama

mcp-weather

世界中の天気を扱うMCPサーバーです。場所名を座標に変換し、CursorなどのMCPクライアントに対してstdio経由で現在の天気を返します。

リポジトリ: github.com/deep3036/mcp-weather

機能

このサーバーは1つのツールを登録します:

ツール

入力

出力

get-current-weather

location (都市名または場所名、2文字以上)

現在の気温、体感温度、湿度、降水量、風、天候、昼夜、タイムゾーン、座標

locationの例: Delhi、Greater Noida、Mumbai、London。

ジオコーディングには Open-Meteo Geocoding を使用します。予報データには Open-Meteo Forecast を使用します。どちらのAPIもこの用途ではキーは不要です。

名前が一致する場所が複数ある場合は、最初のジオコーディング結果が使用されます。

Related MCP server: Weather MCP

要件

  • Node.js 20以上

  • npm

セットアップ

npm install

実行

開発(tsxによるTypeScript):

npm run dev

本番:

npm run build
npm start

このプロセスはstdin/stdoutでMCPを話します。ログはstderrに出力されます。通常のWebアプリとして実行しないでください。

Cursor MCP 設定

クライアントをこのプロジェクトディレクトリに向けてください:

{
  "mcpServers": {
    "weather": {
      "command": "npx",
      "args": ["tsx", "src/index.ts"],
      "cwd": "D:\\mcp\\weather-mcp"
    }
  }
}

ビルド後は、tsxの代わりにnodeとdist/index.jsを使用できます。

プロジェクト構成

パス

役割

src/index.ts

MCPサーバー、ツール、Open-Meteo呼び出し

tsconfig.json

TypeScript(ES2022、NodeNext、srcからdist)

package.json

スクリプト: dev、build、start

ライセンス

ISC

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables users to get current weather information for any city using the Open-Meteo API. Provides detailed meteorological data including temperature, precipitation, day/night status, and hourly forecasts through natural language queries.
    ISC
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables users to get real-time weather information for any city in the world. Provides current temperature and weather conditions through a simple city name query.
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Provides current weather information for any city worldwide using the free Open-Meteo API, enabling users to query temperature, wind speed, humidity, and weather conditions through natural language.
    3 npm
    MIT