SDK reference, React Native SDK

Modules

A module is a self-contained step in an onboarding flow. Add modules to flowConfig for locally configured flows, or configure them in a Flow or Workflow on the Incode Dashboard for online-configured flows.

All the modules supported by the SDK are listed here, with their configuration parameters. For implementation options and instructions, see Common Implementation Patterns.

Every entry in flowConfig includes:

  • module (required): string. The module name.
  • enabled (optional, defaults to true): boolean. Explicitly include or skip the module in the flow.

For completion payloads, update events, and module error examples, see Results.

If the native SDK cannot add a Phone, Email, FullName, CurpValidation, Geolocation, or VideoSelfie module from its configuration, the SDK logs Module <name> was not added: <reason> and omits that module. The flow still starts and resolves without the module; the start method does not reject. Check the device log if one of these modules does not show.

Phone

Ask the user to enter a phone number.

  • otpVerification (optional): boolean. Ask for OTP verification. When omitted, the native SDK setting applies (false unless configured otherwise).
  • defaultRegionPrefix (optional): number. Dialing-code override, 1–9999, without a leading +. Values outside that range are ignored and the device's own region prefix is used.

DocumentScan

Ask the user to capture a document.

  • showTutorial (optional, defaults to false): boolean. Show the document scan tutorial. Only on iOS.
  • showDocumentProviderScreen (optional, defaults to true): boolean. Specify true to show the document provider screen. Specify false to go directly to capture. This parameter is deprecated. Use documentSources instead. false is equivalent to documentSources: ['camera']. true preserves the behavior from before: every source on Android, the SDK default for the document type on iOS. When both are set, documentSources wins.
  • documentSources (optional, defaults to every source the document type supports): array of camera, photoUpload, or fileUpload. Restricts the submission methods offered on the source chooser: for example, ['camera'] to go straight to capture or ['photoUpload', 'fileUpload'] to make the step upload-only. fileUpload (PDF) is only meaningful for document types that support PDFs; on iOS, it is dropped at runtime for types that don't support PDFs (for example, medicalDoc). Always keep another source in the list for those types. In V1, applies only if showDocumentProviderOptions = true. In V2, always used to determine the available sources.
  • type (optional, defaults to addressStatement): addressStatement, paymentProof, medicalDoc, otherDocument1, otherDocument2, or otherDocument3.

Geolocation

Get information about the user's current location.

  • isSkippable (optional, defaults to false): boolean. Allows the geolocation step to be skipped. When set to true, skipping or denying location permission advances the flow instead of ending the session with a permission error. The skipped step is still reported through onStepCompleted, with status: 'fail'. Only a boolean is accepted; any other value is ignored and the default applies.

UserConsent

Ask the user for consent.

  • title (required): string. Title shown on the consent screen.
  • content (required): string. Content shown on the consent screen.

CombinedConsent

Ask the user for data-sharing consent.

  • consentId (required): string. ID for the combined consent configured in the dashboard.

Signature

Ask the user to draw a signature.

  • title (optional): string. Optional title shown at the top of the screen.
  • description (optional): string. Optional description shown below the title.
  • descriptionMaxLines (optional): number. Maximum number of description text lines.

This module enables user to add a digital signature by signing on a canvas.

Besides specifying title and description keys, you must provide text for Android and iOS in their res/values/strings.xml and Localizable.strings files.

{
  module: 'Signature',
  title: 'onboard_sdk_signature_title',
  description: 'onboard_sdk_signature_description',
  descriptionMaxLines: 2
}

For Android:

<string name="onboard_sdk_signature_title">Example title</string>
<string name="onboard_sdk_signature_description">Description example</string>

If your account has the Signature V2 experience enabled, override the dedicated V2 resources as well. V1 keeps using the resources above.

<string name="onboard_sdk_signature_capture_title">Example title</string>
<string name="onboard_sdk_signature_capture_description">Description example</string>

For iOS:

"onboard_sdk_signature_title" = "Example title";
"onboard_sdk_signature_description" = "Description example";

VideoSelfie

Record a video of the user while they repeat the earlier capture steps: selfie, ID, random questions, and voice consent. The SDK then uploads the video. Every parameter is optional. When you omit a parameter, the native SDK default applies.

A boolean parameter with a value that is not a boolean, such as "true" or 1, is ignored, and the default applies. A number parameter with a value that is not a positive integer is ignored too.

Steps:

  • showTutorials (optional, defaults to true): boolean. Show the tutorials.
  • selfieScanEnabled (optional, defaults to true): boolean. Record the selfie step.
  • idScanEnabled (optional, defaults to true): boolean. Record the ID step.
  • showSelfieStepFirst (optional, defaults to false): boolean. Show the selfie step before the ID step.
  • handGestureEnabled (optional, defaults to false): boolean. Ask the user for a hand gesture.
  • randomQuestionsEnabled (optional, defaults to false): boolean. Ask random questions.
  • voiceConsentEnabled (optional, defaults to false): boolean. Ask for voice consent. Voice consent and random questions are independent. One parameter does not enable the other.

Selfie step:

  • selfieMode (optional, defaults to selfieMatch): selfieMatch or faceMatch. Compare the selfie with the earlier selfie (selfieMatch) or with the photo on the ID (faceMatch). With any other value, the SDK logs the error and leaves Video Selfie out of the flow.
  • performLivenessCheck (optional, defaults to false): boolean. Check liveness.
  • performHeadMovementCheck (optional, defaults to false): boolean. Ask for head movement. Needs the selfie step.
  • lensesCheck, faceMaskCheck, closedEyesCheck, headCoverCheck (optional, each defaults to true): boolean. Check for lenses, a face mask, closed eyes, and a head cover.

ID step:

  • compareIdEnabled, compareOcrEnabled (optional, each defaults to true): boolean. Compare the front of the ID, and its OCR data, with the earlier ID capture.
  • compareBackIdEnabled, compareBackOcrEnabled (optional, each defaults to true): boolean. Compare the back of the ID, and its OCR data, with the earlier ID capture.
  • validateId (optional, defaults to true): boolean. iOS only. With false, the SDK keeps the ID on the device and does not check it on the server. Android ignores it.
  • idBackShownAsFrontCheck, idFrontShownAsBackCheck (optional, each defaults to false): boolean. Android only. Check that the user does not show the back of the ID as the front, or the front as the back. iOS ignores them.

Questions and voice consent:

  • randomQuestionsCount (optional, defaults to 3): positive integer. Number of random questions.
  • questions (optional): VideoSelfieQuestion[]. List of { question: string; answer: string } entries for the capture-only mode. The SDK skips an entry without both a question and an answer string. On iOS, the order is not kept, and a repeated question keeps its last answer.
  • consent (optional): string. Consent text for the capture-only mode.
  • voiceConsentFaceRecognition (optional, defaults to false): boolean. Check the face during voice consent.
  • disableAudio (optional, defaults to false): boolean. Record without audio. This skips the random questions and voice consent.

Video:

  • maxVideoLength (optional, defaults to 300): positive integer. Maximum video length, in seconds.
  • minVideoLengthRequired (optional, defaults to true): boolean. Require a minimum video length.
  • logo (optional): string. Name of a native image resource of your app, shown as the logo on the VideoSelfie screens. On Android, it is a drawable resource name (res/drawable/<name>). Add the drawable to res/raw/keep.xml, or the Android shrinker removes it from release builds and the SDK default logo shows instead. See the keep.xml example. On iOS, it is an image asset name from your asset catalog or main bundle. Use the same name on both platforms for consistency. When omitted, or when the name cannot be resolved, the SDK default logo is used.

The result is in Results.

Note

Changed in 9.20.0. Most parameters have new names, and cameraFacingConfig and showDocumentScan are removed. See the migration guide.

On Android, when the Video Selfie v2 experience is enabled for your account, the camera steps hide the close (X) button, so IncodeSdk.showCloseButton(true) does not apply to them. The button still shows on the other screens, and Video Selfie v1 keeps it over the camera.

IdScan

Ask the user to capture ID or passport.

  • showTutorial (optional, defaults to true): boolean. Show the ID scan tutorial.
  • idType (optional): id or passport. Preselects the document type. It doesn't hide the document chooser: set showIdTypeChooser: false for that.
  • showIdTypeChooser (optional, defaults to true): boolean. Specify false to skip the document chooser screen.
  • idCategory (optional, defaults to primary): primary or secondary.
  • showRetakeScreenForManualCapture (optional, defaults to true): boolean. Show the photo review screen for manual captures.
  • showRetakeScreenForAutoCapture (optional, defaults to false): boolean. Show the photo review screen after auto capture.
  • enableFrontShownAsBackCheck (optional, defaults to false): boolean. Show real-time feedback when the front side is shown during back capture.
  • enableBackShownAsFrontCheck (optional, defaults to false): boolean. Show real-time feedback when the back side is shown during front capture.
  • autocaptureUxMode (deprecated, optional, defaults to holdStill): countdown or holdStill. This parameter applies only to V1.
  • showIDOverlay (optional, defaults to false): boolean. Show the ID overlay during capture.
  • streamFrames (optional, defaults to false): boolean. Enables camera frame streaming. Requires the RN SDK -vc variant and the Android com.incode.sdk:video-streaming dependency.

IdScanFront

Ask the user to capture only the front side of an ID.

  • showTutorial (optional, defaults to true): boolean. Show the ID scan tutorial.
  • idType (optional): id or passport. Preselects the document type. It doesn't hide the document chooser: set showIdTypeChooser: false for that.
  • showIdTypeChooser (optional, defaults to true): boolean. Specify false to skip the document chooser screen.
  • idCategory (optional, defaults to primary): primary or secondary.
  • showRetakeScreenForManualCapture (optional, defaults to true): boolean. Show the photo review screen for manual captures.
  • showRetakeScreenForAutoCapture (optional, defaults to false): boolean. Show the photo review screen after auto capture.
  • enableFrontShownAsBackCheck (optional, defaults to false): boolean. Show real-time feedback when the front side is shown during back capture.
  • enableBackShownAsFrontCheck (optional, defaults to false): boolean. Show real-time feedback when the back side is shown during front capture.
  • autocaptureUxMode (deprecated, optional, defaults to holdStill): countdown or holdStill. This parameter applies only to V1.
  • showIDOverlay (optional, defaults to false): boolean. Show the ID overlay during capture.
  • streamFrames (optional, defaults to false): boolean. Enables camera frame streaming. Requires the RN SDK -vc variant and the Android com.incode.sdk:video-streaming dependency.

IdScanBack

Ask the user to capture only the back side of an ID.

  • showTutorial (optional, defaults to true): boolean. Show the ID scan tutorial.
  • idCategory (optional, defaults to primary): primary or secondary.
  • showRetakeScreenForManualCapture (optional, defaults to true): boolean. Show the photo review screen for manual captures.
  • showRetakeScreenForAutoCapture (optional, defaults to false): boolean. Show the photo review screen after auto capture.
  • enableFrontShownAsBackCheck (optional, defaults to false): boolean. Show real-time feedback when the front side is shown during back capture.
  • enableBackShownAsFrontCheck (optional, defaults to false): boolean. Show real-time feedback when the back side is shown during front capture.
  • autocaptureUxMode (deprecated, optional, defaults to holdStill): countdown or holdStill. This parameter applies only to V1.
  • showIDOverlay (optional, defaults to false): boolean. Show the ID overlay during capture.
  • streamFrames (optional, defaults to false): boolean. Enables camera frame streaming. Requires the RN SDK -vc variant and the Android com.incode.sdk:video-streaming dependency.

ProcessId

Process the ID after separated front and back captures.

  • idCategory (optional, defaults to primary): primary or secondary. Applied on Android.
  • enableIdSummaryScreen (deprecated, optional, defaults to true): boolean. This parameter applies only to V1.

Conference

Start a video conference call.

  • disableMicOnStart: boolean. Disable the microphone when the call starts. Always pass this explicitly - the Android native module reads it without a default and can throw if it's omitted. On iOS, this flag is not currently wired up.

SelfieScan

Ask the user to capture a selfie.

  • showTutorial (optional, defaults to true): boolean. Show the selfie scan tutorial.
  • lensesCheck (optional, defaults to true): boolean. Check if the user is wearing glasses.
  • cameraFacing (optional, defaults to front): front or back. Camera used during selfie capture.
  • faceMaskCheck (optional, defaults to true): boolean. Check if the user is wearing a face mask.
  • brightnessThreshold (deprecated, optional): number. Kept in the TypeScript config for compatibility; not read by the current Android or iOS native SDK.
  • streamFrames (optional, defaults to false): boolean. Enables camera frame streaming. Requires the RN SDK -vc variant and the Android com.incode.sdk:video-streaming dependency.
  • logo (optional): string. Name of a native image resource of your app, shown as the logo on the selfie capture screen. On Android, it is a drawable resource name (res/drawable/<name>) Add the drawable to res/raw/keep.xml, or the Android shrinker removes it from release builds and the SDK default logo shows instead. See the keep.xml example. On iOS, it is an image asset name from your asset catalog or main bundle. Use the same name on both platforms for consistency. When omitted, or when the name cannot be resolved, the SDK default logo is used.

FaceMatch

Perform a face match between the captured ID/passport and Selfie or NFC data.

  • idCategory (optional, defaults to primary): primary or secondary.
  • matchType (optional): idSelfie, nfcSelfie, or nfc3Way.
  • showUserExists (optional, defaults to false on Android since the UxV2 migration): boolean. Show whether the user already exists.

QrScan

Ask the user to scan a QR code.

  • No additional parameters

Captcha

Ask the user to enter the OTP generated for the current session.

  • No additional parameters

Email

Ask the user to enter an email.

  • otpVerification (optional): boolean. Ask for OTP verification. When omitted, the native SDK setting applies (false unless configured otherwise).

Approve

Approve the current onboarding session and add the user to the Omni database.

  • forceApproval (optional, defaults to false): boolean. Force approval when set to true.

UserScore

Show the info and scoring for all performed steps.

  • mode (optional, defaults to accurate): accurate or fast. accurate fetches server-side results and can take longer; fast shows results based on on-device processing.

MLConsent

Ask the user for Machine Learning consent.

  • type (required): gdpr or us.

GovernmentValidation

Perform government validation of the ID.

  • isBackgroundExecuted (optional, defaults to false): boolean. Run the module without showing its UI.

Antifraud

Compare the current interview with existing interviews and customers to detect possible fraud.

  • No additional parameters

GlobalWatchlist

Check customer identities against sanctions, PEP, and watchlist sources.

  • No additional parameters

CustomWatchlist

Check whether the user is present in an Incode Dashboard custom watchlist.

  • No additional parameters

Aes

Enable advanced electronic signature document handling.

  • uploadDocument (optional, defaults to false): boolean. Upload the signed document.
  • downloadDocument (optional, defaults to false): boolean. Download the signed document.

FullName

Ask the user to enter a name.

  • No additional parameters

Info

Renamed from Name in 9.18.0. The completion event uses FullName too — see Results.

CurpValidation

Validate the user's CURP against RENAPO, or generate it from the user's personal data. Mexico only.

  • validationEnabled (optional, defaults to true): boolean. Validate the CURP on the server. With false, the module only captures a CURP in a valid format. Workflows always validate.

The result is in Results.

Note

This module was renamed from CURP in 9.19.0. The completion event uses CurpValidation as well.

OCREdit

Review OCR data.

  • isEditable (optional, defaults to false): boolean. Allow the user to edit OCR data.

eKYB

Run KYB validation with business information.

  • checkBusinessName (optional, defaults to false): boolean. Validate business name.
  • checkAddress (optional, defaults to false): boolean. Validate address.
  • checkTaxId (optional, defaults to false): boolean. Validate tax ID.

eKYC

Run KYC validation with user information.

  • checkName (optional, defaults to false): boolean. Validate name.
  • checkEmail (optional, defaults to false): boolean. Validate email.
  • checkAddress (optional, defaults to false): boolean. Validate address.
  • checkPhone (optional, defaults to false): boolean. Validate phone.
  • checkSsn (optional, defaults to false): boolean. Validate SSN.
  • checkDob (optional, defaults to false): boolean. Validate date of birth.
  • checkNationality (optional, defaults to false): boolean. Validate nationality.

NFCScan

Ask the user to scan the NFC chip on their document.

  • idType (optional): id or passport. ID type used for NFC scanning. If omitted, the SDK reuses the ID type from IdScan when available; otherwise, it can show a chooser.
  • showNFCSymbolConfirmationScreen (optional, defaults to true): boolean. Show a screen asking whether the document contains an NFC chip. iOS only; it has no effect on Android, where the SDK no longer shows this screen.
  • showInitialDataConfirmationScreen (optional, defaults to true): boolean. Show the document OCR data confirmation screen before the first NFC scan.
  • processNFCData (optional, defaults to true): boolean. Use data read from the NFC chip to validate identity.

On iOS, when NFC smart gating is enabled for your organization, the module uses the back end's assessment of the ID's chip. It is skipped for IDs with no chip, or with a chip from an issuer that cannot be verified. To always run the module, enable the matching setting in Dashboard's NFC Scan module.

Please check special NFC integration instructions for iOS that need to be applied on app level.

FaceAuthentication

Authenticate an existing user with face recognition.

  • showTutorials (optional, defaults to true): boolean. Show the tutorial before face authentication.
  • autoCaptureTimeout (optional, defaults to 16): number. Timeout in seconds for automatic face capture.
  • captureAttempts (optional, defaults to 3): number. Number of allowed face capture attempts before failing the step.
  • eyesClosedCheck (optional, defaults to true): boolean. Check whether the user's eyes are closed.
  • headCoverCheck (optional, defaults to true): boolean. Check for head coverings that may obstruct face recognition.
  • lensesCheck (optional, defaults to true): boolean. Check whether the user is wearing lenses or glasses.
  • faceMaskCheck (optional, defaults to true): boolean. Check whether the user is wearing a face mask.

To show your logo on the Face Authentication screens, call setLogo before you start the flow.

Modules interdependencies

The order of modules in flowConfig is the execution order.

  • ProcessId expects IdScanFront and IdScanBack to run before it.
  • FaceMatch expects IdScan and SelfieScan to run before it.
  • VideoSelfie expects IdScan with selfieMode: 'faceMatch', or SelfieScan with selfieMode: 'selfieMatch' (the default).
  • Aes expects Phone, IdScan, and SelfieScan to run before it.
  • UserScore should run after all modules that provide scoring inputs.
  • Approve should run after all modules required for the approval decision.
  • UserScore and Approve do not depend on each other, so their relative order can be chosen by the app.

Was this page helpful?