Xiaomi Aqara Zigbee Switch DTH--help needed

SmartThings is currently Not accepting any submissions for official integration. This has been stated recently by SmartThings.

Im cool about that. Official support of end devices carries a support price tag.

What dami was referring to was the broken, filtered catch-all situation.

Endpoint Ids are filtered by the st backend. Dh dont have enough info to know which endpoint sent the messages.


Got a Dual Switch… Have it working with the Button Handler and it shows its being used… YET it won’t trigger any light I have it hooked too… (using the Smart App from Samsung the Automate Lights scenes and switches smart app) yet no joy in Mud vill Any Ideas ???

Okay, so we know that CURRENTLY these devices are unusable.
But do we have a chance to convince ST guys to do anything to fix it in the foreseeable future? (I mean to get the endpoint ID, or to access the “catchall” that triggered the on/off event)

I’m in the middle of replacing my old PLCBus-based lighting control to a more flexible solution (I chose Zigbee with an ST hub as the heart of it. And I hate the multi-hub solution, it’s… it’s simply ugly). I’ve already built endpoints with custom firmware for myself, it was fun, but I don’t want to jump into a never-ending project because of these switches… It’s not that I can’t live without them (I’ve burnt much more money along the way), but there may or may not be other, currently unknown restrictions in the ST ecosystem that render my whole home control system a big pile of paperweight… and I’d love to avoid that.

So… instead of asking for alternatives to ST :slight_smile: , I try to be more constructive:

  • Where to start? Where should we write, who should we ask?
  • Are there any more similar issues that prevent devices to be integrated into ST?
  • Are there any more devices that cannot be integrated because of this very issue?

Good Day All
can some one tell me the process they used to get their Xiaomi Aqara Smart Light Switch Wireless Version paired to the ST hub i have the DHT by aarick created in ST, but cant get the button to pair

You have to pair it using catchall method.

Look for the 7th group of numbers in the catchall logs. You can get the catchalls under hub, List events in the IDE.

Hi guys

I have been reading the forum for a while now, still this is my first post :slight_smile:

So I got two of these 2 button aqara switches and managed to add them to ST by using catchall method. As DH, i am using the one from @aarick - brilliant work mate!
Just to make sure i understand exactly what @simic was mentioning - when you say ST is filtering the backend messages, are these the messages you are talking about?
Button events

  • left button: 1002
  • right button: 2002
  • both buttons: 3002

from here: https://github.com/dresden-elektronik/deconz-rest-plugin/commit/e395207899d4f6c653a25328bf5419073ea850a9


1 Like

Yes, those 3 different button push events are sent with 3 different endpoint tag values, but the SmartThings ZigBee event parser strips out the endpoint values, so the device handler only sees that a button was pushed.

The only time a device handler has a chance to work around this limitation is if the data sent by the ZigBee device isn’t recognized as a normal event, and gets forwarded to the device handler as a “read attr - raw:” message that includes the full string of bytes that the device sent. In that case, if you know what those byte values refer to, then you can code the device handler to do things with that information.

A lot of other Xiaomi devices send events that are forwarded by ST as “read attr - raw:” data, but this particular switch does not, unfortunately.

Here the solution:

I don’t think this helps with the wireless version.


i have done everything like you all said but still i can’t added this switch

The information in this thread is quite outdated. There are newer device handlers, but it depends on which device you are trying to use.

Can you share the model of switch or button you have?


This effectively renders the 2 button version useless. Only the single button version can be used with ST platform, until they change their backend to return more info to the device handler.

Use 2 button

Not true.

I recently released updated device handlers (DTH) for all the of the Xiaomi / Aqara buttons, including the WXKG02LM and WXKG03LM Aqara Wireless Wall Switches. I have the 2016 revision of model WXKG02LM and it’s working just fine now.

Please see this post for more information and the link to the DTH.

1 Like

It’s true that it’s not true… :wink:
I have 02LM running with the new DH and it works great…!!

Still nothing.

Could you tell me exactly what i should to do.

I can help, but first I need to know some more information.

Just to be 100% sure, are you using this:
and it does not connect to the electric wires in your wall?

If yes, then have you successfully paired it to your SmartThings Hub so it appears in the SmartThings “classic” mobile app, like this example where I named my WXKG02LM as “Aqara Button”:

If you have not successfully paired your Aqara WXKG02LM, then I need to know what kind of SmartThings Hub you are using and if you are using the older SmartThings “classic” mobile app.

I can’t paring, how to do this?
Step by step, from beginning
SmartThings Hub V3, latest one. I have both smartthings apps

Do not use the new SmartThings Samsung Connect mobile app for pairing Xiaomi / Aqara devices. You will need to use the SmartThings “classic” mobile app for pairing, and also to interact with them.

You said you have the Aqara Wireless Smart Wall Switch model WXKG02LM. There are actually two versions of that model: A 2016 revision and a 2018 revision. Looking at the button itself here is no way to know which revision you have until you have successfully paired it to SmartThings.

Here are the instructions on how to pair the Aqara model WXKG02LM:

  1. Start “Add a Thing” in the SmartThings (classic) mobile app.

  2. Hold one of the two buttons until you see the LEDs blink at the bottom, and then immediately release the switch. For the 2016 revision you will need to hold about 5 seconds, but for the 2018 revision up to 15-20 seconds. Just only hold until the LEDs blink.

  3. There will be a pause, and the LED(s) will flash again. If you see one flash, then the SmartThings hub has recognized the switch. If you see 3 consecutive quick flashes, pairing was unsuccessful so go back to step #2.

  4. It may take a few seconds after the hub recognizes the WXKG02LM for it to appear in the SmartThings mobile app. Then it can be renamed, and you’re done!

I can make a video if you still have trouble with pairing.