Video inspect with fps 0.4 returns 24 stills from a 60-second clip
The inspect frames program caps at 24 stills and fps at 2. For a 60-second clip, fps 0.4 fills all 24 slots, 2.5 seconds apart, centered in each bin.

For a 60-second clip, frames: {fps: 0.4} returns 24 stills, one every 2.5 seconds. 60 x 0.4 = 24, which is the most video inspect returns in a call. The default, with no frames field, returns 8 mid-bin stills instead.
Where the stills land
Sampling is mid-bin: each still is taken at the center of its bin, so the first is at 0.5 / fps = 1.25 s, the second at 3.75 s, and the last at 58.75 s.
| Program | Stills | Spacing | First / last time |
|---|---|---|---|
| not sent (default) | 8 | 7.5 s | 3.75 s / 56.25 s |
fps: 0.4 | 24 | 2.5 s | 1.25 s / 58.75 s |
fps: 2 | 24 (cap) | limited by the cap | see note |
at: [0, 30, 59] | 3 | as named | 0 / 30 / 59 s |
Why fps 2 does not give 120
The docs set 0 < fps <= 2 and a hard limit of 24 stills per call. At fps 2, a 60-second clip would want 120 stills, so you receive 24 and lose the rest of the clip. Pick fps from the target count: fps = 24 / duration. For a 90-second clip that is about 0.267.
Request
The default mode is sync and waits up to 30 seconds. If the job is not done in that time you get 202 and poll it. Stills are jpeg by default with max_edge 768; send png or a larger edge when you need detail. Import the clip first with POST /v1/media-imports so it sits on media.sume.com, send an Idempotency-Key header, then poll GET /v1/jobs/:id/status and read GET /v1/jobs/:id/result. The API rejects off-host URLs at admit, so a bad URL fails before any work runs.
curl -X POST https://api.sume.com/v1/video-inspect \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: inspect-24-001" \
-d '{"video_url":"https://media.sume.com/artifacts/artf_demo/ad.mp4","frames":{"fps":0.4,"format":"jpeg","max_edge":768}}'Limits
- Source up to 1800 s; 24 stills per call.
- Send only one of
at[]orfps; both together returnsvideo_inspect_frames_program_conflict. - An
atvalue outside the clip returnsframe_time_out_of_rangewith the real duration. - Sume bills probe and stills by their Modal compute; check the live figure in the catalog.
Choosing fps for other lengths
The rule is fps = 24 / duration, capped at 2. A 30-second clip can use fps 0.8 for 24 stills 1.25 seconds apart. A 120-second clip needs fps 0.2, which gives 24 stills 5 seconds apart. A 12-second clip hits the fps cap of 2 at 24 stills, 0.5 seconds apart. When a clip is long, prefer a few explicit at times at the moments you care about, such as the first second, the call to action and the last second. Every media job follows the same lifecycle: submit with an Idempotency-Key, receive a job, poll GET /v1/jobs/:id/status until it is ready, then read GET /v1/jobs/:id/result. A retry with the same key does not queue a second job, so a network error during submit never doubles a charge.
Sources
Related posts
More in Media tools
- Video inspect seek fast vs precise: stills up to one GOP early
Sume video inspect seek: fast snaps each still to the keyframe at or before the time, about 0-5 s early on typical sources. precise decodes the exact instant.
- Video inspect seek fast vs precise: stills up to one keyframe early
Set seek fast to get stills from the keyframe at or before each time, skipping the decode. Stills can be early by a GOP, about 0 to 5 s, never later.
- Video inspect transcribe: no duration hint reserves 1 minute
Sume video inspect with transcribe true bills $0.01 per audio minute. With no duration_seconds it reserves 1 minute; the hint maxes at 600 s (10 min = $0.10).
- Video inspect transcript for an 8-minute clip: $0.08 plus compute
transcribe true in video inspect adds STT at $0.01 per audio minute. An 8-minute clip is $0.08 plus compute; duration_seconds hints up to 600 s of reserve.
Written by Sume