You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+44-38Lines changed: 44 additions & 38 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,16 +1,16 @@
1
1

2
-
# iProov Biometrics Kotlin Multiplatform SDK
2
+
# iProov Face Kotlin Multiplatform SDK
3
3
4
4
## Introduction
5
5
6
-
The iProov Biometrics Kotlin Multiplatform SDK wraps iProov's native [iOS](https://github.com/iProov/ios) (Swift) and [Android](https://github.com/iProov/android) (Java) SDKs behind a Kotlin Multiplatform interface for use from within your Kotlin Multiplatform iOS or Android app.
6
+
The iProov Face Kotlin Multiplatform SDK wraps iProov's native [iOS](https://github.com/iProov/ios) (Swift) and [Android](https://github.com/iProov/android) (Java) SDKs behind a Kotlin Multiplatform interface for use from within your Kotlin Multiplatform iOS or Android app.
7
7
8
8
We also provide an API Client written in Kotlin Multiplatform to call our [REST API v2](https://eu.rp.secure.iproov.me/docs.html) from the Kotlin Multiplatform Example app, which can be used to request tokens directly from the iProov API (note that this is not a secure way of getting tokens, and should only be used for demo/debugging purposes).
9
9
10
10
### Requirements
11
11
12
-
- Kotlin Multiplatform SDK 2.1.21 and above
13
-
- iOS 13 and above
12
+
- Kotlin Multiplatform SDK 2.2.21 and above
13
+
- iOS 15 and above
14
14
- Android API Level 26 (Android 8 Oreo) and above
15
15
16
16
## Repository contents
@@ -57,7 +57,7 @@ The iProov Kotlin Multiplatform SDK is provided via this repository, which conta
57
57
58
58
```kotlin
59
59
commonMain.dependencies {
60
-
implementation('com.iproov.kmp:sdk:1.0.1')
60
+
implementation('com.iproov.kmp:sdk:2.0.0')
61
61
}
62
62
```
63
63
@@ -118,10 +118,10 @@ class IproovViewModel : ViewModel() {
118
118
119
119
is IproovState.Failure -> {
120
120
// The user was not successfully verified/enrolled, as their identity could not be verified,
121
-
// or there was another issue with their verification/enrollment. A reason (as a string)
122
-
// is provided as to why the claim failed, along with a feedback code from the back-end.
123
-
val feedbackCode = state.failureResult.feedbackCode
124
-
val reason = state.failureResult.reason
121
+
// or there was another issue with their verification/enrollment. A list of reasons is provided to understand why the claim failed, where each reason contains two properties:
122
+
// - feedbackCode: A string representation of the feedback code.
123
+
// - description: An informative hint for the user to increase their chances of iProoving successfully next time.
124
+
val reasons = state.failureResult.reasons
125
125
val frame = state.failureResult.frame // An optional image containing a single frame of the user, if enabled for your service provider
126
126
}
127
127
@@ -153,8 +153,8 @@ class IproovViewModel : ViewModel() {
153
153
154
154
👉 You should now familiarize yourself with the following resources:
-[iProov Face iOS SDK documentation](https://github.com/iProov/ios)
157
+
-[Android Face Android SDK documentation](https://github.com/iProov/android)
158
158
159
159
These repositories provide comprehensive documentation about the available customization options and other important details regarding the SDK usage.
160
160
@@ -180,33 +180,34 @@ For full documentation, please read the respective [iOS](https://github.com/iPro
180
180
181
181
A summary of the support for the various SDK options in Kotlin Multiplatform is provided below. Any options not set will default to their platform-defined default value.
@@ -261,7 +262,6 @@ All errors from the native SDKs are re-mapped to Kotlin Multiplatform exceptions
261
262
|`ListenerNotRegisteredException`|| ✅ | The SDK was launched before a listener was registered. |
262
263
|`MultiWindowUnsupportedException`|| ✅ | The user attempted to iProov in split-screen/multi-screen mode, which is not supported. |
263
264
|`CameraException`|| ✅ | An error occurred acquiring or using the camera. This could happen when a non-phone is used with/without an external/USB camera. |
264
-
|`FaceDetectorException`|| ✅ | An error occurred with the face detector. |
265
265
|`InvalidOptionsException`|| ✅ | An error occurred when trying to apply your options.|
266
266
|`UserTimeoutException`|✅ || The user has taken too long to complete the claim.|
267
267
@@ -331,6 +331,12 @@ In the example app folder, check the `Credentials.kt` file and add your credenti
331
331
332
332
> NOTE: iProov is not supported on the iOS or Android simulator, you must use a physical device in order to iProov.
333
333
334
+
### UIStates (optional)
335
+
336
+
Additionally, for those wanting to monitor the user experience, there are also UIStates, which indicate when the Session's UI starts and stops.
337
+
338
+
Similarly, the Session provides a `val uiState: StateFlow<IProov.UIState>` to be collected from.
339
+
334
340
## Help & support
335
341
336
342
You may find your question is answered in the documentation of our native SDKs:
0 commit comments