import requests, time
headers = {"Authorization": "Bearer YOUR_API_KEY"}
resp = requests.post(
"https://dayu.cdn-fly.com/v1/video/generations",
headers=headers,
json={
"model": "happyhorse-1.0-r2v",
"prompt": "身着红色旗袍的女性轻抬玉手展开折扇",
"images": [
"https://example.com/ref1.jpg",
"https://example.com/ref2.jpg",
"https://example.com/ref3.jpg",
],
"parameters": {
"resolution": "720P",
"ratio": "16:9",
"duration": 5,
"watermark": False,
}
}
)
task_id = resp.json()["task_id"]