Android
Full Installation Flow
Use the following method to download and install the latest version of your app in a single step:
This method initiates both the download and installation in one continuous flow, eliminating the need to call separate functions.
Note: The player may be prompted to grant permission the first time this method is used. This prompt appears only once. Future updates will not require additional approval. Depending on the device manufacturer and model, additional popups may appear during the installation process.
Installation process and callbacks
Once permission is granted, the following callbacks triggered in sequence:
onDownloadStarted
: Triggered when the download of the new app version begins.onProgress
: Triggered continuously as new data is downloaded.onDownloadEnded
: Triggered when the download is complete.onInstallationReady
: Triggered when the file is ready to install.
Error handling
The following errors may occur during installation:
- If the player cancels or interrupts the installation, the
onError
callback is triggered with the relevant error code. - If the player declines the installation permission,
onError
callback is triggered with the error code3000
. - Calling
installUpdate()
beforedownloadUpdate()
or before download completion, results in the error code2006
.
For more details on error codes and solutions, review the Android Auto Update SDK troubleshooting article.