天气数据服务器

Weather MCP Server 是一个基于Bun运行时和TypeScript构建的服务器,通过Model Context Protocol (MCP)为Claude Desktop或其他LLM工具提供实时天气数据。

  • by MehmetAkifEmre
  • TypeScript
  • 本地部署
  • 更新于
在 GitHub 查看 MehmetAkifEmre/weather-mcp-server

使用说明

气象MCP服务器🌤️

该项目是一个为Claude Desktop或其他LLM工具提供实时天气数据的服务器,使用 模型上下文协议(MCP)。它是使用 包子 运行时和 TypeScript.

🚀 安装

  1. 克隆存储库:

    git clone [https://github.com/MehmetAkifEmre/weather-mcp-server.git](https://github.com/MehmetAkifEmre/weather-mcp-server.git)
    cd weather-mcp-server
    
    
  2. 安装依赖项:

    bun install
    
  3. 重要提示:打开index.ts文件并将您自己的OpenWeatherMap API密钥粘贴到API_key变量中。(出于安全原因,提供的占位符密钥无效)

⚡ 用法

要使用MCP检查器测试服务器,请执行以下操作:

npx @modelcontextprotocol/inspector bun index.ts

🛠️ 技术

Runtime: Bun

Language: TypeScript

Protocol: Model Context Protocol (MCP) SDK

Validation: Zod

API: OpenWeatherMap

中等 https://medium.com/@mehmetakifemre/桥接llms和实时数据构建天气mcp服务器-带bun-eaf9b366d599