autoussdflutter 1.0.0-alpha-02 autoussdflutter: ^1.0.0-alpha-02 copied to clipboard
Flutter plugin for the AutoUssd Android SDK
AutoUssdFlutter #
❗ THIS PLUGIN CURRENTLY ONLY WORKS ON ANDROID.
AutoUssd is a USSD automation framework. What does this mean? AutoUssd automates dialing a USSD code and interacting through the subsequent dialogs based on a configuration. This allows Android apps to interact with USSD session. This can be sending money via USSD, purchasing airtime or data, pay bills, etc.
AutoUssdFlutter is the Flutter plugin for the AutoUssd.
Install #
flutter pub add autoussdflutter
Setup #
AutoUssdFlutter uses the new AndroidX Activity Result APIs which means your MainActivity
must inherit from a ComponentActivity or a sub-class of it. Follow the steps below to modify your MainActivity
accordingly:
-
Open your
MainActivity.kt
in the Android module of your Flutter app. As an example, if your package name iscom.example.product
, yourMainActivity.kt
will be located at/android/app/src/kotlin/com/example/product/MainActivity.kt
-
Your file should look like the sample below:
package com.example.product import io.flutter.embedding.android.FlutterActivity class MainActivity: FlutterActivity() { }
-
Change your
MainActivity.kt
to look like thispackage com.example.product import io.flutter.embedding.android.FlutterFragmentActivity class MainActivity: FlutterFragmentActivity() { }
Awesome. Now you are ready to start using the SDK.
Documentation #
Get started by visiting our documentation on our website.