IDScan.net
Search Results for

    Show / Hide Table of Contents

    Configuration of the Web Library

    When creating an instance of the 'IDVC' object in Javascript the constructor takes a single Javascript object as its parameter with the following fields.

    Fields

    autoContinue (boolean) - the setting that enables the automatic transition from one step to the next step. Default: true

    capturingMode - The option that switches the mode of capturing the front of the documents. Available values are 2,4, ‘none’. Type 2 - auto capturing with the help of determining the borders. Type 4 - auto capturing which analyses the text in the image. ‘None’ - switch off the auto capturing. This method should be used together with the option showForceCapturingBtn:true. Default: 4

    displayParsedData (boolean) - the option which allows to show parsed results in modal window on submit. Default: false

    el (string) – id of a markup element on the page where the component will be integrated.

    enableFlash (ANDROID ONLY) (boolean) - the option which turns on the flash while capturing an image. Default: false

    enableGeolocation (boolean) - the option which allows to get user's latitude and longitude location. Default: false

    enableLimitation (boolean) - boolean parameter which allows you to be able to switch off the limitation for desktop browsers. Default: true

    enableMobileLimitation (DEPRECATED) (boolean) - enable limitation for mobile browsers. Default: false

    fixFrontOrientAfterUpload (boolean) - this setting will change the orientation of a front step's image if it is not horizontal when it is uploaded. Default: false

    Note

    This setting will only effect the orientation of a front step. So if you are using an mrz step with the Passport document type the orientation will not be effected in any way

    isShowGuidelinesButton - switches on/off the button to show guide lines. Default: false.

    isShowManualSwitchButton (boolean) - option to show the button with which you can switch between the uploader and the video. Default: true

    isShowVersion (boolean) - hide/show version of library in the bottom right of the web library widget. Default: true

    licenseKey (string) – license key for the web library

    minPDFframes (integer) - the setting which determines the minimal number of frames for capturing the PDF417. Default: 1

    networkUrl (string) - path to the folder with the neural networks. Specify the path on the server if you need to remove the folder to another location. Default: networks

    parseMRZ (boolean) - if it is enabled, the captured mrz strings is converted into the parsed document fields. Thus on-server parsing won’t be necessary. At the Front and mrz steps, the parsedData object would be available. Default: false

    parsePDF (boolean) - if it is enabled, the received trackstring is converted into the parsed document fields. Thus on-server parsing won’t be necessary. At the PDF step, the parsedData object would be available. Default: false.

    priority (string) - initial method of work of the component. Available values: 'uploader','camera', 'auto' (on desktop - uploader, on mobile - camera). Default: auto

    realFaceMode (string) - option that enable advanced capture with volumetric face detection. Available values: 'auto','all', 'none'. Auto - enable "realFaceMode" only for iphone. All - enable "realFaceMode" for all devices. None - disable this option. Default: auto

    resizeUploadedImage (integer) - sets the maximum size in pixels (of the larger of the height or width) for a manually uploaded picture. Default: -1

    showForceCapturingBtn (boolean) - Switches on the button over the video. On pressing this button, the capturing of the image will take place. Default: false

    showPreviewForOneStep (boolean) - using this option you can hide the preview if you have only one step configured. Default: true

    showSubmitBtn (boolean) – option to show the button 'submit' after capturing all the images. If a button is switched off, an event will automatically fire that triggers the submit event handler. Default: true

    steps (array) – array of steps which are necessary for you. Every step represents an object with the fields 'type' and 'name'. The field 'name' is the name of a step, which will be represented in the header. The field 'type' is a type of a step. Possible variants are:

    • front – capture of a document with the following analysis of the document type. In case if a document requires the back side, the step for the back side of a document will be added automatically. Use the step 'front' if you use the component for the document validation.

    • barcode – detection, capture and parsing 1 dimensional (barcodes) or 2 dimensional (qr codes)

    • mrz – detection and capture of the mrz-code of a document

    • pdf – detection and capture of pdf417 of a document

    • face – detection and capture of a face using the front camera

    • capturing – capture of a document without analysis

    Steps can be combined in any order and in any combinations, except for the step 'front'.

    E.g.:

    steps:[
    	{type: 'front', name: 'Image'},
    	{type: 'face', name: 'Selfie'}
    ]
    

    strictAllowedTypes (boolean) - strict allowed types mode makes a document not from the list of acceptable document types is throws an error. Default: false

    tapBackSide (boolean) - tap and hold the screen to capture the back side of the ID. Default: false

    tapFace (boolean) - tap and hold the screen to capture the face. Default: false

    tapOnVideo (boolean) - tap and hold on the video if you want capture frame manual. Default: false

    types (array) – array of types of acceptable documents. If you are going to use the component for the document validation, you can limit the list of acceptable documents.

    Available types (int):

    • ID (1) – USA driver license and USA ID (non-driver license), Canadian driver licenses
    • Passport (2) – with 2 lines MRZ
    • PassportCard (3) – with 3 lines MRZ (most European IDs, USA passports/cards)
    • GreenCard (6) – USA Permanent Resident Cards (only MRZ)
    • InternationalId (7) – Internationally approved U.S. IDs with 3 lines MRZ

    E.g.: types:

    ['ID', 'PassportCard']
    

    useCDN (boolean) - set to true if you prefer to load neural networks from cdn instead of your domain. Default: false

    Steps Array Explained

    Front Step

    When you are creating the instance of the IDVC object configure it with the following parameter in the steps array

    new IDVC ({
    	el: 'videoCapturingEl',
    	licenseKey: '',
    	steps: [
    		{type: 'front', name: 'Image'}
    	],
    	submit (data) {
        }
    })
    

    The document upload component will now include a step for capturing the front of a document.

    Effect on the Submit Event Handler's Input Argument

    The submit field of the IDVC object constructor's parameter is a callback function, which is called when pressing the submit button. The callback function's input parameter is an object with the following fields that contain the data collected during the front step:

    {
        "event":"submit",
        "steps":[{
            "img": "",
            "index": 1,
            "type": "front"
        }],
        "documentType":1
    }
    

    In the steps array you will be able to find objects with images of the document (the img field).

    Face Step

    When you are creating the instance of the IDVC object configure it with the following parameter in the steps array

    new IDVC ({
    	el: 'videoCapturingEl',
    	licenseKey: '',
    	steps: [
    		{type: 'face', name: 'Face'}
    	],
    	submit (data) {
        }
    })
    

    The document upload component will now include a step for capturing a user's face.

    When capturing the user's face their is a configuration option that will allow for enhanced anti spoofing checks to be performed. This can be configured using the realFaceMode setting.

    realFaceMode (string) - am option that enables advanced image capturing with volumetric face detection. Available values: 'auto','all', 'none'.

    • Auto - enable "realFaceMode" only for iPhone
    • All - enable "realFaceMode" for all devices
    • None - disable this option

    Effect on the Submit Event Handler's Input Argument

    The submit field of the IDVC object constructor's parameter is a callback function, which is called when pressing the submit button. The callback function's input parameter is an object with the following fields that contain the data collected during the face step:

    {
        "event":"submit",
        "steps":[{
            "img":"",
            "index":1,
            "type": "face"
        }],
        "documentType":null
    }
    

    The field img in the element of the array steps is the face image in the base64 format.

    MRZ Step

    When you are creating the instance of the IDVC object configure it with the following parameter in the steps array

    new IDVC ({
    	el: 'videoCapturingEl',
    	licenseKey: '',
    	steps: [
    		{type: 'mrz', name: 'MRZ'}
    	],
    	submit (data) {
        }
    })
    

    The document upload component will now include a step for capturing the Machine Readable Zone (MRZ).

    Effect on the Submit Event Handler's Input Argument

    The submit field of the IDVC object constructor's parameter is a callback function, which is called when pressing the submit button. The callback function's input parameter is an object with the following fields that contain the data collected during the mrz step:

    {
        "event":"submit",
        "steps":[{
            "img":"",
            "index":1,
            "mrzImg": "",
            "type": "mrz"
        }],
        "documentType":null
    }
    

    The field mrzImg in the element of the array steps is a cut out MRZ image in the base64 format and img is a document image in the base64 format.

    PDF Step

    When you are creating the instance of the IDVC object configure it with the following parameter in the steps array

    new IDVC ({
    	el: 'videoCapturingEl',
    	licenseKey: '',
    	steps: [
    		{type: 'pdf', name: 'PDF'}
    	],
    	submit (data) {
        }
    })
    

    The document upload component will now include a step for capturing the PDF417 barcode

    Effect on the Submit Event Handler's Input Argument

    The submit field of the IDVC object constructor's parameter is a callback function, which is called when pressing the submit button. The callback function's input parameter is an object with the following fields that contain the data collected during the pdf step:

    {
        "event":"submit",
        "steps":[{
            "img":"",
            "index":1,
            "type":"pdf",
            "trackString":""
        }],
        "documentType":null
    }
    

    The trackString field is a field of an element of the steps array. It is the raw PDF417 data from bar code encoded as a base64 string and the img field is the document image encoded as a base64 string.

    Back to top IDScan.net IDScan.net GitHub