Variable to hold device id?

In rules I use local variables to hold "tuning" values. For example a temperature. Then if I need to change the temperature threshold of a rule I just change the value of the variable and it spares me editing a complex conditional statement. I have sometimes found myself wishing to test a rule with a spare sensor that I can easily manipulate before letting it work on the intended device which might be located where I can't make it hot or cold or bright or dark easily. Is there a way I can use a local variable to refer to a device - maybe by UID - so I can simply swap it out instead of editing the whole rule? If not, can I request a "device UID" variable type?

1 Like

No, but if you clone or export/import the rule, you'll be prompted to substitute devices, so that's probably what I'd recommend.

2 Likes

Good suggestion, thank you :slight_smile: