Overlay video_fit contain: keep a wide product clip uncropped
In Sume timeline compose overlay, video_fit contain fits a wide 16:9 product clip inside the frame instead of cropping it, with a sale plate over the top.

To keep a wide product clip from being cropped when you put a sale plate over it, set layout.video_fit to contain on a Sume timeline-1.0/compose request with operation: "overlay". contain fits the whole clip inside the output frame, while cover fills the frame and cuts the edges. The still, which is your plate, sits on top at the position you choose.
The layout keys are listed in Timeline compose (read 2026-10-06). For overlay, video_fit is the only fit key you may send, because image_fit belongs to stack. The job builds one MP4 and costs $0.02 flat.
Which layout keys does overlay accept?
Overlay keeps the plate small and the clip full. Stack keys such as split, image_region, and ratio are refused with compose_overlay_takes_no_stack_layout.
| Key | Values | Default |
|---|---|---|
| position | top, center, or bottom | not stated in the docs |
| width_ratio | 0.05 to 1 of the frame width | 0.9 |
| margin_ratio | 0 to 0.45 of the frame height | 0.05 |
| video_fit | cover, contain, or stretch (blur is not a compose fit) | not stated in the docs |
What does the request look like?
This request lays a sale plate across the bottom of a wide clip at 80 percent of the frame width, and keeps the clip uncropped. Both URLs must be this workspace's media.sume.com files, so import them first with POST /v1/media-imports.
curl -X POST https://api.sume.com/v1/timeline-1.0/compose \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: sale-plate-wide-clip-001" \
-d '{
"operation": "overlay",
"image": { "url": "https://media.sume.com/artifacts/artf_demo/sale-plate.png" },
"video": { "url": "https://media.sume.com/artifacts/artf_demo/wide-product.mp4" },
"layout": { "position": "bottom", "width_ratio": 0.8, "video_fit": "contain" },
"output": { "width": 720, "height": 1280, "fps": 25 }
}'When should I choose cover instead?
Choose cover when the subject is centered and an edge crop costs you nothing. Choose contain when the product runs to the edge of the frame, or when the plate must not hide part of a cropped label. If the clip should be a vertical frame with no empty space, crop the source first with video filter and then compose.
- The output length comes from the video layer, and the still never makes the clip longer.
- Set
output.widthandoutput.heightto your timeline size, so the shot is not rescaled again later. - Read the job through
GET /v1/jobs/:id/result, which returnskind: timeline_composewithvideo_url.
Sources
Related posts
More in Use cases
- Photo to watercolor or pencil sketch with an API, composition kept
Turn a photo into a watercolor or pencil drawing on Sume: send it as an input reference to GPT Image 2.5 and say what to keep. There is no strength slider.
- Pinterest visual search ads: how many image variants per call?
Sume's image API takes n up to 10 per call, with lower per-model ceilings. Read the n range from the endpoint record before you plan a variant set.
- Pinterest visual search ads: a lifestyle scene from one product photo
Pinterest's visual search ads are a planned beta. Generate a lifestyle image from one product photo with POST /v1/images and an input reference, ratio 2:3.
- Pinterest visual search ads: a transparent-background product cutout
Visual search ads match your product by its look. Ask for background: transparent on openai/gpt-image-2.5 and keep a clean PNG cutout of each item.
Written by Sume