I see a couple of other changes that I think should be made.
I believe I'm going to 'fork' off of this and start another version. The logging should not be on all the time, and I have a better way to display the last action to a sensor instead, so that you can troubleshoot and generate the actions easier.
That along with some of the descriptions I think a few tweaks like that would make this a lot better.
The basic code is sound and doesn't need a thing.
Community link for my forked version of this blueprint:
source_url from GitHub: https://github.com/SirGoodenough/HA_Blueprints/blob/master/Automations/Zigbee2MQTT%20-%20Xiaomi%20Cube%20Controller.yaml
Event Sensor in Action:
