Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Develop
Test
Publish
Monetize
Engage users
Device specifications
Resources
Skip to main content
Immediately after Alexa receives your Lambda’s response to GetDisplayableItems, the VideoContentProvider API sends a GetDisplayableItemsMetadata directive back to your Lambda. The purpose of the GetDisplayableItemsMetadata directive is to retrieve information to properly show search results (not to play any content). The following diagram shows the expected Alexa directive and Lambda response: GetDisplayableItemsMetadata Directive and Lambda GetDisplayableItemsMetadataResponse

Utterances for GetDisplayableItemsMetadata Directives

No utterances prompt Alexa to send GetDisplayableItemsMetadata directives. Instead, Alexa sends this directive as a follow-up after receiving your Lambda’s response to GetDisplayableItems.

Handling GetDisplayableItemsMetadata Directives

Alexa sends GetDisplayableItemsMetadata immediately before Alexa displays search results on the device. As such, Alexa might send this directive during search, browse, or landing page scenarios. The directive contains only a list of id values that Alexa needs metadata for. The id values are returned from you during the previous GetDisplayableItemsResponse that your Lambda sent. Your Lambda’s GetDisplayableItemsResponse response should contain metadata for Alexa’s voice response to the user, as well as metadata about icons, badging, selectionAction, etc. Artwork returned to the user should be applicable to the title. The artwork should make it easier for the user to identify the content you are recommending from his or her search.

GetDisplayableItemsMetadata Example

The following is an example GetDisplayableItemsMetadata directive:

Payload Descriptions

The following table describes the payload fields in the GetDisplayableItemsMetadata directive.
Payload Descriptions
FieldDescriptionData Type
locale
required
The locale for the user that should be used to get displayable information for the search results. A locale in the same format specified for languages in in the Network Working Group Best Current Practice 47 (BCP-47). If you receive an unrecognized locale, default to en-US.Examples: en-US, en-GB, de-DEString
mediaIdentifiers
required
Contains a list of id values for the media.Array
id
required
An identifier for the video item that is used to fetch any display or playback related metadata information on subsequent calls to GetDisplayableItemsMetadata or GetPlayableItemsMetadata. This identifier is opaque to Alexa and is just used as-is when querying for metadata information.String

Lambda Response

Your Lambda’s response must contain the metadata information required to populate the templates on the device (provided by Amazon) and render the search results on the screen. The response contains only display-related information — no playback information is required in this case. 

Response Example

The following an example of a GetDisplayableItemsMetadataResponse that your Lambda should send. This response provides a list of id values for the items to display on the device.

Example Response Payloads

The payload object for the GetDisplayableItemsMetadataResponse will contain different fields depending on the media. The following sample responses show the payload for different types of media.

Example Response Payload for an ON_DEMAND Movie

Example Payload for an ON_DEMAND TV Show

Example Payload for LIVE Content

Example Payload for Content That Can Be Browsed

Payload Descriptions

The following table describes the payload fields for a GetDisplayableItemsMetadataResponse.
Payload Descriptions
FieldDescriptionData Type
searchResults
required
The list of search resultsList
name
required
The name of the video. This is used to render a prompt to the user about the video that is going to be played. For example, “Here’s Interstellar.”Example: InterstellarString
contentType
required
ContentType specifies the content type for the video that was returned in the search results. If you send a recorded movie or TV show, the contentType is set to RECORDING. If the result contains information about a live TV show, then the contentType is set to LIVE. If the result contains an on-demand content, then the contentType is set to ON_DEMAND.ContentType is also used to render a prompt to the user. For example, if the contentType is LIVE, Alexa renders a prompt such as, “Here’s the Academy Awards now airing on CBS.” If the contentType is RECORDING, Alexa renders a prompt such as, “Here’s the Academy Awards.”Examples: RECORDING, LIVE, ON_DEMANDEnum
itemType
required
itemType specifies the type of item to be searched. itemType is unique for GetDisplayableItems directives related to the landing page template. When a user opens your landing page (by saying “Alexa, open ACME video” or by saying “Video Home” and then selecting your video skill), Alexa sends two GetDisplayableItems directives:
  • The first GetDisplayableItems directive is to retrieve categories for the landing page by setting the itemType property to CATEGORY and including a sortType of RECOMMENDED.
  • The second GetDisplayableItems directive obtains the featured video for the landing page where the request sets the itemType to VIDEO instead.
After receiving your response (GetDisplayableItemsResponse) for both directives, Alexa sends one GetDisplayableItemsMetadata call with a list combined of Category IDs and Video ID. The response includes metadata about the video as well as the categories.Example: VIDEO, CATEGORY
Enum
releaseYear
optional
Release year of video. This is used to display the release year when showing the item on the screen.2018String
selectionAction
required
Guidance on how to browse the entity when the user selects this item. For example, you may choose to group similar items together when sending the search results. Movies or TV shows can be grouped by Genre, or by Actor, etc. In such cases, you can drill down on the item by selecting the group and may view more results.The following enum values are allowed:
  • BROWSE: This means that you can get browse node items on the grouped entity to view more results. In this case, Alexa ends up calling the GetBrowseNodeItems on the selected entity id.
  • PLAY: This means that the particular entity is not grouped and hence can be selected to play the item. In this case, Alexa ends up calling the GetPlayableItemsMetadata on the selected entity id.
Examples: BROWSE, PLAY
Enum
thumbnailImage
required
Image information that is used to display an image for the result item on the screen. URL prefix must be https.Example:
Object
runtime
optional
Details about the video runtime.Object
runTimeInMilliseconds
optional
Duration of the video in milliseconds.Example: 271871324Long
displayString (runtime)
optional
The formatted display string for the duration of the video. This is used to show the duration on the screen.Example: 2h 30mString
closedCaption
optional
Details about whether closed caption is available for the video and display information.Object
status (closedCaption)
optional
Whether closed caption is available for the video. This is an enum with the following values:
  • AVAILABLE: This means that closed caption is available for the video.
  • NOT_AVAILABLE: This means that closed caption is not available for the video.
Examples: AVAILABLE,NOT_AVAILABLE
Enum
displayString (closedCaption)
optional
The formatted display string to be shown on the screen for closed caption.Example: CCString
series
optional
The metadata about the series if this item is part of a series. This information should be populated for TV shows only. If available, the information here is used to render prompts to the user for example, “Here’s ‘The Big Bang Theory’ Season 1, episode 4.Object
seasonNumber (series)
optional
The season number of the video.Example: 1String
episodeNumber (series)
optional
The episode number of the video.Example: 3String
episodeName (series)
optional
The episode name.Example: 4String
absoluteViewingPositionMilliseconds
required
Progress offset of video in milliseconds based on the user’s watch history. If the user has watched it previously, this represents some offset greater than 0. This is used to display a progress bar on the result item indicating how much has the user watched previously.Example: 1248625Long
parentalControl
required
Parental Control information based on the user and the video.Object
pinControl
required
This field indicates whether parental control is required for the user for this video based on the setting. This is an enum with 2 values.
  • REQUIRED: This means that parental control applies to this item based on the user’s setting. When this is set, there is a lock icon displayed on the item to suggest that parental control applies to this item and the user is required to enter a PIN to view the video.
  • NOT_REQUIRED: This means that parental control does not apply to this item based on the user’s setting.
Examples: REQUIRED, NOT_REQUIRED
Enum
viewingDisplayString
optional
The display string is shown on the screen with the result item and gives the user an indication of whether he/she can play immediately or has to go through buying/renting/subscribing, etc. Based on the entitlement status, the string can be different. The String needs to be localized based on the locale sent in the requestExample: Play Now, SubscribeString
reviews
optional
Information about the reviews for the video.List
totalReviewCount
optional
Total count of reviews for the video.Example: 13425Long
type (review)
optional
The type of review upon which information is based.Example: FIVE_STAREnum
ratingDisplayString
optional
Rating of the video based for the type mentioned above and the reviews. This is used to display the rating under each item in the search results.Example: 4.06String
rating
optional
Rating related information for the video.Object
ratingCategory
optional
Rating category of the video, such as PG-13. This rating applies for the region that this video is resolved from. Also the rating value may differ based on the content. For example, for movies you can send an MPAA rating like “PG-13”; for TV shows, you can send a TV parental guidelines rating like “TV-PG.”Example: PG-13, TV-PGString
recording
optional
Information related to recording. The current structure only has a single field for status. The reason for making this a structure and not a standalone field is because Alexa Skills Kit may want to add some more information to the recording structure in the future. Having it available as an object allows Alexa Skills Kit to group these items and make it extensible for the future requirements.Object
status (recording)
optional
Recording status for the content. The following enum values are allowed:
  • RECORDED: This means that the content was previously recorded.
  • RECORDING: This means that the content is being actively recorded at the time of the request.
  • SCHEDULED: This means that the content is scheduled to be recorded at a future time.
Examples: RECORDED, RECORDING, SCHEDULED
String
contentFreshness
optional
Details about content freshness.Object
state (contentFreshness)
optional
Whether this content is new for the provider that Alexa is fetching results from. The only enum value allowed is NEW — this means that the content is new and airing for the first time on the provider.Example: NEWString
networkDetails
optional
Network details gives information about the network the program is airing from. For example, a new episode of “The Big Bang Theory” airing from CBS, or a live soccer game airing from ESPN. For on-demand content, this could be, for example, Prime Video displaying Game of thrones results from HBO. If the result item represents a live show (contentType = LIVE) on a channel, this object contains its metadata.List
channel
optional
Information about the channel the video is currently airing on.Object
callSign (channel)
optional
Specifies a channel by call sign such as PBS.Example: PBSString
affiliateCallSign(channel)
optional
Specifies a channel by local affiliate call sign such as KCTS9.Example: KCTS9String
uri (channel)
optional
The URI of the channel such as “entity://provider/channel/12307”
channelMetadata
optional
Provides additional information about the specified channel.Object
name (channelMetadata)
optional
Another value that identifies the channel, such as “FOX”.String
image (channelMetadata)
optional
Example: http://ecx.images-amazon.com/images/I/81nSh3pZUDL.RI.jpgString
airingDetails
optional
This object contains information on when content airs.List
isLiveBroadcast
optional
Whether this content is airing in real time. Set this true for live events like watching an NFL football game, or award shows like Oscars or Emmys, etc., that are happening in real time.Set this false for content that was filmed prior to the original airing time. For example, a new episode of Big Bang theory that airs every Thursday. This must also be set to false for content that was once streamed in real time, like a football game in the past, but is no longer happening in real time.Examples: true, falseboolean
end
optional
The end time of the time window.Examples: 2016-09-07T23:59:00+00:00, 2018-01-24T02:30:00ZA string in ISO 8601 format.
start
optional
The start time of the time window.Examples: 2016-09-07T23:59:00+00:00, 2018-01-24T02:30:00ZA string in ISO 8601 format.
mediaIdentifier
required
Identifier for the mediaItem. See Retrieve Image Size Data from the mediaIdentifier Object.Object

Retrieve Image Size Data from the mediaIdentifier Object

The GetDisplayableItemsMetadata API returns relevant information about the items in your catalog. One of these metadata fields is a thumbnail image URL, which is used to load images onscreen as part of the search results, landing page, and category selection. Echo Show devices come in varying sizes and resolutions, so the image containers that these URLs populate are of varying sizes and resolutions too. If the image that GetDisplayableItemsMetadata returns doesn’t fit the device that requested it, then the image might get distorted on some displays. To avoid that, use data from the displayContext object which belongs to the mediaIdentifier.

How to Use the displayContext Object Data

The displayContext object provides you with the following fields: With the imageWidth and imageHeight fields in the request, you know exactly what image size to use. You can also use the two other fields that bucket the images: one to specify the desired imageAspectRatio and one for the imageSize. If you don’t provide the exact ratio or size requested, then your skill automatically scales images, first by trying to match the imageAspectRatio, and then the imageSize. If you use multiple images rather than one, the API matches on imageAspectRatio first to avoid stretching or cropping you images. See the following image properties that the API returns for each device. As a developer, you have the choice of providing images based on the level of granularity you decide. A 16:9 image, for example, displays at scale on all devices except the Echo Show 5, but if you prefer to offer an image of the exact resolution for each device, that option is also available to you.

Properties for imageSize

This table lists all the enum properties for the imageSize field:

Supported Image Sizes for Echo Show Devices

Here are the supported image sizes:
DeviceDevice ResolutionHero Title Resolution
(px)
Hero Title
Aspect Ratio
Search Result Resolution
(px)
Search Result
Aspect Ratio
Echo Show 10
2nd Gen
1280x8001280x80016:10364x20416:9
Echo Show 5960x480960x4802:1368x1842:1
Echo Show
1st Gen
1024x6001024x60016:10564x32016:9
Echo Show 81280x8001280x80016:10522x29316:9

Example Request

Last modified on May 24, 2021