The Up Next API contains the following objects and interfaces for configuring and displaying information about the next content to play as a bottom right bar on the player UI and as a panel at the end of the video, which includes a countdown timer. This API is available from version 2.15.0 onward and only if you have a player with this feature enabled.

UpNext

Properties

The upnext object provides the following properties:

Property Type Description
bar UpNextBar Returns an object to control the bottom right bar that will be shown near the end of the video.
panel UpNextPanel Returns an object to control the up next panel that will be shown at the end of the video.
source UpNextSource Sets or returns the information on the up next video such as a clickthrough link, a thumbnail image, a title, and duration of the video.

Methods

The upnext object provides the following methods:

Method Arguments Description
next   When the next method is called, the page will navigate to the link specified in the up next source.

UpNextSource

The UpNextSource interface contains information about the up next source.

Properties

An object implementing the UpNextSource interface should provide the following properties:

Property Type Optional Description
duration string yes The duration property can be used to display a duration on the up next bar.
image string  no The image property is used to set a thumbnail on the up next bar.
link string  no The link property is used to specify a target URL to navigate to, when clicking the up next bar.
title string yes The title property can be used to display a title on the up next bar.

UpNextBar

The UpNextBar interface contains information about the up next bar.

Properties

An object implementing the UpNextBar interface should provide the following properties:

Property Type Description
showing boolean The showing property indicates whether the up next bar is showing or not.
offset number The offset property is used to specify the offset form which the up next bar will be displayed. The offset is always calculated from the end of the video. Possible values are: 
  • a number (e.g. 10): the bar will be displayed from 10 seconds before the end of the video.
  • a string with a percentage (e.g. "10%"): the bar will be displayed during the last 10% of the video.

By default, the up next bar will be displayed 10 seconds from the end of the video.

Methods

Method Arguments Description
show   When the show method is called, the up next bar will be displayed.
hide   When the hide method is called, the up next bar will be hidden.

UpNextPanel

The UpNextPanel interface contains information about the up next panel.

Properties

An object implementing the UpNextPanel interface should provide the following properties:

Property Type Description
showing boolean The showing property indicates whether the up next panel is showing or not.
countdownDuration number  The countdownDuration property is used to specify the time after showing the up next panel and the next source starting playback. Possible values are:
  • number: the countdown will be number seconds.
  • Infinity: no countdown will happen, only the play button will appear to go to the video that is up next.
By default, the up next screen will be displayed for 10 seconds.
showUpNextPanel boolean The showUpNextPanel property is used to specify whether an up next screen should be shown at the end of the video. Default is true.

Methods

Method Arguments Description
show   When the show method is called, the up next panel will be displayed.
hide   When the hide method is called, the up next panelwill be hidden.