Audio Generation
Authorizationstring*Replace {your api key} with your token
Token {your api key}modelstring*Model name. Available value: audio1.0
durationnumberAudio duration. Default 10, optional range: 2–10 seconds
timing_promptsstring*Controllable audio parameters. Describes multiple sound effect events and their respective time intervals; overlapping events are supported.- Maximum prompt character count per event: 1500 characters- from and to must be within the [0, duration] range
Authorizationstring*Replace {your api key} with your token
Token {your api key}idstring*Task ID, returned upon successful creation by the Create Task API
{your_id}seedintegerRandom seed. If not provided or set to 0, a random number is generated automatically; passing a fixed value produces deterministic results
callback_urlstringCallback protocol. You need to actively set callback_url when creating the task; the request method is POST. When the video generation task's status changes, Vidu will send a callback request containing the task's latest status to this address. The content structure of the callback request is consistent with the return body of the Query Task API.The "status" returned in the callback includes the following states:- processing: task in progress- success: task completed (if sending fails, the callback is retried up to 3 times)- failed: task failed (if sending fails, the callback is retried up to 3 times)Vidu uses a callback signature algorithm for authentication. For details, see: Callback Signature Algorithm
application/jsonResponse fields
idstringTask ID
statestringProcessing status
Available values:
created Created successfully
queueing Task queued
processing Task processing
success Task succeeded
failed Task failed
err_codestringError code. See the error code table for details
creditsintegerNumber of credits consumed by this task, unit: credits
payloadapplication/jsonResponse fields
task_idstringTask ID generated by Vidu
statestringProcessing status. Available values:
-created Created successfully
-queueing Task queued
-processing Task processing
-success Task succeeded
-failed Task failed
modelstringModel name used for this call
Pass-through parameter passed in when this task was called
bgmbooleanWhether BGM was used for this task call
off_peakbooleanWhether off-peak mode was used for this task call
creationsarrayGeneration results
idstringCreation ID, used to identify different generation results
urlstringGeneration result URL, valid for 24 hours
cover_urlstringGeneration result cover image, valid for 24 hours
watermarked_urlstringWatermarked generation result URL, valid for 24 hours
durationVideo duration parameter used for this call
timing_promptsarrayMultiple audio event parameters defined in this call
seedintegerRandom seed parameter used for this call
creditsintegerNumber of credits used for this call
created_atstringTask creation time
curl --request POST \
--url 'https://api.vidu.com/ent/v2/timing2audio' \
--header 'Authorization: Token {your api key}' \
--header 'Content-Type: application/json' \
--data '{
"model": "string",
"duration": 0,
"timing_prompts": "string",
"seed": 0,
"callback_url": "string"
}'{
"task_id": "your_task_id_here",
"state": "created",
"model": "audio1.0",
"duration": 10,
"timing_prompts": [
{
"from": 0.0,
"to": 3.0,
"prompt": "Birds chirping in the early morning"
},
{
"from": 3.0,
"to": 6.0,
"prompt": "The sound of a train passing in the distance"
},
{
"from": 5.0,
"to": 9.5,
"prompt": "Waves gently lapping the shore"
}
],
"seed": random_number,
"credits":credits_number,
"created_at": "2025-01-01T10:00:00.000Z"
}curl --request GET \
--url 'https://api.vidu.com/ent/v2/tasks/{your_id}/creations' \
--header 'Authorization: Token {your api key}'{
"id":"your_task_id",
"state": "success",
"err_code": "",
"credits": 4,
"payload": "",
"creations": [
{
"id": "your_creations_id",
"url": "your_generated_results_url",
"cover_url": "your_generated_results_cover_url",
"watermarked_url": "your_generated_results_watermarked_url"
}
]
}