Control Xiaomi Mijia smart home devices. Use this skill when the user wants to control desk lamps, smart plugs, or other Mijia devices. Supports turning lights on/off, adjusting brightness, setting color temperature, switching modes, and more.
数据来源:ClawHub。 在 ClawSkills 查看
选择你使用的 Agent
方法一:命令行安装(推荐)
推荐(无需提前安装 clawhub)
npx clawhub@latest --dir ~/.claude/skills install mijia或使用 clawhub CLI(需提前安装)
clawhub --dir ~/.claude/skills install mijia⚠️ 需要 Node.js 18+,没有 Node?请使用下方方法二直接下载 ZIP。 安装 Node.js →
方法二:手动下载安装(无需 Node)
下载 ZIP,解压后将文件夹放到以下路径,重启 Agent 即可:
安装路径
~/.claude/skills/mijia/💡解压后将文件夹放到上方路径,重启 Agent 即可生效
--- name: mijia description: Control Xiaomi Mijia smart home devices. Use this skill when the user wants to control desk lamps, smart plugs, or other Mijia devices. Supports turning lights on/off, adjusting brightness, setting color temperature, switching modes, and more. invocable: true ---
Control Xiaomi Mijia smart devices via the mijiaAPI.
Before using this skill, you need to:
cd /path/to/mijia-skill
uv sync
export MIJIA_LAMP_DID="your_device_id"
To find your device IDs, use the mijia-api library:
from mijiaAPI import mijiaAPI
api = mijiaAPI()
api.login()
devices = api.get_device_list()
for d in devices:
print(f"{d['name']}: {d['did']}")
Skill path: ~/.clawdbot/skills/mijia
# Navigate to skill directory
cd ~/.claude/skills/mijia
# Check status
uv run python scripts/lamp_cli.py status
# Turn on/off
uv run python scripts/lamp_cli.py on
uv run python scripts/lamp_cli.py off
uv run python scripts/lamp_cli.py toggle
# Adjust brightness (1-100%)
uv run python scripts/lamp_cli.py brightness 50
# Adjust color temperature (2700-6500K)
uv run python scripts/lamp_cli.py temp 4000
# Set mode
uv run python scripts/lamp_cli.py mode reading # Reading mode
uv run python scripts/lamp_cli.py mode computer # Computer mode
uv run python scripts/lamp_cli.py mode night # Night reading
uv run python scripts/lamp_cli.py mode antiblue # Anti-blue light
uv run python scripts/lamp_cli.py mode work # Work mode
uv run python scripts/lamp_cli.py mode candle # Candle effect
uv run python scripts/lamp_cli.py mode twinkle # Twinkle alert
When the user says the following, execute the corresponding command:
| User Says | Command | |-----------|---------| | Turn on the light / open lamp | scripts/lamp_cli.py on | | Turn off the light / close lamp | scripts/lamp_cli.py off | | Toggle the light | scripts/lamp_cli.py toggle | | Brighter / more bright | Check status first, then increase by 20-30% | | Dimmer / less bright | Check status first, then decrease by 20-30% | | Full brightness / maximum | scripts/lamp_cli.py brightness 100 | | Minimum brightness | scripts/lamp_cli.py brightness 1 | | Warm light | scripts/lamp_cli.py temp 2700 | | Cool light / white light | scripts/lamp_cli.py temp 6500 | | Reading mode | scripts/lamp_cli.py mode reading | | Computer mode | scripts/lamp_cli.py mode computer | | Night mode | scripts/lamp_cli.py mode night | | Lamp status / what's the light status | scripts/lamp_cli.py status |
cd ~/.clawdbot/skills/mijiaMIJIA_LAMP_DID environment variable is setuv run python scripts/lamp_cli.py 安装 Mijia 后,可以对 AI 说这些话来触发它
Help me get started with Mijia
Explains what Mijia does, walks through the setup, and runs a quick demo based on your current project
Use Mijia to control Xiaomi Mijia smart home devices
Invokes Mijia with the right parameters and returns the result directly in the conversation
What can I do with Mijia in my marketing & growth workflow?
Lists the top use cases for Mijia, with example commands for each scenario
将技能文件夹放到 ~/.claude/skills/mijia/ 目录(个人级,所有项目可用),或 .claude/skills/mijia/(项目级)。重启 AI 客户端后,用 /mijia 主动调用,或让 AI 根据上下文自动发现并使用。
Mijia 支持 Claude、Cursor、OpenClaw,可与这些 AI 平台无缝集成,扩展其能力。
Mijia 可免费安装使用。请查阅仓库了解许可证信息。
Control Xiaomi Mijia smart home devices. Use this skill when the user wants to control desk lamps, smart plugs, or other Mijia devices. Supports turning lights on/off, adjusting brightness, setting color temperature, switching modes, and more.
Mijia 属于「Marketing & Growth」分类,该分类的技能帮助 AI 智能体在此领域执行专业任务。
Automate my marketing & growth tasks using Mijia
Identifies repetitive steps in your workflow and sets up Mijia to handle them automatically