generate(参考图片)
开发中
POST
/api/video/luma/pro/generate
请求参数
Query 参数
string
可选
Header 参数
string
可选
Body 参数application/json
key
string
必需
callback_url
string
回调地址
user_prompt
string
描述词
image_url
string
参考图-首帧
image_end_url
string
参考图-尾帧
expand_prompt
boolean
AI优化描述词
默认值:
true
loop
boolean
无限循环
默认值:
false
示例
{
"key": "Bh3oi26r1FPFCMrJ59RKngSXB2",
"callback_url": "http://baidu.com",
"user_prompt": "The camera rotates around the task for shooting, with blinking and smiling expressions",
"image_url": "https://storage.cdn-luma.com/app_data/photon/user_uploads/e864adc9-90f3-4f20-b87e-c3a03c7d03ab/9567bdaa-848a-4df5-8fff-0384c6629252_image_file.jpg",
"image_end_url": "https://storage.cdn-luma.com/app_data/photon/user_uploads/95f78ac4-0fc2-4b0c-9ca4-1d2befcd04fb/4a5c6ff3-8b38-48ca-8f1e-6976a542b289_image_file.jpg",
"expand_prompt": true,
"loop": false
}
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'http://duomiapi.com/api/video/luma/pro/generate' \
--header 'Content-Type: application/json' \
--data-raw '{
"key": "Bh3oi26r1FPFCMrJ59RKngSXB2",
"callback_url":"http://baidu.com",
"user_prompt": "The camera rotates around the task for shooting, with blinking and smiling expressions",
"image_url": "https://storage.cdn-luma.com/app_data/photon/user_uploads/e864adc9-90f3-4f20-b87e-c3a03c7d03ab/9567bdaa-848a-4df5-8fff-0384c6629252_image_file.jpg",
"image_end_url": "https://storage.cdn-luma.com/app_data/photon/user_uploads/95f78ac4-0fc2-4b0c-9ca4-1d2befcd04fb/4a5c6ff3-8b38-48ca-8f1e-6976a542b289_image_file.jpg",
"expand_prompt": true,
"loop":false
}'
返回响应
🟢200成功
application/json
Body
object {0}
示例
{
"code": 200,
"msg": "成功",
"data": {
"task_id": "db989ed2-46ca-4f1c-a346-e34a27b43d19"
},
"exec_time": 4.5706,
"ip": "182.129.164.85"
}
修改于 2024-08-27 04:19:35