Skip to content

Instantly share code, notes, and snippets.

@rdeangel
Last active January 12, 2025 22:12
Show Gist options
  • Save rdeangel/4d275043d9fb5e89c933db2341c9e217 to your computer and use it in GitHub Desktop.
Save rdeangel/4d275043d9fb5e89c933db2341c9e217 to your computer and use it in GitHub Desktop.
aqara-buttons-all-In-One-Zigbee2MQTT
blueprint:
name: Aqara Buttons All-In-One [Zigbee2MQTT] (MQTT Device Trigger)
description: "Blueprint Name: All-In-One package for Aqara Switches.\n Blueprint
Version: 12/01/2025\n\n Updated to use device specific `mqtt device actions` (rather
than previous wildcard version )\n Aquara action types posted by nwootton [here](https://community.home-assistant.io/t/aqara-wireless-switch-zigbee2mqtt-single-double-and-hold-action/275984/27)"
domain: automation
input:
mode:
name: Automation Modes
description: https://www.home-assistant.io/docs/automation/modes/
default: parallel
selector:
select:
mode: dropdown
options:
- single
- restart
- queued
- parallel
multiple: false
custom_value: false
sort: false
zigbee_device:
name: Zigbee Device (Aqara Switch)
description: Select the correct Zigbee device to use.
selector:
device:
integration: mqtt
multiple: false
single_action:
name: Single Click
description: Single click for devices with one button
default: []
selector:
action: {}
double_action:
name: Double Click
description: Double click for devices with one button
default: []
selector:
action: {}
triple_action:
name: Triple Click
description: Triple click for devices with one button
default: []
selector:
action: {}
quadruple_action:
name: Quadruple Click
description: Quadruple click for devices with one button
default: []
selector:
action: {}
hold_action:
name: Hold Action
description: Hold action for devices with one button
default: []
selector:
action: {}
release_action:
name: Release Action
description: Release action for devices with one button
default: []
selector:
action: {}
shake_action:
name: Shake Action
description: Shake action for devices with one button
default: []
selector:
action: {}
single_left_action:
name: Single Left Click
description: Left click for devices with multiple buttons
default: []
selector:
action: {}
double_left_action:
name: Double Left Click
description: Double left click for devices with multiple buttons
default: []
selector:
action: {}
triple_left_action:
name: Triple Left Click
description: Triple left click for devices with multiple buttons
default: []
selector:
action: {}
hold_left_action:
name: Hold Left Action
description: Hold left action for devices with multiple buttons
default: []
selector:
action: {}
release_left_action:
name: Release Left Action
description: Release left action for devices with multiple buttons
default: []
selector:
action: {}
single_center_action:
name: Single Center Click
description: Center click for devices with three buttons
default: []
selector:
action: {}
double_center_action:
name: Double Center Click
description: Double center click for devices with three buttons
default: []
selector:
action: {}
triple_center_action:
name: Triple Center Click
description: Triple center click for devices with three buttons
default: []
selector:
action: {}
hold_center_action:
name: Hold Center Action
description: Hold center action for devices with three buttons
default: []
selector:
action: {}
release_center_action:
name: Release Center Action
description: Release center action for devices with three buttons
default: []
selector:
action: {}
single_right_action:
name: Single Right Click
description: Right click for devices with multiple buttons
default: []
selector:
action: {}
double_right_action:
name: Double Right Click
description: Double right click for devices with multiple buttons
default: []
selector:
action: {}
triple_right_action:
name: Triple Right Click
description: Triple right click for devices with multiple buttons
default: []
selector:
action: {}
hold_right_action:
name: Hold Right Action
description: Hold right action for devices with multiple buttons
default: []
selector:
action: {}
release_right_action:
name: Release Right Action
description: Release right action for devices with multiple buttons
default: []
selector:
action: {}
single_both_action:
name: Single Both Click
description: Both click for devices with multiple buttons
default: []
selector:
action: {}
double_both_action:
name: Double Both Click
description: Double both click for devices with multiple buttons
default: []
selector:
action: {}
triple_both_action:
name: Triple Both Click
description: Triple both click for devices with multiple buttons
default: []
selector:
action: {}
hold_both_action:
name: Hold Both Action
description: Hold both action for devices with multiple buttons
default: []
selector:
action: {}
release_both_action:
name: Release Both Action
description: Release both action for devices with multiple buttons
default: []
selector:
action: {}
source_url: https://gist.github.com/rdeangel/4d275043d9fb5e89c933db2341c9e217
mode: !input mode
max_exceeded: silent
trigger:
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: single
id: single_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: double
id: double_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: triple
id: triple_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: quadruple
id: quadruple_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: hold
id: hold_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: release
id: release_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: shake
id: shake_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: single_left
id: single_left_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: double_left
id: double_left_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: triple_left
id: triple_left_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: hold_left
id: hold_left_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: release_left
id: release_left_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: single_center
id: single_center_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: double_center
id: double_center_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: triple_center
id: triple_center_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: hold_center
id: hold_center_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: release_center
id: release_center_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: single_right
id: single_right_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: double_right
id: double_right_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: triple_right
id: triple_right_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: hold_right
id: hold_right_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: release_right
id: release_right_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: single_both
id: single_both_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: double_both
id: double_both_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: triple_both
id: triple_both_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: hold_both
id: hold_both_action
- platform: device
device_id: !input zigbee_device
domain: mqtt
type: action
subtype: release_both
id: release_both_action
condition: []
action:
- choose:
- conditions:
- condition: trigger
id: single_action
sequence: !input single_action
- conditions:
- condition: trigger
id: double_action
sequence: !input double_action
- conditions:
- condition: trigger
id: triple_action
sequence: !input triple_action
- conditions:
- condition: trigger
id: quadruple_action
sequence: !input quadruple_action
- conditions:
- condition: trigger
id: hold_action
sequence: !input hold_action
- conditions:
- condition: trigger
id: release_action
sequence: !input release_action
- conditions:
- condition: trigger
id: shake_action
sequence: !input shake_action
- conditions:
- condition: trigger
id: single_left_action
sequence: !input single_left_action
- conditions:
- condition: trigger
id: double_left_action
sequence: !input double_left_action
- conditions:
- condition: trigger
id: triple_left_action
sequence: !input triple_left_action
- conditions:
- condition: trigger
id: hold_left_action
sequence: !input hold_left_action
- conditions:
- condition: trigger
id: release_left_action
sequence: !input release_left_action
- conditions:
- condition: trigger
id: single_center_action
sequence: !input single_center_action
- conditions:
- condition: trigger
id: double_center_action
sequence: !input double_center_action
- conditions:
- condition: trigger
id: triple_center_action
sequence: !input triple_center_action
- conditions:
- condition: trigger
id: hold_center_action
sequence: !input hold_center_action
- conditions:
- condition: trigger
id: release_center_action
sequence: !input release_center_action
- conditions:
- condition: trigger
id: single_right_action
sequence: !input single_right_action
- conditions:
- condition: trigger
id: double_right_action
sequence: !input double_right_action
- conditions:
- condition: trigger
id: triple_right_action
sequence: !input triple_right_action
- conditions:
- condition: trigger
id: hold_right_action
sequence: !input hold_right_action
- conditions:
- condition: trigger
id: release_right_action
sequence: !input release_right_action
- conditions:
- condition: trigger
id: single_both_action
sequence: !input single_both_action
- conditions:
- condition: trigger
id: double_both_action
sequence: !input double_both_action
- conditions:
- condition: trigger
id: triple_both_action
sequence: !input triple_both_action
- conditions:
- condition: trigger
id: hold_both_action
sequence: !input hold_both_action
- conditions:
- condition: trigger
id: release_both_action
sequence: !input release_both_action
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment