Shelly PowerStrip
Shelly PowerStrip Gen4 is a four-channel device with a wide range of functionalities. The channels supports the use of automatic timers, webhooks, and schedules. The device has a built-in power meters to instantaneously measure the power consumed by each of the channels individually. In addition, the device features built-in LEDs indicating the power consumption for each of the channels and the status of the network connectivity.
The following components are available in Shelly PowerStrip Gen4:
- System
- WiFi
- Bluetooth Low Energy
- Cloud
- MQTT
- Outbound Websocket
- 4 instances of Switch (
switch:0,switch:1,switch:2,switch:3) - POWERSTRIP_UI
- Virtual components
- BTHome components (not available in Zigbee mode)
- Up to 10 instances of Script
- Matter
- Zigbee
Details on the supported Zigbee features and clusters can be found here.
POWERSTRIP_UI
The POWERSTRIP_UI component handles the settings of a PowerStrip Gen4 device's LEDs.
Methods
POWERSTRIP_UI.SetConfig
Properties:
| Property | Type | Description |
|---|---|---|
| object | Configuration that the method takes |
Find more about the config properties in config section
POWERSTRIP_UI.GetConfig
Find the POWERSTRIP_UI.GetConfig response properties in config section
POWERSTRIP_UI.GetStatus
Find more about the status response properties in status section
Configuration
The configuration of the POWERSTRIP_UI component allows you to set the color mode of the LEDs (power/switch/off). The color mode is valid for all 4 channels.
| Property | Type | Description | ||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| object | POWERSTRIP_UI LED configuration |
| string | LED indication mode
|
| object | LED colors and brightness in RGB format
| ||||||||||||||||||||||||||||||||||||||
| object | LED brightness for LED indication mode power
|
night_mode
object
LED brightness in night mode
| Property | Type | Description |
|---|---|---|
| boolean | Enable or disable night mode |
| number | Value for brightness [0-100] |
| array of 2 elements of type string for start of the period and end of the period in format HH:MM | Value for strings [00:00-23:59] |
controls
object
POWERSTRIP_UI control configuration
| Property | Type | Description | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| object | Switch component instance |
| string | Button mode
|
| Property | Type | Description | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| object | Switch component instance |
| string | Button mode
|
| Property | Type | Description | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| object | Switch component instance |
| string | Button mode
|
| Property | Type | Description | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| object | Switch component instance |
| string | Button mode
|
Status
The POWERSTRIP_UI component does not own any status properties.
Examples
POWERSTRIP_UI.GetStatus example
- POWERSTRIP_UI.GetStatus HTTP GET Request
- POWERSTRIP_UI.GetStatus Curl Request
- POWERSTRIP_UI.GetStatus Mos Request
http://192.168.33.1/rpc/POWERSTRIP_UI.GetStatus
curl -X POST -d '{"id":1,"method":"POWERSTRIP_UI.GetStatus"}' http://${SHELLY}/rpc
mos --port ${PORT} call POWERSTRIP_UI.GetStatus
Response
- POWERSTRIP_UI.GetStatus HTTP GET Response
- POWERSTRIP_UI.GetStatus Curl Response
- POWERSTRIP_UI.GetStatus Mos Response
{}
{
"id": 1,
"params": {}
}
{}
POWERSTRIP_UI.GetConfig example
- POWERSTRIP_UI.GetConfig HTTP GET Request
- POWERSTRIP_UI.GetConfig Curl Request
- POWERSTRIP_UI.GetConfig Mos Request
http://192.168.33.1/rpc/POWERSTRIP_UI.GetConfig
curl -X POST -d '{"id":1,"method":"POWERSTRIP_UI.GetConfig"}' http://${SHELLY}/rpc
mos --port ${PORT} call POWERSTRIP_UI.GetConfig
Response
- POWERSTRIP_UI.GetConfig HTTP GET Response
- POWERSTRIP_UI.GetConfig Curl Response
- POWERSTRIP_UI.GetConfig Mos Response
{
"leds": {
"mode": "power",
"colors": {
"switch:0": {
"on": {
"rgb": [
0,
100,
0
],
"brightness": 100
},
"off": {
"rgb": [
100,
0,
0
],
"brightness": 100
}
},
"power": {
"brightness": 100
}
},
"night_mode": {
"enable": false,
"brightness": 10,
"active_between": [
"22:00",
"06:00"
]
}
},
"controls": {
"switch:0": {
"in_mode": "momentary"
},
"switch:1": {
"in_mode": "momentary"
},
"switch:2": {
"in_mode": "momentary"
},
"switch:3": {
"in_mode": "momentary"
}
}
}
{
"id": 1,
"params": {
"leds": {
"mode": "power",
"colors": {
"switch:0": {
"on": {
"rgb": [
0,
100,
0
],
"brightness": 100
},
"off": {
"rgb": [
100,
0,
0
],
"brightness": 100
}
},
"power": {
"brightness": 100
}
},
"night_mode": {
"enable": false,
"brightness": 10,
"active_between": [
"22:00",
"06:00"
]
}
},
"controls": {
"switch:0": {
"in_mode": "momentary"
},
"switch:1": {
"in_mode": "momentary"
},
"switch:2": {
"in_mode": "momentary"
},
"switch:3": {
"in_mode": "momentary"
}
}
}
}
{
"leds": {
"mode": "power",
"colors": {
"switch:0": {
"on": {
"rgb": [
0,
100,
0
],
"brightness": 100
},
"off": {
"rgb": [
100,
0,
0
],
"brightness": 100
}
},
"power": {
"brightness": 100
}
},
"night_mode": {
"enable": false,
"brightness": 10,
"active_between": [
"22:00",
"06:00"
]
}
},
"controls": {
"switch:0": {
"in_mode": "momentary"
},
"switch:1": {
"in_mode": "momentary"
},
"switch:2": {
"in_mode": "momentary"
},
"switch:3": {
"in_mode": "momentary"
}
}
}
POWERSTRIP_UI.SetConfig example
- POWERSTRIP_UI.SetConfig HTTP GET Request
- POWERSTRIP_UI.SetConfig Curl Request
- POWERSTRIP_UI.SetConfig Mos Request
http://192.168.33.1/rpc/POWERSTRIP_UI.SetConfig?config={"leds":{"mode":"switch","colors":{"switch:0":{"on":{"rgb":[100,100,0],"brightness":100},"off":{"rgb":[100,100,100],"brightness":100}},"power":{"brightness":100}},"night_mode":{"enable":true,"brightness":10,"active_between":["22:00","06:00"]}},"controls":{"switch:0":{"in_mode":"detached"}}}
curl -X POST -d '{"id":1,"method":"POWERSTRIP_UI.SetConfig","params":{"config":{"leds":{"mode":"switch","colors":{"switch:0":{"on":{"rgb":[100,100,0],"brightness":100},"off":{"rgb":[100,100,100],"brightness":100}},"power":{"brightness":100}},"night_mode":{"enable":true,"brightness":10,"active_between":["22:00","06:00"]}},"controls":{"switch:0":{"in_mode":"detached"}}}}}' http://${SHELLY}/rpc
mos --port ${PORT} call POWERSTRIP_UI.SetConfig '{"config":{"leds":{"mode":"switch","colors":{"switch:0":{"on":{"rgb":[100,100,0],"brightness":100},"off":{"rgb":[100,100,100],"brightness":100}},"power":{"brightness":100}},"night_mode":{"enable":true,"brightness":10,"active_between":["22:00","06:00"]}},"controls":{"switch:0":{"in_mode":"detached"}}}}'
Response
- POWERSTRIP_UI.SetConfig HTTP GET Response
- POWERSTRIP_UI.SetConfig Curl Response
- POWERSTRIP_UI.SetConfig Mos Response
{
"restart_required": false
}
{
"id": 1,
"params": {
"restart_required": false
}
}
{
"restart_required": false
}