sms_consent 0.0.4 copy "sms_consent: ^0.0.4" to clipboard
sms_consent: ^0.0.4 copied to clipboard

outdated

A Flutter plugin that enable the use of SMS User Consent API.

sms_consent #

A Flutter plugin that enable the use of SMS User Consent API.

Only Android Support #

Since iOS have his own way to make easier to users to input the incoming OTP, this package only target the ANDROID OS.

To understand the flow and the API check this link

Installation #

Just follow the basic installation of any flutter plugin by adding the package to the project's pubspec.yaml.

On your Flutter project # See the installation instructions on pub.

Using this amazing plugin #

It's a very easy thing, trust me. With just 1 line you make the SMS User Consent API work on your app.

await SmsConsent.startSMSConsent(senderPhoneNumber: '321321312');

OR

await SmsConsent.startSMSConsent();

Part of the journey is the end #

When you ended with the plugin, is important to stop the Consent Service. Not calling the method below may result in unexpected behaviour in your app!

await SmsConsent.stopSMSConsent();

Considerations #

You need to call the plugin before requesting the OTP, since the SMS User Consent API will ONLY show SMS that are received after the initialization of it. In other words: the API doesn't show old messages.

1
likes
0
pub points
7%
popularity

Publisher

unverified uploader

A Flutter plugin that enable the use of SMS User Consent API.

Homepage

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on sms_consent