Scripting Bridge

RSS for tag

Automate scriptable apps by sending and receiving Apple events using Scripting Bridge.

Scripting Bridge Documentation

Posts under Scripting Bridge tag

3 Posts
Sort by:
Post not yet marked as solved
0 Replies
44 Views
HI! I am developing an application that should utilize ScriptingBridge.framework to interact with another process. Firstly, I created a separate test application for which I have added Apple Events entitlements via "Signing & Capabilities" section in Xcode and updated its Info.plist to have "Privacy - AppleEvents Sending Usage Description". While the test app works fine (I see an automation request popup and the process executes as expected) the main application where I want to integrate this functionality gets closed immediately after reaching the code interacting with Scripting Bridge. On its launch, I see the following error message from tccd in Console: Prompting policy for hardened runtime; service: kTCCServiceAppleEvents requires entitlement com.apple.security.automation.apple-events but it is missing for accessing={TCCDProcess: identifier=<app bundleID>, ..., binary_path=<path to the app's binary>} I had no such issues with the test app. Moreover, I should mention that the bundle I want to have with such functionality is stored in another bundle, both main and inner bundles aren't sandboxed, and the target app has Application is agent (UIElement) key set in Info.plist. Can you suggest any ideas as to why processes behave so differently despite having pretty much the same build configurations?
Posted
by yblk.
Last updated
.
Post not yet marked as solved
2 Replies
343 Views
My project (an non-sandbox app) was written in Swift on MacOS and it can execute the Apple script successfully. I would like to listen for Privacy &amp; Security &gt; Automation &gt; System Events status changes when the user changes it in System Settings to disable or enable my app feature in MacOS. My app can receive Accessibility changes through this notification "com.apple.accessibility.api" Are there any system notifications for my app to receive Automation &gt; System Events status changes? Thank you!
Posted
by lgminh.
Last updated
.