Capture API
Methods to start a session
| Method | Description |
|---|---|
prepareSelfieCamera(config, cameraType) | Prepares the selfie camera. Returns a Promise<CameraOpener>. |
prepareSelfieCameraForIFrame(config, cameraType) | Prepares the selfie camera for use inside an iFrame. Returns a Promise<CameraOpener>. |
prepareDocumentCamera(config, documentType) | Prepares the document camera. Returns a Promise<CameraOpener>. |
cameraOpener.open(callback) | Opens the prepared camera with the callback object |
Capture options / parameters
SelfieCameraTypes — see Enums.
DocumentCameraTypes — see Enums.
Result types and fields
The success handler receives an object with:
| Field | Type | Description |
|---|---|---|
base64 | String | Captured image in Base64 |
encrypted | String | JWT to be sent to the backend |