
Yeelight IoT MCP Server
io.github.Yeelight由 GitHub 账号 Yeelight 发布v0.1.0更新于 Oct 25, 2026
Yeelight device discovery, state, control, and scene execution.
概览
Yeelight 官方云端 MCP 服务器,让助手发现 Yeelight Pro 家庭中的区域、房间、设备、群组和场景,并预览或执行设备控制与场景。
- 可以做什么
- 读取当前选定的家庭,列出区域、房间、设备、群组和场景,支持游标分页,设备与群组可按房间筛选。预览或执行设备节点属性命令,默认试运行。预览或执行场景,默认试运行。
- 适用场景
- 适用于已有或专用集成需要直接读取 Yeelight Pro 家庭实时状态并进行聚焦控制的场景,包括 control_node 和 execute_scene 工具。普通用户更适合使用合并的 Yeelight MCP 安装方案,而不是单独安装此服务器。
- 运行要求
- 远程 Streamable HTTP 端点,位于 Yeelight 官方 API 主机;或使用 Python 3.10 以上和 uv 进行本地部署。每个请求都必须提供 Yeelight Authorization 令牌;Yeelight-Region 和 House-Id 请求头可选。本地部署仍调用 Yeelight 云端 API,并非离线网关。
安装
在 SourceWeft 中
- 打开 控制台中的 Yeelight IoT MCP Server,将其添加到工作区。
- 连接 Authorization token 凭据。它们会被私密存储,绝不会在公开页面上展示。
- 为需要使用其工具的对话启用该服务。
Web executable,通过 Streamable HTTP。 远程服务在工作区中配置后即可从网页运行时运行。
交给智能体安装
把这段提示词粘贴到 Claude Code、Codex、Cursor 等智能体,或 SourceWeft 对话中。智能体会读取该服务器的安装指南,先向你展示发布者、端点和登录方式,经你同意后再把它添加到你的客户端。密钥不会写进任何命令。
阅读 https://sourceweft.com/mcp/io.github.Yeelight%2Fyeelight-iot-mcp/install.md,并按其中说明把这个 MCP 服务器接入我的客户端。修改任何配置之前,先告诉我它的发布者、端点和登录方式,等我确认。不要把 API 密钥写进命令或我会提交的文件;问我密钥应从哪里获取。其他 MCP 客户端
把它添加到你客户端的 mcpServers 配置中。
{
"mcpServers": {
"yeelight-iot": {
"type": "http",
"url": "https://api.yeelight.com/apis/mcp_server/v1/mcp",
"headers": {
"Authorization": "Bearer <YOUR_TOKEN>"
}
}
}
}README
Yeelight IoT MCP
Official Repository And Mirrors
GitHub is the canonical source for issues, contributions, CI, and releases. Read-only mirrors are available on Gitee and GitCode for users who cannot reach GitHub reliably, with GitLab.com as an additional global fallback. Clone from any reachable source, but report issues and contribute changes on GitHub.
[!IMPORTANT] New to Yeelight MCP? Use one Yeelight MCP setup instead of installing this repository separately.
The setup configures this live-state/control service and Yeelight Metadata MCP together. This repository remains the developer reference for its specialized server, endpoint, and tools.
Follow the official English Yeelight MCP tutorial for the complete beginner path, or open the Simplified Chinese tutorial.
Yeelight Cloud MCP Suite
This repository is the focused-control part of the official Yeelight cloud MCP suite. Ordinary users receive both independently deployed services as one capability group through the same setup:
Recommended composition: run one Yeelight MCP setup so both services are available without a second install or scan.
Which MCP should I use?
Place In Yeelight AI
yeelight-home provides the recommended installation, QR sign-in, and client-configuration flow. Ordinary users should prefer the complete yeelight-smart-home Skill; MCP-only clients run one cloud setup for the complete Yeelight MCP suite. The cloud services then execute independently of the local Runtime.
In plain language: ordinary users do not install this server separately. It is included by the unified setup and remains independently addressable for existing or specialized integrations. It is not a dependency of Yeelight Home or either Skill.
Existing and specialized IoT MCP integrations
Yeelight IoT MCP is the official focused Model Context Protocol server for Yeelight Pro homes. It lets MCP clients discover homes, areas, rooms, devices, groups, and scenes, read current capabilities, prepare safe device controls, and execute confirmed controls or scenes. The following documentation remains the supported reference for existing and specialized integrations.
For the suite overview and recommended default setup, return to Yeelight Metadata MCP.
Capabilities
- Streamable HTTP MCP transport.
- Official hosted endpoint or self-hosted source deployment.
- Eight tools for topology discovery, device control, and scene execution.
- Cursor pagination for area, room, device, group, and scene lists.
- Dry-run by default for device control and scene execution.
- Redacted control plans and explicit side-effect confirmation.
Requirements
- Python 3.10 or later for local deployment.
uvfor the documented local workflow.- A Yeelight Authorization token. Region and House ID are optional.
Recommended: let Yeelight Home complete sign-in and configuration
The command displays a QR code. In Yeelight Pro app Home, tap the top-right +, choose MCP Authorization, and scan it. One Pro home is selected automatically; multiple homes are presented by name. Cloud mode configures Metadata and IoT MCP together through local credential proxies, without copying Authorization into the AI client's configuration. Manual token configuration remains an advanced compatibility path.
Hosted Service
Use the official Streamable HTTP endpoint:
Required request header:
Optional headers are Yeelight-Region and House-Id. The server accepts a raw
token or a value prefixed with Bearer. When Region is omitted, a JWT Region
claim selects the official endpoint before the complete token is validated.
When House ID is omitted, the server selects the first Pro home in that Region.
Users never configure a Client ID; IoT upstream calls derive it from the
validated JWT when required, falling back to dev in the development Region
and iot-app in cn, sg, us, or eu.
Local Development
The local MCP URL is http://127.0.0.1:9000/mcp. Local deployment still uses Yeelight cloud APIs; it is not an offline gateway. Every request must provide an explicit Authorization header regardless of bind address or runtime environment. The service never reads an operator's CLI Profile; tests may use an explicit isolated credential provider. Nacos registration is disabled by default in the public project and can be enabled explicitly through environment variables.
MCP Client Configuration
Restart the MCP client after changing its configuration, then verify that
tools/list returns the Yeelight tools.
Tools
For request examples and operating rules, read the usage guide. For client and deployment details, read the integration guide.
Safety Model
control_node and execute_scene default to dryRun=true. A live operation
requires both dryRun=false and confirmSideEffect=true. Callers should:
- Resolve names to current IDs using read tools.
- Inspect the target's supported properties and operators.
- Generate and review a dry-run plan.
- Obtain user confirmation in the calling application.
- Execute once and query the resulting state when possible.
The control property rs is blocked by the current safety policy. Do not retry
failed writes or scene executions blindly.
Configuration
Common environment variables for local deployments:
Test
Tests cover JWT claim handling, multi-Region routing, local Profile isolation, Pro home fallback, authorization normalization, pagination, redacted plans, dry-run defaults, confirmation guards, and configuration overrides. They do not call the live Yeelight cloud.
License
来源:README.md,提交 4d441cd
工具
0版本历史
1- v0.1.0最新Oct 12, 2026
评分
已满足适用检查项的 85%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通必需25 分
- 已声明认证方式必需10 分
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分