Skip to content

Mobile ID SDK installation & setup

Android integration (Kotlin/Java)

Gradle configuration

Step 1: Add the SDK dependency to your app's build.gradle.kts:

dependencies {
    implementation("de.baltech:sdk-android:0.01.00")
}

Step 2: Configure Java compatibility settings:

android {
    compileOptions {
        sourceCompatibility = JavaVersion.VERSION_11
        targetCompatibility = JavaVersion.VERSION_11
    }
}

kotlin {
    jvmToolchain(11)
}

AndroidManifest.xml configuration

Add the following permissions to your AndroidManifest.xml:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android">

    <!-- Bluetooth permissions -->
    <uses-permission android:name="android.permission.BLUETOOTH" />
    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />

    <!-- Location permissions required for BLE scanning -->
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />

    <!-- Android 12+ BLE permissions -->
    <uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
    <uses-permission android:name="android.permission.BLUETOOTH_SCAN" />
    <uses-permission android:name="android.permission.BLUETOOTH_ADVERTISE" />

    <!-- Declare BLE hardware requirement -->
    <uses-feature
        android:name="android.hardware.bluetooth_le"
        android:required="true"/>

    <application>
        <!-- Your application configuration -->
    </application>
</manifest>

Important notes:

  • Location permissions (ACCESS_FINE_LOCATION or ACCESS_COARSE_LOCATION) are required for BLE scanning on Android.
  • Android 12+ requires BLUETOOTH_CONNECT, BLUETOOTH_SCAN, and BLUETOOTH_ADVERTISE.
  • The SDK automatically handles permission requests.

iOS integration (Swift/Objective-C)

XCode project setup

Step 1: Add the MobileIDSdk.xcframework to your project

  1. Drag MobileIDSdk.xcframework into your Xcode project
  2. Ensure it's added to "Frameworks, Libraries, and Embedded Content"
  3. Select "Embed & Sign" or "Embed Without Signing" based on your needs

Step 2: Configure framework search paths

  1. Go to Build Settings
  2. Search for "Framework Search Paths"
  3. Add the path to the directory containing MobileIDSdk.xcframework

Info.plist configuration

Add the following keys to your Info.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <!-- Bluetooth usage descriptions (required) -->
    <key>NSBluetoothAlwaysUsageDescription</key>
    <string>This app uses Bluetooth to communicate with access control readers for secure credential transfer.</string>

    <key>NSBluetoothPeripheralUsageDescription</key>
    <string>This app acts as a Bluetooth peripheral to transfer credentials to access control readers.</string>

    <!-- Required device capabilities -->
    <key>UIRequiredDeviceCapabilities</key>
    <array>
        <string>bluetooth-le</string>
    </array>

    <!-- Background modes for BLE -->
    <key>UIBackgroundModes</key>
    <array>
        <string>bluetooth-peripheral</string>
    </array>
</dict>
</plist>

Important notes:

  • Usage descriptions are shown to users when requesting Bluetooth permissions
  • Customize the description text to match your app's use case
  • bluetooth-peripheral background mode enables background BLE operation
Title