Light Mode
Get Task
GET
/api/v1/task/{task_id}This is provided as part of the Kling API from PiAPI.
This endpoint could get video generation progress or result of Kling task.
Request
Path Params
task_id
string
required
Header Params
x-api-key
string
required
Your API Key used for request authorization
Request samples
Responses
Success(200)
HTTP Code: 200
Content Type : JSONapplication/json
Data Schema
object {0}
Example
{
"code": 200,
"data": {
"task_id": "b3efc0ab-3fdb-4b88-b20a-94eef777e125",
"model": "kling",
"task_type": "video_generation",
"status": "completed",
"config": {
"service_mode": "private",
"webhook_config": {
"endpoint": "",
"secret": ""
}
},
"input": {},
"output": {
"type": "m2v_txt2video_hq",
"status": 99,
"works": [
{
"status": 99,
"type": "m2v_txt2video_hq",
"cover": {
"resource": "https://xxx.png",
"resource_without_watermark": "",
"height": 1440,
"width": 1440,
"duration": 0
},
"video": {
"resource": "https://xxx.mp4",
"resource_without_watermark": "https://storage.goapi.ai/xxx.mp4",
"height": 1440,
"width": 1440,
"duration": 5100
}
}
]
},
"meta": {},
"detail": null,
"logs": [],
"error": {
"code": 0,
"raw_message": "",
"message": "",
"detail": null
}
},
"message": "success"
}
Modified at 9 days ago