# BiometricPrompt.AuthenticationResult

Artifact: [androidx.biometric:biometric](https://developer.android.com/jetpack/androidx/releases/biometric) [View Source](https://cs.android.com/search?q=file:androidx/biometric/BiometricPrompt.java+class:androidx.biometric.BiometricPrompt.AuthenticationResult) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/biometric#1.0.0)

*** ** * ** ***


```
class BiometricPrompt.AuthenticationResult
```

<br />

*** ** * ** ***

A container for data passed to `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.AuthenticationCallback#onAuthenticationSucceeded(androidx.biometric.BiometricPrompt.AuthenticationResult)` when the user has successfully authenticated.

## Summary

| ### Public functions |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.AuthenticationResult#getAuthenticationType()()` Gets the type of authentication (e.g. device credential or biometric) that was requested from and successfully provided by the user. |
| `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.CryptoObject?` | `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.AuthenticationResult#getCryptoObject()()` Gets the `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.CryptoObject` associated with this transaction. |

## Public functions

### getAuthenticationType

Added in [1.1.0](https://developer.android.com/jetpack/androidx/releases/biometric#1.1.0)

```
fun getAuthenticationType(): Int
```

Gets the type of authentication (e.g. device credential or biometric) that was requested from and successfully provided by the user.

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | An integer representing the type of authentication that was used. |

| See also |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricConstants#AUTHENTICATION_RESULT_TYPE_UNKNOWN()` |   |
| `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricConstants#AUTHENTICATION_RESULT_TYPE_DEVICE_CREDENTIAL()` |   |
| `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricConstants#AUTHENTICATION_RESULT_TYPE_BIOMETRIC()` |   |

### getCryptoObject

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/biometric#1.0.0)

```
fun getCryptoObject(): BiometricPrompt.CryptoObject?
```

Gets the `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.CryptoObject` associated with this transaction.

| Returns |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.CryptoObject?` | The `https://developer.android.com/reference/kotlin/androidx/biometric/BiometricPrompt.CryptoObject` provided to `authenticate()`. |