创建视频(V1)
curl --request POST \
--url https://api.pipellm.ai/v1/videos/generations \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.pipellm.ai/v1/videos/generations"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.pipellm.ai/v1/videos/generations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.pipellm.ai/v1/videos/generations"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}创建视频(V1)
通过 PipeLLM 网关调用旧版视频模型。
POST
/
v1
/
videos
/
generations
创建视频(V1)
curl --request POST \
--url https://api.pipellm.ai/v1/videos/generations \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.pipellm.ai/v1/videos/generations"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.pipellm.ai/v1/videos/generations', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.pipellm.ai/v1/videos/generations"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}V1 计划淘汰,具体停用日期尚未公布。新接入请优先选择 V2 支持的模型。迁移前请核对 V2 支持的模型和请求参数。V1 模型并不自动支持 V2,不能只替换 URL;尚未迁移的模型继续使用其文档规定的 V1 路由。
POST https://api.pipellm.ai/v1/videos/generations。/api/v3/kwaivgi/... 是供应商上游路径,不是 PipeLLM 的公开调用入口。
curl https://api.pipellm.ai/v1/videos/generations \
-H "Authorization: Bearer $PIPELLM_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"kling-o1-text-to-video","prompt":"A blue ball rolling on a table"}'
model 填写平台模型 ID。其他必填字段、可选参数和异步响应格式取决于具体模型;示例仅展示网关调用结构,请补齐该模型需要的参数。
V2 支持列表中的 Seedance 模型使用 POST /v2/videos,不要混用 V1 模型参数和 V2 请求格式。此页面对您有帮助吗?