Questions about NSAppleScriptMBS.DeterminePermissionToAutomateTarget

The bundle id for DeterminePermissionToAutomateTarget should be the own bundle id, correct?

What does the result of -1 mean? That’s what I get on Sierra when executing the example.

The target is the app you like to control.

-1 is the answer from plugin if the function is not available, e.g. on MacOS 10.13.

Sigh… yes, you are correct. In the security I can see that my app needs permissions for every app it wants to automate.