360 Secure SkillHub
360 安全技能中心

Shelly Sync

核心功能含读取三相实时电力消耗/注入数据、按阈值触发家电、生成电力统计;适用于家庭光伏余电利用、负载优化场景。输入为操作指令(get_status/optimize_load),可指定目标家电;输出为JSON格式结果,数据获取失败则返回连接错误。

jcbuer
jcbuer
热度 22.16
最近更新 2026-06-09 01:04:40
分类:自动化依赖:第三方 API / 代码执行应用场景:自动化脚本 / 数据处理

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add shelly-sync
Metadata
name
shelly_sync
description
Monitor real-time power consumption from Shelly Pro 3EM and control local appliances/automation based on solar yield or grid usage.
version
1.0.1
license
MIT
capabilities
["Read current power consumption and grid injection (W)","Trigger smart plugs/appliances based on power thresholds","Provide power stats summary"]
inputs
{"action":{"type":"string","description":"The operation: 'get_status' or 'optimize_load'","required":true},"target_load":{"type":"string","description":"Optional: Specific appliance to toggle (e.g. 'heatpump', 'charger')","required":false}}
env
["SHELLY_EM_IP"]

Shelly Sync Skill

Interface between Shelly Pro 3EM energy monitoring and home automation.

Usage Guidelines

  • Power output in Watts (W) or Kilowatts (kW)
  • Negative = grid injection (surplus). Positive = grid consumption
  • If data fetch fails → report connection error immediately, don't hallucinate

Commands

get_status

Returns current power consumption across all 3 phases.

/shelly get_status

optimize_load

Analyzes surplus and triggers load optimization if excess energy available.

/shelly optimize_load
/shelly optimize_load target_load:heatpump

Implementation

  • Script: shelly_client.py
  • Calls Shelly Pro 3EM RPC API (EMData.GetStatus)
  • Returns clean JSON with total power and phase breakdown