A bridge to connect HTTP-based IoT devices to MQTT. Supports Home Assistant discovery.
Note: This project is still in development and new releases might introduce unannounced breaking changes regularly.
- myStrom WiFi Button
- myStrom WiFi Button Plus
- myStrom WiFi Switch
- Edimax Smart Plug SP-2101W V2
- Edimax Smart Plug SP-1101W V2 (untested)
- Edimax Smart Plug SP-2101W (untested)
- Edimax Smart Plug SP-1101W (untested)
- Shelly 1PM
- Shelly 1 untested
NOTE: If your Edimax plug uses recent firmware (v3) and you don't know your plug's password, please refer to this guide on how to factory-reset your plug and obtain its auto-generated password during setup.
Note that Device Triggers won't show up as entities under the device. They are, however, available as triggers in the automation editor UI.
Name | Device Type | Trigger Type | Trigger Subtype | Value | Units |
---|---|---|---|---|---|
Single Press | Device Trigger | button_short_press |
button_1 |
||
Double Press | Device Trigger | button_double_press |
button_1 |
||
Long Press | Device Trigger | button_long_press |
button_1 |
||
Battery | Sensor | Battery level | % |
Name | Device Type | Trigger Type | Trigger Subtype | Value | Units |
---|---|---|---|---|---|
Single Press | Device Trigger | button_short_press |
button_1 |
||
Double Press | Device Trigger | button_double_press |
button_1 |
||
Long Press | Device Trigger | button_long_press |
button_1 |
||
Touch | Device Trigger | button_short_press |
button_2 |
||
Wheel | Sensor | Number between wheelMin and wheelMax |
|||
Wheel Final | Device Trigger | button_short_press |
button_3 |
||
Battery | Sensor | Percentage level | % |
Name | Device Type | Value | Units |
---|---|---|---|
Relay | Switch | ||
Power | Sensor | Power usage | W |
Temperature | Sensor | Temperature | °C |
Name | Device Type | Value | Units |
---|---|---|---|
Relay | Switch | ||
Power | Sensor | Power usage | W |
Amperage | Sensor | Power current / amperage | A |
Name | Device Type | Value | Units |
---|---|---|---|
Relay | Switch | ||
Power | Sensor | Power usage | W |
Temperature | Sensor | PCB Temperature | °C |
Note that the temperature is the operating temperature of the device i.e. PCB temperature, not the room temperature.
Name | Device Type | Value | Units |
---|---|---|---|
Relay | Switch |
logLevel
: (optional; default: 'info') Log level. One of "error", "warn", "info", "verbose", "debug", "silly".http.host
(optional; default: '0.0.0.0'): Interface IP for the HTTP server to listen on.http.port
(optional; default: 8321): Port for the HTTP server to listen on.mqtt.broker
(required): MQTT Broker URL.mqtt.username
(optional): MQTT broker username.mqtt.password
(optional): MQTT broker password.mqtt.homeAssistant.discovery
(optional; default: false): Enable publishing discovery information for Home Assistant.options.PLUGIN_NAME
(optional): Plugin-specific options
mystrom-buttons.route
(optional; default:"/mystrom-buttons"
): Route path under which to handle actions from the buttonsmystrom-buttons.mqttTopic
(optional; default: 'http2mqtt/mystrom/wifi_buttons'): MQTT topic prefix under which to publish button statesmystrom-buttons.buttons
(required): Configuration for each button. Only buttons configured here will be handled.
mac
(required): MAC address of the buttonname
(required): A friendly name for the buttontype
(required): Either"button"
or"button-plus"
for myStrom Wifi button or myStrom Wifi Button Plus respectivelywheelMin
(button-plus only; required): Minimum value for the wheelwheelMax
(button-plus only; required): Maximum value for the wheelwheelSpeed
(button-plus only; optional; default: 1): Multiplier for the wheel value. Higher number means fewer rotations to go fromwheelMin
towheelMax
and vice versa
mystrom-switch.mqttTopic
(optional; default: 'http2mqtt/mystrom/wifi_switches'): MQTT topic prefix under which to publish switch statesmystrom-switch.switches
(required): Configuration for each switch. Only switches configured here will be handled.
host
(required): Host or IP address of the switch.name
(required): A friendly name for the switch.
edimax-plug.mqttTopic
(optional; default: 'http2mqtt/edimax/wifi_plugs'): MQTT topic prefix undwe which to publish switch states.edimax-plug.switches
(required): Configuration for each switch. Only switches configured here will be handled.
host
(required): Host or IP address of the switch.name
(required): A friendly name for the switch.username
(optional; default: 'admin'): Username to log in to the switch.password
(required): Password to log in to the switch.
shelly-switch.mqttTopic
(optional; default: 'http2mqtt/shelly/wifi_relays'): MQTT topic prefix undwe which to publish switch states.shelly-switch.switches
(required): Configuration for each switch. Only switches configured here will be handled.
type
(required): Either"shelly-1"
or"shelly-1pm"
for Shelly 1 or Shelly 1PM respectively.host
(required): Host or IP address of the switch.name
(required): A friendly name for the switch.username
(optional; default: 'admin'): Username to log in to the switch.password
(optional): Password to log in to the switch.
{
"http": {
"host": "0.0.0.0",
"port": 8321
},
"mqtt": {
"broker": "mqtt://10.13.37.42:1883",
"username": "user",
"password": "secret"
},
"homeAssistant": {
"discovery": "yes"
},
"options": {
"mystrom-buttons": {
"route": "/mystrom/generic",
"buttons": [
{
"mac": "BADA55FA7A55",
"name": "Kitchen Wifi Button Plus",
"type": "button-plus",
"wheelMin": 0,
"wheelMax": 255,
"wheelSpeed": 2.5
},
{
"mac": "FA7A55BADA55",
"name": "Bathroom Wifi Button",
"type": "button"
}
]
},
"mystrom-switch": {
"switches": [
{
"host": "10.13.37.43",
"name": "Wifi Switch 1"
},
{
"host": "10.13.37.44",
"name": "Wifi Switch 2"
}
]
},
"edimax-plug": {
"switches": [
{
"name": "Edimax Switch 1",
"host": "10.13.37.45",
"username": "admin",
"password": "1234"
}
]
},
"shelly-switch": {
"switches": [
{
"type": "shelly-1pm",
"host": "10.13.37.46",
"name": "Shelly 1PM",
"username": "chiefcommander",
"password": "s3cr3t"
}
]
}
}
}
Copyright (c) 2020 Max Kueng
MIT License