IDV Module

The IDV Module provides an all-in-one solution for implementing OCR and Biometrics in your application’s onboarding flow. It seamlessly integrates with vendor SDKs and automatically handles all necessary API calls between FrankieOne and vendor systems.

You may need to adjust your Content Security Policy (CSP) settings to allow the IDV module to function correctly. Refer to this page for more details.

Vendor Implementations

1

Country Selection

Users select their country of origin

2

Document Selection

Users choose their identification document type

3

Document Upload

Users capture or upload their chosen document

4

Biometrics Process

System prepares for biometric capture

5

Biometric Capture

Users complete their biometric verification

Onfido provides a complete in-browser verification experience without requiring device switching.

Event System

The IDV module uses an event-driven architecture to communicate state changes and results.

ready

Emitted when IDV is successfully mounted

1idv.on('ready', () => {
2 console.log('IDV component is ready');
3});
detection_complete

Signals successful information detection

1idv.on('detection_complete', () => {
2 setMounted(false); // Clean up
3});
1idv.on('results', (checkStatus, document, entityId) => {
2 switch(checkStatus) {
3 case 'COMPLETE':
4 // Handle successful verification
5 break;
6 case 'FAILED':
7 // Handle failed verification
8 break;
9 }
10});

The results event provides comprehensive verification outcomes, including document data and entity references.

1interface InputRequiredEvent {
2 information: {
3 entityId: string
4 },
5 checkStatus:
6 | 'AWAITING_DOCUMENT_UPLOAD_INVALID_TYPE'
7 | 'WAITING_DOC_UPLOAD'
8 | 'WAITING_SELFIE_UPLOAD'
9 | 'INCOMPLETE'
10 | 'INTERRUPTED'
11}
12
13idv.on('input_required', (information, checkStatus) => {
14 switch(checkStatus) {
15 case 'WAITING_SELFIE_UPLOAD':
16 console.log("Awaiting selfie capture");
17 break;
18 case 'WAITING_DOC_UPLOAD':
19 console.log("Awaiting document upload");
20 break;
21 // Handle other states...
22 }
23});

For Incode integrations, the ‘INTERRUPTED’ status typically indicates missing camera permissions.

1interface ErrorEvent {
2 message: string;
3 payload: object;
4}
5
6idv.on('error', (error) => {
7 console.error(`Error: ${error.message}`, error.payload);
8 // Implement your error handling logic
9});

For Incode integrations, refer to the Incode documentation for detailed error payload information.

Implementation Tips
  1. Always test the flow on both desktop and mobile devices
  2. Implement proper cleanup on component unmount
  3. Consider implementing retry logic for failed verifications
  4. Store the entityId for future reference
Was this page helpful?
Built with