Error 908 in android 15 − (im)possible to send an automated SMS

It seems impossible to send an automated SMS from appinventor in android 15.
I simple cannot get the permission neither with code nor manually in the phone settings.
This is a Motorola 5g stylus 2025
Thanks
Erhard

Hi erhard

That is because of the Google Android security measures. Google don't want other developers to be able to do that. So far as I know, the only work-around is to produce an App that is not distributed via Google Play.

Obviously this has been discussed before:

It would really help if you provided a screenshot of your relevant blocks, so we can see what you are trying to do, and where the problem may be.

To get an image of your blocks, right click in the Blocks Editor and select "Download Blocks as Image". You might want to use an image editor to crop etc. if required. Then post it here in the community.

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

On Android 15+ you can...

See also here:

hi everyone i really appreciate your quick response.
here my blocks - the relevant one is the upper right and i tried the features below - nothing works. if i go to the phone app info and permission the SMS feature "allow" is greyed out on the android15 phone but not greyed out on android 13, but i did not have a SIM card in there so i could not test further on android 13.
i tried 'directmessaging ' and 'messaging', nothing works.

i should add the phonecall works but i still have to push manually the button to start calling

Is checkbox1 checked ?

thanks Anke - looked at it
advice does not apply because the 3 dots are not on my screen in android15 (they are there in android 13)
so i simply cannot lift the restricted permission

sorry which checkbox? the permission checkbox for 'allow SMS' is greyed out

oh yes this checkbox in the app was checked

so no one can easily write a fall sensor alert messaging app for elders

Of course , they are there on Android 15 and 16. I checked it.

Of course you can
You only now have to grant that permission manually once... say "Thank you Google" for protecting us from the evil

Probably device dependant?
@erhard which device are you using for your tests? Samsung?

Taifun

I have the Motoröla 5G stylus 2025

Ok this is embarrassing. I just checked it again and there it is and I could give permission.
Look I tried this many times yesterday and this morning, sadly I did not take a screenshot.

Which phones do u have.?

Ok now when I shake it prefill the message but it does not send. Oh, I still have the ,"send message but not send messagedirect.
Need to go home and modify and let you know.
Thank u both so much but honestly the dots were not there😊

it WORKED with messagedirect statement - GREAT
i shake and it messaged it - no other human interaction necessary

Android 16, Pixel 7 Pro

1 Like

It happens the same to me. Can't select the Allow SMS checkbox, because it appears greyed.
As the link you provided says: " In Android 15, the SEND_SMS permission is restricted to system apps and cannot be granted to regular apps, as it’s a whitelisted permission."
May be it's improved at Android 16, so you can get those screenshots?

I had to change mobile (because the battery swelled and threatened to burst into flames if I keep charging it, and I couldn't get a replacement battery).
The new device came with Android 15, and my app no longer works.

My problem is the app checks the mobile phone number of the device by sending to itself a code by an SMS.
I only use SMS for this purpose, once, after the installation.

Does anybody know if is there a better way (not Android version dependent) to get the device's phone number, or to check if the app's user entered it correctly, without sending/receiving an SMS?

Did you read the otther answer in that stackoverflow thread?

To Grant SMS permissions on Android 15+, Long Press the Android app and tap on "App info" Then tap on the menu button on the top right and select "Allow restricted permissions".

Once this is done you can now tap on the Permissions menu under "App info" and you can give SMS permission to the android app.

I wrote a full blogpost with step by step guide here

Taifun

1 Like

Thanks Taifun.
"Allow restricted settings" does'nt appear in my Redmi phone.
I'm afraid that (even if it worked) it would be too complicated to have to instruct every possible user of the app to go through the menus to do such a thing (and dependent of the Android version on their mobiles)
It's not practical, when you are trying to help people to share empty car seats on their trips to work, with just the press of a button: "I'm leaving now".

I don't mind working as much as necessary to design and test the app that is just the user interface of a platform that makes really complicated things.
But it has to be simple for the user. Or it won't suceed.