X API Post attach rule: 4 photos, 1 GIF or 1 video

An X Post takes up to 4 photos, or 1 animated GIF, or 1 video. A Sume image call can return 1 to 4 images, which matches the 4-photo ceiling.

4 min readSume
All posts

X says you may attach up to 4 photos, 1 animated GIF or 1 video in a Post, and not a mix. Sume's image routes take n or num_images from 1 to 4, so one call can fill a four-photo Post; the image docs list no GIF output format.

The attach rule is from X's Media best practices page, read 2026-10-01. Sume facts are from Image API and Image 1.0.

What is the attach rule?

The page states "up to 4 photos, 1 animated GIF or 1 video in a Post". It also says upload and Post-create limits are separately enforced, so a media_id that finalized can still be rejected by POST /2/tweets.

What one X Post can carry, from the X best practices page, read 2026-10-01.
MediaMax in one Post
Photos4
Animated GIF1
Video1

How many images can one Sume call return?

The image catalog entry for bytedance-seed/seedream-4.5 shows n as a range from 1 to 4, and Image 1.0 documents num_images as an integer from 1 to 4. Each output gets a durable media.sume.com URL. Ask for four, review them, and attach the ones you keep.

Which ratio suits a feed Post?

Image 1.0 notes that 4:5 is Instagram portrait (1080 by 1350), not 4:3, and aspect ratios are a per-model catalog, so check what your model accepts. X's page does not give a photo aspect ratio, so this is a choice for your layout, not an X requirement.

What about a GIF or a video in the same Post?

They exclude photos. The Sume image formats listed for the catalog entry are png, jpeg and webp, so animated output comes from video, not from the image routes. For the GIF limits and an MP4 alternative see X animated GIF limits.

Sources

Related posts

More in Use cases

All Use cases posts

Written by Sume