VOOZH about

URL: https://shopify.dev/docs/api/liquid/objects/external_video

⇱ Liquid objects: external_video


Skip to main content

Information about an external video from YouTube or Vimeo.


Tip

Use the external_video_tag filter to output the video in an HTML <iframe> tag. Use the external_video_url filter to specify parameters for the external video player.

Tip:

Use the external_video_tag filter to output the video in an HTML <iframe> tag. Use the external_video_url filter to specify parameters for the external video player.

Tip: Use the <a href="/docs/api/liquid/filters/external_video_tag"><code><span class="PreventFireFoxApplyingGapToWBR">external<wbr/>_video<wbr/>_tag</span></code> filter</a> to output the video in an HTML <code>&lt;iframe&gt;</code> tag. Use the <a href="/docs/api/liquid/filters/external_video_url"><code><span class="PreventFireFoxApplyingGapToWBR">external<wbr/>_video<wbr/>_url</span></code> filter</a> to specify parameters for the external video player.


Properties

The alt text of the external video.

Anchor to
aspect_ratioaspect_ratio

The aspect ratio of the video as a decimal.

Anchor to
external_idexternal_id

The ID of the video from its external source.

Anchor to
hosthost
string from a set of values

The service that hosts the video.

Possible values
youtube
vimeo

The ID of the external video.

Anchor to
media_typemedia_type

The media type of the external video. Always returns external_video.

Anchor to
positionposition

The position of the external video in the product.media array.

Anchor to
preview_imagepreview_image

A preview image of the media.

Note

Preview images don't have an ID attribute.

Note:

Preview images don't have an ID attribute.

Note: Preview images don&#39;t have an ID attribute.

{
"alt": "Potion beats",
"aspect_ratio": "1.77",
"external_id": "vj01PAffOac",
"host": "youtube",
"id": 22015756402753,
"media_type": "external_video",
"position": 1,
"preview_image": {}
}
Example
{
 "alt": "Potion beats",
 "aspect_ratio": "1.77",
 "external_id": "vj01PAffOac",
 "host": "youtube",
 "id": 22015756402753,
 "media_type": "external_video",
 "position": 1,
 "preview_image": {}
}
Was this section helpful?