Skip to content

arrange_timeline ​

POST /arrange_timeline

口径:本页参数表最后核对于 v23.9(2026-10-27)。v24.0~v24.8 的改动(add_video 的 timeline_start/timeline_end 别名、apply_edl 批内失败计数、resource/search 的 limit 与 count 等价、/agent/route 类型分诊等)以 llms-full.txt 与 GET /agent/capabilities 为准。

接口说明 ​

原子化移动或重排同一轨道上的多个片段。接口会先计算整组新时间范围,确认没有重叠后再一次性写入,因此交换相邻片段不会因为中间状态重叠而报错。

请求参数 ​

参数必填默认值说明
draft_id是—草稿 ID
track_name否—要编排的轨道名称
order二选一—片段 ID 数组,按数组顺序从 start 开始依次排列
segments二选一—每个片段显式给出 segment_id 和新的 start、end 或 duration
start否0order 模式的起始时间,单位秒
gap否0order 模式片段之间的间隔,单位秒

调用示例 ​

交换两个相邻图片:

json
{
  "draft_id": "dfd_cat_demo_001",
  "track_name": "image_main",
  "order": ["第二个片段ID", "第一个片段ID"],
  "start": 0
}

显式调整多个片段:

json
{
  "draft_id": "dfd_cat_demo_001",
  "segments": [
    {"segment_id": "第一个片段ID", "start": 0, "duration": 3},
    {"segment_id": "第二个片段ID", "start": 3, "duration": 3}
  ]
}

返回格式 ​

json
{
  "success": true,
  "output": {
    "draft_id": "dfd_cat_demo_001",
    "count": 2,
    "segments": [
      {"segment_id": "第二个片段ID", "start": 0.0, "end": 3.0, "duration": 3.0},
      {"segment_id": "第一个片段ID", "start": 3.0, "end": 6.0, "duration": 3.0}
    ]
  },
  "error": ""
}

个人自建服务