Can I run KM JXA Functions Without Automatically Opening KM Editor?

Whenever I call Application(“Keyboard Maestro”) in JXA, it opens up the editor. Is there a way to make so that it doesn’t open up the editor, so I can enable/disable macros/macro groups in the background?
@peternlewis, if this is not possible, I think it would be great to duplicate all the applescript hooks from Keyboard Maestro for Keyboard Maestro Engine as well. Then we could use all those awesome functions in the background without opening the editor!
I also know that this could be achieved from doScript with xml string through KME (not KM), but it would be so much nicer if we could do the same way in KM.
kme = Application(“Keyboard Maestro Engine”)
kme.setmacroenable(“Macro Name or ID”, {enable:true})
Thanks!

You cannot use Application(“Keyboard Maestro”) without opening the Keyboard Maestro editor.

You can use Application(“Keyboard Maestro Engine”) without opening the editor, and you can enable/disable macro groups with that, but only by execute macro actions.

Thanks @peternlewis for the reply.

You can use Application(“Keyboard Maestro Engine”) without opening the
editor, and you can enable/disable macro groups with that, but only by
execute macro actions.

Does “execute macro actions” mean doScript with xml?
It would be amazing if we could easily activate/deactivate
enable/disable macro/macro groups using Keyboard Maestro Engine through
JXA without having to use xml.
Can I ask for feature request? :slight_smile:
Thanks!