查询任务列表
curl --request GET \
--url https://api.dreamto.ai/api/v3/contents/generations/tasks \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.dreamto.ai/api/v3/contents/generations/tasks"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.dreamto.ai/api/v3/contents/generations/tasks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.dreamto.ai/api/v3/contents/generations/tasks';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.dreamto.ai/api/v3/contents/generations/tasks"
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.dreamto.ai/api/v3/contents/generations/tasks")
.header("Authorization", "Bearer <token>")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.dreamto.ai/api/v3/contents/generations/tasks",
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;
}require 'uri'
require 'net/http'
url = URI("https://api.dreamto.ai/api/v3/contents/generations/tasks")
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_bodyusing RestSharp;
var options = new RestClientOptions("https://api.dreamto.ai/api/v3/contents/generations/tasks");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
import Foundation
let url = URL(string: "https://api.dreamto.ai/api/v3/contents/generations/tasks")!
var request = URLRequest(url: url)
request.httpMethod = "GET"
request.timeoutInterval = 10
request.allHTTPHeaderFields = ["Authorization": "Bearer <token>"]
let (data, _) = try await URLSession.shared.data(for: request)
print(String(decoding: data, as: UTF8.self))val client = OkHttpClient()
val request = Request.Builder()
.url("https://api.dreamto.ai/api/v3/contents/generations/tasks")
.get()
.addHeader("Authorization", "Bearer <token>")
.build()
val response = client.newCall(request).execute()false{
"items": [
{
"id": "task_8c1d2e3f4a5b6c7d8e9f0a1b",
"model": "seedance-2.5-flash",
"status": "succeeded",
"content": {
"video_url": "https://example-cdn.com/videos/2026/11/11/output.mp4"
},
"created_at": 1794384000,
"updated_at": 1794384196,
"duration": 5,
"ratio": "16:9",
"resolution": "720p",
"output_format": "mp4",
"usage": {
"completion_tokens": 108900,
"total_tokens": 108900
}
}
],
"total": 1,
"request_id": "req_c3d5e7f9a1b2c4d6e8f0a2b4"
}{
"error": {
"code": "unauthorized",
"message": "Invalid API key",
"type": "authentication_error",
"http_status": 401,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "forbidden",
"message": "No permission to access this resource",
"type": "permission_error",
"http_status": 403,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "rate_limit_exceeded",
"message": "Rate limit exceeded. Please try again later.",
"type": "rate_limit_error",
"http_status": 429,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "api_error",
"message": "Internal server error, please retry later",
"type": "api_error",
"http_status": 500,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "service_unavailable",
"message": "Service temporarily unavailable, please retry later",
"type": "api_error",
"http_status": 503,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}Seedance 2.5 Flash
查询任务列表
批量查询当前 API Key 创建的任务,按创建时间倒序。
GET
/
api
/
v3
/
contents
/
generations
/
tasks
查询任务列表
curl --request GET \
--url https://api.dreamto.ai/api/v3/contents/generations/tasks \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.dreamto.ai/api/v3/contents/generations/tasks"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.dreamto.ai/api/v3/contents/generations/tasks', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.dreamto.ai/api/v3/contents/generations/tasks';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.dreamto.ai/api/v3/contents/generations/tasks"
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.dreamto.ai/api/v3/contents/generations/tasks")
.header("Authorization", "Bearer <token>")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.dreamto.ai/api/v3/contents/generations/tasks",
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;
}require 'uri'
require 'net/http'
url = URI("https://api.dreamto.ai/api/v3/contents/generations/tasks")
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_bodyusing RestSharp;
var options = new RestClientOptions("https://api.dreamto.ai/api/v3/contents/generations/tasks");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
import Foundation
let url = URL(string: "https://api.dreamto.ai/api/v3/contents/generations/tasks")!
var request = URLRequest(url: url)
request.httpMethod = "GET"
request.timeoutInterval = 10
request.allHTTPHeaderFields = ["Authorization": "Bearer <token>"]
let (data, _) = try await URLSession.shared.data(for: request)
print(String(decoding: data, as: UTF8.self))val client = OkHttpClient()
val request = Request.Builder()
.url("https://api.dreamto.ai/api/v3/contents/generations/tasks")
.get()
.addHeader("Authorization", "Bearer <token>")
.build()
val response = client.newCall(request).execute()false{
"items": [
{
"id": "task_8c1d2e3f4a5b6c7d8e9f0a1b",
"model": "seedance-2.5-flash",
"status": "succeeded",
"content": {
"video_url": "https://example-cdn.com/videos/2026/11/11/output.mp4"
},
"created_at": 1794384000,
"updated_at": 1794384196,
"duration": 5,
"ratio": "16:9",
"resolution": "720p",
"output_format": "mp4",
"usage": {
"completion_tokens": 108900,
"total_tokens": 108900
}
}
],
"total": 1,
"request_id": "req_c3d5e7f9a1b2c4d6e8f0a2b4"
}{
"error": {
"code": "unauthorized",
"message": "Invalid API key",
"type": "authentication_error",
"http_status": 401,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "forbidden",
"message": "No permission to access this resource",
"type": "permission_error",
"http_status": 403,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "rate_limit_exceeded",
"message": "Rate limit exceeded. Please try again later.",
"type": "rate_limit_error",
"http_status": 429,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "api_error",
"message": "Internal server error, please retry later",
"type": "api_error",
"http_status": 500,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}{
"error": {
"code": "service_unavailable",
"message": "Service temporarily unavailable, please retry later",
"type": "api_error",
"http_status": 503,
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
},
"request_id": "req_3f9a1c2b7d4e5f60718293a4"
}
