Audio
Introduction
Audio files are commonly used in <audio>
tags on the web, and as inputs for media players.
Required props
As with all Tasks, you must provide:
- either a
file_id
or aurl
to use as the input file - the kind of task to create
File ID
The file_id
should be the unique ID of a file in your project’s Files collection.
e.g. "file_id": "file_abcdefgh1234"
URL
The url
should be the URL of the audio
file to process.
This should be a publicly accessible or signed URL.
e.g. "url": "https://example.com/audio.mp3"
Kind
For audio tasks, this is always audio
.
e.g. "kind": "audio"
Shared options
All tasks support the following (optional) props:
filename
folder
ref
Supported inputs & task outputs
Formats
Uploaded or ingested files can be:
Property | Values |
---|---|
Audio Stream Codec | aac , opus , mp3 , flac , vorbis |
Media Container | mp3 , m4a , wav , ogg |
Tasks can output:
Property | Values |
---|---|
Audio Stream Codec | aac , opus , mp3 |
Media Container | mp3 , ogg , wav |
If you require flac
or any other audio codec, please contact us for early access.
Duration
Uploaded or ingested files can be:
- up to
4 hours
in duration
Tasks have the same default limits. 1
Filesize
Uploaded or ingested files can be:
- up to
4TB
in size
Tasks have the same default limits. 1
Example: Media object with audio
A representative Media
object (trimmed to audio-relevant fields):
Usage in HTML
Task status & webhooks
Tasks are processed asynchronously. You can poll the task by id until it completes, or use Webhooks to receive notifications. See Tasks for status values and examples.