비디오 생성 작업 생성
curl --request POST \
--url https://api.gravitex.ai/api/v3/contents/generations/tasks \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"content": [
{}
],
"prompt": "<string>",
"callback_url": "<string>",
"return_last_frame": true,
"service_tier": "<string>",
"execution_expires_after": 123,
"generate_audio": true,
"safety_identifier": "<string>",
"resolution": "<string>",
"ratio": "<string>",
"duration": 123,
"seed": 123,
"watermark": true
}
'import requests
url = "https://api.gravitex.ai/api/v3/contents/generations/tasks"
payload = {
"model": "<string>",
"content": [{}],
"prompt": "<string>",
"callback_url": "<string>",
"return_last_frame": True,
"service_tier": "<string>",
"execution_expires_after": 123,
"generate_audio": True,
"safety_identifier": "<string>",
"resolution": "<string>",
"ratio": "<string>",
"duration": 123,
"seed": 123,
"watermark": True
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({
model: '<string>',
content: [{}],
prompt: '<string>',
callback_url: '<string>',
return_last_frame: true,
service_tier: '<string>',
execution_expires_after: 123,
generate_audio: true,
safety_identifier: '<string>',
resolution: '<string>',
ratio: '<string>',
duration: 123,
seed: 123,
watermark: true
})
};
fetch('https://api.gravitex.ai/api/v3/contents/generations/tasks', 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.gravitex.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 => "POST",
CURLOPT_POSTFIELDS => json_encode([
'model' => '<string>',
'content' => [
[
]
],
'prompt' => '<string>',
'callback_url' => '<string>',
'return_last_frame' => true,
'service_tier' => '<string>',
'execution_expires_after' => 123,
'generate_audio' => true,
'safety_identifier' => '<string>',
'resolution' => '<string>',
'ratio' => '<string>',
'duration' => 123,
'seed' => 123,
'watermark' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.gravitex.ai/api/v3/contents/generations/tasks"
payload := strings.NewReader("{\n \"model\": \"<string>\",\n \"content\": [\n {}\n ],\n \"prompt\": \"<string>\",\n \"callback_url\": \"<string>\",\n \"return_last_frame\": true,\n \"service_tier\": \"<string>\",\n \"execution_expires_after\": 123,\n \"generate_audio\": true,\n \"safety_identifier\": \"<string>\",\n \"resolution\": \"<string>\",\n \"ratio\": \"<string>\",\n \"duration\": 123,\n \"seed\": 123,\n \"watermark\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.gravitex.ai/api/v3/contents/generations/tasks")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"<string>\",\n \"content\": [\n {}\n ],\n \"prompt\": \"<string>\",\n \"callback_url\": \"<string>\",\n \"return_last_frame\": true,\n \"service_tier\": \"<string>\",\n \"execution_expires_after\": 123,\n \"generate_audio\": true,\n \"safety_identifier\": \"<string>\",\n \"resolution\": \"<string>\",\n \"ratio\": \"<string>\",\n \"duration\": 123,\n \"seed\": 123,\n \"watermark\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gravitex.ai/api/v3/contents/generations/tasks")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"<string>\",\n \"content\": [\n {}\n ],\n \"prompt\": \"<string>\",\n \"callback_url\": \"<string>\",\n \"return_last_frame\": true,\n \"service_tier\": \"<string>\",\n \"execution_expires_after\": 123,\n \"generate_audio\": true,\n \"safety_identifier\": \"<string>\",\n \"resolution\": \"<string>\",\n \"ratio\": \"<string>\",\n \"duration\": 123,\n \"seed\": 123,\n \"watermark\": true\n}"
response = http.request(request)
puts response.read_bodySeedance 2.0(/generations/tasks)
비디오 생성 작업 생성
Seedance 2.0 New POST /api/v3/contents/generations/tasks
POST
/
api
/
v3
/
contents
/
generations
/
tasks
비디오 생성 작업 생성
curl --request POST \
--url https://api.gravitex.ai/api/v3/contents/generations/tasks \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"model": "<string>",
"content": [
{}
],
"prompt": "<string>",
"callback_url": "<string>",
"return_last_frame": true,
"service_tier": "<string>",
"execution_expires_after": 123,
"generate_audio": true,
"safety_identifier": "<string>",
"resolution": "<string>",
"ratio": "<string>",
"duration": 123,
"seed": 123,
"watermark": true
}
'import requests
url = "https://api.gravitex.ai/api/v3/contents/generations/tasks"
payload = {
"model": "<string>",
"content": [{}],
"prompt": "<string>",
"callback_url": "<string>",
"return_last_frame": True,
"service_tier": "<string>",
"execution_expires_after": 123,
"generate_audio": True,
"safety_identifier": "<string>",
"resolution": "<string>",
"ratio": "<string>",
"duration": 123,
"seed": 123,
"watermark": True
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({
model: '<string>',
content: [{}],
prompt: '<string>',
callback_url: '<string>',
return_last_frame: true,
service_tier: '<string>',
execution_expires_after: 123,
generate_audio: true,
safety_identifier: '<string>',
resolution: '<string>',
ratio: '<string>',
duration: 123,
seed: 123,
watermark: true
})
};
fetch('https://api.gravitex.ai/api/v3/contents/generations/tasks', 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.gravitex.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 => "POST",
CURLOPT_POSTFIELDS => json_encode([
'model' => '<string>',
'content' => [
[
]
],
'prompt' => '<string>',
'callback_url' => '<string>',
'return_last_frame' => true,
'service_tier' => '<string>',
'execution_expires_after' => 123,
'generate_audio' => true,
'safety_identifier' => '<string>',
'resolution' => '<string>',
'ratio' => '<string>',
'duration' => 123,
'seed' => 123,
'watermark' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.gravitex.ai/api/v3/contents/generations/tasks"
payload := strings.NewReader("{\n \"model\": \"<string>\",\n \"content\": [\n {}\n ],\n \"prompt\": \"<string>\",\n \"callback_url\": \"<string>\",\n \"return_last_frame\": true,\n \"service_tier\": \"<string>\",\n \"execution_expires_after\": 123,\n \"generate_audio\": true,\n \"safety_identifier\": \"<string>\",\n \"resolution\": \"<string>\",\n \"ratio\": \"<string>\",\n \"duration\": 123,\n \"seed\": 123,\n \"watermark\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.gravitex.ai/api/v3/contents/generations/tasks")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"model\": \"<string>\",\n \"content\": [\n {}\n ],\n \"prompt\": \"<string>\",\n \"callback_url\": \"<string>\",\n \"return_last_frame\": true,\n \"service_tier\": \"<string>\",\n \"execution_expires_after\": 123,\n \"generate_audio\": true,\n \"safety_identifier\": \"<string>\",\n \"resolution\": \"<string>\",\n \"ratio\": \"<string>\",\n \"duration\": 123,\n \"seed\": 123,\n \"watermark\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gravitex.ai/api/v3/contents/generations/tasks")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"model\": \"<string>\",\n \"content\": [\n {}\n ],\n \"prompt\": \"<string>\",\n \"callback_url\": \"<string>\",\n \"return_last_frame\": true,\n \"service_tier\": \"<string>\",\n \"execution_expires_after\": 123,\n \"generate_audio\": true,\n \"safety_identifier\": \"<string>\",\n \"resolution\": \"<string>\",\n \"ratio\": \"<string>\",\n \"duration\": 123,\n \"seed\": 123,\n \"watermark\": true\n}"
response = http.request(request)
puts response.read_body소개
Seedance 2.0 공식 미러 비동기 비디오 생성 작업을 제출합니다. 성공 시 작업id를 반환합니다. content와 prompt 중 최소 하나를 제공해야 합니다.
BytePlus Ark 공식 인터페이스와 요청 본문 및 응답 본문이 완전히 동일합니다.
인증
string
필수
Bearer Token, 예:
Bearer sk-your_token_keystring
application/json요청 매개변수
string
필수
모델 ID:
seedance-2-0 / seedance-2-0-fast / seedance-2-0-NSFWarray
콘텐츠 배열:
text / image_url / video_url / audio_url, 각 요소에 role 지정 가능 (first_frame / last_frame / reference_image / reference_video / reference_audio); prompt와 중 최소 하나 필수string
간소화 작성 방식,
content와 택일string
작업 상태 변경 시 콜백 주소
boolean
기본값:"false"
마지막 프레임 이미지 반환 여부
string
기본값:"default"
default / flexinteger
기본값:"172800"
작업 만료 시간(초), 범위
[3600, 259200]boolean
기본값:"true"
오디오 생성 여부
string
최종 사용자 고유 식별자(사용자 ID 해시 전달 권장)
string
기본값:"720p"
480p / 720p / 1080p / 4K (seedance-2-0-fast는 480p/720p만 지원)string
기본값:"adaptive"
16:9 / 4:3 / 1:1 / 3:4 / 9:16 / 21:9 / adaptiveinteger
기본값:"5"
초 단위,
[4,15] 또는 -1(자동)integer
기본값:"-1"
랜덤 시드
boolean
기본값:"false"
워터마크 추가 여부
content[].image_url.url / video_url.url / audio_url.url은 세 가지 값을 지원합니다: 공개 URL, Base64 (data:image/png;base64,...), asset://<ASSET_ID> 자산 라이브러리 참조.요청 예제
curl -X POST https://api.gravitex.ai/api/v3/contents/generations/tasks \
-H "Authorization: Bearer sk-your_token_key" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{"type": "text", "text": "黄金时刻,无人机航拍连绵山脉"}
],
"duration": 5,
"resolution": "720p",
"ratio": "16:9",
"generate_audio": true
}'
응답 예제
{
"id": "cgt-20260708094649-mxfjc"
}
⌘I
