Developer Console
Thank you for your visit. This page is only available in English at this time.

GetNextPage Directives (VSK Echo Show)

When users select to go to the "next page" of search results, or when they scroll beyond the viewable search results on the screen, the VideoContentProvider API sends a GetNextPage directive to your Lambda to fetch more results. Your response provides additional items to populate the next page.

The following diagram shows this workflow:

GetNextPage Directive and Lambda GetNextPageResponse

Utterances for GetNextPage Directives

Feature Sample Utterances Expected Response Complete
Get Next Page
Required for certification

The next page of results appears on the screen.

 

Handling GetNextPage Directives

After receiving search results from your Lambda (through your GetDisplayableItemsMetadataResponse), a user might want to see additional search results, or "the next page" of search results. Users can paginate to the next page of search results with a simple phrase such as "Get next page."

This prompts Alexa to send a GetNextPage directive. Your Lambda response to this directive should include basic metadata for search results. The response is analogous to GetDisplayableItemsResponse.

After Alexa receives your GetNextPageResponse, Alexa will follow up with a GetDisplayableItemsMetadata directive as more information is needed.

GetNextPage Example

The following is an example GetNextPage directive. Note the minResultLimit and maxResultLimit for the items you must send.

{
    "directive": {
        "header": {
            "correlationToken": "dFMb0z+PgpgdDmluhJ1LddFvSqZ/jCc8ptlAKulUj90jSqg==",
            "messageId": "9f4803ec-4c94-4fdf-89c2-d502d5e52bb4",
            "name": "GetNextPage",
            "namespace": "Alexa.VideoContentProvider",
            "payloadVersion": "3"
        },
        "endpoint": {
            "cookie": {

            },
            "endpointId": "<the identifier of the target endpoint>",
            "scope": {
                "token": "<an OAuth2 bearer token>",
                "type": "BearerToken"
            }
        },
        "payload": {
            "nextToken": "fvkjbr20dvjbkwOpqStr",
            "minResultLimit": 8,
            "maxResultLimit": 25
        }
    }
}

Payload Descriptions

The following table describes the payload for GetNextPage directives.

Payload Descriptions
Field Description Data Type



Lambda Response

Your Lambda response should be a list of items to display on the device.

Response Example

The following is an example of the GetNextPageResponse that your Lambda should send. This payload follows the same format as GetDisplayableItemsMetadata.

{
    "event": {
        "header": {
            "correlationToken": "dFMb0z+PgpgdDmluhJ1LddFvSqZ/jCc8ptlAKulUj90jSqg==",
            "messageId": "9f4803ec-4c94-4fdf-89c2-d502d5e52bb4",
            "name": "GetNextPageResponse",
            "namespace": "Alexa.VideoContentProvider",
            "payloadVersion": "3"
        },
        "endpoint": {
            "scope": {
                "type": "BearerToken",
                "token": "Alexa-access-token"
            },
            "endpointId": "appliance-001"
        },
        "payload": {
            "nextToken": "qefjrfiugef74",
            "mediaItems": [
                {
                    "mediaIdentifier": {
                        "id": "recordingId://provider1.dvr.rp.1234-2345-63434-asdf"
                    }
                },
                {
                    "mediaIdentifier": {
                        "id": "recordingId://provider1.dvr.rp.1234-2345-63434-asdf"
                    }
                }
            ]
        }
    }
}

Payload Descriptions

Payload Descriptions
Field Description Data Type