Editing
Video Editing
Apply local video edits with the Wonda CLI: trim, crop, merge, overlay, captions, audio mixing, and more.
Video editing is CLI-first. wonda edit video downloads inputs when needed, renders locally with ffmpeg or hyperframes, uploads the output media, and prints the resulting mediaId. There is no server-side editor job for current video edits.
The retired POST / endpoint returns 410 Gone with a migration hint for known operations. Move scripts to the CLI commands below.
Setup
Join, then run the install command from your account. It installs Wonda and signs you in.
curl -fsSL https://wonda.sh/install.sh | bash -s -- <your code>
wonda doctorAlready installed? Sign in with wonda auth login.
wonda doctor checks local prerequisites such as ffmpeg. Hyperframes operations such as textOverlay and animatedCaptions also need the bundled Chromium renderer.
Usage
wonda edit video --operation <operation> \
--media <media-id-or-local-file> \
--params '{...}' \
--wait -o ./out.mp4Common flags:
| Flag | Description |
|---|---|
- | Required operation name. Run wonda operations list to see the local registry. |
- | Media IDs or local file paths. Pass multiple inputs as a comma-separated value, such as -. |
- | Raw JSON object for operation-specific params. Run wonda operations info <operation> for the shape. |
- | Featured preset name scoped to -. Explicit - values override preset params. |
- | Audio media ID or local audio file for editAudio. |
- | Required text for textOverlay. |
- | Raw JSON array for animatedCaptions. Produce timing data with wonda alignment extract-. |
- | Accepted for compatibility. Local renders finish before output is printed. |
-, - | Download the rendered output to a local file path. Implies -. |
Video-only shortcut flags:
| Flag | Applies to | Description |
|---|---|---|
- | splitScenes | Scene-change sensitivity from 0. to 0.. |
- | splitScenes | Minimum scene duration in seconds. |
- | splitScenes | split for separate scene files or omit to remove one scene and concatenate the rest. |
- | splitScenes | first, last, or a 1-indexed scene number. |
- | imageToVideo | Hold a still image for this many milliseconds, from 500 to 60000. |
- | skipSilence | Silence detection noise floor in dB. |
- | skipSilence | Shortest gap that counts as silence, in seconds. |
- | skipSilence | Silence beyond this gets cut; remaining silence is bounded to this value. |
Output
Without -, a successful local render prints:
{
"mediaId": "019e1b70-6f9e-80fd-8c49-690bcbdaf8db",
"status": "succeeded"
}With -, the CLI downloads the result and prints the local path plus mediaId:
{
"path": "./trimmed.mp4",
"mediaId": "019e1b70-6f9e-80fd-8c49-690bcbdaf8db"
}splitScenes in split mode prints a scenes array because it can produce multiple media outputs.
Operations
| Operation | Renderer | Inputs | Key params |
|---|---|---|---|
trim | ffmpeg | One video | trimStartMs, trimEndMs |
crop | ffmpeg | One video | aspectRatio, customWidth, customHeight, cropPercent, cropAxis, position, paddingTop |
merge | ffmpeg | Multiple videos | Input order comes from - |
overlay | ffmpeg | Base video plus overlay video | position, resizePercent, resizeAxis, baseVideoVolume, overlayVideoVolume, overlayStartMs, overlayDurationMs |
splitScreen | ffmpeg | Two videos | targetAspectRatio |
speed | ffmpeg | One video | speed, preservePitch |
volume | ffmpeg | One video | volume, muted |
reverseVideo | ffmpeg | One video | None |
extractFrame | ffmpeg | One video | timestampMs or timestampPercent |
extractAudio | ffmpeg | One video | None |
editAudio | ffmpeg | One video plus one audio input | videoVolume, audioVolume, audioStartMs, audioEndMs, audioOffsetMs |
imageToVideo | ffmpeg | One image | durationMs, or the - shortcut |
skipSilence | ffmpeg | One video with audio | silenceThresholdDb, minSilenceDuration, maxSilenceDuration |
splitScenes | ffmpeg | One video | mode, outputSelection, threshold, minClipDuration |
textOverlay | hyperframes | One video or image plus - | Styling params such as fontFamily, position, sizePercent, fontSizeScale, strokeWidth |
animatedCaptions | hyperframes | One video plus - | Caption styling params such as fontFamily, position, sizePercent, fontSizeScale, strokeWidth, highlightColor |
For exact parameter defaults and ranges, run:
wonda operations info trim
wonda operations info textOverlayExamples
Trim a video:
wonda edit video --operation trim --media 019e1b70-6f9e-80fd-8c49-690bcbdaf8db \
--params '{"trimStartMs":3000,"trimEndMs":10000}' \
--wait -o ./trimmed.mp4Merge videos locally:
wonda edit video --operation merge \
--media 019e1b70-6f9e-80fd-8c49-690bcbdaf8db,019e1b72-0742-8bae-bb93-b569036d05af \
--wait -o ./merged.mp4Add a static text overlay:
wonda edit video --operation textOverlay --media 019e1b70-6f9e-80fd-8c49-690bcbdaf8db \
--prompt-text "Launch day" \
--params '{"fontFamily":"TikTok Sans SemiCondensed","position":"top-center","sizePercent":66,"fontSizeScale":0.5,"strokeWidth":4.5}' \
--wait -o ./with-text.mp4Render animated captions:
wonda edit video --operation animatedCaptions --media 019e1b70-6f9e-80fd-8c49-690bcbdaf8db \
--caption-segments '[{"text":"Launch","startS":0},{"text":"day","startS":0.4}]' \
--params '{"fontFamily":"TikTok Sans SemiCondensed","position":"bottom-center","sizePercent":80}' \
--wait -o ./captioned.mp4Replace or mix audio:
wonda edit video --operation editAudio \
--media 019e1b70-6f9e-80fd-8c49-690bcbdaf8db \
--audio-media 019e1b73-32a4-8c9e-8bbf-3661a14a5716 \
--params '{"videoVolume":30,"audioVolume":80,"audioOffsetMs":2000}' \
--wait -o ./with-audio.mp4