@synthetic-ai/premiere-mcp 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. package/CHANGELOG.md +73 -0
  2. package/LICENSE +21 -0
  3. package/README.md +242 -0
  4. package/cep-plugin/.debug +8 -0
  5. package/cep-plugin/CSInterface.js +70 -0
  6. package/cep-plugin/CSXS/manifest.xml +49 -0
  7. package/cep-plugin/host.jsx +7 -0
  8. package/cep-plugin/index.html +419 -0
  9. package/cep-plugin/main.js +327 -0
  10. package/cep-plugin/premiere.jsx +24947 -0
  11. package/cep-plugin/synthetic-logo.png +0 -0
  12. package/dist/bridge/file-bridge.d.ts +29 -0
  13. package/dist/bridge/file-bridge.js +145 -0
  14. package/dist/bridge/script-builder.d.ts +19 -0
  15. package/dist/bridge/script-builder.js +408 -0
  16. package/dist/http-server.d.ts +21 -0
  17. package/dist/http-server.js +140 -0
  18. package/dist/index.d.ts +3 -0
  19. package/dist/index.js +70 -0
  20. package/dist/resources/extendscript-reference.d.ts +2 -0
  21. package/dist/resources/extendscript-reference.js +219 -0
  22. package/dist/server.d.ts +4 -0
  23. package/dist/server.js +276 -0
  24. package/dist/tools/advanced.d.ts +530 -0
  25. package/dist/tools/advanced.js +923 -0
  26. package/dist/tools/audio-advanced.d.ts +847 -0
  27. package/dist/tools/audio-advanced.js +1653 -0
  28. package/dist/tools/audio.d.ts +84 -0
  29. package/dist/tools/audio.js +123 -0
  30. package/dist/tools/captions.d.ts +30 -0
  31. package/dist/tools/captions.js +73 -0
  32. package/dist/tools/clipboard.d.ts +153 -0
  33. package/dist/tools/clipboard.js +381 -0
  34. package/dist/tools/color-advanced.d.ts +821 -0
  35. package/dist/tools/color-advanced.js +772 -0
  36. package/dist/tools/discovery.d.ts +128 -0
  37. package/dist/tools/discovery.js +445 -0
  38. package/dist/tools/effects.d.ts +211 -0
  39. package/dist/tools/effects.js +554 -0
  40. package/dist/tools/export-presets.d.ts +333 -0
  41. package/dist/tools/export-presets.js +490 -0
  42. package/dist/tools/export.d.ts +320 -0
  43. package/dist/tools/export.js +618 -0
  44. package/dist/tools/health.d.ts +9 -0
  45. package/dist/tools/health.js +25 -0
  46. package/dist/tools/inspection.d.ts +179 -0
  47. package/dist/tools/inspection.js +1089 -0
  48. package/dist/tools/keyframes.d.ts +253 -0
  49. package/dist/tools/keyframes.js +611 -0
  50. package/dist/tools/markers.d.ts +117 -0
  51. package/dist/tools/markers.js +206 -0
  52. package/dist/tools/media.d.ts +297 -0
  53. package/dist/tools/media.js +493 -0
  54. package/dist/tools/metadata.d.ts +178 -0
  55. package/dist/tools/metadata.js +278 -0
  56. package/dist/tools/multicam.d.ts +199 -0
  57. package/dist/tools/multicam.js +212 -0
  58. package/dist/tools/playback.d.ts +34 -0
  59. package/dist/tools/playback.js +63 -0
  60. package/dist/tools/playhead.d.ts +77 -0
  61. package/dist/tools/playhead.js +185 -0
  62. package/dist/tools/project-manager.d.ts +65 -0
  63. package/dist/tools/project-manager.js +81 -0
  64. package/dist/tools/project.d.ts +390 -0
  65. package/dist/tools/project.js +596 -0
  66. package/dist/tools/scripting.d.ts +98 -0
  67. package/dist/tools/scripting.js +434 -0
  68. package/dist/tools/selection.d.ts +120 -0
  69. package/dist/tools/selection.js +334 -0
  70. package/dist/tools/sequence-advanced.d.ts +84 -0
  71. package/dist/tools/sequence-advanced.js +471 -0
  72. package/dist/tools/sequence-settings.d.ts +397 -0
  73. package/dist/tools/sequence-settings.js +967 -0
  74. package/dist/tools/sequence.d.ts +211 -0
  75. package/dist/tools/sequence.js +378 -0
  76. package/dist/tools/source-monitor.d.ts +95 -0
  77. package/dist/tools/source-monitor.js +180 -0
  78. package/dist/tools/text.d.ts +97 -0
  79. package/dist/tools/text.js +159 -0
  80. package/dist/tools/timeline.d.ts +265 -0
  81. package/dist/tools/timeline.js +575 -0
  82. package/dist/tools/track-management.d.ts +482 -0
  83. package/dist/tools/track-management.js +787 -0
  84. package/dist/tools/track-targeting.d.ts +666 -0
  85. package/dist/tools/track-targeting.js +1318 -0
  86. package/dist/tools/tracks.d.ts +90 -0
  87. package/dist/tools/tracks.js +183 -0
  88. package/dist/tools/transitions-motion.d.ts +788 -0
  89. package/dist/tools/transitions-motion.js +680 -0
  90. package/dist/tools/transitions.d.ts +124 -0
  91. package/dist/tools/transitions.js +267 -0
  92. package/dist/tools/utility.d.ts +469 -0
  93. package/dist/tools/utility.js +1118 -0
  94. package/dist/tools/workspace.d.ts +25 -0
  95. package/dist/tools/workspace.js +61 -0
  96. package/package.json +66 -0
  97. package/scripts/build-chat-dmg.sh +210 -0
  98. package/scripts/build-chat-zip.sh +291 -0
  99. package/scripts/install-cep-windows.ps1 +99 -0
  100. package/scripts/install-cep.sh +66 -0
  101. package/scripts/install-chat-plugin.bat +67 -0
  102. package/scripts/install-chat-plugin.sh +85 -0
  103. package/scripts/install-windows.bat +95 -0
  104. package/scripts/package.mjs +218 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,73 @@
1
+ # Changelog
2
+
3
+ All notable changes to this MCP server. Every fix below was discovered via
4
+ **static audit + live runtime testing against Premiere Pro 2026.2.2 on
5
+ Spanish-localized Windows**.
6
+
7
+ The audit started at **31/100 sellability score** (22% green tools) and
8
+ finished at **~78/100** (~75% green) after the rounds below.
9
+
10
+ ---
11
+
12
+ ## [v1.2.0] — PP 2026 compatibility + locale resilience
13
+
14
+ ### Round 6 — Live runtime validation
15
+ - `6f20892` capture_frame: honest error for PP 2026 host limitation
16
+ - `8152021` bridge: sanitize NaN and Infinity to null
17
+ - `a74ce33` Round 5: 8 more fixes from full smoke test (137 tools tested)
18
+ - `45fdaba` track-targeting: locale-resilient set_clip_position/scale/rotation
19
+ - `f9589cb` premiere.jsx: locale-resilient fadeIn/fadeOut/crossFadeClips
20
+ - `29e941d` graceful fallbacks for setSpeed signature + track volume
21
+ - `0533162` Live-test fixes: setSpeed signature, locale prop names, audio clip volume
22
+ - `084ef49` Live-test fixes: set_clip_opacity locale, color_correct Lumetri name
23
+
24
+ ### Round 5 — Bridge JSON sanitization
25
+ - `f3d83d7` Fix bridge JSON: ExtendScript ignores replacer; sanitize tree pre-stringify
26
+
27
+ ### Round 4 — premiere.jsx loading (single highest-impact fix)
28
+ - `366f325` Fix premiere.jsx SyntaxError that broke ALL JSX helpers
29
+ - **1-char fix, ~30+ tools unblocked**
30
+ - `premiere.jsx` (22k lines) had `package:` as bare property name at line
31
+ 22006. ExtendScript is strict ES3 where `package` is reserved → entire
32
+ file fails to parse → every JSX-helper-backed tool returns
33
+ `ReferenceError: <fn> is not a function`. Quoting fixes everything.
34
+ - `b12a0d8` Round 4: bridge JSON-parse failure + locale-resilient transition lookup
35
+
36
+ ### Round 3 — Concrete code bugs from re-audit
37
+ - `21bf821` Round 3 part 2: fix remaining 9 files
38
+ - `e4534d5` Round 3: fix 32 concrete code bugs from re-audit
39
+ - ticks/Time correctness (markers, source-monitor, scripting, clipboard, audio)
40
+ - property-vs-method (media.check_offline_media)
41
+ - QE-only methods routed correctly (timeline.move_clip/speed_change, transitions)
42
+ - missing `app.enableQE()` guards
43
+ - nested Lumetri prop lookup via `__findProp`
44
+
45
+ ### Round 2 — Locale-resilient helpers
46
+ - `bdaebaa` Round 2: guard QE multicam enumeration and proxy detach
47
+ - `48d3648` Round 2 part 2: fix remaining 8 files
48
+ - `2b718b3` Round 2 part 1: locale-resilient helpers + fix 13 tool files
49
+ - Added `__findIntrinsic(clip, key)` with matchName-first lookup
50
+ - Added `__findComponent`, `__findProp`, `__readMaybe`, `__findTransition`
51
+
52
+ ### Round 1 — Property-vs-method bugs
53
+ - `ffe6931` Fix 21 red tools: property-vs-method bugs, missing APIs, stub handlers
54
+ - `35ecbfa` Fix PP 2026 compatibility: sequence creation, tracks, audio, effects, export
55
+
56
+ ---
57
+
58
+ ## Validated tool inventory
59
+
60
+ ### ✅ 66 tools confirmed working in runtime (PP 2026.2.2 es-ES)
61
+ Inspection, transform, audio/video FX, timeline editing, selection, markers,
62
+ sequence ops, project/bins, captions, source monitor, track management,
63
+ metadata, scripting, export. Full list in [README.md](README.md).
64
+
65
+ ### ⚠️ Honest errors (PP 2026 host limitations, not bugs)
66
+ - `set_track_volume`, `speed_change`, `capture_frame`, Lumetri-when-not-applied
67
+ - All return clear errors with the recommended UI workaround
68
+
69
+ ### Validated against
70
+ - Premiere Pro 2026.2.2 on Windows
71
+ - Spanish (es-ES) locale — names like "Opacidad", "Movimiento", "Escala",
72
+ "Posición", "Disolvencia cruzada" all handled
73
+ - 15-item test project with multi-track timeline, transitions, fades, Lumetri
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Premiere Pro MCP Contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,242 @@
1
+ # Premiere Pro MCP
2
+
3
+ **Control Adobe Premiere Pro with natural language through Claude (or any MCP-compatible LLM).**
4
+
5
+ [![Premiere Pro 2026](https://img.shields.io/badge/Premiere%20Pro-2026-blueviolet)](https://www.adobe.com/products/premiere.html)
6
+ [![MCP](https://img.shields.io/badge/MCP-compatible-green)](https://modelcontextprotocol.io)
7
+ [![License](https://img.shields.io/badge/license-MIT-blue)](LICENSE)
8
+
9
+ ---
10
+
11
+ ## What it does
12
+
13
+ ```
14
+ You: "Apply a cinematic look to all clips on V1, ducking the music
15
+ when there's voice, and export to YouTube 1080p."
16
+
17
+ Claude: ✓ Applied Lumetri (-15K temperature, +10 contrast) to 4 clips
18
+ ✓ Added voiceover ducking on A2 (-12dB during A1 voice)
19
+ ✓ Queued H.264 1080p export to ~/Videos/final.mp4
20
+ ```
21
+
22
+ 437 tools exposed via MCP to drive Premiere Pro 2026 from any LLM agent.
23
+ Tested in runtime against PP 2026.2.2 on Spanish-localized Windows install.
24
+
25
+ ---
26
+
27
+ ## Highlights
28
+
29
+ - **Locale-resilient**: works on Premiere Pro in Spanish, German, French, etc.
30
+ (most competitors hardcode English component names and silently fail)
31
+ - **Honest errors**: when a Premiere host API genuinely doesn't expose
32
+ something (PP 2026 has known limitations), you get a clear error with
33
+ the recommended workaround — not a silent no-op
34
+ - **Battle-tested**: 137 tools validated in live runtime against PP 2026 with
35
+ detailed bug fixes (see [CHANGELOG.md](CHANGELOG.md))
36
+ - **AI-first**: built for LLM-driven workflows. Pair it with Whisper for
37
+ speech-to-text, ComfyUI for thumbnails, FFmpeg for analysis — chain MCPs
38
+
39
+ ---
40
+
41
+ ## Quick start
42
+
43
+ ### 1. Install the CEP plugin
44
+
45
+ Copy `cep-plugin/` to your Adobe CEP extensions folder:
46
+
47
+ - **Windows**: `%APPDATA%\Adobe\CEP\extensions\MCPBridgeCEP\`
48
+ - **macOS**: `~/Library/Application Support/Adobe/CEP/extensions/MCPBridgeCEP/`
49
+
50
+ Enable CEP debugging:
51
+ ```powershell
52
+ # Windows
53
+ reg add HKCU\Software\Adobe\CSXS.11 /v PlayerDebugMode /t REG_SZ /d 1 /f
54
+ ```
55
+
56
+ ### 2. Build the MCP server
57
+
58
+ ```bash
59
+ cd premiere-pro-mcp
60
+ npm install
61
+ npm run build
62
+ ```
63
+
64
+ ### 3. Register with Claude Desktop
65
+
66
+ Add to `%APPDATA%\Claude\claude_desktop_config.json`:
67
+
68
+ ```json
69
+ {
70
+ "mcpServers": {
71
+ "premiere-pro": {
72
+ "command": "node",
73
+ "args": ["C:/path/to/premiere-pro-mcp/dist/index.js"]
74
+ }
75
+ }
76
+ }
77
+ ```
78
+
79
+ ### 4. Open Premiere Pro
80
+
81
+ - Launch Premiere Pro 2026
82
+ - `Window > Extensions > MCPBridgeCEP` (the bridge panel)
83
+ - Click "Start Bridge"
84
+
85
+ ### 5. Talk to Claude
86
+
87
+ ```
88
+ "Show me the active sequence structure."
89
+ "Add a 1-second fade-in to the audio clip on A2."
90
+ "Apply Cross Dissolve at every cut on V1, 0.5 seconds each."
91
+ ```
92
+
93
+ ---
94
+
95
+ ## What works (validated runtime, PP 2026 es-ES)
96
+
97
+ ### Project & Inspection
98
+ - Full project / sequence / clip overviews
99
+ - Bins, markers, metadata (XMP), color labels
100
+ - Effect properties with all values, keyframes, source media details
101
+ - Find/search project items, list sequences
102
+
103
+ ### Timeline editing
104
+ - Add/remove/move/duplicate clips, split, trim
105
+ - Set in/out points, playhead, work area
106
+ - Selection by name/range/color, invert, deselect
107
+ - Enable/disable clips, link/unlink
108
+
109
+ ### Transform & Motion
110
+ - Position, scale, rotation, opacity (locale-resilient)
111
+ - Anchor point, blend mode
112
+ - Position/scale keyframes via `add_keyframe`
113
+
114
+ ### Color
115
+ - Lumetri full parameter control: exposure, contrast, highlights/shadows,
116
+ whites/blacks, temperature/tint, saturation, vibrance, sharpen, vignette,
117
+ faded film
118
+ - LUTs apply
119
+ - Copy/paste color grade across clips
120
+ - ⚠️ See limitations: applying Lumetri *for the first time* requires manual UI
121
+
122
+ ### Audio
123
+ - Per-clip volume, fade in/out (locale-resilient)
124
+ - Volume/panning keyframes
125
+ - Audio FX pipeline: Compressor, EQ, De-Esser, De-Hum, De-Reverb, Limiter,
126
+ Noise Reduction
127
+ - Voiceover ducking
128
+ - Normalize, detect clipping
129
+
130
+ ### Effects & Transitions
131
+ - 60+ video effects (Gaussian/Directional Blur, Sharpen, Warp Stabilizer,
132
+ Noise Reduction, Mirror, Spherize, Corner Pin, Lens Distortion, etc.)
133
+ - Transitions with locale-aware name lookup (Cross Dissolve works on any
134
+ language install)
135
+ - Batch apply across cuts
136
+
137
+ ### Captions
138
+ - Import SRT files as caption tracks
139
+ - Pipeline integration: Whisper-transcribe → SRT → MCP creates captions
140
+
141
+ ### Export
142
+ - Single sequence + batch export via Adobe Media Encoder
143
+ - Match Source presets, YouTube/Vimeo/Twitter/Facebook presets
144
+ - Encode arbitrary files via AME
145
+ - AAF, OMF, FCPXML export
146
+
147
+ ### Multicam
148
+ - Create multicam sequences, switch angles, flatten
149
+
150
+ ### Markers
151
+ - Add/update/delete on sequence or clip
152
+ - Color labels, comments, in/out range
153
+ - Import/export CSV
154
+
155
+ ---
156
+
157
+ ## Known limitations (PP 2026 host)
158
+
159
+ These are not bugs in this MCP — they're verified limitations of Premiere Pro
160
+ 2026's ExtendScript/QE-DOM surface. Each tool returns a clear actionable error
161
+ with the recommended workaround.
162
+
163
+ | Feature | Status | Workaround |
164
+ |---------|--------|------------|
165
+ | `capture_frame` programmatic | ❌ `qeSeq.exportFramePNG` reports success but never writes file | UI: File > Export > Media > Single Frame |
166
+ | `set_track_volume` | ❌ Audio track DOM no longer exposes `.components` or `.volume`; QE has no `setVolume` | Use `add_audio_keyframes` per-clip, or Audio Track Mixer |
167
+ | `speed_change` programmatic | ❌ `qeClip.setSpeed` signature changed in PP 2026 (rejects all known forms) | UI: Clip > Speed/Duration, or change duration with `trim_clip` |
168
+ | Apply Lumetri for the first time | ❌ `addVideoEffect` reports success but doesn't add component | Apply Lumetri manually once; afterwards all 28 setters work perfectly |
169
+ | LUFS integrated measurement | ❌ Not scriptable | Export and measure with ffmpeg-loudnorm |
170
+ | Native PP Speech-to-Text | ❌ Adobe AI STT not exposed | Use Whisper + `create_caption_track` (works great) |
171
+ | Adobe Libraries MOGRT | ❌ Adobe Libraries not scriptable | Use local `.mogrt` files via `import_mogrt` |
172
+ | Dynamic Link with AE | ❌ `import_ae_comps` not implemented | Render from AE and import as video |
173
+ | Async export completion | ⚠️ AME runs async, no callback | Poll `get_render_queue_status` |
174
+
175
+ ---
176
+
177
+ ## Architecture
178
+
179
+ ```
180
+ ┌─────────────┐ ┌──────────────┐ ┌─────────────┐
181
+ │ Claude │ │ Node.js │ │ Premiere │
182
+ │ (or LLM) │◄───────►│ MCP server │◄───────►│ Pro CEP │
183
+ └─────────────┘ stdio └──────────────┘ files │ plugin │
184
+ │ (panel) │
185
+ └─────────────┘
186
+ │
187
+ ▼
188
+ ┌──────────────┐
189
+ │ ExtendScript │
190
+ │ DOM + QE │
191
+ └──────────────┘
192
+ ```
193
+
194
+ The bridge automatically prepends locale-resilient helpers to every script:
195
+
196
+ ```javascript
197
+ __findIntrinsic(clip, "motion" | "opacity" | "volume" | "lumetri" | "timeRemap")
198
+ // tries matchName ("AE.ADBE Motion") first — locale-INDEPENDENT —
199
+ // then localized displayName ("Movimiento", "Bewegung", "Mouvement", etc.)
200
+
201
+ __findProp(component, ["Position", "Posición", "Position", "Position"])
202
+ // also descends one level into nested groups (needed for Lumetri's
203
+ // grouped parameters like Exposure inside Basic Correction)
204
+
205
+ __readMaybe(obj, "isMuted", false)
206
+ // reads members that are property in some PP versions, method in others
207
+
208
+ __findTransition(name, "video")
209
+ // resolves transition names across locales:
210
+ // "Cross Dissolve" matches "Disolvencia cruzada" / "Fondu enchaîné"
211
+ ```
212
+
213
+ ---
214
+
215
+ ## Development
216
+
217
+ ```bash
218
+ npm run dev # Watch mode
219
+ npm run build # Build dist/
220
+ npx tsc --noEmit # Type-check only
221
+ ```
222
+
223
+ When adding a tool, prefer:
224
+ - `__findIntrinsic` / `__findComponent` over hardcoded `displayName === "Motion"`
225
+ - `__readMaybe` for any `isSomething()` / `isSomething` property
226
+ - Pass `.ticks` strings (not Time objects) to `insertClip`/`setInPoint`/etc.
227
+
228
+ ---
229
+
230
+ ## Credits
231
+
232
+ Built on top of work from
233
+ [`AdobePremiereProMCP`](https://github.com/bdenney99/AdobePremiereProMCP)
234
+ with extensive fixes for PP 2026 compatibility, locale resilience, and
235
+ runtime-validated behavior. See [CHANGELOG.md](CHANGELOG.md) for the full
236
+ fix log.
237
+
238
+ ---
239
+
240
+ ## License
241
+
242
+ MIT
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <ExtensionList>
3
+ <Extension Id="com.mcp.premiere.bridge.panel">
4
+ <HostList>
5
+ <Host Name="PPRO" Port="8088"/>
6
+ </HostList>
7
+ </Extension>
8
+ </ExtensionList>
@@ -0,0 +1,70 @@
1
+ /**************************************************************************************************
2
+ * ADOBE SYSTEMS INCORPORATED
3
+ * Copyright 2013 Adobe Systems Incorporated
4
+ * All Rights Reserved.
5
+ *
6
+ * NOTICE: Adobe permits you to use, modify, and distribute this file in accordance with the
7
+ * terms of the Adobe license agreement accompanying it. If you have received this file from a
8
+ * source other than Adobe, then your use, modification, or distribution of it requires the prior
9
+ * written permission of Adobe.
10
+ *
11
+ * CSInterface.js - v12.0.0 (minimal shim for MCP Bridge)
12
+ * Download the full version from: https://github.com/nicscott9/CSInterface
13
+ **************************************************************************************************/
14
+
15
+ /**
16
+ * CSInterface class for Adobe CEP extensions.
17
+ * This is a minimal implementation. For production use, download the full
18
+ * CSInterface.js from Adobe's GitHub repository.
19
+ */
20
+ function CSInterface() {}
21
+
22
+ /**
23
+ * Evaluates an ExtendScript in the host application.
24
+ * @param {string} script - The ExtendScript to evaluate.
25
+ * @param {function} callback - Callback with the result string.
26
+ */
27
+ CSInterface.prototype.evalScript = function (script, callback) {
28
+ if (typeof __adobe_cep__ !== "undefined") {
29
+ // CEP 9+ requires the callback to be passed directly to __adobe_cep__.evalScript.
30
+ // Calling it without a callback causes the result to be silently discarded,
31
+ // making every command return null/undefined.
32
+ __adobe_cep__.evalScript(script, callback || function () {});
33
+ } else {
34
+ // Running outside CEP (for testing)
35
+ console.warn("[CSInterface] Not running in CEP environment");
36
+ if (callback) callback("EvalScript Error: Not in CEP environment");
37
+ }
38
+ };
39
+
40
+ /**
41
+ * Get the host environment.
42
+ */
43
+ CSInterface.prototype.getHostEnvironment = function () {
44
+ if (typeof __adobe_cep__ !== "undefined") {
45
+ try {
46
+ return JSON.parse(__adobe_cep__.getHostEnvironment());
47
+ } catch (e) {
48
+ return null;
49
+ }
50
+ }
51
+ return null;
52
+ };
53
+
54
+ /**
55
+ * Get the system path.
56
+ * @param {string} pathType - The path type constant.
57
+ */
58
+ CSInterface.prototype.getSystemPath = function (pathType) {
59
+ if (typeof __adobe_cep__ !== "undefined") {
60
+ return __adobe_cep__.getSystemPath(pathType);
61
+ }
62
+ return "";
63
+ };
64
+
65
+ // System path constants
66
+ CSInterface.prototype.EXTENSION_ID = "extensionId";
67
+
68
+ // Note: This is a minimal shim. For the full CSInterface.js, download from:
69
+ // https://github.com/nicscott9/CSInterface
70
+ // and replace this file with the appropriate version for your CEP target.
@@ -0,0 +1,49 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <ExtensionManifest Version="7.0" ExtensionBundleId="com.mcp.premiere.bridge" ExtensionBundleVersion="1.1.1" ExtensionBundleName="MCP Bridge">
3
+ <ExtensionList>
4
+ <Extension Id="com.mcp.premiere.bridge.panel" Version="1.1.1"/>
5
+ </ExtensionList>
6
+ <ExecutionEnvironment>
7
+ <HostList>
8
+ <Host Name="PPRO" Version="[14.0,99.9]"/>
9
+ </HostList>
10
+ <LocaleList>
11
+ <Locale Code="All"/>
12
+ </LocaleList>
13
+ <RequiredRuntimeList>
14
+ <RequiredRuntime Name="CSXS" Version="9.0"/>
15
+ </RequiredRuntimeList>
16
+ </ExecutionEnvironment>
17
+ <DispatchInfoList>
18
+ <Extension Id="com.mcp.premiere.bridge.panel">
19
+ <DispatchInfo>
20
+ <Resources>
21
+ <MainPath>./index.html</MainPath>
22
+ <ScriptPath>./host.jsx</ScriptPath>
23
+ <CEFCommandLine>
24
+ <Parameter>--allow-file-access-from-files</Parameter>
25
+ <Parameter>--enable-nodejs</Parameter>
26
+ </CEFCommandLine>
27
+ </Resources>
28
+ <Lifecycle>
29
+ <AutoVisible>true</AutoVisible>
30
+ </Lifecycle>
31
+ <UI>
32
+ <Type>Panel</Type>
33
+ <Menu>Synthetic Premiere MCP</Menu>
34
+ <Geometry>
35
+ <Size>
36
+ <Height>300</Height>
37
+ <Width>400</Width>
38
+ </Size>
39
+ <MinSize>
40
+ <Height>200</Height>
41
+ <Width>300</Width>
42
+ </MinSize>
43
+ </Geometry>
44
+ <Icons/>
45
+ </UI>
46
+ </DispatchInfo>
47
+ </Extension>
48
+ </DispatchInfoList>
49
+ </ExtensionManifest>
@@ -0,0 +1,7 @@
1
+ // Host-side ExtendScript (runs in Premiere Pro's ExtendScript engine)
2
+ // This file can contain ExtendScript helper functions that are always available.
3
+ // The main execution happens dynamically via CSInterface.evalScript() from main.js.
4
+
5
+ function mcpBridgePing() {
6
+ return "pong";
7
+ }