# Shelly Gen2 MQTT Help

**URL:** <https://discourse.nodered.org/t/shelly-gen2-mqtt-help/53024>\
**Category:** General\
**Created:** [31 October 2021 19:41 UTC](https://discourse.nodered.org/t/shelly-gen2-mqtt-help/53024 "2021-10-31T19:41:37Z")\
**Posts on this page:** 1\
**Showing post:** 29

<div class="post-metadata">

**Author:** ![E1cid](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/e1cid/32/77971_2.png) [@E1cid](https://discourse.nodered.org/u/E1cid)\
**Post date:** [1 February 2022 12:03 UTC](https://discourse.nodered.org/t/shelly-gen2-mqtt-help/53024/29 "2022-02-01T12:03:43Z")

</div>

The shelly gen2 uses rpc channel to switch the device, so the topic is totally different.

There is an example here which should be similar

> [@Shellyplus1 (gen2) Nodered to MQTT](https://discourse.nodered.org/t/shellyplus1-gen2-nodered-to-mqtt/56522/4):
>
> I do not have any gen2 devices. But what have you tried? As far as i can make out you send {"id":123, "src":"user\_1", "method":"Switch.Set", "params":{"id":0,"on":true}} to topic shelly\_id/rpc id : number/string, identifier of this request, will be used to match the response frame. Required src : string, name of the source of the request (you can choose whatever string you like to identify you as the source of the request). Required method : string, name of the procedure to be called.…

and the shelly docs here

> **[Switch | Shelly Technical Documentation](https://shelly-api-docs.shelly.cloud/gen2/ComponentsAndServices/Switch/)**
>
> The Switch component handles a switch (relay) output terminal with optional power metering capabilities. It uses Switch as an RPC namespace and provides the following methods:

---

_[View the full topic](https://discourse.nodered.org/t/shelly-gen2-mqtt-help/53024)._
