NFC Scan - Integration & Usage Guide

Prerequisites

NOTE

While any ICAO 9303 document could theoretically be scanned, the tutorials in the module assume the document is a Passport booklet.

Integration

In your module-level app/build.gradle, add the Incode library for NFC alongside any required dependencies. See the Library Dependencies section for more info.

Usage

To add the NfcScan module to the flow, simply:

1) Create a new NfcScan module with its Builder class:

Kotlin

val nfcScan = NfcScan.Builder()
  .setShowNfcSymbolConfirmationScreen(true/false)
  .setProcessNfcData(true/false)
  .build()
NfcScan nfcScan = new NfcScan.Builder()
  .setShowNfcSymbolConfirmationScreen(true/false)
  .setProcessNfcData(true/false)
  .build();

2) Add it to a FlowConfig.Builder:

Kotlin

flowConfigBuilder.addNfcScan(nfcScan)
flowConfigBuilder.addNfcScan(nfcScan);

3) Add this callback to your IncodeWelcome.OnboardingListener:

Kotlin

override fun onNfcScanCompleted(nfcScanResult: NfcScanResult) {
  // NFC scan completed. Process result.
}
@Override
public void onNfcScanCompleted(@NonNull NfcScanResult nfcScanResult) {
  // NFC scan completed. Process result.
}

Methods for NfcScan.Builder():

Returning result of the module is an NfcScanResult object which contains:

Face Match and NFC Scanning:

If NfcScan.Builder().setProcessNfcData() is set to true, the data read from the NFC chip will be processed on the backend and can be used in the FaceMatch module. Moreover, when NFC data is available on the backend, 2 new FaceMatch.MatchTypes become available on top of the default ID_SELFIE type:

Capturing Multiple IDs and NFC Scanning:

If your Flow includes capturing multiple IDs before an NFC scan is initiated, the nfc module is only supported for the first ID.

Displaying the NFC Bottom Sheet on a Transparent Background

To show the NFC scanning bottom sheet on a transparent background (so your screen remains visible during the scan), use the following configuration:

Java

NfcScan nfcScan = new NfcScan.Builder()
    .setShowTutorials(false)
    .setShowNfcSymbolConfirmationScreen(false)
    .setIdType(IdScan.IdType.PASSPORT) // or ID
    .setShowInitialDataConfirmationScreen(false)
    // ... other builder options as needed
    .build();

Kotlin

val nfcScan = NfcScan.Builder()
    .setShowTutorials(false)
    .setShowNfcSymbolConfirmationScreen(false)
    .setIdType(IdScan.IdType.PASSPORT) // or ID
    .setShowInitialDataConfirmationScreen(false)
    // ... other builder options as needed
    .build()

License

Copyright 2026 Incode Technologies. All rights reserved.