Trim a TikTok or Instagram clip on Sume: import first, then cut

Sume media tools only read files on media.sume.com. To trim a public TikTok or Instagram video, import it first, then send the artifact URL to video-trim.

5 min readSume
All posts

Sume trim, filter, detach and timeline do not fetch from the open internet. Their video_url must be a media.sume.com file in your workspace. To cut a public TikTok or Instagram video, call POST /v1/media-imports first, wait for the mirrored artifact, then send that URL to POST /v1/video-trim.

What the import does

The route description in the API says it imports a public TikTok or Instagram video URL into Sume-owned storage. It creates a queued job and a mimp_ resource, mirrors the bytes to media.sume.com, and records a workspace asset with status mirrored. The estimate is a fixed $0.15 per accepted import. The practical size cap is about 2 GB.

YouTube and other hosts are rejected with unsupported_platform. The body takes a url (public HTTPS) and an optional get_transcript boolean, plus the usual communication options.

Step 1: import

Send the public post URL. Keep the Idempotency-Key stable for the post, so a retry replays the same import instead of creating a second one.

curl -sS -X POST "https://api.sume.com/v1/media-imports" \
  -H "Authorization: Bearer $SUME_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: import-reel-001" \
  -d '{ "url": "https://www.instagram.com/reel/EXAMPLE/" }'

Step 2: read the durable URL

GET /v1/media-imports/{id} returns the public-safe status, the durable media.sume.com URL, the asset id and source metadata. Provider download URLs and internals are omitted. Use the durable URL as the input of every later step.

Step 3: trim

Send video_url, start, and only one of end or duration. The default precision is exact, a frame-accurate re-encode. Use keyframe for a stream copy when speed matters more than the first frame, and re-base your times against actual_start_seconds in the result.

The trim costs $0.02 per job. The result is a new artf_ MP4, never the source. Put it into timeline_create video[] with source_in 0.

curl -sS -X POST "https://api.sume.com/v1/video-trim" \
  -H "Authorization: Bearer $SUME_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: trim-reel-001" \
  -d '{
    "video_url": "https://media.sume.com/artifacts/artf_demo/talk.mp4",
    "start": 2,
    "duration": 8
  }'

What fails if you skip the import

Pass the TikTok or Instagram page URL straight to video-trim and the API refuses it at admit. The trim, filter and detach pages list the same three source codes, and they apply to every Sume-hosted media tool.

Plan the budget as two lines: the import at a fixed $0.15 estimate, then the trim at $0.02, which is $0.17 before any later step. If you only need to know whether the clip has sound or how long it is, POST /v1/video-inspect with frames: false reads the probe first, and it is billed by Modal compute rather than at a flat rate.

From docs.sume.com/models/video-trim, read 2026-10-05
CodeMeaning
unsupported_media_sourcevideo_url is not on the Sume media host
source_not_foundThe media.sume.com URL is dead or belongs to another workspace
unsupported_media_typeThe HEAD result is not a video

Rights stay with you

The import only moves a file that is already public. It does not give you the right to reuse it. Confirm that you may use the clip before you cut it into a new video.

Related posts

More in Media tools

All Media tools posts

Written by Sume