Probe a finished video before upload: duration, size and aspect
Run video inspect with frames false to read a render's duration, size and frame rate before posting. Check it against the 3-minute Shorts limit.

Call POST /v1/video-inspect on the finished MP4 with frames set to false and read the probe block of the result for duration, size and frame rate before you upload it anywhere. Video inspect is synchronous by default and waits up to 30 seconds. Probing first stops a render that is 4 seconds over a limit from being rejected after you have already queued the post. YouTube's help pages say Shorts can be up to 3 minutes and that a three-minute Short needs a square or vertical aspect ratio, which are both properties you can read from a probe.
The probe tells you facts about the file; whether a platform accepts them is the platform's decision, so compare against the page you read, not against this post.
What video inspect returns
The request takes the Sume-hosted video URL and optional frames (at[] or fps, max_edge from 64 to 2160 with a default of 768) and transcribe, which runs speech-to-text at $0.01 per audio minute. The result always carries probe. If you omit frames you get 8 stills, so send frames: false for the probe alone. Stills use Modal compute, and the source can be up to 1800 seconds.
If you need a still at the exact source size, use video frames instead: it always returns 202, takes 1 to 24 at values, max_edge from 16 to 2160, a source of up to 300 seconds, and is billed by Modal compute.
| Probe value | Compare with | Source of the limit |
|---|---|---|
| duration | 3 minutes for a Short | YouTube Help: Shorts |
| width and height | Square or vertical for a three-minute Short | YouTube Help: three-minute Shorts |
| frame rate | The rate you meant to deliver | Your own plan |
| file size | The platform's file cap | The platform's own page |
A probe call
The request below asks only for the probe, with frames set to false. It needs an Idempotency-Key like the other Sume media writes, and the source has to be a media.sume.com artifact. If it does not finish in 30 seconds you get a 202 and can read GET /v1/video-inspect/:id later. Read the numbers from the response and test them with a few lines of your own code.
curl -X POST https://api.sume.com/v1/video-inspect \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: probe-001" \
-d '{
"video_url": "https://media.sume.com/artifacts/artf_demo/final.mp4",
"frames": false
}'A pre-upload gate
Wrap the call in a small check: refuse to upload when the duration is over 180 seconds or the shape is wider than tall. Keep the limits in one place in your code, with the date you read the pages, since platforms change them; the reading date for this post is 2026-10-07.
When the probe passes, store its output beside the file. If a platform later rejects the upload, you can compare the rejected file's values with the probe rather than guess.
When the numbers are wrong
If the duration is over, shorten the audio spine and re-render, or cut with video trim, which is $0.02 per job. If the shape is wrong, re-render with different output.width and output.height; the price is by output minute, not by pixel, so a re-render of a clip of a minute or less is $0.10.
Putting the gate in a pipeline
The natural place for the probe is the step right after the render finishes and before anything is published. The render result already reports duration_seconds, so the probe is a second opinion on the delivered file, plus width, height and frame rate, which the render result does not repeat.
Log the probe with the render's job id. When a platform's page changes, you can search your logs for every file that would have passed or failed the old and the new limit, without re-probing anything.
Sources
Related posts
More in Developers
- Python: cheapest Sume image model that lists your aspect ratio
A 25-line Python script reads Sume's image catalog, keeps models that list your aspect ratio, prices each from its endpoints record and prints the cheapest.
- Reconcile Sume jobs after a deploy or outage: poll what is open
After downtime, read status for every job your own table still shows as open, honor terminal and result_ready, and never resubmit. Python with sqlite.
- Redact faces and license plates: Pillow first, AI edit only to replace
For redaction use Pillow boxes you control; use an AI mask edit on openai/gpt-image-2.5 only to replace a plate or face, from $0.0094 per image on Sume.
- Rotate the Sume webhook signing secret without dropping a delivery
Upgrade the verifier first, rotate with POST /v1/webhooks/signing-secret/rotate, deploy the new secret inside the 24-hour two-signature window, then confirm it.
Written by Sume