Flutter Mobile SDK
This document is a guide to the example project included in the plugin files. In addition, following the below steps will help you learn how to add and use (eNROLL plugin) in your flutter application.
1. REQUIREMENTS
Minimum Flutter version 3.3.4
Android minSdkVersion 24
Kotlin Version 1.9.0
2. INSTALLATION
Run this command:
With Flutter:
This will add a line like this to your package's pubspec.yaml (and run an implicit flutter pub get
):
2.1. Android
Add these lines in Build.gradle file:
Upgrade minSdkVersion to in app/build.gradle.
Add the following lines to settings.gradle file:
2.2. iOS
add the following to your project info.plist file
Add these two sources to the iOS project Podfile
2.3. Add a license file to your project:
For Android
For iOS
Make sure your iOS project has a reference for the license file or instead:
open ios project
drag and drop the license file to the root folder of the project as described above
make sure copy items if needed check box is checked
then done
2.4. Run Command line:
3. Import
4. USAGE
Create a widget and just return EnrollPlugin widget in the build function as:
5. VALUES DESCRIPTION
localizationCode
Select your language code enum value LocalizationCode.en for English, and LocalizationCode.ar if Arabic.
tenantId
Write your organization tenant id.
tenantSecret
Write your organization tenant secret.
mainScreenContext
Screen context
enrollCallback
Callback function to receive success, error, and getRequestID and response.
applicationId
Write your Application id.
skipTutorial
Choose to ignore the tutorial or not.
levelOfTrust
Write your Organization level of trust.
enrollMode
ONBOARDING, AUTH, UPDATE or FORGET_PROFILE_DATA
enrollEnvironment
Select the EnrollEnvironment: EnrollEnvironment.STAGING for staging and EnrollEnvironment.PRODUCTION for production.
googleApiKey
Google Api Key to view the user current location on the map.
Last updated