Kling multi-image to video
curl --request POST \
--url https://models.phanedge.cloud/kling/v1/videos/multi-image2video \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data'import requests
url = "https://models.phanedge.cloud/kling/v1/videos/multi-image2video"
payload = "-----011000010111000001101001\r\n-----011000010111000001101001--"
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "multipart/form-data"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const form = new FormData();
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://models.phanedge.cloud/kling/v1/videos/multi-image2video', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://models.phanedge.cloud/kling/v1/videos/multi-image2video",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://models.phanedge.cloud/kling/v1/videos/multi-image2video"
payload := strings.NewReader("-----011000010111000001101001\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://models.phanedge.cloud/kling/v1/videos/multi-image2video")
.header("Authorization", "Bearer <token>")
.body("-----011000010111000001101001\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://models.phanedge.cloud/kling/v1/videos/multi-image2video")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{}视频生成
多图参考生视频
接口与可灵官网一致;支持多张参考图片生成视频
POST
/
kling
/
v1
/
videos
/
multi-image2video
Kling multi-image to video
curl --request POST \
--url https://models.phanedge.cloud/kling/v1/videos/multi-image2video \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data'import requests
url = "https://models.phanedge.cloud/kling/v1/videos/multi-image2video"
payload = "-----011000010111000001101001\r\n-----011000010111000001101001--"
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "multipart/form-data"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const form = new FormData();
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
options.body = form;
fetch('https://models.phanedge.cloud/kling/v1/videos/multi-image2video', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://models.phanedge.cloud/kling/v1/videos/multi-image2video",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "-----011000010111000001101001\r\n-----011000010111000001101001--",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: multipart/form-data"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://models.phanedge.cloud/kling/v1/videos/multi-image2video"
payload := strings.NewReader("-----011000010111000001101001\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://models.phanedge.cloud/kling/v1/videos/multi-image2video")
.header("Authorization", "Bearer <token>")
.body("-----011000010111000001101001\r\n-----011000010111000001101001--")
.asString();require 'uri'
require 'net/http'
url = URI("https://models.phanedge.cloud/kling/v1/videos/multi-image2video")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request.body = "-----011000010111000001101001\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body{}- 路径
POST /kling/v1/videos/multi-image2video - 与官网一致:本页所有请求体、字段命名与返回结构与可灵官网保持一致
- 字段详解:请参考官网权威文档
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
model_name | string | 否 | 模型名称,仅支持 kling-v1-6,默认 kling-v1-6 |
image_list | array | 是 | 图片列表,1-4 张 |
prompt | string | 是 | 正向文本提示词 |
negative_prompt | string | 否 | 负向文本提示词 |
mode | string | 否 | 生成模式:std、pro,默认 std |
duration | string | 否 | 视频时长:5、10,默认 5 |
aspect_ratio | string | 否 | 画面纵横比:16:9、9:16、1:1,默认 16:9 |
callback_url | string | 否 | 回调通知地址 |
external_task_id | string | 否 | 自定义任务ID |
{
"image_list": [
{"image": "https://example.com/image1.jpg"},
{"image": "https://example.com/image2.jpg"}
]
}
image_list最多 4 张图片;duration仅支持5/10;aspect_ratio仅支持16:9/9:16/1:1。
场景:多张参考图生成视频
curl --request POST \
--url https://models.phanedge.cloud/kling/v1/videos/multi-image2video \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model_name": "kling-v1-6",
"image_list": [
{"image": "https://example.com/character-front.jpg"},
{"image": "https://example.com/character-side.jpg"}
],
"prompt": "The character turns around and waves at the camera",
"mode": "std",
"duration": "5",
"aspect_ratio": "16:9"
}'
{
"code": 0,
"message": "success",
"request_id": "req_1735558800_multi123",
"data": {
"task_id": "task_01JGHN...",
"task_status": "submitted",
"created_at": 1735558800000,
"updated_at": 1735558800000
}
}
# 查询单个任务
curl "https://models.phanedge.cloud/kling/v1/videos/multi-image2video/$TASK_ID" \
-H "Authorization: Bearer $TOKEN"
# 查询任务列表
curl "https://models.phanedge.cloud/kling/v1/videos/multi-image2video?pageNum=1&pageSize=30" \
-H "Authorization: Bearer $TOKEN"
Authorizations
Authorization: Bearer
Body
multipart/form-data
The body is of type object.
Response
200 - application/json
OK
The response is of type object.

