韩国天气 MCP 服务器
该 MCP(多平台通信协议)服务器提供对韩国气象局 (KMA) API 的访问,允许 AI 代理检索韩国各地的天气预报信息。
概述
- 检索韩国行政区域的精确网格坐标
- 获取韩国任何地点的详细短期天气预报
- 支持韩国所有行政区划(市、区、街道)
- 针对 LLM 使用进行了优化的结构化文本响应
- 综合天气数据,包括温度、降水、天空状况、湿度、风向和风速
目录
设置
先决条件
- Python 3.12+
- 韩国气象局 API 凭证
- 您可以通过在公共数据门户注册并请求访问“기상청_단기예보 ((구)_동네예보) 조회서비스”API 来获取 API 凭据。
安装
- 克隆存储库:
- 紫外线安装
- 创建虚拟环境并安装依赖项:
- 使用您的 KMA API 凭据创建一个
.env
文件:
- 将网格坐标数据从 Excel 迁移到 SQLite:
使用 Docker
- 构建 Docker 镜像:
- 运行容器:
使用本地
- 运行服务器:
配置 MCP 设置
将服务器配置添加到您的 MCP 设置文件:
克劳德桌面应用程序
- 要通过Smithery自动安装:
- 要手动安装,请打开
~/Library/Application Support/Claude/claude_desktop_config.json
将其添加到mcpServers
对象:
游标 IDE
打开~/.cursor/mcp.json
将其添加到mcpServers
对象:
对于 Docker
与 Claude 一起使用
配置完成后,您可以向 Claude 询问以下问题:
- “서울특별시 서초구 양재1동의 날씨는?”
- “부산광역시 해운대구 우동의 날씨 예보를 알려줘”
- “경기도 성남시 분당구의 현재 기온은?”
API 参考
工具
获取网格位置
检索韩国气象局 API 针对指定位置使用的网格坐标 (nx, ny)。此工具会根据市/道、区/县以及街区/城镇信息,在数据库中搜索精确坐标。
获取预测
调用韩国气象局的超短期预报 API,提供特定地点的天气预报信息。返回包括温度、降水量、天空状况、湿度、风向和风速在内的综合天气数据。
资源
天气说明
提供有关如何使用韩国天气 MCP 服务器的详细文档,包括工具工作流程和响应格式。
提示
天气查询
该服务器包含一个结构化的提示模板,用于引导有关天气查询的对话,确保高效的信息收集和清晰的预报数据呈现。
响应格式
天气预报响应以结构化文本格式提供,针对 LLM 处理进行了优化:
致谢
执照
该项目根据 MIT 许可证获得许可 - 有关详细信息,请参阅 LICENSE 文件。
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
MCP 服务器使用网格坐标和韩国气象局 API 提供韩国天气信息,允许用户查询韩国特定地点的当前天气状况和预报。
Related MCP Servers
- -securityFlicense-qualityThis is a Model Context Protocol (MCP) server that provides weather information using the National Weather Service (NWS) API. Features Get weather alerts for a US state Get weather forecast for a specific location (using latitude and longitude)Last updated -Python
- AsecurityAlicenseAqualityAn MCP server that provides real-time weather information including temperature, humidity, wind speed, and sunrise/sunset times through the OpenWeatherMap API.Last updated -1PythonMIT License
- -securityFlicense-qualityAn MCP server implementation that allows users to fetch and display weather information for specified cities, including temperature, humidity, wind speed, and weather descriptions.Last updated -Python
- -securityAlicense-qualityAn MCP server that connects to OpenWeatherMap's API to provide current weather data and multi-day forecasts for locations worldwide in different measurement units.Last updated -12TypeScriptMIT License