Item state in Javascript transformation accessible?

Hi,
is it possible to access item states from Javascrip transformations. I’d like to use them to set defaults outside the javascript and I can not pass them to the script as they are invoked by an mqtt channel.

The script itself creates a JSON request.

Thanks very much.

There is no way I know of. Only the state gets passed to the transformation as a String. There is no access to anything else outside of that in the transformation.

Thanks very much.