idmission-web-sdk 1.0.73 → 1.0.75
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -0
- package/dist/components/CompositeWizard.d.ts +5 -3
- package/dist/components/customer_flows/CustomerIdAndBiometricsEnrollment.d.ts +2 -0
- package/dist/components/customer_flows/IdAndFaceValidation.d.ts +2 -0
- package/dist/components/customer_flows/IdValidation.d.ts +2 -0
- package/dist/components/customer_flows/VideoIdValidation.d.ts +25 -3
- package/dist/components/submission/SubmissionProvider.d.ts +2 -1
- package/dist/components/video_id/IdVideoCaptureWizard.d.ts +4 -3
- package/dist/contexts/SubmissionContext.d.ts +1 -0
- package/dist/sdk2.cjs.development.js +2662 -2593
- package/dist/sdk2.cjs.development.js.map +1 -1
- package/dist/sdk2.cjs.production.js +1 -1
- package/dist/sdk2.cjs.production.js.map +1 -1
- package/dist/sdk2.esm.js +2662 -2593
- package/dist/sdk2.esm.js.map +1 -1
- package/dist/sdk2.umd.development.js +2662 -2593
- package/dist/sdk2.umd.development.js.map +1 -1
- package/dist/sdk2.umd.production.js +1 -1
- package/dist/sdk2.umd.production.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -103,6 +103,7 @@ Render a fullscreen ID capture component that instructs the user to photograph b
|
|
|
103
103
|
<tr><td><code>webhooksStripSpecialCharacters</code> (optional)</td><td>boolean flag to indicate whether non-alphanumeric characters should be removed from the submission data when customer-configured webhooks are invoked. Defaults to true.</td></tr>
|
|
104
104
|
<tr><td><code>webhooksSendInputImages</code> (optional)</td><td>boolean flag to indicate whether raw user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
105
105
|
<tr><td><code>webhooksSendProcessedImages</code> (optional)</td><td>boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
106
|
+
<tr><td><code>webhooksFireOnReview</code> (optional)</td><td>boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. Defaults to false.</td></tr>
|
|
106
107
|
<tr><td><code>assets</code> (optional)</td><td>object containing any asset overrides, for available options consult the Assets table below.</td></tr>
|
|
107
108
|
<tr><td><code>colors</code> (optional)</td><td>object containing any color overrides, for available options consult the Colors table below.</td></tr>
|
|
108
109
|
<tr><td><code>verbiage</code> (optional)</td><td>object containing any verbiage overrides, for available options consult the Verbiage table below.</td></tr>
|
|
@@ -358,6 +359,7 @@ Render a fullscreen capture component that performs IDValidation and FaceValidat
|
|
|
358
359
|
<tr><td><code>webhooksStripSpecialCharacters</code> (optional)</td><td>boolean flag to indicate whether non-alphanumeric characters should be removed from the submission data when customer-configured webhooks are invoked. Defaults to true.</td></tr>
|
|
359
360
|
<tr><td><code>webhooksSendInputImages</code> (optional)</td><td>boolean flag to indicate whether raw user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
360
361
|
<tr><td><code>webhooksSendProcessedImages</code> (optional)</td><td>boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
362
|
+
<tr><td><code>webhooksFireOnReview</code> (optional)</td><td>boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. Defaults to false.</td></tr>
|
|
361
363
|
<tr><td><code>assets.idCapture</code> (optional)</td><td>object containing any asset overrides, for available options consult the ID Capture Assets table above.</td></tr>
|
|
362
364
|
<tr><td><code>assets.faceLiveness</code> (optional)</td><td>object containing any asset overrides, for available options consult the Face Liveness Assets table above.</td></tr>
|
|
363
365
|
<tr><td><code>colors.idCapture</code> (optional)</td><td>object containing any color overrides, for available options consult the ID Capture Colors table above.</td></tr>
|
|
@@ -429,6 +431,7 @@ Render a fullscreen capture component that performs IDValidation and FaceValidat
|
|
|
429
431
|
<tr><td><code>webhooksStripSpecialCharacters</code> (optional)</td><td>boolean flag to indicate whether non-alphanumeric characters should be removed from the submission data when customer-configured webhooks are invoked. Defaults to true.</td></tr>
|
|
430
432
|
<tr><td><code>webhooksSendInputImages</code> (optional)</td><td>boolean flag to indicate whether raw user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
431
433
|
<tr><td><code>webhooksSendProcessedImages</code> (optional)</td><td>boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
434
|
+
<tr><td><code>webhooksFireOnReview</code> (optional)</td><td>boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. Defaults to false.</td></tr>
|
|
432
435
|
<tr><td><code>assets.idCapture</code> (optional)</td><td>object containing any asset overrides, for available options consult the ID Capture Assets table above.</td></tr>
|
|
433
436
|
<tr><td><code>assets.faceLiveness</code> (optional)</td><td>object containing any asset overrides, for available options consult the Face Liveness Assets table above.</td></tr>
|
|
434
437
|
<tr><td><code>colors.idCapture</code> (optional)</td><td>object containing any color overrides, for available options consult the ID Capture Colors table above.</td></tr>
|
|
@@ -660,6 +663,9 @@ Render a fullscreen capture component that performs IDValidation and FaceValidat
|
|
|
660
663
|
<tr><td><code>onExitCapture</code> (optional)</td><td>callback function that fires when the user clicks the X button during capture.</td></tr>
|
|
661
664
|
<tr><td><code>onExitAfterFailure</code> (optional)</td><td>callback function that fires when the user clicks the exit button after failing the realness check.</td></tr>
|
|
662
665
|
<tr><td><code>lang</code> (optional)</td><td>language code to use. Supported values: 'auto' (detect based on user's OS), 'en' (English), 'es' (Spanish). Defaults to auto.</td></tr>
|
|
666
|
+
<tr><td><code>captureSignature</code> (optional)</td><td>boolean indicating whether the user should be prompted to sign the screen before submission. Defaults to false.</td></tr>
|
|
667
|
+
<tr><td><code>captureSignatureVideo</code> (optional)</td><td>boolean indicating whether the user should be prompted to record themselves signing the screen before submission. Defaults to false.</td></tr>
|
|
668
|
+
<tr><td><code>captureAdditionalDocuments</code> (optional)</td><td>array of additional documents to be captured. Each element includes a name and description.</td></tr>
|
|
663
669
|
<tr><td><code>companyId</code> (optional)</td><td>company identifier to include with submission.</td></tr>
|
|
664
670
|
<tr><td><code>needImmediateResponse</code> (optional)</td><td>boolean to indicate if validation of the minimum resolution for an ID document image should be triggered. Defaults to true.</td></tr>
|
|
665
671
|
<tr><td><code>manualReviewRequired</code> (optional)</td><td>boolean flag to indicate whether responses should always be reviewed by a human. Defaults to false.</td></tr>
|
|
@@ -675,6 +681,7 @@ Render a fullscreen capture component that performs IDValidation and FaceValidat
|
|
|
675
681
|
<tr><td><code>webhooksStripSpecialCharacters</code> (optional)</td><td>boolean flag to indicate whether non-alphanumeric characters should be removed from the submission data when customer-configured webhooks are invoked. Defaults to true.</td></tr>
|
|
676
682
|
<tr><td><code>webhooksSendInputImages</code> (optional)</td><td>boolean flag to indicate whether raw user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
677
683
|
<tr><td><code>webhooksSendProcessedImages</code> (optional)</td><td>boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. Defaults to false.</td></tr>
|
|
684
|
+
<tr><td><code>webhooksFireOnReview</code> (optional)</td><td>boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. Defaults to false.</td></tr>
|
|
678
685
|
<tr><td><code>idCaptureProps</code> (optional)</td><td>object containing any overrides for IDValidation.</td></tr>
|
|
679
686
|
<tr><td><code>faceLivenessProps</code> (optional)</td><td>object containing any overrides for IDValidation.</td></tr>
|
|
680
687
|
<tr><td><code>idCardFrontDetectionThreshold</code> (optional)</td><td>number between 0 and 1 at which document detection guidance score condition is considered to be met for the ID card front during video capture. Defaults to 0.48.</td></tr>
|
|
@@ -5,14 +5,16 @@ import { SubmissionAction, SubmissionEnvironment, SubmissionResponse } from '../
|
|
|
5
5
|
import { AdditionalDocumentCaptureWizardProps } from './additional_document_capture/AdditionalDocumentCaptureWizard';
|
|
6
6
|
import { SignatureCaptureProps } from './signature_capture/SignatureCapture';
|
|
7
7
|
import { VideoSignatureWizardProps } from './video_signature_capture/VideoSignatureWizard';
|
|
8
|
-
|
|
8
|
+
import { VideoIdWizardProps } from './video_id/IdVideoCaptureWizard';
|
|
9
|
+
export type CompositeWizardCheck = 'IdCapture' | 'FaceLiveness' | 'SignatureCapture' | 'VideoSignatureCapture' | 'AdditionalDocumentCapture' | 'VideoIdCapture';
|
|
9
10
|
export type CompositeWizardComponentProps = {
|
|
10
11
|
checks: CompositeWizardCheck[];
|
|
11
12
|
idCaptureProps?: IdCaptureWizardProps;
|
|
12
13
|
faceLivenessProps?: FaceLivenessWizardProps;
|
|
14
|
+
additionalDocumentCaptureProps?: AdditionalDocumentCaptureWizardProps;
|
|
13
15
|
signatureCaptureProps?: SignatureCaptureProps;
|
|
14
16
|
videoSignatureCaptureProps?: VideoSignatureWizardProps;
|
|
15
|
-
|
|
17
|
+
videoIdCaptureProps?: VideoIdWizardProps;
|
|
16
18
|
captureSignature?: boolean | (() => Promise<boolean>);
|
|
17
19
|
captureSignatureVideo?: boolean | (() => Promise<boolean>);
|
|
18
20
|
debugMode?: boolean;
|
|
@@ -25,4 +27,4 @@ export type CompositeWizardProps = CompositeWizardComponentProps & {
|
|
|
25
27
|
onComplete?: (submissionResponse: SubmissionResponse) => void;
|
|
26
28
|
};
|
|
27
29
|
export declare const CompositeWizard: (props: CompositeWizardProps) => ReactElement;
|
|
28
|
-
export declare const CompositeWizardComponent: ({ checks: userChecks, idCaptureProps, faceLivenessProps, signatureCaptureProps, videoSignatureCaptureProps,
|
|
30
|
+
export declare const CompositeWizardComponent: ({ checks: userChecks, idCaptureProps, faceLivenessProps, additionalDocumentCaptureProps, signatureCaptureProps, videoSignatureCaptureProps, videoIdCaptureProps, captureSignature, captureSignatureVideo, debugMode, }: CompositeWizardComponentProps) => ReactElement;
|
|
@@ -74,6 +74,8 @@ export interface CustomerEnrollmentProps extends PropsWithChildren {
|
|
|
74
74
|
webhooksSendInputImages?: boolean;
|
|
75
75
|
/** Boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. */
|
|
76
76
|
webhooksSendProcessedImages?: boolean;
|
|
77
|
+
/** Boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. */
|
|
78
|
+
webhooksFireOnReview?: boolean;
|
|
77
79
|
/** Boolean to indicate whether photos should be captured automatically when guidance conditions are met. Default is `true`. */
|
|
78
80
|
idAutoCaptureEnabled?: boolean;
|
|
79
81
|
/** Number between 0 and 1 at which document detection guidance score condition is considered to be met for ID cards. Defaults to 0.8. */
|
|
@@ -66,6 +66,8 @@ export interface IdAndFaceValidationProps extends PropsWithChildren {
|
|
|
66
66
|
webhooksSendInputImages?: boolean;
|
|
67
67
|
/** Boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. */
|
|
68
68
|
webhooksSendProcessedImages?: boolean;
|
|
69
|
+
/** Boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. */
|
|
70
|
+
webhooksFireOnReview?: boolean;
|
|
69
71
|
/** Boolean to indicate whether photos should be captured automatically when guidance conditions are met. Default is `true`. */
|
|
70
72
|
idAutoCaptureEnabled?: boolean;
|
|
71
73
|
/** Number between 0 and 1 at which document detection guidance score condition is considered to be met for ID cards. Defaults to 0.8. */
|
|
@@ -56,6 +56,8 @@ export interface IdValidationProps extends PropsWithChildren {
|
|
|
56
56
|
webhooksSendInputImages?: boolean;
|
|
57
57
|
/** Boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. */
|
|
58
58
|
webhooksSendProcessedImages?: boolean;
|
|
59
|
+
/** Boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. */
|
|
60
|
+
webhooksFireOnReview?: boolean;
|
|
59
61
|
/** Boolean to indicate whether photos should be captured automatically when guidance conditions are met. Default is `true`. */
|
|
60
62
|
idAutoCaptureEnabled?: boolean;
|
|
61
63
|
/** Number between 0 and 1 at which document detection guidance score condition is considered to be met for ID cards. Defaults to 0.8. */
|
|
@@ -5,10 +5,24 @@ import { VideoIdWizardAssets, VideoIdWizardClassNames, VideoIdWizardColors, Vide
|
|
|
5
5
|
import { IdCaptureWizardProps } from '../id_capture/IdCaptureWizard';
|
|
6
6
|
import { FaceLivenessWizardProps } from '../face_liveness/FaceLivenessWizard';
|
|
7
7
|
import { ThemeInput } from '../../themes';
|
|
8
|
+
import { AdditionalDocument } from '../additional_document_capture/AdditionalDocumentCapture';
|
|
9
|
+
import { AdditionalDocumentCaptureWizardClassNames, AdditionalDocumentCaptureWizardVerbiage } from '../additional_document_capture/AdditionalDocumentCaptureWizard';
|
|
10
|
+
import { SignatureCaptureClassNames, SignatureCaptureVerbiage } from '../signature_capture/SignatureCapture';
|
|
11
|
+
import { VideoSignatureClassNames, VideoSignatureColors, VideoSignatureVerbiage } from '../video_signature_capture/VideoSignatureWizard';
|
|
8
12
|
export type VideoIdValidationAssets = VideoIdWizardAssets;
|
|
9
|
-
export type VideoIdValidationClassNames = VideoIdWizardClassNames
|
|
10
|
-
|
|
11
|
-
|
|
13
|
+
export type VideoIdValidationClassNames = VideoIdWizardClassNames & {
|
|
14
|
+
additionalDocumentCapture?: AdditionalDocumentCaptureWizardClassNames;
|
|
15
|
+
signatureCapture?: SignatureCaptureClassNames;
|
|
16
|
+
videoSignatureCapture?: VideoSignatureClassNames;
|
|
17
|
+
};
|
|
18
|
+
export type VideoIdValidationColors = VideoIdWizardColors & {
|
|
19
|
+
videoSignatureCapture?: VideoSignatureColors;
|
|
20
|
+
};
|
|
21
|
+
export type VideoIdValidationVerbiage = VideoIdWizardVerbiage & {
|
|
22
|
+
additionalDocumentCapture?: AdditionalDocumentCaptureWizardVerbiage;
|
|
23
|
+
signatureCapture?: SignatureCaptureVerbiage;
|
|
24
|
+
videoSignatureCapture?: VideoSignatureVerbiage;
|
|
25
|
+
};
|
|
12
26
|
export interface VideoIdValidationProps extends PropsWithChildren {
|
|
13
27
|
/** Language code to use. Supported values: 'auto' (detect based on user's OS), 'en' (English), 'es' (Spanish). Defaults to auto. */
|
|
14
28
|
lang?: LangOption;
|
|
@@ -44,6 +58,8 @@ export interface VideoIdValidationProps extends PropsWithChildren {
|
|
|
44
58
|
webhooksSendInputImages?: boolean;
|
|
45
59
|
/** Boolean flag to indicate whether processed user-captured images should be included in the submission data when customer-configured webhooks are invoked. */
|
|
46
60
|
webhooksSendProcessedImages?: boolean;
|
|
61
|
+
/** Boolean flag to indicate whether customer-configured webhooks should be invoked upon ID being marked for manual review. */
|
|
62
|
+
webhooksFireOnReview?: boolean;
|
|
47
63
|
/** Callback function that fires immediately prior to submission, giving the client application an opportunity to specify custom asynchronous logic that mutates the request before it executes. The submission request is passed in as a parameter and a promise resolving to the updated request should be returned. */
|
|
48
64
|
onBeforeSubmit?: (req: SubmissionRequest) => Promise<SubmissionRequest>;
|
|
49
65
|
/** Callback function that fires when the user has completed the flow instead of making a call to IDmission's servers, allowing customers to specify their own submission logic. Arguments: the request payload that would have been dispatched to IDmission's API, which contains the images/documents/video submitted by the user. Note that when this parameter is supplied, `onComplete` will never fire, and the customer will need to implement their own error handling/retry logic. Use at your own risk! */
|
|
@@ -58,6 +74,12 @@ export interface VideoIdValidationProps extends PropsWithChildren {
|
|
|
58
74
|
idCaptureProps?: IdCaptureWizardProps;
|
|
59
75
|
/** Object containing any overrides for FaceLiveness. */
|
|
60
76
|
faceLivenessProps?: FaceLivenessWizardProps;
|
|
77
|
+
/** Boolean or async function indicating whether the user should be prompted to sign the screen before submission. Defaults to `false`. */
|
|
78
|
+
captureSignature?: boolean | (() => Promise<boolean>);
|
|
79
|
+
/** Boolean or async function indicating whether the user should be prompted to record themselves signing the screen before submission. Defaults to `false`. */
|
|
80
|
+
captureSignatureVideo?: boolean | (() => Promise<boolean>);
|
|
81
|
+
/** Array of additional documents to be captured. Each element includes a name and description. */
|
|
82
|
+
captureAdditionalDocuments?: AdditionalDocument[];
|
|
61
83
|
/** Number between 0 and 1 at which document detection guidance score condition is considered to be met for the ID card front during video capture. */
|
|
62
84
|
idCardFrontDetectionThreshold?: number;
|
|
63
85
|
/** Number between 0 and 1 at which focus guidance score condition is considered to be met for the ID card front during video capture. */
|
|
@@ -27,10 +27,11 @@ export type SubmissionProviderProps = {
|
|
|
27
27
|
webhooksStripSpecialCharacters?: boolean;
|
|
28
28
|
webhooksSendInputImages?: boolean;
|
|
29
29
|
webhooksSendProcessedImages?: boolean;
|
|
30
|
+
webhooksFireOnReview?: boolean;
|
|
30
31
|
onSubmit?: (payload: SubmissionRequest) => void;
|
|
31
32
|
onBeforeSubmit?: (req: SubmissionRequest) => Promise<SubmissionRequest>;
|
|
32
33
|
onBeforeLivenessCheck?: (req: LivenessCheckRequest) => Promise<LivenessCheckRequest>;
|
|
33
34
|
onResponseReceived?: (res: SubmissionResponse, req: SubmissionRequest) => void;
|
|
34
35
|
onRequestFailure?: (err: Error) => void;
|
|
35
36
|
};
|
|
36
|
-
export declare const SubmissionProvider: ({ action, children, url, environment, token, companyId, enrollmentId, personalData, cardData, bypassAgeValidation, bypassNameMatching, needImmediateResponse, manualReviewRequired, idBackImageRequired, idImageResolutionCheck, verifyIdWithExternalDatabases, deduplicationEnabled, deduplicationSynchronous, geolocationEnabled, geolocationRequired, webhooksEnabled, webhooksClientTraceId, webhooksStripSpecialCharacters, webhooksSendInputImages, webhooksSendProcessedImages, onSubmit, onBeforeSubmit, onBeforeLivenessCheck, onResponseReceived, onRequestFailure, }: SubmissionProviderProps) => ReactElement;
|
|
37
|
+
export declare const SubmissionProvider: ({ action, children, url, environment, token, companyId, enrollmentId, personalData, cardData, bypassAgeValidation, bypassNameMatching, needImmediateResponse, manualReviewRequired, idBackImageRequired, idImageResolutionCheck, verifyIdWithExternalDatabases, deduplicationEnabled, deduplicationSynchronous, geolocationEnabled, geolocationRequired, webhooksEnabled, webhooksClientTraceId, webhooksStripSpecialCharacters, webhooksSendInputImages, webhooksSendProcessedImages, webhooksFireOnReview, onSubmit, onBeforeSubmit, onBeforeLivenessCheck, onResponseReceived, onRequestFailure, }: SubmissionProviderProps) => ReactElement;
|
|
@@ -27,10 +27,11 @@ export type VideoIdWizardVerbiage = {
|
|
|
27
27
|
success?: IdVideoCaptureSuccessVerbiage;
|
|
28
28
|
};
|
|
29
29
|
export type VideoIdWizardProps = {
|
|
30
|
-
|
|
31
|
-
faceLivenessProps?: FaceLivenessWizardProps;
|
|
30
|
+
onComplete?: () => void;
|
|
32
31
|
onExitCapture?: () => void;
|
|
33
32
|
onExitAfterFailure?: (resp: SubmissionResponse | null, req: LivenessCheckRequest | null) => void;
|
|
33
|
+
idCaptureProps?: IdCaptureWizardProps;
|
|
34
|
+
faceLivenessProps?: FaceLivenessWizardProps;
|
|
34
35
|
idCardFrontDetectionThreshold?: number;
|
|
35
36
|
idCardFrontFocusThreshold?: number;
|
|
36
37
|
goodIdCardFrontFramesThreshold?: number;
|
|
@@ -46,4 +47,4 @@ export type VideoIdWizardProps = {
|
|
|
46
47
|
verbiage?: VideoIdWizardVerbiage;
|
|
47
48
|
debugMode?: boolean;
|
|
48
49
|
};
|
|
49
|
-
export declare const VideoIdWizard: ({
|
|
50
|
+
export declare const VideoIdWizard: ({ onComplete, onExitCapture, onExitAfterFailure, idCaptureProps, faceLivenessProps, idCardFrontDetectionThreshold, idCardFrontFocusThreshold, goodIdCardFrontFramesThreshold, showIdCardBackDurationMs, readTextPrompt, readTextTimeoutDurationMs, skipIdCapture, skipShowIdCardBack, assets, classNames, colors, verbiage, debugMode, }: VideoIdWizardProps) => ReactElement;
|
|
@@ -56,6 +56,7 @@ export type SubmissionRequest = {
|
|
|
56
56
|
deDuplicationRequired: 'Y' | 'N';
|
|
57
57
|
bypassNameMatching: 'Y' | 'N';
|
|
58
58
|
postDataAPIRequired: 'Y' | 'N';
|
|
59
|
+
postDataOnReviewRequired: 'Y' | 'N';
|
|
59
60
|
sendInputImagesInPost: 'Y' | 'N';
|
|
60
61
|
sendProcessedImagesInPost: 'Y' | 'N';
|
|
61
62
|
needImmediateResponse: 'Y' | 'N';
|