AlexaPreviewModeService

@IviExperimental(message = "This API is experimental and relies on the Alexa Auto Preview modefeature, which is not fully mature yet. It may change in the future without providing backward compatibility.", reasons = [])
interface AlexaPreviewModeService

Service responsible for handling communication with AVS (Alexa Voice Service) to enable or disable Alexa Preview Mode using the InstantDeviceRegistration API. For security reasons, the InstantDeviceRegistration API calls must be done on the OEM's backend, rather than directly by this service or by any other service running on the device. This service must exclusively communicate with the OEM's backend. For more information on implementing the InstantDeviceRegistration API to enable Preview mode, please contact your local Alexa sales representative.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
abstract suspend fun deregisterDevice(deviceSerialNumber: String): PreviewModeResult

Requests the OEM's backend to unregister this device for Alexa Preview Mode using the AVS InstantDeviceRegistration API.

Link copied to clipboard
abstract suspend fun refreshToken(deviceSerialNumber: String, countryId: CountryId): PreviewModeResult

Requests the OEM's backend to retrieve a new access token using the AVS InstantDeviceRegistration API. This method is called when the current access token is expired or is about to expire.

Link copied to clipboard
abstract suspend fun registerDevice(deviceSerialNumber: String, countryId: CountryId): PreviewModeResult

Requests the OEM's backend to register this device for Alexa Preview Mode using the AVS InstantDeviceRegistration API.