Tag Object in Event Scripts Documentation

The documentation describes the modern approach to accessing parameters via the tag object:
paramValue =tag['parameters']['myParam']

https://docs.inductiveautomation.com/display/DOC81/Tag+Event+Scripts

A thread here alludes to some other properties:

I could not find any other documentation as to what else is contained in that object. I do a lot of string manipulation of the tagPath in event script to read properties, and I think some of those properties might be in the tag object.

Is there some more detail somewhere or even some kind of recursive introspection one can do on that tag object?

Most of the known properties are going to be from this list of constants:
https://files.inductiveautomation.com/sdk/javadoc/ignition81/8.1.24/com/inductiveautomation/ignition/common/tags/config/properties/WellKnownTagProps.html

You can always dir() the object to do introspection at runtime. It looks like tag.getPropertyModel().getProperties() will also have a pretty complete list from the runtime object.

1 Like

Thanks. I'll have a look to see if there is something I can use rather than tag reads