But Keyboard Maestro only has one data-type (String) so when you retrieve the value, its up to you to interpret that 1 as an integer – by applying calc functions etc to it.
I'm working on a subroutine macro that gathers attributes of selected items within the Finder. I plan to return the array of attributes using a JSON string.
That I knew, but I was hoping that there might be a function or token to address this situation.
Yes, not difficult, but I was hoping to simplify if it was unnecessary.
If you wanted to detect and report the types of values, perhaps returning them in key value tuples {type: "Number", value: 2} etc
you could do some preprocessing in JavaScript for automation to get a 'typeof' type name for the value, and make use of it in KM actions.