Back to MCP directory
publicPublicdnsLocal runtime

caiyun-weather-mcp-server

一个提供彩云天气API无缝访问的MCP服务项目

article

README

🚀 青云天气 MCP 服务器

青云天气 MCP 服务器能够提供无缝访问青云天气 API 的服务,为用户获取天气信息带来便利。

🚀 快速开始

注册并获取 API 密钥

访问 青云平台 进行注册,注册成功后生成您的 API 密钥。

克隆仓库并设置环境

克隆仓库,然后使用 uv 创建 Python 虚拟环境并安装依赖项。

git clone https://github.com/mrchi/caiyun-weather-mcp-server.git
cd caiyun-weather-mcp-server/
uv venv
uv sync

配置环境变量

创建一个 .env 文件用于存储您的 API 密钥。

CAIYUN_API_KEY="your-key"

配置 MCP 客户端

打开兼容的 MCP 客户端,例如 Claude for Desktop 或 VSCode 中的 Cline,并按照以下方式进行配置:

{
    "mcpServers": {
        "weather": {
            "command": "uv",
            "env": {},
            "args": [
                "--directory",
                "<your repo directory>",
                "run",
                "--env-file",
                ".env",
                "servers/caiyun_weather.py"
            ]
        }
    }
}

查询天气

可进行简单询问,例如:

天安门广场的天气怎么样?
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client