The Rules DSL is a customized version of Xtend.
Xtend is a language that runs on the Java Runtime Environment and therefore has access to ALL that Java provides.
So, for the structure of your .rules files and things like triggers and the like look here.
For the general syntax of the language (e.g. variables, for loops, if statements, etc) go here. NOTE, Rules DSL is not Xtend and there are features in Xtend that are not supported like Classes and arrays.
For the Java stuff that is available see this.
For Actions (special functions created by OH for use in Rules) see this.
Xtend’s Collections operations (filter, forEach, et al) use Java’s Stream API. You can see how to use those in an OH Rule’s context in Design Pattern: Working with Groups in Rules.