Users of a the logic engine WebCore will read your question as: "Do hub variables come in a 'device' flavor?" The short answer is "No."
For Rule Machine to target different devices based on the contents of a Hub Variable (be it of type String, Number, Boolean, whatever...), you are essentially constrained to using a series of IF-THEN statements in your rule.
IF (this makes sense) == TRUE
THEN hope it works with conditionals
ELSE show us a screenshot of your rule
END-IF :-)
Ha! I feel like youāre following me on here. You answered a Webcore question I had in another post.
Youāre either going to get tired of me or weāre about to become best friends. LOL
Thanks for the reply. I assumed that you couldnāt do it, but there are so many things about Hubitat I am learning every day that I donāt want to assume.
Actually really enjoying your questions, though I'm much more of an RM user than WC. But what I appreciate most are slightly off-label uses of logic engines; the more obfuscated the better IMHO.
Would enjoy seeing your evolving rule regardless, in case there are any pointers worth sharing.
One potential consolation I can offer here, if your hub var were instead of type Number, and your target devices were all registered with Maker API for this purpose, you could theoretically do the following (calling them by device ID rather than Name):
Hub Variable āŗ devNum = 51
Maker App āŗ include device #51
Rule Machine āŗ Send GET request:
http://hub.ip/apps/api/36/devices/%devNum%/[Command]/[Secondary value]?access_token=edec259a
Is this solution elegant? No. Would it work? Yep! But only with similar devices who share a common target capability; for example, where [Command] is setTemperature and [Secondary value] is a ##.
Maker API and, more generally speaking, endpoints may enable you to do this kind of end run, but my example kind of pushes the boundaries a bit. I'm merely illustrating how flexible this platform is for those who believe "Where there's a will, there's a way."