The Hover SDK requires the following permissions which you do not need to add as they are automatically merged by including the SDK in the gradle.build dependencies:
Some of these permissions are considered "dangerous" by Google and must be granted by the user at app runtime. As of Android Oreo the runtime permissions that must be granted by the user are READ_PHONE_STATE/CALL_PHONE and RECEIVE_SMS/READ_SMS. BIND_ACCESSIBILITY_SERVICE is a special permission which users must enable through a permission management screen in Android settings. Users can be can be sent to the screen from your app, but must toggle the setting themselves. SYSTEM_ALERT_WINDOW is also a special permission, but so long as your app is downloaded from the Play Store it will be granted without the user having to do anything. During development and if your app is sideloaded then the user will also have to grant this in the settings.
Hover includes an optional helper activity to get the permissions from the user. This helper is automatically used if you start a ussd session without first getting the required permissions:
The result is RESULT_OK if ALL the permissions were granted.
Below is the full permission flow provided by PermissionActivity. If any permissions have already been granted then they will be missing from the summary list and their corresponding dialog with not show. Most strings can be translated, see customization
Will only list permissions not yet granted
Allows reading the SIM card and dialing USSD codes. This dialog is provided by Android and cannot be changed.
Allows reading SMS as they are received. This dialog is provided by Android and cannot be changed.
Pressing "allow" will take the user directly to the following overlay toggle settings page.
The user must press the toggle in the top right and then press back to return to the app. The text on this screen is provided by Android and cannot be changed.
Pressing "open settings" will take the user directly to the following accessibilty settings list page.
The user must find your app in the list and choose it.
The user must press the toggle in the top right which will show the following confirmation dialog. The text on this screen is customizable.
Once the user presses "OK" they will automatically be taken back to your app and the Permission Activity will complete with RESULT_OK
In all versions of android except 6.0.1-6.0.4, the SYSTEM_ALERT_WINDOW permission is automatically granted to apps that request it, as long as the app is downloaded from the Play Store. The "Allow display over other apps" screen is only shown to users when the permission is not granted automatically.