> 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/sdks/sdk-mobile/framework-plugins/capacitor/componentes/nfc.md).

# NFC Capture

This component reads NFC data from identity documents and passports.

Its main processes are:

* Internal management of the NFC sensor.
* Permission management.
* Document analysis.
* Progress analysis.
* Assistance with the reading processes.
* Returning all information that can be read
* Returning images when they are available to be read

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

### Capacitor:

```bash
npm install @facephi/sdk-nfc-capacitor@<versión>
npm run build
npx cap sync
```

### Android - Gradle:

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

### iOS - CocoaPods:

```swift
s.dependency 'FPHISDKNFCComponent', '~> $version'
```

## startNfc method <a href="#id-4-lanzamiento-simplificado" id="id-4-lanzamiento-simplificado"></a>

Once the SDK has been initialized and a new operation has been created, the component can be launched. Any of its controllers can be used to execute its functionality.

NFC reader launch:

```dart
startNfc(configuration: NfcConfiguration): Promise<NfcResult>;
```

## Basic configuration <a href="#id-5-configuracion-basica" id="id-5-configuracion-basica"></a>

To launch the current component, an object must be created. ***NfcConfiguration*** which will be the component controller configuration.

The basic configuration required is as follows:

```typescript
class NfcConfiguration
{
  docNumber: string;
  birthDate: string;
  expirationDate: string;
  extractionTimeout?: number;
  docType?: NfcDocumentType;
  showTutorial?: boolean;
  vibrationEnabled?: boolean;
  skipPACE?: boolean;
  debug?: boolean;
  showDiagnostic?: boolean;
  showPreviousTip?: boolean;
  extractFacialImage?: boolean;
  extractSignatureImage?: boolean;
}
```

### Advanced component configuration

All the fields that make up this class are detailed below.

{% content-ref url="/pages/da633eac0bce920270e2a99ecb8badeec0a2a580" %}
[Nfc Configuration](https://docs.facephi.com/docs.facephi-en/sdks/sdk-mobile/framework-plugins/extras/nfc/nfc-configuracion.md)
{% endcontent-ref %}

## Receiving the result <a href="#id-6-recepcion-del-resultado" id="id-6-recepcion-del-resultado"></a>

Launching it will return the information in ***NfcResult***. Differentiating between a successful and an unsuccessful launch:

```typescript
class NfcResult
{
  finishStatus: number;
  finishStatusDescription?: string;
  errorType: string;
  errorMessage?: string;
  nfcDocumentInformation?: any;
  nfcPersonalInformation?: any;
  nfcValidations?: any;
  facialImage?: string;
  fingerprintImage?: string;
  signatureImage?: string;
}
```

All the fields that make up this class are detailed below.

{% content-ref url="/pages/55ad7f803484789c3b0990695802a5b8609b4f38" %}
[Nfc Result](https://docs.facephi.com/docs.facephi-en/sdks/sdk-mobile/framework-plugins/extras/nfc/nfc-resultado.md)
{% endcontent-ref %}
