Offline & Downloads on mobile iOS & Android
From iOS SDK 11.2.0 and Android SDK 11.1.0 Applicaster supports built-in advanced offline capabilities and support for custom offline screen plugins that can be created by external developers.
The offline support is included as a part of the SDK without any additional configuration.
In many cases Offline support is complemented with the option to Download content and watch it offline.
Offline Mode -
To enjoy the Offline mode option, there is no need to install any plugin, but rather only use the relevant SDK that supports this feature. Hence, this feature is supported out-of-the box with the relevant SDK.
Content Download -
To implement the option of Content download you’ll need to install the `Downloads plugin` and use cell styles that support this feature by providing a download space placeholder in their cell.
You can find in the Appendix to this article, the list of supported cell styles that include in their design the download feature.
Alternatively, you can proceed to implement/develop your own supported cell style.
Offline Mode support
- iOS SDK 11.2.0 and above
- Android SDK 11.1.0 and above
The extended capabilities included the following features:
1. A Built-in offline screen that is displayed automatically any time an end user navigates to a screen that requires internet connectivity in order to show its content.
The built in screen includes the following:
- Offline Message - A configurable and translatable message (configured via the Zapp Localizations section), that prompts the end user that he/she is unable to reach the content due to the app being Offline.
- Retry/Refresh Button - A configurable and translatable button to refresh the screen and check if the internet connectivity has been restored. The default text for this button is "Try Again", but it can be changed via the Zapp Localizations section.
- Offline Home Screen - The option to go to a default Offline Home Screen that can be configured on the layout level in the UI Builder (more on that below).
2. Enablement for custom screen plugins to implement their own offline mode.
A screen plugin developer can implement offline support into his full screen plugin (please refer to the Developer Portal for additional information).
By implementing this feature the Automatic Offline Home Screen offered on an SDK-Level will Not display, but rather invoke instead the custom screen plugin and display the Custom Offline implementation that is part of this custom screen plugin.
3. The option to override the default UI Builder Offline screen, with an Offline Home Screen.
The offline home screen can be chosen from the list of supported offline screens created and available on the Layout Level.
The configuration of the Home screen is done via the layout settings, which is located on the upper-right-hand side of the Layout screen:
* Please note that Not Any screen will appear in the Offline Home dropdown menu.
For a Screen to appear in the "Offline Home" dropdown menu, it must:
i- Be an Empty screen - A screen which contains an empty component will NOT work, as the app can't load the component when there is no connectivity.
ii- An Offline Plugin - Or it must be a plugin that calls for a screen that loads offline content, such as the Download Plugin, which calls for VODs that are stored on the device, and does not require any connectivity.
Common use cases for offline mode
To better understand how this feature works we’ve included a list of use cases that are common when a user uses the app while offline.
Use case 1 - The user opens the app in offline mode -
The default behaviour in such a case, is to show the built-in offline screen as described above.
Use case 2 - The app lost connectivity while the end-user was browsing the app -
If the app loses internet connectivity while the end-user is browsing the app, the user won’t see any change in the app UI until he/she tries to navigate to content that is only available while online (ie: only when the end-user navigates to content that requires an internet connection to load).
In that case, the app will show the built in offline screen (or in the case that the target screen has a built in offline implementation, show the custom offline implementation the screen plugin provided).
* Note - if connectivity was lost during online video playing - the Player will implement its own offline handling.
Appendix - relevant SDK keys to configure the build in offline screen
Localization - All `offline mode` section keys:
- Offline screen title
- Offline screen retry button title
- Offline screen description
- Go To Offline Home Screen
Styles - All `General - Offline Mode` section keys:
The downloads plugin
As described above - to be able to Download VODs you must install the downloads plugin and rebuild your app. Once you have done so, you will be able to download VOD content from the app to your device.
By default, a VOD is Not available for download. This is because the broadcaster needs to have specific Content Rights to allow content download.
To allow content to be downloadable, the data source provider must pass the `is_downloable` Extension as part of the content Entry.
[please refer to the DSP developer notes in the Developer Portal, to understand how to add this capability to your data source].
If you use Applicaster as your DSP - checking the HQME feature on Applicaster2 CMS will enable this feature .
How to configure downloads in Zapp?
Note: To configure downloads in Zapp you’ll need to make sure you installed the downloads plugin in your version.
Data source - To allow users to download content, the VOD data source item entry should have the extension key ‘is_downloadable` set to true.
The data source feed can also provide the `download_expiration_date` extension with a valid ISO 8601 format to restrict downloads and remove downloaded items once the expiration date started.
Adding the described keys to the data source entry will allow the cell style to present a download button that the end user can interact with (as mentioned above, the cell style itself must support the Download option).
Setting up the downloads screen
Zapp treats “downloads” as any other data source type. Meaning you can add downloads to any component on any “general content screen” as you see fit.
To create a downloads screen the Zapp user needs to:
1) Create a regular "General Content Screen" in Zapp
2) Add a Single component with “Downloads” as its data source type (please make sure it is the ONLY component on this screen!).
3) t’s recommended to set this screen as the `offline home screen` in the layout settings, so that this screen will show up as the default home screen when the end user opens the app in offline mode:
Downloads end user workflow
If a VOD item is defined as downloadable and shown in a cell style the supports showing the downloads button, then the end user will see on the cell style a download button:
Once a user taps on the download button the item will start downloading
Appendix 1 - List of currently supported cell styles that have a built in download button:
Colorado Cell Style Family (Only)