npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@duwenji/weather-mcp-server

v2.4.0

Published

MCP server providing real-time weather information for AI assistants like Claude and Cline

Readme

Weather MCP Server

MCP (Model Context Protocol) サーバーでAIアシスタント(Claude、Clineなど)に天気情報を提供するパッケージです。

🌟 特徴

  • リアルタイム天気情報: 指定した場所の現在の天気を取得
  • MCPプロトコル準拠: Claude、ClineなどのAIアシスタントとシームレスに連携
  • TypeScript実装: 型安全で信頼性の高いコードベース
  • 柔軟な設定: ダミーデータまたは実際の天気APIとの統合が可能
  • 軽量高速: 最小限の依存関係で高速なレスポンス

🚀 クイックスタート

インストール

npm install @duwenji/weather-mcp-server

Clineでの使用方法

  1. Clineの設定ファイルに追加:
{
  "weather-server": {
    "autoApprove": [],
    "disabled": false,
    "timeout": 60,
    "type": "stdio",
    "command": "npx",
    "args": [
      "-y",
      "@duwenji/weather-mcp-server"
    ],
    "env": {
      "OPENWEATHER_API_KEY": "your_api_key_here"
    }
  }
}
  1. Clineを再起動

  2. 天気情報を取得:

@weather-server get_weather location="東京"

または自然言語で:

東京の天気を教えてください

📋 提供されるツール

get_weather

指定した場所の現在の天気情報を取得します。

パラメータ:

  • location (必須): 都市名または場所(例: "Tokyo", "大阪", "New York")

使用例:

{
  "location": "Tokyo"
}

レスポンス例:

{
  "content": [
    {
      "type": "text",
      "text": "Weather in Tokyo: 25°C, 晴れ, 湿度: 65%, 風速: 5km/h"
    }
  ]
}

🛠️ 開発者向け

サーバー実行方法

# MCPサーバーとして実行
npx weather-mcp-server

# 開発モード(TypeScript直接実行)
npm run dev

# ビルド
npm run build

# 実行(ビルド後)
npm start

# クリーン(distディレクトリ削除)
npm run clean

依存関係のインストール

npm install

🔧 設定

環境変数を使用して設定をカスタマイズできます:

# 実際の天気APIを使用する場合
export OPENWEATHER_API_KEY=your_api_key

📊 使用例

Clineとの連携例

ユーザー: 東京の天気は?
Cline: @weather-server get_weather location="東京"
天気サーバー: Weather in Tokyo: 22°C, 曇り, 降水確率: 30%
Cline: 東京の天気は22度で曇り、降水確率は30%です。

複数都市の天気比較

ユーザー: 東京と大阪の天気を比較して
Cline: @weather-server get_weather location="東京"
天気サーバー: Weather in Tokyo: 25°C, 晴れ
Cline: @weather-server get_weather location="大阪"  
天気サーバー: Weather in Osaka: 26°C, 曇り
Cline: 東京は25度で晴れ、大阪は26度で曇りです。気温はほぼ同じですが、大阪は曇り空です。

🤝 貢献

バグレポート、機能リクエスト、プルリクエストは歓迎します!

  1. リポジトリをフォーク
  2. 機能ブランチを作成 (git checkout -b feature/amazing-feature)
  3. 変更をコミット (git commit -m 'Add amazing feature')
  4. ブランチにプッシュ (git push origin feature/amazing-feature)
  5. プルリクエストを作成

📄 ライセンス

このプロジェクトはMITライセンスの下で公開されています - 詳細はLICENSEファイルを参照してください。

🔗 関連リンク