Limits
This page states every limit of the API and what a request over a limit gets. The errors page lists every answer of the API.
Organisation limits
Each organisation has the limits below. The table shows their default values. The service's staff can change them for your organisation.
| Limit | Default | What a request over it gets |
|---|---|---|
| Submit requests per minute | 150 | 429 rate_limit_error |
| Read requests per minute | 600 | 429 rate_limit_error |
| Unfinished jobs at one time | 1,000 | See Caps on jobs. |
| Jobs per 24 hours | 1,000 | See Caps on jobs. |
| Minutes of video per hour | 108 | See The queue window. |
| Download links per file per 24 hours | 20 | 429 rate_limit_error |
Requests per minute
- Submit requests are
POST /batches,POST /batches/{batch_id}/cancelandDELETE /jobs/{job_id}/result. Every GET is a read request. - The window is the calendar minute. A refused request gets a
Retry-Afterheader with the seconds until the minute ends. - Every request with a valid key counts. This includes the repeat of a batch, a 404 for an unknown id, and refusals such as 400 and 413.
- These do not count: 401, a 404 for an unknown path, 405, and the admission answers.
Caps on jobs
- A batch with more inputs whose links passed the link rules than your unfinished jobs cap gets 400 with the param
inputsand the messageThe batch has more inputs than the organisation may have unfinished. - A batch with more inputs than your 24-hour cap, counting every input, gets 400 with the param
inputsand the messageThe batch has more inputs than the organisation may submit in 24 hours. - A batch that fits a cap alone, but not together with your other jobs, gets 429
capacity_exceeded. ItsRetry-Afterheader says when to try again. - Jobs that failed at acceptance count toward the 24-hour cap.
The queue window
Your organisation may queue 72 hours of processing. At the default of 108 minutes of video per hour, that is 7,776 minutes of video.
- Each unfinished job counts 30 minutes until the service has read its video.
- After that, the job counts its video's length in whole minutes, rounded up.
- Jobs that failed at acceptance take no room.
So at the default limits, one batch can hold at most 259 inputs whose links passed the link rules. A batch of 260 such inputs gets 400 with the param inputs and the message The batch holds more video than the organisation may queue.
A batch that fits the window alone, but not together with your unfinished jobs, gets 429 capacity_exceeded. Its Retry-After header says when to try again.
Credits
Your organisation prepays credits. Each output has a price in credits for each minute of video. Prices are not published on these pages.
- When a batch is accepted, the API reserves 30 minutes of every chosen output for each job whose link passed the link rules.
- When the service has read a video, it holds credits for the video's billable length instead.
- The billable length is the video's decoded length, rounded up to a whole second, and at least 60 seconds (1 minute).
- Only completed outputs are charged. A failed output has no charge. A job's hold is released when the job finishes.
- A batch keeps the prices of the moment it was accepted.
usage.credits_pending_microon a job shows the 30-minute reservation, in millionths of a credit, until the service has read the video, or until the job ends if that comes first. After the read it is 0, and the hold for the billable length stays on your balance until the job finishes.
A batch that needs more credit than your organisation has gets 429 insufficient_quota with the message The organisation does not have enough credit for this batch. This answer has no Retry-After header: add credit before you send the batch again.
When an output that a batch asks for has no price, the batch gets 503 service_unavailable with a Retry-After of 300 seconds (5 minutes). pii_blur is part of every batch.
Processing limits
- A video may be at most 1,800 seconds (30 minutes) long. A longer video makes its job fail.
- A video is billed for at least 60 seconds (1 minute).
- A job must finish within 72 hours of the acceptance of its batch. Otherwise it fails with the code
deadline_exceeded. - The shortest video, and the limits on frame rate, picture size, container and codec, are not published yet.
The API does not see the video when it accepts a batch. So a video outside these limits is accepted, and its job fails later.
Request limits
| Limit | Value |
|---|---|
| Inputs in one batch | 1 to 1,000 |
Body of POST /batches | 8 MiB |
| Body of cancel and of a result delete | 1,024 bytes |
Idempotency-Key | 1 to 255 printable ASCII characters without spaces |
| JSON values in one body | 100,000 |
| Length of one string | 65,536 UTF-16 code units |
| Nesting of arrays and objects | 32 levels |
| Length of a link | 1 to 4,096 characters |
| Length of a link's host | 253 characters |
Items on a page of GET /batches | 1 to 100 |
| Items on a page of a job list | 1 to 1,000 |
A body of POST /batches over 8 MiB gets 413 request_too_large. A body nested too deep gets 400 with the message The body nests arrays and objects deeper than 32 levels. The input contract lists every message of the JSON rules.
Failed authentications
The API counts failed authentications from each IP address. An IPv6 address counts as its /64 network. A failed authentication is a request with a missing, malformed, unknown or revoked key.
- After 30 failed authentications from one address, a request from that address gets 429
rate_limit_erroruntil the window ends. A request whose key the API accepted recently is still served. - The window starts at the address's first failed authentication and lasts 60 seconds (1 minute).
- A key that the API has not checked yet counts toward the 30 while its check runs. So more than 30 requests at once from one address can get this 429 before any failure, with a
Retry-Afterof 1 second. - Each server of the API keeps its own count.
- The answer's message is
Too many failed authentications from this address. Retry after the number of seconds in the Retry-After header.After 30 failures itsRetry-Afterheader holds the seconds until the window ends.
Admission limits
The service shares its capacity between organisations and between requests.
- When your organisation's share is full, a request gets 429
rate_limit_errorwith aRetry-Afterof 1 second. - When the whole service is busy, a request gets 503
service_unavailablewith aRetry-Afterof 1 second. - A request for a file link gets 503
service_unavailablewith aRetry-Afterof 1 second when too many file links are being made at once. - These answers do not count toward your requests per minute.
Retry-After
Every Retry-After header holds a whole number of seconds, at most 86,400 seconds (24 hours).
Downloads
The service downloads each video and each CSV IMU file from its link.
- Each attempt sends one GET request. A link gets at most two attempts, and its job fails when both fail. A failure that a second attempt cannot change fails the job after the first attempt.
- It accepts the status 200 only. It does not follow a redirect.
- It refuses a compressed body and an empty body.
- It looks up both the IPv4 and the IPv6 addresses of the host. Both lookups must succeed, and every address they return must be public, or the job fails.
- It connects to the first IPv4 address of the host, on port 443, so the host needs an IPv4 address in DNS.
- The server's certificate must be valid.
| Limit | Value |
|---|---|
| Size of a video file | 8 GiB |
| Size of an IMU file | 256 MiB |
| Name lookup | 5 seconds |
| Connection and TLS handshake, together | 10 seconds |
| First answer after the TLS handshake | 30 seconds |
| Response headers | 16,384 bytes |
| Whole download | 3,600 seconds (1 hour) |
| Rate | At least 4 MiB per second, measured over each window of 30 seconds |
Retention
The result of a job is kept for 30 days after the job finishes. The job's expires_at says when. After that time, the result route answers 410 result_expired. You can delete a result before that time.