Skip to content

Installation ​

Quick Start ​

  1. Add the plugin to your pubspec.yaml:

    yaml
    dependencies:
      scansdk:
        git:
          url: git@github.com:OVD-Kinegram-AG/scan-sdk-flutter.git
          ref: main
  2. Import the plugin with import 'package:scansdk/scansdk.dart';.

  3. Create a ScanSDK instance.

  4. Call openScanner() and handle the returned ScanSdkResult objects.

dart
final ScanSDK _scanSdk = ScanSDK();

Future<void> _openScanner() async {
  final results = await _scanSdk.openScanner();
  for (final result in results) {
    debugPrint('${result.type}: ${result.message}');
  }
}

Check example/lib/main.dart in the SDK repository for a complete Flutter app.

Android ​

On Android, the plugin loads the SDK from the kinegram.digital Maven repository and adds it to your Android build. Gradle ignores it if android/settings.gradle or android/settings.gradle.kts sets repositoriesMode to PREFER_SETTINGS or FAIL_ON_PROJECT_REPOS. In this case, copy the maven { … } block from android/build.gradle.kts of the plugin into the repositories of your settings file.