Pre-recorded limits
The pre-recorded API (POST /v2/upload, POST /v2/pre-recorded) has the limits of Gladia’s own API, with the same
values. Your account manager can set other values for your workspace.
| limit | value | past it |
|---|---|---|
File size, POST /v2/upload (a file sent in the form, or downloaded from its audio_url) |
1000 MB; up to 5000 MB for your workspace | 413 “file too large”, nothing stored |
| Audio duration per file | 8,100 s (2 h 15 min); up to 12 h for your workspace | 413 “Audio duration is greater than the maximum allowed duration (…)” |
| Channels per file | 8 | the job fails with 400 |
Uploads at once, POST /v2/upload |
5 per workspace | 429 with Retry-After |
Jobs created per minute, POST /v2/pre-recorded |
200 per workspace | 429 “Rate limit exceeded. …” with Retry-After |
| Jobs waiting for their turn | 300 per workspace | 429 “Max concurrent requests reached. …” |
| Jobs processing at once | 25 per workspace | the next ones wait their turn: no error |
The audio formats a job takes are listed with the API: see Transcribe a file.
Audio duration
Section titled “Audio duration”A file longer than your workspace’s limit is refused:
- at
POST /v2/pre-recorded, with413, when its duration is known before it is transcribed: a WAV file sent toPOST /v2/upload(its header gives it); - otherwise when its job starts: the job ends with
status: "error"anderror_code: 413, and the same message. A failed job is not billed.
The message names your limit and the file’s duration:
Audio duration is greater than the maximum allowed duration (8100 seconds but actual duration is 9000 seconds).
For longer recordings, split the file into parts of about an hour (with ffmpeg -f segment, for example) and send
one job per part, or ask your account manager for a higher limit (up to 12 h, as far as the endpoints that run
your jobs take such files).
Jobs waiting and processing
Section titled “Jobs waiting and processing”Your workspace’s jobs run 25 at a time; the next ones wait in your workspace’s queue and start as the running ones
end. A job waiting counts until it starts. With 300 jobs waiting, POST /v2/pre-recorded
answers 429 “Max concurrent requests reached”: send the next job once some have started (a
callback tells you when one ends). A 201 means the job is accepted: do not send it again
while it waits.
Requests per minute
Section titled “Requests per minute”Your workspace may create 200 jobs per minute, all its API keys together. Past it, POST /v2/pre-recorded answers
429 “Rate limit exceeded” with a Retry-After header: the seconds to wait before the next one is accepted. Spread a
batch of files over time rather than sending it at once.
Retrying
Section titled “Retrying”| answer | what to do |
|---|---|
413 “file too large” |
Compress the file (an MP3 or an Opus file is ten times smaller than a WAV), or split it. |
413 “Audio duration is greater than the maximum allowed duration …” |
Split the file, or ask for a higher limit. Retrying the same file will not help. |
429 “Rate limit exceeded …” |
Wait for the Retry-After header’s seconds, then send it again. |
429 “Max concurrent requests reached …” |
Wait for some of your jobs to start, then send it again, with backoff. |
429 with Retry-After on POST /v2/upload |
Your workspace is uploading 5 files at once: wait that many seconds. |
Compared with Gladia’s API
Section titled “Compared with Gladia’s API”The values are Gladia’s paid-plan defaults, and Gladia’s Enterprise maximum for the audio duration. Two differences:
- Channels: Gladia’s API takes 2 channels per file; Gladia Enterprise takes up to 8, each transcribed apart (see how channels are billed in Transcribe a file).
- Audio duration’s status: Gladia’s API answers
400for a file over the limit, atPOST /v2/pre-recorded; Gladia Enterprise answers413, the same message, and refuses atPOST /v2/pre-recordedonly when the duration is known then (a WAV upload): any other file is refused when its job starts.