How to automatically run a .jsx script from a UXP plugin in Photoshop?

Hi everyone,

I’m trying to trigger an existing .jsx script automatically from within a UXP plugin in Photoshop. My goal is to let the user click a button and have Photoshop run an existing JSX script (e.g. “Mockup.jsx”) that lives in a known path (either inside the plugin folder or in Google Drive Desktop).

I’ve tried the following:

  1. shell.openExternal("file://...") → returns URI scheme "file" is not accepted
  2. shell.openPath(jsxFile.nativePath) → returns Extension ".jsx" is not accepted
  3. Using batchPlay with _obj: "open" and the path to .jsx → also blocked due to extension

I understand that UXP is sandboxed for security, but is there any supported method to trigger a .jsx file (even via bridge or a secure context)?

My setup:

  • Photoshop 25.0+
  • macOS
  • JSX file is valid and works manually via File > Scripts > Browse

Thanks in advance! Any workaround or insight would be appreciated :folded_hands:

Our intention is to keep the UXP and ExtendScript separate, so there isn’t a supported method for what you ask. We acknowledge that converting scripts from .jsx to .psjs is not a simple task. We are dealing with it internally, as well.

While there may still exist workarounds, you shouldn’t expect them to continue indefinitely.

Sam

Hello, any news about the “we are dealing with it internally” part since last summer ? Right now, UXP is not really usable for anyone really serious about developping advanced panels…