增加视频选区

POST /kling/v1/videos/multi-elements/add-selection

MethodPOST
Path/kling/v1/videos/multi-elements/add-selection
Typehttp
Status1
Module2102810
Folder72890869

概览

MethodPOST
Path/kling/v1/videos/multi-elements/add-selection
Typehttp
Status1
Module2102810
Folder72890869

参数

{
  "header": [
    {
      "required": false,
      "description": "",
      "type": "string",
      "id": "n4NxjJ1qDt",
      "enable": true,
      "name": "Content-Type",
      "sampleValue": "application/json"
    },
    {
      "required": false,
      "description": "",
      "type": "string",
      "id": "sPzOgdO7P2",
      "enable": true,
      "name": "Authorization",
      "sampleValue": "Bearer {{YOUR_API_KEY}}"
    }
  ]
}

请求体

{
  "type": "application/json",
  "parameters": [],
  "jsonSchema": {
    "type": "object",
    "properties": {
      "session_id": {
        "type": "string",
        "description": "会话ID,会基于视频初始化任务生成,不会随编辑选区行为而改变"
      },
      "frame_index": {
        "type": "integer",
        "description": "帧号 最多支持添加10个标记帧,即最多基于10帧标记视频选区 1次仅支持标记1帧"
      },
      "points": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "x": {
              "type": "integer"
            },
            "y": {
              "type": "integer"
            }
          },
          "x-apifox-orders": [
            "x",
            "y"
          ]
        },
        "description": "点选坐标,用x、y表示 取值范围:[0,1],用百分比表示;[0,1]代表画面左上角 支持同时增加多个标记点,某一帧最多可标记10个点"
      }
    },
    "required": [
      "session_id",
      "frame_index",
      "points"
    ],
    "x-apifox-orders": [
      "session_id",
      "frame_index",
      "points"
    ]
  },
  "required": true,
  "mediaType": "",
  "examples": [
    {
      "mediaType": "application/json",
      "value": "{\r\n    \"session_id\": \"828033558945619987\",\r\n    \"frame_index\": 1,\r\n    \"points\": [\r\n        {\r\n            \"x\": 0.0,\r\n            \"y\": 1.0\r\n        }\r\n    ]\r\n}"
    }
  ],
  "oasExtensions": ""
}

响应

[
  {
    "id": 138246842,
    "name": "成功",
    "code": 200,
    "contentType": "json",
    "jsonSchema": {
      "type": "object",
      "properties": {}
    },
    "itemSchema": {},
    "description": "",
    "mediaType": "",
    "headers": []
  }
]