Skip to content

Functional Description

After modifying the timeline json, start the synthesis task

Update Notes

Update TimeUpdate Notes
2024.04.23To facilitate the addition of fields unrelated to the timeline file and to make them easier to distinguish, the timeline parameters are extracted as a single file, with the data structure unchanged.

Original { } -> New {"timeline":{ } }

Request

plain
POST /task/create/timeline
Content-Type: application/json

The JSON data structure of the timeline in the request body is shown in the "Timeline JSON Data Structure Description". It should be noted that only one timeline in the timelines array is needed for synthesis, and the entire timelines array does not need to be passed in. The detailed parameters in the track are omitted below.

json
{
  "extraConfig":{
    "genCoverPoint":0
  },
  "timeline":{
    "duration": 59720000,
    "enableRenderOrderByZValue": true,
    "encoderMode": "cbr",
    "encoderType": "H.264",
    "fps": 30,
    "nvenc": true,
    "outputEnd": -1,
    "outputStart": 0,
    "outputType": "mp4",
    "resHeight": 540,
    "resWidth": 960,
    "sizeLevel": 1080,
    "volume": 0.5226850115488941,
    "videoBitrate": 16000000,
    "videoSize": "16:9",
    "templateId": "",
    "videoTracks": [],
    "audioTracks": [],
    "timelineVideoFxTracks": [],
    "captionTracks": [],
    "compoundCaptionTracks": [],
    "stickerTracks": [],
    "musicLyricsTracks": []
  }
}
FieldTypeDescriptionRequired
extraConfigobjectAdditional configuration informationNo
genCoverPointlongThe time to generate the cover, in microsecondsNo
timelineobjectTimeline related informationYes

Response

Response body

json
{
  "code": 0,
  "msg": "success",          
  "data": {
    "taskId": "ea496f25ee544f7aba9e9edc089424ad"
  }
}
FieldTypeDescriptionRequired
codeintStatus code, 0 is success, all others are failureYes
msgstringStatus informationYes
dataobjectReturned data bodyYes
taskIdstringTask idYes