← 返回 Skills 市场
al-one

🏠 Home Assistant via MCP protocol

作者 Alone · GitHub ↗ · v1.0.1
cross-platform ✓ 安全检测通过
5072
总下载
10
收藏
26
当前安装
2
版本数
在 OpenClaw 中安装
/install mcp-hass
功能描述
The skill for control Home Assistant smart home devices and query states using MCP protocol.
使用说明 (SKILL.md)

Home Assistant

Control Home Assistant smart home and query states using MCP protocol.

Prerequisites

Enable MCP server in Home Assistant:

  • Browse to your Home Assistant instance.
  • Go to Settings > Devices & services.
  • In the bottom right corner, select the + Add Integration button.
  • From the list, select Model Context Protocol.
  • Follow the instructions on screen to complete the setup.

Usage

# Get states
mcporter call home-assistant.GetLiveContext

# Turn on the device
mcporter call home-assistant.HassTurnOn(name: "Bedroom Light")
mcporter call home-assistant.HassTurnOn(name: "Light", area: "Bedroom")

# Turn off the device
mcporter call home-assistant.HassTurnOff(name: "Bedroom Light")
mcporter call home-assistant.HassTurnOff(area: "Bedroom", domain: ["light"])

# Control light
# brightness: The percentage of the light, where 0 is off and 100 is fully lit.
# color: Name of color
mcporter call home-assistant.HassLightSet(name: "Bedroom Light", brightness: 50)

# Control fan
# percentage: The percentage of the fan, where 0 is off and 100 is full speed.
mcporter call home-assistant.HassFanSetSpeed(name: "Fan", area: "Bedroom", percentage: 80)

Execute the following command to learn about specific usage methods:

  • mcporter list home-assistant --schema --all-parameters

Config

When prompted that the MCP server does not exist, remind the user to configure the HASS_BASE_URL and HASS_ACCESS_TOKEN environment variables by executing the following command to add the configuration:

mcporter config add home-assistant \
  --transport http \
  --url "${HASS_BASE_URL:-http://homeassistant.local:8123}/api/mcp" \
  --header "Authorization=Bearer \${HASS_ACCESS_TOKEN}"

About mcporter

安全使用建议
Install only if you want an agent to access Home Assistant. Use a dedicated, least-privileged token where possible, review commands that change device state, and be especially careful with locks, alarms, heaters, garage doors, appliances, or other safety-relevant devices.
功能分析
Type: OpenClaw Skill Name: mcp-hass Version: 1.0.1 The skill is designed to control Home Assistant devices using the `mcporter` tool. All instructions in `SKILL.md` are consistent with this stated purpose, detailing setup, usage, and configuration. It requires `HASS_ACCESS_TOKEN` and `HASS_BASE_URL` environment variables, which are used legitimately for authentication and connectivity to Home Assistant, not for exfiltration. There is no evidence of malicious execution, persistence, data theft, or prompt injection attempts against the agent beyond the skill's stated functionality.
能力评估
Purpose & Capability
The stated purpose is Home Assistant control via MCP, and the documented commands match that purpose, including reading live context and changing lights or fans.
Instruction Scope
The instructions are straightforward setup and command examples; they would benefit from clearer confirmation guidance before changing real device state.
Install Mechanism
The skill declares a Node install for mcporter and allows npx fallback, which is coherent with the MCP workflow, though the dependency is not pinned in the artifact.
Credentials
HASS_BASE_URL and HASS_ACCESS_TOKEN are sensitive but expected for Home Assistant API access, and the artifact uses them only for the Home Assistant MCP endpoint and authorization header.
Persistence & Privilege
The mcporter config command persistently registers the Home Assistant MCP server with an authorization header placeholder; this is disclosed and purpose-aligned.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install mcp-hass
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /mcp-hass 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.1
- Added homepage and metadata fields to the skill, including requirements and install instructions. - Updated all example commands to use mcporter directly, with a note to use npx if mcporter is not installed. - Improved documentation by clarifying tool usage and environment variable setup. - Enhanced guidance for installation and configuration steps.
v1.0.0
Initial release of mcp-hass skill. - Control Home Assistant devices and query states using the MCP protocol. - Provides command examples for turning devices on/off and adjusting lights/fans. - Includes setup instructions for integrating MCP server into Home Assistant. - Explains configuration of required environment variables for connection. - Recommends using npx for running mcporter commands. - Documentation includes command references and usage tips.
元数据
Slug mcp-hass
版本 1.0.1
许可证
累计安装 28
当前安装数 26
历史版本数 2
常见问题

🏠 Home Assistant via MCP protocol 是什么?

The skill for control Home Assistant smart home devices and query states using MCP protocol. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 5072 次。

如何安装 🏠 Home Assistant via MCP protocol?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install mcp-hass」即可一键安装,无需额外配置。

🏠 Home Assistant via MCP protocol 是免费的吗?

是的,🏠 Home Assistant via MCP protocol 完全免费(开源免费),可自由下载、安装和使用。

🏠 Home Assistant via MCP protocol 支持哪些平台?

🏠 Home Assistant via MCP protocol 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 🏠 Home Assistant via MCP protocol?

由 Alone(@al-one)开发并维护,当前版本 v1.0.1。

💬 留言讨论