Slightly related, I've added an Object.keys function to the scripting API. Also works on arrays but will return an empty array in that case.

https://github.com/christophhart/HISE/pull/695?new_mergebox=false