列出 Seedance 材质资产组
curl --request GET \
--url https://api.tokenlab.sh/v1/videos/assets/groups \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tokenlab.sh/v1/videos/assets/groups"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tokenlab.sh/v1/videos/assets/groups', 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.tokenlab.sh/v1/videos/assets/groups",
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.tokenlab.sh/v1/videos/assets/groups"
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.tokenlab.sh/v1/videos/assets/groups")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tokenlab.sh/v1/videos/assets/groups")
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{
"groups": [
{
"id": "group-20260720123456-vrt01",
"object": "seedance.material_asset_group",
"library_type": "aigc_avatar",
"group_name": "Product references",
"description": "可复用的产品拍摄素材",
"status": "ACTIVE",
"metadata": null,
"created_at": 1782998400000
},
{
"id": "group-20260720123456-real1",
"object": "seedance.material_asset_group",
"library_type": "liveness_face",
"group_name": "Creator A",
"description": null,
"status": "ACTIVE",
"metadata": null,
"created_at": 1782998400000
}
],
"next_page_token": null
}{
"error": {
"message": "model: Model is required",
"type": "invalid_request_error",
"param": "model"
},
"validation_errors": [
{
"field": "model",
"message": "Model is required"
}
]
}{
"error": {
"message": "Invalid API key provided",
"type": "invalid_api_key"
}
}{
"error": {
"message": "An internal error occurred",
"type": "server_error"
}
}视频与素材
列出素材组
列出当前工作区的 Seedance 素材组。
GET
/
v1
/
videos
/
assets
/
groups
列出 Seedance 材质资产组
curl --request GET \
--url https://api.tokenlab.sh/v1/videos/assets/groups \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tokenlab.sh/v1/videos/assets/groups"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tokenlab.sh/v1/videos/assets/groups', 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.tokenlab.sh/v1/videos/assets/groups",
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.tokenlab.sh/v1/videos/assets/groups"
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.tokenlab.sh/v1/videos/assets/groups")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tokenlab.sh/v1/videos/assets/groups")
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{
"groups": [
{
"id": "group-20260720123456-vrt01",
"object": "seedance.material_asset_group",
"library_type": "aigc_avatar",
"group_name": "Product references",
"description": "可复用的产品拍摄素材",
"status": "ACTIVE",
"metadata": null,
"created_at": 1782998400000
},
{
"id": "group-20260720123456-real1",
"object": "seedance.material_asset_group",
"library_type": "liveness_face",
"group_name": "Creator A",
"description": null,
"status": "ACTIVE",
"metadata": null,
"created_at": 1782998400000
}
],
"next_page_token": null
}{
"error": {
"message": "model: Model is required",
"type": "invalid_request_error",
"param": "model"
},
"validation_errors": [
{
"field": "model",
"message": "Model is required"
}
]
}{
"error": {
"message": "Invalid API key provided",
"type": "invalid_api_key"
}
}{
"error": {
"message": "An internal error occurred",
"type": "server_error"
}
}列出当前工作区的素材组。可用
library_type 和 status 筛选虚拟人物或真人素材组。
上传素材时使用返回的 id;生成视频时使用具体素材的 id,不要传素材组 ID。
project_name 用于同一组织内的资源隔离,默认为 default。相关素材组和素材须使用相同且区分大小写的值;POST/PUT 在 JSON 请求体中传入,GET/DELETE 在查询参数中传入。
请求示例
curl "https://api.tokenlab.sh/v1/videos/assets/groups?library_type=aigc_avatar&page_size=20&project_name=default" \
-H "Authorization: Bearer $TOKENLAB_API_KEY"
响应示例
{
"groups": [
{
"id": "group-20260720123456-vrt01",
"object": "seedance.material_asset_group",
"project_name": "default",
"library_type": "aigc_avatar",
"group_name": "Product references",
"status": "ACTIVE",
"created_at": 1782998400000
}
],
"next_page_token": null
}
授权
API Key 身份验证。在 Dashboard > API > API Keys 中创建或管理 API Key。
查询参数
必填范围:
1 <= x <= 100可用选项:
ACTIVE, DELETED 按 TokenLab 材质库类别过滤。
可用选项:
aigc_avatar, liveness_face 素材资源的项目范围。
Required string length:
1 - 128