Skip to main content
POST
Use this format for a new integration or for reference audio, reference video and video editing. See Video models and pricing.

Setup

Use https://api.aiohub.org. Every request carries Authorization: Bearer <AIOHUB_API_KEY>. Replace the placeholder with your full sk- API key and choose a key group that can access the model.

Example request

Start with a text-only request so no image setup is needed.
Creation returns an id. Save it for polling; the video is not ready yet.
After saving the task identifier, poll the task.

Image, audio and video inputs

An Ark / Seedance task request carries a content[] array of a text prompt and reference media. Each media item names its role: Media url values are HTTPS URLs. Images and audio also accept base64 data URLs such as data:image/png;base64,.... Each item may be up to 100 MB. Images sent next to a video or audio need role: reference_image. Reference clips are 2 to 30 s each and 30 s in total on 2.5, and 2 to 15 s each and 15 s in total on the 2.0 series. An edit source video is 4 to 30 s and the output follows its length.

Status callbacks

Set callback_url at creation to receive the task object by POST on status changes. Requests carry User-Agent: AIOHub-LibTV-Callback/1. Respond with 2xx within 5 seconds; failed deliveries are retried up to three times.
If creation times out without a task identifier, check the usage log before resubmitting to avoid duplicate generation and charges. Correct parameters after a 400 and check the API key after a 401. See Authentication for access and quota requirements.

Authorizations

Authorization
string
header
required

API key (sk-xxx)

Body

application/json
model
string
required

Video model name. See Video generation for the models and their limits.

Example:

"doubao-seedance-2-5-260628"

content
object[]
required

Prompt and reference media. Text-to-video needs one text item only.

resolution
enum<string>
default:720p

Output resolution. The allowed values depend on the model.

Available options:
480p,
720p,
1080p,
4k
ratio
enum<string>
default:adaptive

Aspect ratio. adaptive lets the model follow the prompt or the input image.

Available options:
adaptive,
16:9,
4:3,
1:1,
3:4,
9:16,
21:9
duration
integer
default:5

Duration in whole seconds. The allowed range depends on the model. Video edit tasks use -1.

generate_audio
boolean
default:true

Whether to generate audio.

omni_reference_task_type
enum<string>
default:auto

How reference media is used. edit edits a single reference_video.

Available options:
auto,
reference,
edit
return_last_frame
boolean
default:false

When true, the task result includes content.last_frame_url, a JPEG of the final frame.

tools
object[]

Set to [{"type": "web_search"}] to let the model search the web while generating.

priority
integer
default:0

Queue priority. Higher values dequeue earlier; running tasks are not preempted.

Required range: 0 <= x <= 9
callback_url
string<uri>

Public HTTPS URL. AIOHub POSTs the task object to it on each status change; reply with 2xx within 5 seconds or the delivery is retried up to three times.

safety_identifier
string

Stable end-user identifier, up to 64 characters, echoed in task reads.

Maximum string length: 64

Response

Task created

id
string
required

Task ID