com.biometrid:biometridfull (3.1.2)
Published 2026-10-22 10:17:59 +00:00 by ci-publisher
Installation
<repositories>
<repository>
<id>gitea</id>
<url> </url>
</repository>
</repositories>
<distributionManagement>
<repository>
<id>gitea</id>
<url> </url>
</repository>
<snapshotRepository>
<id>gitea</id>
<url> </url>
</snapshotRepository>
</distributionManagement><dependency>
<groupId>com.biometrid</groupId>
<artifactId>biometridfull</artifactId>
<version>3.1.2</version>
</dependency>mvn installmvn dependency:get -DremoteRepositories= -Dartifact=com.biometrid:biometridfull:3.1.2About this package
# BiometridFull - Android Integration Guide
## Overview
BiometridFull is a comprehensive identity verification SDK that provides a complete, WebView-based verification flow. It integrates all BiometridStandard modules (Liveness, NFC, AutoCapture) into a single, unified interface. The SDK manages the entire verification process through a web interface while leveraging native device capabilities for biometric operations.
## Prerequisites
- Android API Level 26+ (Android 8.0)
- Kotlin 2.2.0+
- AndroidX AppCompat
- Camera, Microphone and NFC permissions declared in `AndroidManifest.xml`
## Installation
### 1. Add Repositories
Add the following repositories to your project-level `build.gradle.kts` (or `settings.gradle.kts`):
```kotlin
repositories {
google()
mavenCentral()
maven { url = uri("https://dl.cloudsmith.io/public/biometrid/mobile/maven/") }
maven { url = uri("https://dl.cloudsmith.io/public/biometrid/mobile-test/maven/") }
maven { url = uri("https://dl.cloudsmith.io/public/biometrid/face01-liveness/maven/") }
maven { url = uri("https://maven.innovatrics.com/releases") }
maven { url = uri("https://raw.githubusercontent.com/iProov/android/master/maven/") }
maven { url = uri("https://maven.regulaforensics.com/RegulaDocumentReader/") }
maven { url = uri("https://jitpack.io") }
}
```
### 2. Add Dependency
Add the BiometridFull dependency to your app's `build.gradle.kts`:
```kotlin
dependencies {
implementation("com.biometrid:biometridfull:3.1.2")
}
```
### 3. Required Permissions
Add the following permissions to your `AndroidManifest.xml`:
```xml
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.NFC" />
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
<uses-feature android:name="android.hardware.nfc" android:required="false" />
<uses-feature android:name="android.hardware.camera" android:required="false" />
<uses-feature android:name="android.hardware.camera.front" android:required="false" />
<uses-feature android:name="android.hardware.microphone" android:required="false" />
```
### 4. Register Required Activities
The SDK uses internal activities that must be declared in your `AndroidManifest.xml` inside the `<application>` tag:
```xml
<activity
android:name="com.biometrid.biometridfull.ui.BiometridFullComposeActivity"
android:theme="@style/Theme.AppCompat.Light.NoActionBar"
android:exported="false" />
<activity
android:name="com.biometrid.autocapture.screens.ml.CameraActivity"
android:exported="false" />
<activity
android:name="com.biometrid.autocapture.screens.simple.SimpleCameraActivity"
android:exported="false" />
<activity
android:name="com.biometrid.biometridfull.webview.AndroidWebViewActivity"
android:theme="@style/Theme.AppCompat.Light.NoActionBar"
android:exported="false" />
<activity
android:name="com.biometrid.biometridstandardnfc.activity.BiometridNFCActivity"
android:exported="false" />
```
## Initialization
```kotlin
import com.biometrid.biometridfull.BiometridFull
import com.biometrid.biometridfull.callbacks.BiometridFullCallback
import com.biometrid.biometridfull.helpers.ScreenType
import com.biometrid.biometridstandard.enums.Language
import com.biometrid.biometridstandard.model.BiometridErrorInfo
// 1. Create your callback implementation
val callback = object : BiometridFullCallback {
override val url: String = "your-url"
override val app: String = "your-app-id"
override val appUrl: String = "your-app-url"
override val credential: String = "your-credential"
override val language: Language = Language.English
override val customHeaders: Map<Any?, *>? = null
override fun initialized(status: Boolean, error: BiometridErrorInfo?) {
// Handle initialization result
}
override fun processCreated(processId: String) {
// Handle process creation
}
override fun processUpdated(processId: String, stepId: String, action: String) {
// Handle step update — process moved to the next step
}
override fun processFinished(processId: String) {
// Handle process completion
}
override fun error(status: Boolean, error: BiometridErrorInfo) {
// Handle errors
}
}
// 2. Create the BiometridFull instance
val biometridFull = BiometridFull(callback)
```
## Available Methods
### `initialize()`
Initializes the SDK by connecting to the Biometrid backend and preparing all required services.
```kotlin
suspend fun initialize()
```
This method must be called before `start()`. It performs backend authentication using the provided `url`, `app`, and `credential` from the callback. The result is delivered through the `initialized` callback.
---
### `start(processId, screenType)`
Starts the identity verification process and presents the WebView interface.
```kotlin
suspend fun start(processId: String?, screenType: ScreenType)
```
| Parameter | Type | Description |
|-----------|------|-------------|
| `processId` | `String?` | Optional process ID. Pass `null` to create a new process, or provide an existing ID to resume. |
| `screenType` | `ScreenType` | Platform-specific screen context. On Android, wrap the current `Context`. |
---
### `stop()`
Stops the current verification process and cleans up all resources.
```kotlin
fun stop()
```
Stops any active WebView sessions, cancels pending native operations (Liveness, NFC, AutoCapture), and releases associated resources. Safe to call at any point.
## Callback Interface
### **BiometridFullCallback**
The callback interface that must be implemented to receive SDK lifecycle events and provide configuration.
#### Properties
| Property | Type | Description |
|----------|------|-------------|
| `url` | `String` | The Biometrid API base URL (e.g., `https://api.biometrid.com/`) |
| `app` | `String` | Your application identifier provided by Biometrid |
| `appUrl` | `String` | The Biometrid web application URL (e.g., `https://app.biometrid.com/`) |
| `credential` | `String` | Your credential key provided by Biometrid |
| `language` | `Language` | The language for the verification interface |
| `customHeaders` | `Map<Any?, *>?` | Optional custom HTTP headers to include in API requests |
#### Methods
| Method | Description |
|--------|-------------|
| `initialized(status: Boolean, error: BiometridErrorInfo?)` | Called when SDK initialization completes. `status` is `true` on success. |
| `processCreated(processId: String)` | Called when a new verification process is created. Returns the process ID. |
| `processUpdated(processId: String, stepId: String, action: String)` | Called when a step is successfully updated and the process moves to the next step. Returns the completed step's ID and action type. |
| `processFinished(processId: String)` | Called when the verification process completes successfully. Returns the process ID. |
| `error(status: Boolean, error: BiometridErrorInfo)` | Called when an error occurs during the verification process. |
## Data Models
### **BiometridErrorInfo**
```kotlin
data class BiometridErrorInfo(
val code: String? = null,
val message: String? = null,
val data: JsonElement? = null
)
```
| Property | Type | Description |
|----------|------|-------------|
| `code` | `String?` | Error code identifier (e.g., `"MBF001"`) |
| `message` | `String?` | Human-readable error description |
| `data` | `JsonElement?` | Optional additional error data |
---
### **ScreenType**
Platform-specific screen context wrapper used to present the verification interface.
```kotlin
// Android
class ScreenType(val context: Context)
```
| Property | Type | Description |
|----------|------|-------------|
| `context` | `Context` | The Android Context (typically an Activity) used to present the WebView |
## Enums
### **Language**
```kotlin
enum class Language(val value: String) {
English("en-GB"),
Portuguese("pt-PT"),
French("fr-FR"),
Spanish("es-ES"),
Italian("it-IT")
}
```
## Error Handling
Errors are delivered through the `error` method of `BiometridFullCallback`. Each error includes a `BiometridErrorInfo` object with a code and descriptive message.
Error codes follow the prefix convention:
- `MBF` - BiometridFull module errors
Handle errors in the callback:
```kotlin
override fun error(status: Boolean, error: BiometridErrorInfo) {
val errorCode = error.code ?: "Unknown"
val errorMessage = error.message ?: "An unknown error occurred"
// Handle or display the error
}
```
## Usage Example
### ViewModel Integration
```kotlin
import androidx.lifecycle.ViewModel
import androidx.lifecycle.viewModelScope
import com.biometrid.biometridfull.BiometridFull
import com.biometrid.biometridfull.callbacks.BiometridFullCallback
import com.biometrid.biometridfull.helpers.ScreenType
import com.biometrid.biometridstandard.enums.Language
import com.biometrid.biometridstandard.model.BiometridErrorInfo
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.StateFlow
import kotlinx.coroutines.launch
class BiometridFullVM : ViewModel() {
private val _isInitialized = MutableStateFlow(false)
val isInitialized: StateFlow<Boolean> = _isInitialized
private val _error = MutableStateFlow<String?>(null)
val error: StateFlow<String?> = _error
private val _isProcessCompleted = MutableStateFlow(false)
val isProcessCompleted: StateFlow<Boolean> = _isProcessCompleted
private val biometridFull = BiometridFull(object : BiometridFullCallback {
override val url = "your-url"
override val app = "your-app-id"
override val appUrl = "your-app-url"
override val credential = "your-credential"
override val language = Language.English
override val customHeaders: Map<Any?, *>? = null
override fun initialized(status: Boolean, error: BiometridErrorInfo?) {
_isInitialized.value = status
error?.let { _error.value = it.message }
}
override fun processCreated(processId: String) {
// Store processId if needed
}
override fun processUpdated(processId: String, stepId: String, action: String) {
// Step updated, process moved to next step
}
override fun processFinished(processId: String) {
_isProcessCompleted.value = true
}
override fun error(status: Boolean, error: BiometridErrorInfo) {
_error.value = error.message
}
})
fun initialize() {
viewModelScope.launch {
biometridFull.initialize()
}
}
fun start(context: android.content.Context) {
viewModelScope.launch {
biometridFull.start(
processId = null,
screenType = ScreenType(context)
)
}
}
fun stop() {
biometridFull.stop()
}
override fun onCleared() {
super.onCleared()
biometridFull.stop()
}
}
```
### Activity Usage
```kotlin
class MainActivity : AppCompatActivity() {
private val viewModel: BiometridFullVM by viewModels()
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
// Observe state
lifecycleScope.launch {
viewModel.isInitialized.collect { initialized ->
if (initialized) {
// SDK is ready, enable start button
}
}
}
lifecycleScope.launch {
viewModel.error.collect { error ->
error?.let {
// Show error to user
}
}
}
lifecycleScope.launch {
viewModel.isProcessCompleted.collect { completed ->
if (completed) {
// Verification process completed
}
}
}
// Initialize the SDK
viewModel.initialize()
// Start verification when ready (e.g., on button click)
startButton.setOnClickListener {
viewModel.start(this)
}
}
override fun onDestroy() {
super.onDestroy()
viewModel.stop()
}
}
```
Dependencies
io.ktor:ktor-client-android
2.3.7
io.ktor:ktor-client-okhttp
2.3.7
io.ktor:ktor-client-core
2.3.7
io.ktor:ktor-client-content-negotiation
2.3.7
io.ktor:ktor-serialization-kotlinx-json
2.3.7
io.ktor:ktor-client-websockets
2.3.7
io.socket:socket.io-client
2.0.1
dev.icerock.moko:socket-io
0.6.0
androidx.lifecycle:lifecycle-viewmodel-compose
2.6.2
androidx.security:security-crypto
1.1.0-alpha06
androidx.webkit:webkit
1.8.0
androidx.activity:activity-compose
1.9.3
androidx.compose.ui:ui-android
1.7.8
androidx.appcompat:appcompat
1.7.0
androidx.compose.material3:material3-android
1.3.2
org.jetbrains.compose.components:components-resources
1.8.2
org.jetbrains.kotlinx:kotlinx-datetime
0.6.0
org.jetbrains.kotlinx:kotlinx-coroutines-core
1.8.0
org.jetbrains.kotlinx:kotlinx-coroutines-android
1.8.0
com.russhwolf:multiplatform-settings
1.1.1
com.russhwolf:multiplatform-settings-coroutines
1.1.1
io.coil-kt:coil-compose
2.4.0
io.coil-kt:coil-svg
2.4.0
com.biometrid.face01:biometrid-android-active-liveness
9.7.110
com.iproov.sdk:iproov
11.0.0
org.tensorflow:tensorflow-lite
2.14.0
com.microsoft.onnxruntime:onnxruntime-android
1.23.2
androidx.camera:camera-core
1.4.2
androidx.camera:camera-camera2
1.4.2
androidx.camera:camera-lifecycle
1.4.2
androidx.camera:camera-view
1.4.2
androidx.exifinterface:exifinterface
1.3.7
androidx.concurrent:concurrent-futures
1.2.0
com.innovatrics.dot:dot-nfc
8.15.1
com.innovatrics.dot:dot-document
8.15.1
io.dyte:core-android
2.1.0
io.livekit:livekit-android
2.11.1
com.google.mediapipe:tasks-vision
0.20230731
io.sentry:sentry-kotlin-multiplatform
0.12.0
com.regula.documentreader.core:mrzrfid
7.7.+
com.regula.documentreader:api
7.7.+
Details
Assets (3)
Versions (9)
View all