frame_time_out_of_range: fix a video frames request
frame_time_out_of_range means an at value fell outside 0 to the clip length. Sume's video frames tool names the probed duration; keep every time below it.

frame_time_out_of_range means one of the times in your at[] list is at or past the end of the clip (or below zero). Sume's video frames tool requires every value to satisfy 0 <= t < duration, so the fix is to read the clip's real duration and keep each time strictly under it.
The rule and the codes below are from the Sume docs page for Video frames, read 2026-09-29, with the probe fields from Video inspect.
Why did my request fail after it was accepted?
The API checks the shape of the body when you submit: at[] must hold 1 to 24 values that are each 0 or more. It cannot know the clip length yet. The worker probes the file afterwards, and only then can it see that a time is out of range, so the job fails with frame_time_out_of_range and names the probed duration.
That is why a submit can return 202 and the job still fail. Poll the job until it is terminal before you read anything.
How do I find the duration first?
Run Video inspect on the same clip. Its result carries a probe object, and with frames: false you get the facts without the stills. Then pick times below the duration. The exclusive upper bound matters: the last valid instant is just before the duration, not on it.
| Code | When it appears |
|---|---|
frame_time_out_of_range | An at value outside [0, duration), found by the worker after the probe |
duration_out_of_range | Source longer than 300 s |
ffmpeg_fields_rejected | Body carries vf, filter, select or similar ffmpeg fields |
400 schema error | Both at[] and fps, neither, more than 24 at values, fps above 2, or a video_url not on media.sume.com |
Can I ask for frames without knowing the length?
Yes. Send fps instead of at[]. It samples the clip at mid-bin positions (0.5/fps, 1.5/fps and so on), so every sample lands inside the clip, and the result is capped at 24 frames. The rate must be above 0 and at most 2. Send exactly one of at[] or fps.
curl -X POST https://api.sume.com/v1/video-frames \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: frames-fps-001" \
-d '{
"video_url": "https://media.sume.com/artifacts/artf_demo/talk.mp4",
"fps": 0.5,
"format": "png"
}'How do I pick safe times for the last frame?
Read source_duration_seconds from the finished result or probe from inspect, then request a time a little under it, for example the duration minus a fraction of a second. Asking for exactly the duration is the classic way to trigger frame_time_out_of_range, because the range is exclusive at the top. If you only need a few evenly spread stills and do not care about exact instants, fps avoids the question entirely.
What else can stop the job?
A source longer than 300 seconds fails duration_out_of_range, even when your times are fine. A single instant whose extract failed comes back with a null url and does not fail the job, so check each frame in frames[] before you use it. Clips over 90 seconds may add a low_confidence_long_video warning, which is not a failure.
Sources
Related posts
More in Media tools
- Google Business Profile photo size: 720 × 720 px, JPG or PNG
Google recommends Business Profile photos at 720 × 720 px, at least 250 × 250 px, JPG or PNG, 10 KB to 5 MB. What that means for cover, logo and posts.
- Google Play feature graphic size (1024×500) and AI images
Google Play asks for a 1024×500 feature graphic. Sume's ChatGPT Image 2.5 cannot output that exact size, so generate the same shape larger and resize.
- Google Shopping image requirements: size, rules and AI tags
Google Shopping images must be at least 500 × 500 px from January 31, 2027, under 64 MP and 16 MB, with no promo overlays; AI images need AI metadata.
- How to flip a video horizontally with an API
To mirror a video left to right, run the hflip filter. Sume's video filter takes it as a one-line filtergraph and returns a new MP4.
Written by Sume