Luma Videos Generation API
POSThttps://api.acedata.cloud/luma/videos

This API can generate videos by inputting prompt words and the first and last frame images.

Related Products

Luma - Ace Data Cloud
Luma video generation platform, directly interfaces with this API, high-speed and stable availability.

Request Headers

acceptstring
Specify the response format returned by the server.
Please select
authorizationstring
Bearer token

Request Body

actionstring
Operation type. Use `generate` when creating a video for the first time, and use `extend` when continuing an existing video.
Please select
video_idstring
The unique identifier of the generated video used for the continuation operation (`extend`). If both are specified, `video_id` takes precedence over `video_url`.
aspect_ratiostring
Generate the aspect ratio of the video, for example `16:9`.
promptstring
Text prompts for generating videos.
video_urlstring
The original video URL used for the extend operation (`extend`). If `video_id` is specified at the same time, then `video_id` shall prevail.
start_image_urlstring
The URL of the starting frame image, which will be used as the first frame of the generated video.
end_image_urlstring
The URL of the ending frame image, which will be used as the last frame of the generated video.
callback_urlstring
Webhook callback URL for receiving asynchronous notifications.
asyncboolean
Whether to process in asynchronous mode. When set to `true`, the interface immediately returns `task_id`, without the need to provide `callback_url`, and then the result can be obtained by polling the corresponding task query interface; if `callback_url` is also provided, the result will be pushed to that callback address.
Please select
enhancementboolean
Whether to enable automatic optimization enhancement for the input prompt text, suitable for use when unsure how to write prompt words.
Please select
timeoutnumber
The timeout for the API return data (unit: seconds).
loopboolean
Whether to enable loop playback for the generated video.
Please select

Response

Luma Video Generation
Allow Use General Balance

When 'Allow General Balance' is enabled, the general balance is used automatically if an app's balance is insufficient.

Shell

Python

JavaScript

Java

Go

PHP

Kind reminder: For streaming requests, the above code may not be fully applicable. Please refer to the integration documentation for changes.