exceptionCaptured
An exception occurred during execution.
Details
Emitted when errors or unexpected situations occur during capture.
Event: exceptionCaptured
Type: FacephiSelphidWidgetCustomEvent<ExceptionCapturedEvent> | CustomEvent<ExceptionCapturedEvent>
Syntax
selphid.addEventListener('exceptionCaptured', onExceptionCaptured);Received object
The useful payload is of type SelphidExceptionCapturedDetail and is available in event.detail.detail:
eventType(string): Type of event emitted.exceptionType(string): Exception type (ExceptionType).message(string): Brief error description.code(string): Error code associated withexceptionType.
Values exceptionType — terminal:
AndroidWebViewBehaviour
The widget cannot run in the Android WebView.
BrowserApiNotCompatible
The browser is not compatible.
CameraHardwareError
Error accessing the camera.
PermissionsDenied
Required permissions not granted.
CameraPermissionDenied
Camera permission denied.
MicrophonePermissionDenied
Microphone permission denied.
SettingsError
Malformed configuration property.
UnknownInternalError
Unknown internal error.
ExternalCameraChangeTimeout
Timeout while changing the external camera.
Values exceptionType — extraction:
ErrorTimeout
The extraction time limit has been exceeded.
Values code:
exceptionType
Code
AndroidWebViewBehaviour
SPD_318
UnknownInternalError
SPD_329
CameraHardwareError
SPD_305
PermissionsDenied
SPD_332
CameraPermissionDenied
SPD_301
MicrophonePermissionDenied
SPD_319
SettingsError
SPD_320
BrowserApiNotCompatible
SPD_321
ErrorTimeout
SPD_001
Description
Lets you filter and respond to the different error types that occur during document capture.
Considerations
The useful payload is in event.detail.detail (see event format). Terminal exceptions display an error view and close the widget after errorTimer.
The SPD codes are aligned with the results. For ExternalCameraChangeTimeout, check the value emitted in code.
In IDV flows, recoverable extraction exceptions are reported as a step retry and do not set a verdict for that step; the verdict is determined by how the capture ends: maxAttemptsExceeded or a terminal exception.
Example
Last updated