Please give us some kind of collections (arrays, lists) and a possibility to loop (e.g. for each) through all the elements.
I have noticed that I often write the same code for many devices (e.g. "for all devices of type x do y"). And with e.g. 10 Chromecast devices it's a lot of clicking (and don't forget, that there is no cut'n'paste in the rule editor to copy lines).
Example (set all silent devices to 50%): Set cc_devices to (CollectDevices type:Chromecast Audio) FOREACH dev IN cc_devices
....IF (dev.Volume < 50) Set Volume on dev to 50 END FOR
This isn't in our plans... As above, beyond the scope of RM. There are ways to integrate with RM from custom apps, see Rule Machine API (forum post available), and through Connectors. Embedding Groovy somehow in a rule is a non-starter.
There are a large number of 3rd party apps published, and installed by users who are not capable of understanding what the code does. The security risk is to other users, not to yourself. You will have to take my word for it that there are bad actors and that these are not imaginary risks.
This is not available, nor planned to ever be available. There are always going to be restricted methods, sandbox restrictions, etc.
I could write Groovy code on my Hubitat only (same as writing rules in Rule Machine), this code would be saved locally on my Hubitat, it can not connect to other users' Hubitat.
=> The security risk is only to myself and never to other users.
Still remains the question: Why not?
Hint: "Security" is not the reason.
So I know it’s not the answer you want and you’re certainly welcome to your opinions, but you’ve already gotten your answer from the powers that be and their answer isn’t going to change. Your replies are not going to be so persuasive to change their stated facts and will more likely just inflame the conversation further.
So my unsolicited advice is to proceed and to write your own apps to do some of the more advanced things you are hoping to do. As you mentioned being a groovy developer, there’s plenty of example code out in the community that should set you down the right path.