Get Task Status
curl --request GET \
--url https://api.modelhunter.ai/api/v1/tasks/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.modelhunter.ai/api/v1/tasks/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.modelhunter.ai/api/v1/tasks/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.modelhunter.ai/api/v1/tasks/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.modelhunter.ai/api/v1/tasks/{id}"
req, _ := http.NewRequest("GET", 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))
}HttpResponse<String> response = Unirest.get("https://api.modelhunter.ai/api/v1/tasks/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.modelhunter.ai/api/v1/tasks/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "task_abc123",
"type": "video",
"status": "succeeded",
"provider": "vidu",
"model": "viduq3-turbo",
"result": [
{
"url": "https://cdn.modelhunter.ai/results/task_abc123.mp4",
"duration": 4,
"format": "mp4",
"size_bytes": 12582912
}
],
"created_at": "2025-01-15T10:00:00Z",
"completed_at": "2025-01-15T10:00:32Z",
"metadata": { "project": "demo" }
}
}
{
"success": true,
"data": {
"id": "task_abc123",
"type": "video",
"status": "running",
"provider": "vidu",
"model": "viduq3-turbo",
"created_at": "2025-01-15T10:00:00Z",
"metadata": { "project": "demo" }
}
}
{
"success": false,
"error": {
"code": "TASK_NOT_FOUND",
"message": "Task not found"
}
}
Tasks
Get Task Status
Retrieve the current status and result of a generation task.
GET
/
api
/
v1
/
tasks
/
{id}
Get Task Status
curl --request GET \
--url https://api.modelhunter.ai/api/v1/tasks/{id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.modelhunter.ai/api/v1/tasks/{id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.modelhunter.ai/api/v1/tasks/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.modelhunter.ai/api/v1/tasks/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.modelhunter.ai/api/v1/tasks/{id}"
req, _ := http.NewRequest("GET", 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))
}HttpResponse<String> response = Unirest.get("https://api.modelhunter.ai/api/v1/tasks/{id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.modelhunter.ai/api/v1/tasks/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "task_abc123",
"type": "video",
"status": "succeeded",
"provider": "vidu",
"model": "viduq3-turbo",
"result": [
{
"url": "https://cdn.modelhunter.ai/results/task_abc123.mp4",
"duration": 4,
"format": "mp4",
"size_bytes": 12582912
}
],
"created_at": "2025-01-15T10:00:00Z",
"completed_at": "2025-01-15T10:00:32Z",
"metadata": { "project": "demo" }
}
}
{
"success": true,
"data": {
"id": "task_abc123",
"type": "video",
"status": "running",
"provider": "vidu",
"model": "viduq3-turbo",
"created_at": "2025-01-15T10:00:00Z",
"metadata": { "project": "demo" }
}
}
{
"success": false,
"error": {
"code": "TASK_NOT_FOUND",
"message": "Task not found"
}
}
Path Parameters
string
required
Task ID returned from the generation request.
Response Fields
boolean
Whether the request was successful.
object
Task details.
Show data properties
Show data properties
string
Unique task identifier (e.g.
task_abc123).string
Media type. One of:
video, image, audio, music.string
Current task status. One of:
pending, queued, running, succeeded, failed, cancelled, expired.string
Provider that processed the request (e.g.
vidu, kling, seedream).string
Model used for generation (e.g.
viduq3-turbo, gen3-alpha-turbo).object[]
object
string
ISO 8601 timestamp when the task was created.
string
ISO 8601 timestamp when the task completed (succeeded, failed, or cancelled).
object
Custom key-value metadata attached when the task was created.
{
"success": true,
"data": {
"id": "task_abc123",
"type": "video",
"status": "succeeded",
"provider": "vidu",
"model": "viduq3-turbo",
"result": [
{
"url": "https://cdn.modelhunter.ai/results/task_abc123.mp4",
"duration": 4,
"format": "mp4",
"size_bytes": 12582912
}
],
"created_at": "2025-01-15T10:00:00Z",
"completed_at": "2025-01-15T10:00:32Z",
"metadata": { "project": "demo" }
}
}
{
"success": true,
"data": {
"id": "task_abc123",
"type": "video",
"status": "running",
"provider": "vidu",
"model": "viduq3-turbo",
"created_at": "2025-01-15T10:00:00Z",
"metadata": { "project": "demo" }
}
}
{
"success": false,
"error": {
"code": "TASK_NOT_FOUND",
"message": "Task not found"
}
}
⌘I