Veo Videos Generation API Integration Guide
This article introduces a Veo Videos Generation API integration method that can generate official Veo videos by inputting custom parameters.
¶ Preparing a Video Request
Copy the API key from a general-purpose application in the application list, and confirm that the application can use the selected Veo model. Select the application in Veo Online Debugging, or use Authorization: Bearer {token} in your own code.
¶ Basic Usage
First, let's look at the basic usage: input the prompt prompt, generation action action, reference image URL array for the first and last frames image_urls, and model model to obtain the processed result. First, simply pass an action field with the value text2video. It primarily includes three actions: text-to-video (text2video), image-to-video (image2video), and getting a 1080p video (get1080p). Then, we also need to input the model model. Currently, the main models are veo31-fast, veo3, veo31, veo3-fast, and veo31-fast-ingredients. The details are as follows:

As you can see, we have set the Request Headers here, including:
accept: The desired response format, set here toapplication/json, meaning JSON format.authorization: The key for calling the API, which can be selected directly from the dropdown after application.
We have also set the Request Body, including:
model: The model for generating the video. The main models areveo31-fast,veo3,veo31,veo3-fast, andveo31-fast-ingredients.action: The action for this video generation task. There are three main actions: text-to-video (text2video), image-to-video (image2video), and getting a 1080p video (get1080p).image_urls: Reference image links that must be provided when the image-to-video actionimage2videois selected.veo31-fast-ingredientssupports up to 3 images (multi-image fusion), while the other models support up to 2 images (first-and-last-frame mode).resolution: Select the resolution of the generated video. The veo31 model supports 4k resolution, while the other models do not. All models support 1080p and gif resolutions. If this value is not provided, 720p resolution is used by default. The main options are:1080p,gif, and4k.prompt: The prompt.callback_url: The URL for the result callback.async: Optional. When set totrue, the API immediately returns atask_idwithout requiring acallback_url. The result can then be obtained by polling the corresponding task query API.
¶ 📌 Model Summary
| Model Name | Supported Modes | Image Input Rules |
|---|---|---|
| veo3-fast | Text-to-video (no images) Image-to-video (with images) |
1 image → First-frame mode 2 images → First-and-last-frame mode |
| veo31-fast | Text-to-video (no images) Image-to-video (with images) |
1 image → First-frame mode 2 images → First-and-last-frame mode |
| veo31-fast-ingredients | ❌ Text-to-video (not supported) ✅ Mandatory multi-image fusion (images required) |
1–3 images → Multi-image fusion mode (up to 3 images) |
| veo3 | Text-to-video (no images) Image-to-video (with images) |
1 image → First-frame mode 2 images → First-and-last-frame mode |
| veo31 | Text-to-video (no images) Image-to-video (with images) |
1 image → First-frame mode 2 images → First-and-last-frame mode |
¶ 🔑 Key Rules
- General Logic:
- No image input → Automatically triggers text-to-video mode.
- Image input provided → Triggers image-to-video mode (the specific behavior depends on the number of images).
- Image-to-Video Mode Types:
- First-frame mode (1 image): The first frame is fixed to the input image.
- First-and-last-frame mode (2 images): The first and last frames are fixed to the input images.
- Multi-image fusion mode (1–3 images): Supported only by
veo31-fast-ingredients; generates a video by combining content from multiple images.
- Mode Categories:
- Fast mode:
veo3-fast,veo31-fast,veo31-fast-ingredients. - Quality mode:
veo3,veo31(higher generation quality).
¶ ⚠️ Notes
- Only model requiring image input:
veo31-fast-ingredientsrequires images (1–3); otherwise, it cannot run. - Image count limits:
veo31-fast-ingredientssupports 1–3 images as input (multi-image fusion mode).- Other models support up to 2 images as input (first-and-last-frame mode).
After making the selection, you can see that the corresponding code is also generated on the right, as shown below:

Click the “Try” button to test. As shown above, we obtained the following result:
{
"success": true,
"task_id": "697ea2fc-58fd-48c8-8191-29041ff23c3c",
"trace_id": "70e1cb12-c619-4292-a416-90191205996b",
"data": [
{
"id": "24ac06a5-9cc7-448f-802e-0b4db19f6e96",
"video_url": "https://cdn.acedata.cloud/assets/examples/veo/f5389ec0-2eb5-4212-b4a8-04b513b0129a-0b0c3113d691.mp4",
"created_at": "2026-06-30T04:01:50.364Z",
"complete_at": "2026-06-30T04:03:20.495Z",
"state": "succeeded"
}
]
}
The returned result contains multiple fields, described as follows:
success, the status of the video generation task.task_id, the ID of the video generation task.data, the result of the video generation task.id, the video ID of the video generation task.video_url, the video link of the video generation task.created_at, the creation time of the video generation task.complete_at, the completion time of the video generation task.state, the state of the video generation task. As in the example above, the synchronously generated video is located atdata[0].video_url. When choosing asynchronous submission, save thetask_idand check the progress through Veo Task Query. After the task succeeds, obtain the video fromresponse.data[0].video_urlin the query response.
Additionally, if you want to generate the corresponding integration code, you can copy the generated code directly. For example, the CURL code is as follows:
curl -X POST 'https://api.acedata.cloud/veo/videos' \
-H 'accept: application/json' \
-H 'authorization: Bearer {token}' \
-H 'content-type: application/json' \
-d '{
"action": "text2video",
"model": "veo31-fast",
"prompt": "White ceramic coffee mug on glossy marble countertop with morning window light. Camera slowly rotates 360 degrees around the mug, pausing briefly at the handle."
}'
¶ Image-to-Video Feature
If you want to generate a video based on images for the first and last frames, you can set the action parameter to image2video and enter an array of image URLs for the first and last frames in image_urls.
Next, we must enter the prompt to be extended in the next step to customize the generated video. You can specify the following:
model: The model used to generate the video, mainlyveo31-fast,veo3,veo31,veo3-fast, andveo31-fast-ingredients.image_urls: The reference image URLs that must be uploaded when choosing theimage2videoaction.prompt: The prompt.
An example is shown below:

After completing the fields, the code is automatically generated as follows:

The corresponding Python code:
import requests
url = "https://api.acedata.cloud/veo/videos"
headers = {
"accept": "application/json",
"authorization": "Bearer {token}",
"content-type": "application/json"
}
payload = {
"action": "image2video",
"model": "veo31-fast",
"prompt": "Let it dance",
"image_urls": ["https://cdn.acedata.cloud/7p1jhy.png"]
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)
Click Run, and you will get a result as follows:
{
"success": true,
"task_id": "98e309f3-35bc-438d-8cb3-4015fc864b87",
"trace_id": "8bc68066-36de-41ef-ae5e-b7d61ff6aee8",
"data": [
{
"id": "59f12222b1fa4fbe9331ff2400ad1583",
"video_url": "https://platform.cdn.acedata.cloud/veo/98e309f3-35bc-438d-8cb3-4015fc864b87.mp4",
"created_at": "2025-07-25 16:13:07",
"complete_at": "2025-07-25 16:16:12",
"state": "succeeded"
}
]
}
As you can see, the result is consistent with the one above, thereby achieving the image-to-video feature.
¶ Get 1080p Video Feature
If you want to obtain a 1080p version of an already generated Veo video, you can set the action parameter to get1080p and enter the ID of the video for which you want to obtain a 1080p version. The video ID can be obtained according to the basic usage instructions, as shown below:

At this point, you can see that the video ID is:
"id": "59f12222b1fa4fbe9331ff2400ad1583"
Note that
video_idhere is the ID of the generated video. If you do not know how to generate a video, you can refer to the basic usage instructions above to generate one.
Next, we must enter the prompt to be extended in the next step to customize the generated video. You can specify the following:
model: The model used to generate the video, mainlyveo31-fast,veo3,veo31,veo3-fast, andveo31-fast-ingredients.video_id: The reference video ID, used to obtain the 1080p video.
An example is shown below:

After completing the fields, the code is automatically generated as follows:

Click Run, and you will get a result as follows:
{
"success": true,
"task_id": "47a51cfe-2e24-4aba-93b3-546c2dc52984",
"trace_id": "a8922eec-6f50-4f77-8104-00ded071d59d",
"data": [
{
"id": "59f12222b1fa4fbe9331ff2400ad1583",
"video_url": "https://platform.cdn.acedata.cloud/veo/47a51cfe-2e24-4aba-93b3-546c2dc52984.mp4",
"created_at": "2025-07-25 16:13:07",
"complete_at": "2025-07-25 16:16:12",
"state": "succeeded"
}
]
}
As you can see, the result is consistent with the one above, thereby achieving the feature of obtaining a 1080p video.
¶ Generate a Video with Specified Dimensions
If you want to generate a Veo video with custom dimensions, you can set the aspect_ratio parameter to the desired dimensions. Next, we must enter the prompt to be extended in the next step to customize the generated video. You can specify the following:
model: The model used to generate the video, mainlyveo31-fast,veo3,veo31,veo3-fast, andveo31-fast-ingredients.aspect_ratio: The dimensions of the video. Currently supported:16:9,16:9,3:4,4:3, and1:1. The default is16:9.translation: Whether to enable automatic translation of the prompt. The default isfalse. An example is shown below:

After completing the fields, the code is automatically generated as follows:

Click Run, and you will get a result as follows:
{
"success": true,
"task_id": "d2b93290-ab0e-4d20-ae45-60c062a32687",
"trace_id": "9834e64d-c8fe-43ae-8114-ee2b5f93d886",
"data": [
{
"id": "fc667e7d3b8f44beaa61a3c339af0e50",
"video_url": "https://platform.cdn.acedata.cloud/veo/d2b93290-ab0e-4d20-ae45-60c062a32687.mp4",
"created_at": "2025-08-24 20:09:06",
"complete_at": "2025-08-24 20:10:45",
"state": "succeeded"
}
]
}
As you can see, the result is consistent with the one above, thereby achieving the feature of generating videos with specified dimensions.
¶ Asynchronous Callbacks
Since generation with the Veo Videos Generation API takes a relatively long time, approximately 1–2 minutes, the HTTP request would remain connected if the API did not respond for a long time, resulting in additional system resource consumption. Therefore, this API also provides support for asynchronous callbacks.
The overall process is as follows: When the client initiates a request, it specifies an additional callback_url field. After the client initiates the API request, the API immediately returns a result containing a task_id field, which represents the current task ID. Once the task is complete, the generated video result is sent as POST JSON to the callback_url specified by the client, and it also includes the task_id field, so the task result can be associated using the ID.
Below, we will use an example to understand how this works in practice.
First, a Webhook callback is a service that can receive HTTP requests, and developers should replace it with the URL of their own HTTP server. For convenience, this demonstration uses a public Webhook sample website, https://webhook.site/. Open the website to obtain a Webhook URL, as shown below:

Copy this URL to use it as a Webhook. The example here is https://webhook.site/aed5cd28-f8aa-4dca-9480-8ec9b42137dc.
Next, we can set the callback_url field to the Webhook URL above and fill in the corresponding parameters, as shown below:

Click Run, and you will immediately receive a result as follows:
{
"task_id": "1ebe4f2b-59ba-4385-a4ea-0ce8a3fe12ed"
}
After waiting a moment, we can observe the generated video result at https://webhook.site/aed5cd28-f8aa-4dca-9480-8ec9b42137dc, as shown below:

The content is as follows:
{
"success": true,
"task_id": "1ebe4f2b-59ba-4385-a4ea-0ce8a3fe12ed",
"trace_id": "d1d53c04-58c5-4c40-bb63-f00188540e56",
"data": [
{
"id": "2f43ceed37944b4d836e1a1899dad0a1",
"video_url": "https://platform.cdn.acedata.cloud/veo/1ebe4f2b-59ba-4385-a4ea-0ce8a3fe12ed.mp4",
"created_at": "2025-07-25 17:19:20",
"complete_at": "2025-07-25 17:21:45",
"state": "succeeded"
}
]
}
As you can see, the result contains a task_id field, while the other fields are similar to those described above. This field can be used to associate the task with its result.
¶ Error Handling
When calling the API, if an error occurs, the API will return the corresponding error code and message. For example:
400 token_mismatched: Bad request, possibly due to missing or invalid parameters.400 api_not_implemented: Bad request, possibly due to missing or invalid parameters.401 invalid_token: Unauthorized, invalid or missing authorization token.429 too_many_requests: Too many requests, you have exceeded the rate limit.500 api_error: Internal server error, something went wrong on the server.
¶ Error Response Example
{
"success": false,
"error": {
"code": "api_error",
"message": "fetch failed"
},
"trace_id": "2cf86e86-22a4-46e1-ac2f-032c0f2a4e89"
}
¶ Conclusion
Through this document, you have learned how to use the Veo Videos Generation API to generate videos by providing a prompt and a first-frame reference image. We hope this document helps you better integrate and use the API. If you have any questions, please feel free to contact our technical support team.
