DaVinci Resolve-compatible Python scripting API for Kdenlive via D-Bus.
Scripts written for the Resolve API work with minimal changes. The library communicates with a modified Kdenlive build that exposes Q_SCRIPTABLE methods over D-Bus (org.kde.kdenlive.scripting).
pip install -r requirements.txtfrom kdenlive_api import Resolve
resolve = Resolve()
pm = resolve.GetProjectManager()
project = pm.GetCurrentProject()
timeline = project.GetCurrentTimeline()
# Import media and build a timeline
pool = project.GetMediaPool()
clips = pool.ImportMedia(["scene01.mp4", "scene02.mp4"])
pool.AppendToTimeline(clips)Resolve
└── ProjectManager
└── Project
├── MediaPool
│ ├── Folder
│ └── MediaPoolItem
├── MediaStorage
└── Timeline
└── TimelineItem
All class and method names follow the DaVinci Resolve Scripting API naming conventions. Kdenlive-specific extensions (transitions, clip insertion, audio track) are added on top.
| Script | Description |
|---|---|
scripts/build_timeline.py |
Reads a scene script and builds a complete Kdenlive project |
scripts/replace_scene.py |
Swaps a single scene clip on the timeline |
scripts/add_transitions.py |
Applies a transition map (dissolve, wipe, cut) between scenes |
scripts/preview.py |
Prints a text summary of the current timeline |
- Python 3.10+
- Linux (D-Bus transport requires
pydbusandPyGObject) - Modified Kdenlive build with D-Bus scripting support
- API reference — full class/method documentation
- MoSCoW priorities — feature prioritization
pytest tests/81 unit tests using a MockDBus backend — no running Kdenlive instance needed.
MIT