AI 模型介面生成任務
查询非同步生成任務
查詢非同步生成任務的狀態和結果。
認證
BearerAuth
AuthorizationBearer <token>
使用 Bearer Token 認證。
格式:Authorization: Bearer sk-xxxxxx
In: header
路徑參數
task_id*string
The unique public task ID.
curl -X GET "https://us-api.tokenhub.com/generation/tasks/string"{
"code": "success",
"message": "string",
"data": {
"task_id": "task_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"media_type": "image",
"model": "gpt-image-2",
"status": "succeeded",
"progress": "100%",
"result_urls": [
"https://example.com/result-1.png",
"https://example.com/result-2.png"
],
"error": "string",
"created_at": 1780000000,
"updated_at": 1780000030,
"submit_time": 1780000000,
"start_time": 1780000005,
"finish_time": 1780000030
}
}回應體
application/json
最後更新於