sms_detector 0.0.2

Flutter Android iOS

A flutter plugin for receiving incoming sms in android. Currently supports on only Android.

Flutter SMS Detector #

A flutter plugin for receiving incoming sms in android. Currently supports on only Android.

Usage #

To use this plugin, add sms_detector as a dependency in your pubspec.yaml file.

Example #

  @override
  void initState() {
    super.initState();
    retrieveNewSms();
  }

  retrieveNewSms()  {
    SmsDetector.waitForSms().then((x){
      // x is the body of SMS.
      setState(() {_smsBody = x;});
    }).catchError((e){
      print(e);
    });
  }


  @override
  void dispose() {
    //stop sms receiver
    SmsDetector.stopSmsReceiver();
    super.dispose();
  }
0
likes
80
pub points
26%
popularity

A flutter plugin for receiving incoming sms in android. Currently supports on only Android.

Repository (GitHub)
View/report issues

Documentation

API reference

Uploader

developer.rouf69nb@gmail.com

License

BSD (LICENSE)

Dependencies

flutter

More

Packages that depend on sms_detector