My Final Cut Pro extension is not allowed assistive access

I’m building an app extension for Final Cut Pro. It includes a main app that doesn't perform any actions, an extension that handles the code execution, and an export app responsible for uploading the exported file.

To assist the user, I’ve added an upload button that triggers an AppleScript. This script exports the current project and then uploads it.

The AppleScript simply selects the share option and the appropriate share destination.

However, the issue arises when I click the upload button: the app asks the user to grant Automation permission, allowing it to control Final Cut Pro and System Events. After granting this permission, the script proceeds to the AppleScript, but an error occurs, stating: System Events got an error: APP is not allowed assistive access.

Is there a permission I'm missing?

My Final Cut Pro extension is not allowed assistive access
 
 
Q