GN4XMLCommand support has been added to InDesign scripting. It can be used to automate InDesign and the GN4 plug-ins. GN4XMLCommand is added to the InDesign.Application object and can take and return an XML string.
Use the Table of Contents to find information. See also Using table of contents in help.