> For the complete documentation index, see [llms.txt](https://docs.facephi.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.facephi.com/docs.facephi-en/products/idv-suite/flujos-and-integraciones/configuracion-tecnica-del-cliente/sdk-mobile/android-sdk/componentes-modulos/captura-facial.md).

# Face Capture

## Introduction <a href="#id-1-introduccion" id="id-1-introduccion"></a>

Face Capture is performed through the **Selphi Component**.

This component is responsible for capturing a selfie of the user and extracting its most relevant facial features. During the process, among others, the following steps are carried out:

* Internal management of cameras and permissions.
* Guided assistance during Face Capture.
* Generation of biometric templates and user images.

***

## Dependency <a href="#id-2-dependencia" id="id-2-dependencia"></a>

The specific dependency for the component is:

```kotlin
implementation "com.facephi.androidsdk:selphi_component:$version"
```

***

## Available controllers

This component includes several controllers, each focused on a specific functionality.

| Controller          | Description                        |
| ------------------- | ---------------------------------- |
| `FSelphiController` | Main Facial Recognition controller |

***

## Receipt of Face Capture errors <a href="#id-6-recepcion-del-resultado" id="id-6-recepcion-del-resultado"></a>

Errors will be returned as a 'SelphiError' object.

<details>

<summary>List of Face Capture errors:</summary>

* SPI\_ACTIVITY\_RESULT\_ERROR: The activity result is incorrect.
* SPI\_ACTIVITY\_RESULT\_MSG\_ERROR: The activity result received in msg is incorrect.
* SPI\_APPLICATION\_CONTEXT\_ERROR: The required application context is null.
* SPI\_BAD\_EXTRACTOR\_CONFIGURATION\_ERROR: Widget: Incorrect extractor configuration.
* SPI\_CAMERA\_PERMISSION\_DENIED: The user has denied permissions.
* SPI\_CANCEL\_BY\_USER: The user has canceled the process.
* SPI\_CANCEL\_LAUNCH: A general cancellation of the SDK has been performed.
* SPI\_COMPONENT\_LICENSE\_ERROR: The component license is not correct.
* SPI\_CONTROL\_NOT\_INITIALIZATED\_ERROR: Widget: Initialization error.
* SPI\_EMPTY\_LICENSE: The license String is empty.
* SPI\_EXTRACTION\_LICENSE\_ERROR: Widget: License error.
* SPI\_FETCH\_DATA\_ERROR: Error collecting the result.
* SPI\_FLOW\_ERROR: Error in the flow process.
* SPI\_HARDWARE\_ERROR: Widget: Hardware error.
* SPI\_INITIALIZATION\_ERROR: Initialization error.
* SPI\_MANAGER\_NOT\_INITIALIZED: The managers are null.
* SPI\_NO\_DATA\_ERROR: The input data are null.
* SPI\_OPERATION\_NOT\_CREATED: There is no operation in progress.
* SPI\_RESOURCES\_NOT\_FOUND: The resources zip was not found.
* SPI\_SETTINGS\_PERMISSION\_ERROR: Widget: Permission error.
* SPI\_TEMPLATE\_ERROR:
* SPI\_TIMEOUT: Timeout in the process.
* SPI\_UNEXPECTED\_CAPTURE\_ERROR: Widget: Capture error.
* SPI\_UNKNOWN\_ERROR: Unknown error.
* SPI\_WIDGET\_RESULT\_DATA\_ERROR: Error in the widget's output data.

</details>
