Grato por sua visita. Neste momento esta página está apenas disponível em inglês.

Transport Controls Layout

You can control the appearance of the controls for your video–such as Play, Pause, Restart–with the Transport Controls layout.

For general information about how to include layouts in your APL responses, see Layouts.

For information about how to develop the best customer experience using the transport control layout, see Design Guide Links.

Import Alexa layouts

To import Alexa layouts into your skill, ensure that your document component includes an import object such as the following:

    "document": {
      "type": "APL",
      "version": "1.0",
      "import": [
        {
          "name": "alexa-layouts",
          "version": "1.0.0"
        }
		]...
	} ...

Transport controls specification

The complete transport controls specification is shown here.

Transport Controls layout controls

The Transport Controls layout includes several controls: secondaryControls, primaryControlSize, secondaryControlSize, mediaComponentId, autoplay, and playPauseToggleButtonId.

secondaryControls

Name Type Description Default
secondaryControls enum Type of secondary controls to use. One of: skip | none skip

primaryControlSize

Name Type Description Default
primaryControlSize dimension Height and width for the primary button "@transportPrimaryButtonSize"

secondaryControlSize

Name Type Description Default
secondaryControlSize dimension Height and width for the secondary button "@transportSecondaryButtonSize"

mediaComponentId

Name Type Description Default
mediaComponentId string Id of the media-playing component  

autoplay

Name Type Description Default
autoplay boolean Determines the starting state of the Play/Pause icon. This value should match the autoplay state of the media-playing component. false

playPauseToggleButtonId

Name Type Description Default
playPauseToggleButtonId string Optional id to set on the Play/Pause toggle button. This is useful when displaying multiple videos on one screen, each with their own transport controls. alexaPlayPauseToggleButton

Transport Controls layout example

This APL document references a video in mp4 format.