Conform a trim to 540x960 at 30 fps for TikTok non-Spark ads

TikTok's non-Spark ad spec sets 540x960 as the 9:16 minimum. One video-trim job with output 540x960 at 30 fps costs $0.02. Bitrate is not a field.

4 min readSume
All posts

Send video-trim with precision: exact and output: {width: 540, height: 960, fps: 30} to get a 9:16 file at TikTok's stated minimum size for $0.02. TikTok's ad specification page (read 2026-10-09) lists 540x960 as the minimum for 9:16 video, and Sume's trim output accepts width and height from 256 to 2160.

What TikTok asks for

These are TikTok's non-Spark ad figures from its own specification page; Sume does not enforce them.

  • File types listed: .mp4, .mov, .mpeg, .3gp, .avi.
  • Length up to 10 minutes and file size up to 500 MB.
  • Bitrate of at least 516 kbps.
TikTok non-Spark video ad specs, read 2026-10-09
RatioMinimum size
9:16540x960
16:9960x540
1:1640x640

The request

output works only with precision: exact. A keyframe cut with output returns video_trim_output_requires_exact. Allowed fps values are 24, 25, 30 and 60. 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-trim \
  -H "Authorization: Bearer $SUME_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: tiktok-540-001" \
  -d '{"video_url":"https://media.sume.com/artifacts/artf_demo/ad.mp4","start":0,"duration":30,"precision":"exact","output":{"width":540,"height":960,"fps":30}}'

Two honest gaps

First, the docs do not say how a source with a different aspect ratio is fitted into the output frame. Send a source that is already 9:16 and check the result frame with video frames. Second, Sume does not expose a bitrate field: the server compiles ffmpeg and rejects codec, crf and similar keys with ffmpeg_fields_rejected. So the 516 kbps floor is something you confirm on upload, not something you can set here.

Cost

One trim job is $0.02 at the public rate. Three ad lengths from one master (15, 30 and 45 seconds) are three jobs, 3 x $0.02 = $0.06.

Checking the result

After the job is ready, run video inspect on the result with frames: false to read the probe, and sample one frame at the middle of the clip with video frames. That costs a few cents of compute at most and confirms the size before you upload. Because the TikTok page also lists a 10-minute length limit and a 500 MB file limit, keep ads short: a 30-second 540x960 file is far below both. 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

All Media tools posts

Written by Sume