I decided to make this a new post, since I’ve been kind of off topic asking this around since yesterday.
I’m using Sumit’s OneSignal Extension succesfully to make my app receive push notifications published with OneSignal via a custom PHP back-end. So, app workflow goes like this: “PHP backend POST to → OneSignal that sends notification to → Android device with app installed”.
This solution is working ok. But Android 13 devices all show on the OneSignal dashboard with status “Permission Not Granted”. In my Android 13 testing device, I cannot receive notifications until I go to the settings for applications and manually allow notifications permission for my app.
Other Android version devices receive notification normally just after installing the app and launching it for the first time. So, I guess implementarion is ok other than permission-wise.
I am currently asking for permission like this:
The problem is, on the Android 13 testing device, it doesn’t show any dialog prompting the user to allow the permission when running the app for the first time as expected.
I could get this prompt to work by exporting an APK and editing it on APK Studio Editor, which allows me to change Target SDK to 33. Then, with this modified APK installed on the Android 13 device, the permission popup shows correctly to the user after installation and starting the app for the firt time.
But that wouldn’t allow me to publish to Google Play, since I can’t convert modified APK to AAB (tried some solutions to convert APK to AAB found in forums, but couldn’t make them work).
I’m writing in the hope of someone who knows a solution for this. Either by making permission prompt show correctly without having to target SDK 33, or by making Kodular export AAB targeting SDK 33, or by pointing me to a solution to convert modified APK to AAB correctly.
I appreciate any help and, as always, will post solution here once I find it.
Thank you!