Skip to main content

Drive Adobe Premiere Pro from the command line: a Python CLI plus a bundled CEP bridge panel exposing Premiere's scripting APIs over local HTTP

Project description

premiere-cli

Drive Adobe Premiere Pro from the command line.

premiere-cli pairs a zero-dependency Python CLI (premiere-cli, premiere-log) with a bundled CEP panel ("Premiere Bridge") that runs a local HTTP server (port 47823) inside Premiere Pro and exposes its ExtendScript / QE scripting APIs as ~230 JSON-in/JSON-out commands — reading project/sequence/clip state, editing the timeline, applying effects, managing markers and bins, exporting media and frames, and more.

It is also a Claude Code plugin: install it and Claude gets a skill documenting every command, so it can inspect and edit your open Premiere project for you.

Install

# 1. The CLI (isolated, no dependencies)
pipx install git+https://github.com/stefanwebb/premiere-cli
#    or: uv tool install git+https://github.com/stefanwebb/premiere-cli

# 2. The CEP panel (copies it into Adobe's extensions dir + enables PlayerDebugMode)
premiere-cli install-panel

# 3. Restart Premiere Pro, open  Window > Extensions > Premiere Bridge

# 4. Verify the whole chain
premiere-cli doctor

Supported: macOS and Windows (CEP does not exist on Linux). The panel targets Premiere Pro 2020+ (CEP 10-12); the API behavior notes in docs/BUILD_FINDINGS.md were live-calibrated on Premiere Pro 26.3.0 (macOS) — Premiere's undocumented QE APIs vary by build, so re-verify build-sensitive commands on other versions.

Use from the command line

premiere-cli get-premiere-state
premiere-cli get-active-sequence
premiere-cli add-marker --seconds 12.5 --name "Chapter 1"
premiere-cli export-frame --output /tmp/frame.png --timecode 00:12:05
premiere-log "rendering pass 2/3 started"   # shows up in the panel's log view

Every command prints a JSON object: {"ok": true, "result": ...} or {"ok": false, "error": "..."} (exit code 1). Full command reference: docs/COMMANDS.md.

Use from Claude Code

/plugin marketplace add stefanwebb/premiere-cli
/plugin install premiere-cli@premiere-cli

This gives Claude the premiere-cli skill — a complete, behavior-annotated catalog of the panel's commands (including which ones are verified working, build-sensitive, or destructive). You still need steps 1-4 above so the premiere-cli binary and panel exist on the machine.

How it works

premiere-cli ──HTTP──> CEP panel (Node server, port 47823)
                            │ csInterface.evalScript
                            ▼
                       ppb_dispatch() ──$.evalFile──> host/commands/<name>.jsx
                            │
                            ▼
                Premiere DOM (app.project...) + QE DOM (qe.project...)
  • Each command is one ExtendScript file under src/premiere_cli/panel/host/commands/, lazily loaded on first use.
  • Mutating commands verify their own effect with read-backs (clip counts, property values, undo-stack index) — never by trusting an API's return value, since several Premiere APIs "succeed" without doing anything.
  • docs/ carries the hard-won API findings: which Premiere scripting APIs are broken, which lie, and the calibrated signatures that actually work (BUILD_FINDINGS.md, PREMIERE_API_NOTES.md, QE_DOM_NOTES.md).

Scope

This package deliberately contains only the machinery to drive Premiere Pro's APIs. AI-assisted workflows built on top of it (transcription with word-level timestamps, silence removal, etc.) live separately and depend on this package.

Development

git clone https://github.com/stefanwebb/premiere-cli
cd premiere-cli
pip install -e ".[dev]"
premiere-cli install-panel --symlink   # panel edits apply on next panel reload
pytest

Adding a panel command means three edits: the new host/commands/<name>.jsx, its registration in host/index.jsx (PPB_COMMANDS), and the allowlist in js/main.js (ALLOWED_COMMANDS) — plus a CLI subparser in src/premiere_cli/cli.py and a row in docs/COMMANDS.md. Bump the version in pyproject.toml, premiere_cli/__init__.py, and PANEL_VERSION in js/main.js together (premiere-cli doctor flags mismatches).

License

CC-BY-SA-4.0.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

premiere_cli-0.2.0.tar.gz (270.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

premiere_cli-0.2.0-py3-none-any.whl (459.3 kB view details)

Uploaded Python 3

File details

Details for the file premiere_cli-0.2.0.tar.gz.

File metadata

  • Download URL: premiere_cli-0.2.0.tar.gz
  • Upload date:
  • Size: 270.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for premiere_cli-0.2.0.tar.gz
Algorithm Hash digest
SHA256 553ff07e3a93f36ed7969280ac3a250e72b058418917c734b5762f7ee83b4782
MD5 0d6d7eb816b26a9d4bf6f8e0e65f20a3
BLAKE2b-256 632c7f1c3164078dfdb83960217117f10c9bcecde48288586a85a0cabb90471c

See more details on using hashes here.

File details

Details for the file premiere_cli-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: premiere_cli-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 459.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for premiere_cli-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 26ed01410329ad17a25ac1b06f7b9cbab8d2b0eb9ac37c1bb1d0b554aef926c9
MD5 336be04f345b01f665dd95a0fa9c99f0
BLAKE2b-256 19ca18b1fc0cdf926e406bb7a605785828456006bb98f429d1ec10f06e7b12bf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page