# 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)

*** ** * ** ***


```
public class BiometricPrompt.AuthenticationResult
```

<br />

*** ** * ** ***

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

## Summary

| ### Public methods |
|---|---|
| `int` | `https://developer.android.com/reference/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://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/biometric/BiometricPrompt.CryptoObject` | `https://developer.android.com/reference/androidx/biometric/BiometricPrompt.AuthenticationResult#getCryptoObject()()` Gets the `https://developer.android.com/reference/androidx/biometric/BiometricPrompt.CryptoObject` associated with this transaction. |

## Public methods

### getAuthenticationType

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

```
public int getAuthenticationType()
```

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

| Returns |
|---|---|
| `int` | An integer representing the type of authentication that was used. |

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

### getCryptoObject

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

```
public @Nullable BiometricPrompt.CryptoObject getCryptoObject()
```

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

| Returns |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/biometric/BiometricPrompt.CryptoObject` | The `https://developer.android.com/reference/androidx/biometric/BiometricPrompt.CryptoObject` provided to `authenticate()`. |