Cut And Reframe Video
cut_and_reframe_videoCreate one edited MP4 by cutting and reordering selected time ranges of a video in your Library, keeping the original audio, and reframing each cut for portrait, landscape, square or custom output. Does not choose highlights, transcribe, keep selectable subtitle streams or track faces. Costs 2 credits per started 30 output seconds. Returns a job immediately; check_job returns the permanent URL once it is completed. A failed job is refunded automatically.
1 to 40 non-overlapping ranges, each at least 150 ms, up to 300 output seconds. The source must be a video in your Library; import it with upload_asset first. Ranges are half-open and play in the order listed. Framing is set per range: {"mode":"pad"} keeps the whole frame, {"mode":"center_crop"} fills it, {"mode":"crop"} takes a source-pixel rectangle matching the output aspect ratio with static x and y or up to 20 keyframes (times start at zero for that range). Odd crop sizes are rounded down to even.
Optional captions take source-timed words, such as the words from transcribe; they are moved with the cuts, and a word that straddles a cut is left out while the cut is kept. check_job returns the MP4, contactSheetUrl (one frame per cut) and cuts (where each range landed).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"video_url": "<video_url>",
"segments": "<segments>"
},
"name": "cut_and_reframe_video"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fps | No | Default: source. | |
| name | No | Name for the result in the Library. | |
| tags | No | Tags for the result. | |
| width | No | Output width, even, 128-1920. Default: 1080. | |
| height | No | Output height, even, 128-1920. Default: 1920. | |
| captions | No | Optional burned captions. | |
| segments | Yes | Half-open source ranges in seconds, in playback order. | |
| force_new | No | An identical request submitted in the last 10 minutes returns that job without charging again; true generates it again. | |
| video_url | Yes | A video in your Library; import the file first. | |
| skills_used | No | Optional workflow analytics: names of the skills (or skill/reference paths) followed for this call. Stored with generation jobs only. Never include private data, local paths or media URLs. | |
| audio_fade_ms | No | Fade at each discontinuous audio cut, milliseconds. Default: 30. Above 100 is treated as 100. | |
| budget_project | No | Optional budget project this generation's cost counts toward, for tracking spend per client or job. Pass its slug; an id or the exact display name also works. Create one with create_budget_project and find slugs with list_budget_projects. An unknown project never stops the generation: it runs without one, and the result warns how to add it with assign_to_budget_project. | |
| normalize_audio | No | Level the whole output. Default: false. |