# Howto set a Zigbee switch

**URL:** <https://discourse.nodered.org/t/howto-set-a-zigbee-switch/45227>\
**Category:** General\
**Created:** [5 May 2021 15:30 UTC](https://discourse.nodered.org/t/howto-set-a-zigbee-switch/45227 "2021-05-05T15:30:57Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![edje11](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/edje11/32/572_2.png) [@edje11](https://discourse.nodered.org/u/edje11)\
**Post date:** [5 May 2021 18:02 UTC](https://discourse.nodered.org/t/howto-set-a-zigbee-switch/45227/2 "2021-05-05T18:02:37Z")

</div>

Hi,

With the Tasmota Zigbee bridge I'm using  
`cmnd/ZigbeeBridge/Zbsend` as topic and

```auto
{
    "device": "TestLamp",
    "send": {
        "Dimmer": 25
    }
}

```

as payload.

Here's a sample flow:

```auto
[{"id":"2ae88aaf.e2fa8e","type":"mqtt out","z":"c4d9fae1.52009","name":"TestLamp","topic":"","qos":"0","retain":"","broker":"2f537664.491afa","x":1100,"y":4820,"wires":[]},{"id":"e13c799b.23f4f8","type":"inject","z":"c4d9fae1.52009","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"cmnd/ZigbeeBridge/Zbsend","payload":"{\"device\":\"TestLamp\",\"send\":{\"Dimmer\":25}}","payloadType":"json","x":770,"y":4820,"wires":[["2ae88aaf.e2fa8e"]]},{"id":"2f537664.491afa","type":"mqtt-broker","name":"MosquittoLocal","broker":"127.0.0.1","port":"1883","clientid":"","usetls":false,"compatmode":false,"protocolVersion":4,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""}]

```

This works fine for me.  
You can adapt this sample very easy to use it with a switch.

---

_[View the full topic](https://discourse.nodered.org/t/howto-set-a-zigbee-switch/45227)._
