SDK Integration
PowerAuth Flutter SDK Dependency
The PowerAuth Flutter SDK is a required dependency that will be automatically installed (if not already specified in your project).
Supported Platforms
The library is available for the following Flutter 3.44.0+ platforms:
- Android 6.0 (API 23) and newer
- iOS 13.4 and newer
How To Install
1. Prerequisites
- Flutter SDK installed (Get Started)
- A working Flutter project (
flutter create my_appif starting fresh)
2. Add Dependency
Open pubspec.yaml and add:
dependencies:
# Replace VERSION_DEFINITION with the actual package version.
mtoken_sdk_flutter: VERSION_DEFINITION
Then run:
flutter pub get
3. Configure Native Platforms
Android
In android/app/build.gradle, make sure to set the minimum SDK version:
compileSdkVersion 37
minSdkVersion 23
Also, make sure to enable Java 17:
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}
iOS
In ios/Podfile, ensure the platform version is at least 13.4:
platform :ios, '13.4'
Then install pods:
cd ios
pod install
cd ..
4. Import in your Dart files
import 'package:mtoken_sdk_flutter/mtoken_sdk_flutter.dart';
import 'package:flutter_powerauth_mobile_sdk_plugin/flutter_powerauth_mobile_sdk_plugin.dart';
Future<void> createMtokenInstance() async {
final powerAuth = PowerAuth("my-instance");
// note that an activated PowerAuth instance is required. How to activate the PowerAuth instance, follow https://github.com/wultra/flutter-powerauth-mobile-sdk documentation.
// Then, use PowerAuth's helper function to create the mtoken instance:
final mtoken = await powerAuth.createMobileToken();
}
Read Next
Last updated on Aug 20, 2026 (19:34)
Edit on Github
Send Feedback