Read SMS

Hello! How to read SMS?

Corona SDK does not provide a facility for this. I do not believe it’s possible on iOS and there’s a good chance it’s not possible on Android without a rooted or jailbroken device.

If it is possible on Android without being rooted, then you potentially could use Corona Enterprise to reach the native SDK’s needed.

Rob

WhatsApp certainly can read SMS messages without root on Android (not sure about iOS).  I’m not sure on a valid case for reading users SMS messages as that is quite invasive.

I’ve done it before on Android studio.

It is possible on corona enterprise, as Android already has this feature few years ago, to read SMS. You need to set the priority to the highest so your app captures the SMS first.

Thanks! Example http://swarajsaaj.github.io/posts/reading-sms-automatically-otp-verification-android

I need Corona Enterprise :slight_smile:

// public static final String INBOX = "content://sms/inbox"; // public static final String SENT = "content://sms/sent"; // public static final String DRAFT = "content://sms/draft"; Cursor cursor = getContentResolver().query(Uri.parse("content://sms/inbox"), null, null, null, null); if (cursor.moveToFirst()) { // must check the result to prevent exception do { String msgData = ""; for(int idx=0;idx\<cursor.getColumnCount();idx++) { msgData += " " + cursor.getColumnName(idx) + ":" + cursor.getString(idx); } // use msgData } while (cursor.moveToNext()); } else { // empty box, no SMS }

This is Java code for reading SMS. How can this be done on the Corona SDK Free?

As I stated above, we really have no way do this in Corona SDK (the free product). But you have several options that you can explore and they include.

  1. Purchase Corona Enterprise and do it yourself.

  2. Vote up the existing feature request for this.  Visit http://feedback.coronalabs.com/forums/188732-corona-sdk-feature-requests-feedback/suggestions/4398825-be-able-to-recieve-and-send-sms-in-app-instead-of and cast more votes for it.

  3. Find a plugin developer who has Corona Enterprise and see if they can build a plugin for you.

Rob

Thank you!

Corona SDK does not provide a facility for this. I do not believe it’s possible on iOS and there’s a good chance it’s not possible on Android without a rooted or jailbroken device.

If it is possible on Android without being rooted, then you potentially could use Corona Enterprise to reach the native SDK’s needed.

Rob

WhatsApp certainly can read SMS messages without root on Android (not sure about iOS).  I’m not sure on a valid case for reading users SMS messages as that is quite invasive.

I’ve done it before on Android studio.

It is possible on corona enterprise, as Android already has this feature few years ago, to read SMS. You need to set the priority to the highest so your app captures the SMS first.

Thanks! Example http://swarajsaaj.github.io/posts/reading-sms-automatically-otp-verification-android

I need Corona Enterprise :slight_smile:

// public static final String INBOX = "content://sms/inbox"; // public static final String SENT = "content://sms/sent"; // public static final String DRAFT = "content://sms/draft"; Cursor cursor = getContentResolver().query(Uri.parse("content://sms/inbox"), null, null, null, null); if (cursor.moveToFirst()) { // must check the result to prevent exception do { String msgData = ""; for(int idx=0;idx\<cursor.getColumnCount();idx++) { msgData += " " + cursor.getColumnName(idx) + ":" + cursor.getString(idx); } // use msgData } while (cursor.moveToNext()); } else { // empty box, no SMS }

This is Java code for reading SMS. How can this be done on the Corona SDK Free?

As I stated above, we really have no way do this in Corona SDK (the free product). But you have several options that you can explore and they include.

  1. Purchase Corona Enterprise and do it yourself.

  2. Vote up the existing feature request for this.  Visit http://feedback.coronalabs.com/forums/188732-corona-sdk-feature-requests-feedback/suggestions/4398825-be-able-to-recieve-and-send-sms-in-app-instead-of and cast more votes for it.

  3. Find a plugin developer who has Corona Enterprise and see if they can build a plugin for you.

Rob

Thank you!