media
A media item attached to a product: image, video (adaptive streaming), or 3D model.
Properties
| Property | Description |
|---|---|
media.alt | Alt text. |
media.aspect_ratio | Width ÷ height. |
media.attached_to_variant? | Boolean predicate for attached_to_variant on this media. |
media.duration | Buyer-visible duration value for this media. |
media.embed_url | Buyer-visible URL for embed, or nil/empty when unavailable. |
media.external_id | Identifier for the related external record, or nil/empty when unavailable. |
media.file_size_bytes | Buyer-visible file_size_bytes value for this media. |
media.file_type | Public file type value. |
media.filename | Buyer-visible filename value for this media. |
media.height | Height in px. |
media.host | Host being served. |
media.id | Unique identifier. |
media.media_type | Media type (‘image’, ‘video’, ‘model’). |
media.mime_type | Public mime type value. |
media.position | Position/order index. |
media.presentation | Buyer-visible presentation value for this media. |
media.preview_image | Preview image for the media. |
media.product_id | Identifier for the related product record, or nil/empty when unavailable. |
media.sources | Buyer-visible sources value for this media. |
media.src | Source URL. |
media.url | Relative URL of the resource. |
media.variants | Variants exposed in this resource context. |
media.width | Width in px. |
Property list is generated from the storefront engine (AnyMediaDrop), so it always matches what your theme can use. Use {{ media | json }} only as a curated debug snapshot; it can omit lazy or otherwise public properties.