react-native-sms icon indicating copy to clipboard operation
react-native-sms copied to clipboard

How can I complete sending SMS

Open DeanKamali opened this issue 7 years ago • 6 comments

Hello,

I have installed and configured this library on my Android phone, following the example in documentation when I invoke someFunction it composes a text message window that has the body and recipients, however it doesn't send the SMS message unless I press send.

How can I go about automating that? so that when I call someFunction it will send the text message without having to press send on Android text message app.

Thanks

DeanKamali avatar May 22 '17 19:05 DeanKamali

Hi!

The original intent wasn't to integrate automatically sent SMS messages (especially as this is only available for Android, and not iOS). That said, you're welcome to fork and create a PR with an option to autosend for Android. I haven't personally implemented autosending SMS but here's a jumping off point if you're interested

tkporter avatar May 23 '17 20:05 tkporter

@DeanKamali any progress on this?

sibelius avatar Jun 12 '17 18:06 sibelius

@tkporter , I'm just confirming what you mean by "only available for Android and not iOS" is that auto-sms features are not possible AT ALL on iOS platforms in their SDK? It's a bit confusing reading your comment when I'm not sure whether you're saying auto-SMS isn't possible on iOS or whether you just chose not to implement that even though it's possible. I entirely understand Apple's general policy and security implications and why they might not make such feasible.

tmaly1980 avatar Jul 08 '17 16:07 tmaly1980

Hello, I have one question. If we can't send a SMS automatically (on background) how can I return back to the app after sending a message? I my example it return to the android homescreen and user have to open the app manually.

Thanks

novotny avatar Jul 19 '17 15:07 novotny

I have the same question @novotny , haven't you fixed yet? Can you help me to solve this problem?

lytrant avatar Jan 04 '19 06:01 lytrant

the readme really should use highlight the below statement

Currently, only user-initiated sending of an SMS is supported. This means you can't use react-native-sms to send an SMS in the background-- this package displays the native SMS view (populated with any recipients/body you want), and gives a callback describing the status of the SMS (completed/cancelled/error). PRs are welcome!

I think https://github.com/yeyintkoko/react-native-sms-x is what I want.

Just waste of 1 hour to config

gamesover avatar Jan 30 '19 18:01 gamesover