Zum Hauptinhalt springen
POST
/
v1
/
videos
Create a Video
curl --request POST \
  --url https://aihubmix.com/v1/videos \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form 'prompt=<string>' \
  --form input_reference.0='@example-file'
{
  "id": "<string>",
  "object": "video",
  "model": "<string>",
  "progress": 123,
  "created_at": 123,
  "completed_at": 123,
  "expires_at": 123,
  "prompt": "<string>",
  "seconds": "<string>",
  "remixed_from_video_id": "<string>",
  "error": {
    "code": "<string>",
    "message": "<string>"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.aihubmix.com/llms.txt

Use this file to discover all available pages before exploring further.

Autorisierungen

Authorization
string
header
erforderlich

Gateway-issued API key, formatted as sk-gateway-xxxxxxxx. Used by OpenAI-shaped endpoints (/v1/chat/completions, etc.).

Body

Multipart parameters for creating a new video generation job.

prompt
string
erforderlich

Text prompt that describes the video to generate.

Required string length: 1 - 32000
model

The video generation model to use (allowed values: sora-2, sora-2-pro). Defaults to sora-2.

input_reference

Optional reference asset upload or reference object that guides generation.

seconds
enum<string>

Clip duration in seconds (allowed values: 4, 8, 12). Defaults to 4 seconds.

Verfügbare Optionen:
4,
8,
12
size
enum<string>

Output resolution formatted as width x height (allowed values: 720x1280, 1280x720, 1024x1792, 1792x1024). Defaults to 720x1280.

Verfügbare Optionen:
720x1280,
1280x720,
1024x1792,
1792x1024

Antwort

Success

Structured information describing a generated video job.

id
string
erforderlich

Unique identifier for the video job.

object
enum<string>
Standard:video
erforderlich

The object type, which is always video.

Verfügbare Optionen:
video
model
erforderlich

The video generation model that produced the job.

status
enum<string>
erforderlich

Current lifecycle status of the video job.

Verfügbare Optionen:
queued,
in_progress,
completed,
failed
progress
integer
erforderlich

Approximate completion percentage for the generation task.

created_at
integer<unixtime>
erforderlich

Unix timestamp (seconds) for when the job was created.

completed_at
integer<unixtime> | null
erforderlich

Unix timestamp (seconds) for when the job completed, if finished.

expires_at
integer<unixtime> | null
erforderlich

Unix timestamp (seconds) for when the downloadable assets expire, if set.

prompt
string | null
erforderlich

The prompt that was used to generate the video.

size
enum<string>
erforderlich

The resolution of the generated video.

Verfügbare Optionen:
720x1280,
1280x720,
1024x1792,
1792x1024
seconds
string
erforderlich

Duration of the generated clip in seconds. For extensions, this is the stitched total duration.

remixed_from_video_id
string | null
erforderlich

Identifier of the source video if this video is a remix.

error
Error · object
erforderlich

Error payload that explains why generation failed, if applicable.