You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To add NFC support to a document stage for some document types you need to add the following to your settings object:
466
+
467
+
With the ComplyCube SDK, you can read NFC-enabled identity documents and confirm their authenticity and identity.
468
+
469
+
To perform an NFC read, you'll first have to scan the document to obtain the necessary key for accessing the chip.
470
+
471
+
> :information_source: Please get in touch with your **Account Manger** or **[support](https://support.complycube.com/hc/en-gb/requests/new)** to get access to our NFC Enabled Mobile SDK.
472
+
473
+
The SDK supports the following features
474
+
475
+
- Basic access control
476
+
- Secure messaging
477
+
- Passive Authentication
478
+
- Active authentication
479
+
- Chip authentication
480
+
481
+
##### Pre-requisites (iOS)
482
+
483
+
> :information_source: To use this feature, your app must have the `Near Field Communication Tag Reading` capability enabled. To add this capability to your app, refer to [Apple's guide here](https://help.apple.com/xcode/mac/current/#/dev88ff319e7).
484
+
485
+
- You must add the following keys to your application `Info.plist` file:
486
+
487
+
```xml
488
+
<key>NFCReaderUsageDescription</key>
489
+
<string>Required to read from NFC enabled documents</string>
490
+
```
491
+
492
+
- To read NFC tags correctly, you need to add the following entries to your app target's `Info.plist` file:
|```ComplyCubeErrorCode.NotAuthorized```| The SDK has attempted a request to an endpoint you are not authorized to use.|
673
+
|```ComplyCubeErrorCode.ExpiredToken```| The token used to initialize the SDK has expired. Create a new SDK token and restart the flow. |
674
+
|```ComplyCubeErrorCode.DocumentMandatory```| A **Document stage** is mandatory with the currently configured stages. |
675
+
|```ComplyCubeErrorCode.JailBroken```| The SDK cannot be launched on this device as it has been compromised. |
676
+
|```ComplyCubeErrorCode.NoDocumentTypes```| A **Document stage** has been initialized without setting document types. |
677
+
|```ComplyCubeErrorCode.BiometricStageCount```| The configuration provided contains duplicate **Selfie photo** or **Selfie video** stages. |
678
+
|```ComplyCubeErrorCode.UploadError```| An error occurred during the upload document or selfie upload process. |
679
+
|```ComplyCubeErrorCode.InvalidCountryCode```| An invalid country code is provided. |
680
+
|```ComplyCubeErrorCode.UnsupportedCountryTypeCombination```| An unsupported country code is provided for a specific document type. |
681
+
|```ComplyCubeErrorCode.Unknown```| An unexpected error has occurred. If this keeps occurring, let us know about it. |
682
+
|```ComplyCubeErrorCode.FlowError```| An unrecoverable error occurred during the flow.|
683
+
684
+
## 8. Custom Event handling
685
+
686
+
687
+
Custom event handler
688
+
689
+
If you want to implement your own user tracking, the SDK enables you to insert your custom tracking code for the tracked events.
690
+
691
+
To incorporate your own tracking, define a function and apply it using withEventHandler when initializing the FlowBuilder:
692
+
693
+
```dart
694
+
// onCustomEvent with event that contains event name
695
+
void onCustomEvent(ComplyCubeCustomEvent event){
696
+
switch(event.name){
697
+
case 'BIOMETRICS_STAGE_SELFIE_CAMERA':
698
+
print("The client reached capture camera for a selfie")
699
+
break;
700
+
}
701
+
}
702
+
703
+
704
+
ComplyCubeWidget(
705
+
settings: settings,
706
+
...
707
+
onCustomEvent: onCustomEvent,
708
+
...
709
+
),
710
+
711
+
```
712
+
713
+
714
+
### Handled Events
715
+
Below is the list of events being tracked by the SDK:
716
+
717
+
| Event | Description |
718
+
| --- | --- |
719
+
|```BIOMETRICS_STAGE_SELFIE_CAMERA```| The client reached capture camera for a selfie. |
720
+
|```BIOMETRICS_STAGE_SELFIE_CAMERA_MANUAL_MODE```| The client reached manual capture camera for a selfie. |
721
+
|```BIOMETRICS_STAGE_SELFIE_CAPTURE_GUIDANCE```| The client has reached the guidance screen showing how to take a good selfie. |
722
+
|```BIOMETRICS_STAGE_SELFIE_CHECK_QUALITY```| The client has reached the photo review screen after capturing a selfie photo.. |
723
+
|```BIOMETRICS_STAGE_VIDEO_ACTION_ONE```| The client reached the first action in a video selfie |
724
+
|```BIOMETRICS_STAGE_VIDEO_ACTION_TWO```| The client reached the second action in a video selfie. |
725
+
|```BIOMETRICS_STAGE_VIDEO_CAMERA```| The client reached capture camera for a video selfie. |
726
+
|```BIOMETRICS_STAGE_VIDEO_CAMERA_MANUAL_MODE```| The client reached manual capture camera for a video selfie. |
727
+
|```BIOMETRICS_STAGE_VIDEO_CHECK_QUALITY```| The client has reached the video review screen after recording a video selfie. |
728
+
|```CAMERA_ACCESS_PERMISSION```| The client has reached the permission request screen for camera permissions. |
729
+
|```COMPLETION_STAGE```| The client has reached the Completion screen. |
730
+
|```CONSENT_STAGE```| The client has reacher the consent stage screen. |
731
+
|```CONSENT_STAGE_WARNING```| The client has attempted to exit without giving consent and receive a confirmation prompt. |
732
+
|```DOCUMENT_STAGE_TWO_SIDE_CHECK_QUALITY_BACK```| The client reached quality preview screen for the back side of a two-sided ID document. |
733
+
|```DOCUMENT_STAGE_TWO_SIDE_CHECK_QUALITY_FRONT```| The client reached quality preview screen for the front side of a two-sided ID document. |
734
+
|```DOCUMENT_STAGE_ONE_SIDE_CHECK_QUALITY```| The client reached image quality preview screen for one-sided ID document. |
735
+
|```DOCUMENT_STAGE_TWO_SIDE_CAMERA_BACK```| The client reached camera for the back side of a two-sided ID document. |
736
+
|```DOCUMENT_STAGE_TWO_SIDE_CAMERA_BACK_MANUAL_MODE```| The client reached manual capture camera for the back side of two-sided ID document. |
737
+
|```DOCUMENT_STAGE_TWO_SIDE_CAMERA_FRONT```| The client reached camera stage for the front side of two-sided ID document. |
738
+
|```DOCUMENT_STAGE_TWO_SIDE_CAMERA_FRONT_MANUAL_MODE```| The client reached manual capture camera for the back side of two-sided ID document. |
739
+
|```DOCUMENT_STAGE_ONE_SIDE_CAMERA_MANUAL_MODE```| The client reached manual capture camera of one-sided ID document. |
740
+
|```DOCUMENT_STAGE_ONE_SIDE_CAMERA```| The client reached the capture camera stage for a one-sided ID document. |
741
+
|```DOCUMENT_STAGE_DOCUMENT_TYPE```| The client has reached the document type selection screen for an ID Document capture stage. |
742
+
|```DOCUMENT_STAGE_SELECT_COUNTRY```| The client reached country selection screen for ID document. |
743
+
|```DOCUMENT_STAGE_CAPTURE_GUIDANCE```| The client reached capture guidance screen for ID document. |
744
+
|```INTRO```| The client has reached the intro screen. |
745
+
|```PROOF_OF_ADDRESS_STAGE_TWO_SIDE_CHECK_QUALITY_FRONT```| The client reached quality preview screen for the front side of a two-sided proof of address document. |
746
+
|```PROOF_OF_ADDRESS_STAGE_CAPTURE_GUIDANCE```| The client has reach capture guidance screen for proof of address document. |
747
+
|```PROOF_OF_ADDRESS_STAGE_TWO_SIDE_CHECK_QUALITY_BACK```| The client reached quality preview screen for the back side of a two-sided proof of address document. |
748
+
|```PROOF_OF_ADDRESS_STAGE_ONE_SIDE_CHECK_QUALITY```| The client reached quality preview screen for a one-sided proof of address document. |
749
+
|```PROOF_OF_ADDRESS_STAGE_DOCUMENT_TYPE```| The client has reached the document type selection screen for a Proof Of Address capture stage. |
750
+
|```PROOF_OF_ADDRESS_STAGE_ONE_SIDE_CAMERA```| The client reached capture camera stage for a one-sided proof of address. |
751
+
|```PROOF_OF_ADDRESS_STAGE_TWO_SIDE_CAMERA_FRONT_MANUAL_MODE```| The client reached manual capture camera for the front side of a two-sided proof address document. |
752
+
|```PROOF_OF_ADDRESS_STAGE_TWO_SIDE_CAMERA_FRONT```| The client reached capture camera for the front side of a two-sided proof address document. |
753
+
|```PROOF_OF_ADDRESS_STAGE_TWO_SIDE_CAMERA_BACK_MANUAL_MODE```| The client reached manual capture camera for the back side of a two-sided proof address document. |
754
+
|```PROOF_OF_ADDRESS_STAGE_ONE_SIDE_CAMERA_MANUAL_MODE```| The client reached manual capture camera for the front side of a one-sided proof address document. |
755
+
|```PROOF_OF_ADDRESS_STAGE_SELECT_COUNTRY```| The client reached country selection screen for a proof of address document. |
756
+
|```PROOF_OF_ADDRESS_STAGE_TWO_SIDE_CAMERA_BACK```| The client reached camera for the back side of a two-sided proof address document. |
757
+
758
+
759
+
## 9. Token expiry handler
760
+
761
+
If you want to automatically manage token expiration, you can use a callback function to generate a new token and seamlessly continue the process with it.
0 commit comments