Video Generation

POSThttps://api.oneinfer.ai/v1/ula/generate-video

Generate videos from text prompts or uploaded media files. Supports both application/json and multipart/form-data (for file uploads). Powered by providers like novita and google.

Request headers

Authorizationstringrequired
Bearer token for authentication. Format: Bearer <YOUR_TOKEN>. Exchange your API key for a token via the Authentication endpoint.
Content-Typestringrequired
Use application/json for text-only requests, or multipart/form-data when including file uploads (e.g. image-to-video).

Request body

Required fields

promptstringrequired
Text prompt describing the video to generate.
modelstringrequired
The video model to use. Retrieve the full list from the GET Models endpoint and use the model name from the response.
resolutionstringrequired
Video resolution. Options: "480P", "720P", "1080P".
aspect_ratiostringrequired
Aspect ratio of the output video. Options: "16:9", "9:16", "1:1", "4:3", "3:4", "21:9".
durationintegerrequired
Duration of the video in seconds. Must be an integer between 4 and 12.
generate_audiobooleanrequired
Whether to generate audio alongside the video.
camera_fixedbooleanrequired
Keep the camera fixed during generation.
service_tierstringrequired
Service tier for priority routing. Options: "default", "flex".

Optional fields

fpsinteger
Frames per second. Default: 24.
seedinteger
Random seed for reproducibility. Omit or use -1 for random output.

File uploads

When using multipart/form-data, include file attachments under the files field (e.g. a reference image for image-to-video). All other fields are passed as form string values.

Example request: text-to-video generation
{
  "model": "seedance-v1.5-pro-t2v",
  "prompt": "a cat drinking milk in a cozy kitchen",
  "resolution": "720P",
  "aspect_ratio": "16:9",
  "duration": 5,
  "generate_audio": true,
  "camera_fixed": false,
  "service_tier": "default",
  "fps": 24,
  "seed": -1
}

Response

Response fields

idstring
Unique request identifier (UUID).
createdinteger
Unix timestamp of when the job was created.
textstring
Confirmation message echoing the prompt used.
finish_reasonstring
Reason generation stopped. Typically "stop".
providerstring
The provider that handled the request.
modelstring
The model used for generation.
usageobject
Token counts: prompt_tokens, completion_tokens, total_tokens.
latency_msnumber
End-to-end processing latency in milliseconds.
videosarray
Array of generated video objects, each with a url and type (e.g. mp4).
resolutionstring
Resolution of the generated video (e.g. "1280*720").
imagesarray
Image outputs if applicable, otherwise an empty array.
audiosstring | null
Audio file path if generated, otherwise null.
application/json
200 OK
{
  "api_details": {
    "api_status": "success",
    "api_message": "API has return response successfully."
  },
  "data": {
    "id": "3a4dbc94-455f-47f4-ae42-4cb528ac5b3d",
    "created": 1774529224,
    "text": "Generated video for prompt: a cat drinking the milk",
    "finish_reason": "stop",
    "provider": "novita",
    "model": "seedance-v1.5-pro-t2v",
    "usage": {
      "prompt_tokens": 11,
      "completion_tokens": 0,
      "total_tokens": 11
    },
    "latency_ms": 46795.58,
    "images": [],
    "videos": [
      { "url": "https://...", "type": "mp4" }
    ],
    "resolution": "1280*720",
    "audios": null
  },
  "error": {}
}

Error status codes

CodeStatusDescription
200OKVideo generated successfully.
400Bad RequestInvalid request body or unsupported model.
401UnauthorizedMissing or invalid Authorization header / Bearer token.
403ForbiddenInsufficient credit balance.
422Unprocessable EntityRequest body failed schema validation.
500Internal Server ErrorUnexpected error during video generation.

Response

202 - application/json