mytm_liveness_sdk 1.0.0
mytm_liveness_sdk: ^1.0.0 copied to clipboard
Liveness and KYC SDK for Flutter — passport and ID capture, MRZ, NFC chip reading, selfie liveness, face match, and backend verification.
// Sullis KYC SDK — Example App
//
// This example demonstrates two ways to use the SDK:
//
// 1. **High-level API**: `SullisKycSdk.instance.createSession()` →
// `capturePassport()` → `captureSelfie()` → `submitVerification()`.
// The SDK orchestrates everything; you get a result and lifecycle
// callbacks. Good when you want the default Sullis UI.
//
// 2. **Low-level UI widgets**: compose your own screens using the
// `PassportCameraOverlay`, `FaceCameraOverlay`, `NfcCapturePrompt`
// widgets. Good when you want the SDK's logic but your own UX.
//
// Both flows are accessible from the home screen.
import 'package:flutter/material.dart';
import 'package:mytm_liveness_sdk/mytm_liveness_sdk.dart';
import 'screens/home_screen.dart';
import 'screens/overlay_demo_screen.dart';
import 'screens/high_level_flow_screen.dart';
void main() {
runApp(const SullisExampleApp());
}
class SullisExampleApp extends StatelessWidget {
const SullisExampleApp({super.key});
@override
Widget build(BuildContext context) => MaterialApp(
title: 'Sullis KYC Example',
debugShowCheckedModeBanner: false,
theme: ThemeData(
colorScheme: ColorScheme.fromSeed(
seedColor: const Color(0xFF1A6FFB),
brightness: Brightness.light,
),
useMaterial3: true,
appBarTheme: const AppBarTheme(centerTitle: false),
),
routes: {
'/': (_) => const HomeScreen(),
'/high-level': (_) => const HighLevelFlowScreen(),
'/overlays': (_) => const OverlayDemoScreen(),
},
);
}