Skip to main content

smart_auth 4.0.0 copy "smart_auth: ^4.0.0" to clipboard
smart_auth: ^4.0.0 copied to clipboard

PlatformAndroid

Wrapper of Android SMS User Consent API, SMS Retriever API to read one time sms code, get user phone number, OTP, OTC, sms autofill, android autofill

4.0.0 · 6/11/2026 #

Breaking requirements (the existing Dart API is unchanged), see the Migrating section

  • Minimum Flutter 3.44 / Dart 3.12
  • Android: compileSdk 35 or above, the AGP, Gradle and Kotlin versions required by your Flutter version (see the README)
  • Raised the plugin minSdkVersion from 16 to 21, the minimum of androidx.credentials

New

  • Added Credential Manager support for passwords and passkeys: getCredential, createPasswordCredential, createPublicKeyCredential, prepareGetCredential, getPreparedCredential and clearCredentialState
  • Added const constructor to SmartAuthSms and the @immutable annotation to SmartAuthResult
  • Documentation: redesigned README, documented getAppSignature, added a 4.x migration note and the version requirements

Fixes

  • removeSmsRetrieverApiListener and removeUserConsentApiListener now finish a waiting SMS call as canceled instead of leaving its Future pending forever
  • Starting a new SMS call now finishes the previous waiting one as canceled instead of leaving it pending forever
  • getSmsWithRetrieverApi can now return SmartAuthResult.canceled
  • requestPhoneNumberHint and the SMS calls no longer share a result, so an SMS can't be returned as the phone number

Android

  • Migrated Android to built-in Kotlin and removed the Kotlin Gradle Plugin classpath from the plugin's build.gradle (AGP 9 support)
  • Updated androidx.credentials from 1.5.0-beta01 to the stable 1.5.0
  • Added the missing meta dependency

Tooling

  • Replaced very_good_analysis with flutter_lints: ^6.0.0 and fixed the analyzer warnings
  • Aligned the example app's SDK constraints with Flutter 3.44 / Dart 3.12
  • More reliable SMS and phone number hint integration tests, CI path filters and Dependabot

Closed issues

  • #32 Ability to get saved password options: getCredential
  • #33 Ability to save a credential: createPasswordCredential and createPublicKeyCredential
  • #34 prepareGetCredential
  • #44 Version requirements in docs
  • #45 Migrate plugin to built-in Kotlin

Pull requests

#47, #49, #50, #53, #54, #62

3.2.0 · 1/1/2025 #

  • Fixed method type by Dishank Jindal - PR
  • Removed unnecessary type declarations
  • Removed unnecessary exclude from the analyses_options.yaml
  • Replaced flutter_lints with very_good_analysis in the example app

3.1.0 · 22/12/2024 #

  • Lowered Java version to 11 for better compatibility
  • Retracted version 3.0.0

3.0.0 · 20/12/2024 #

  • Improved readme by adding detailed instructions
  • Improved the result returned from all methods

3.0.0-beta.1 · 19/12/2024 #

  • Upgraded Android Dependencies PR - with help of OneXeor 🙏
  • Kotlin version 2.0.0
  • gradle plugin 8.3.2
  • android sdk 35
  • core-ktx 1.15.0
  • Java 21
  • Removed fake support for other operating systems
  • Migrated to Pigeon
  • Added new Credentials Manager API
    • requestPhoneNumberHint
  • Removed deprecated SmartLock API
    • getCredential
    • saveCredential
    • deleteCredential

2.0.0 · 21/01/2024 #

  • Fixed RECEIVER_EXPORTED exception in android SDK 34 PR
  • Fix "Namespace not specified" error when upgrading to AGP 8.0 PR
  • Updated readme
  • Formatted example app

1.1.1 · 24/07/2023 #

  • Fixed AGP 4.2<= compatibility
  • Updated SDK constraints
  • Updated default SMS code matcher regex length to 8 digits

1.1.0 · 12/05/2023 #

  • Upgraded Gradle to 7.2.0
  • Added GitHub Actions
    • Static Analysis

1.0.8 · 29/12/2022 #

  • Fixed Error receiving broadcast Intent

1.0.6 #

  • Improved docs

1.0.5 #

  • Remove downcast of Activity => FlutterActivity

1.0.4 #

  • Replaced dart.io with foundation.dart

1.0.3 #

  • Fake support of all operating systems, because other packages is depended on this one

1.0.1 #

  • Fixed reinitializing listeners
  • Fixed Typos

0.9.1 #

Initial Release

  • Android Autofill**
    • SMS Retriever API
    • SMS User Consent API
  • Showing Hint Dialog
  • Getting Saved Credential
  • Saving Credential
  • Deleting Credential
212
likes
160
points
172k
downloads
screenshot

Documentation

API reference

Publisher

verified publishertornike.dev

Weekly Downloads

Wrapper of Android SMS User Consent API, SMS Retriever API to read one time sms code, get user phone number, OTP, OTC, sms autofill, android autofill

Repository (GitHub)
View/report issues
Contributing

Topics

#otp #sms-autofill #sms-user-consent-api #sms-retriever-api #smart-lock

Funding

Consider supporting this project:

ko-fi.com

License

MIT (license)

Dependencies

flutter, meta

More

Packages that depend on smart_auth

Packages that implement smart_auth