Liveness is used to protect against biometric attacks. It’s a proof of a real person working on Id analysis, Face biometry verification and Liveness verification.

Swagger links:
Test: https://test.zignsec.com/v3/scan/swagger/index.html#/ScanningLiveness
Production: https://api.zignsec.com/v3/scan/swagger/index.html#/ScanningLiveness

Flow

  1. Initialize scanning session
  2. Complete browser steps
  3. Get analysis result

A scan session is the overarching unit of work. It contains a collection of documents to be analysed. A scanning session can contain several analyses. An analysis is started by supplying the scanning session with an analysis configuration object.

Scanning flow can be configured using merchant settings.

Step 1: Initialize scanning session

NOTE: If a document scan is not required, we choose the option no document but f it is required, we have to change the option in settings and choose to scan the front page or both front and back side. Even in Available actions: we set up the value as following: “FollowText”, “MoveTowardsCamera” and “MoveAwayFromCamera”.

Note: Liveness is video based only and no audio is available.

Step 1.1: Create a new Browser flow (web flow) scanning session

POST https://test.zignsec.com/v3/scanning/liveness

Authorization: YOUR-KEY....
{
  "relay_state": "11111",
  "target": "https://www.google.com/?q=Success",
  "cancel_url": "https://www.google.com/?q=Cancel",
  "target_error": "https://www.google.com/?q=targetError",
  "webhook": "",
  "options": "FrontSide",
  "action": "Random",
  "available_actions": [
    "FollowText"
   
  ],
  "css": []
}

Step 1.2: Description of request model

localePreferred Language to use, we support multiple languages like : en , se ,de , fr, gr, it ,ru ,es , cz, tr.


We can add more languages as per your business requirements
Not required
relay_statewill be returned to you at the redirect back to your server. Use it to link an unique ID of your choice that you can parse. If not relaystate is specified, ZignSec will automatically set the ZignSec’s unique session identifier, the RequestID token here.
Example: "relay_state":"client_state"
Semi-optional/not required
targetIf this parameter is supplied the browser session will finally be redirected to this URL-value
(it’s applicable only if analysis with provider’s UI is used i.e. liveness)
Example : "target": "https://landing.mysite.com"
Not required
target_errortarget_error works as target except it is navigated on user cancel or error situations.Not required
webhook

A URL where success/error results will automatically be POST:ed.

During test you try https://webhook.site/ for free webhook URLs.

Not required
options
Liveness options

Enum: [ FrontSide, NoDocument, FrontAndBack ]

Required
action

String

Liveness check action

Enum: [ Random, MoveTowardsCamera, MoveAwayFromCamera, FollowText ]

Required
available_actions

string

[uniqueItems: false

Allows to limit possible actions when “action” property set to Random

Enum:
[ MoveTowardsCamera, MoveAwayFromCamera, FollowText
]

Optional
css

[uniqueItems: false

each item in this array is a path to custom css file to allow ui branding

string]

Optional
doc

 ZignSec.Scanning.Application.Dto.DocumentDefinitionDtoZignSec.Scanning.Application.Dto.DocumentDefinitionDto

{

ignore_errors_in_fields
[uniqueItems: false

string]
}

 

Step 1.3: Example of response for initializing scanning session

{
    "id": "61652a58-1921-4593-abab-fcbc24f972b0",
    "errors": [],
    "redirect_url": "https://test.zignsec.com/v3/scan/ui/61652a58-1921-4593-abab-fcbc24f972b0/liveness?otp=P3r27O1U20WE8tVUnlLH5w"
}

Step 1.4: Description of response model

idThe session identifier, a GUID (globally unique identifier) unique for the started workflow, used both in the redirect_url and the get analysis results.
errorsA JSON object that contains information on error conditions that might have resulted from the request, in an array of property-value pairs. If multiple errors occur, a pair of parameters is returned for each error. code Code for the error. List of codes is in table below. description A string that describes the type of error that occurred. If no errors occur, then this object is empty. errors : []
redirect_urlThe URL that the user need to be redirected to complete the data via the web interface. It is possible to load the URL in an iframe.

Step 2: Browser steps

There are two approaches to complete files upload to scanning:

    • Browser flow
    • Mobile flow

Step 2.1: Example of browser flow

Browser flow: Upload all images from current browser.

Authenticate with your access tokenControl your settings and Choose to scan through browser Follow instructions 1- Make a photo of document’s front side 

2- Confirm and start face analysis =>Align your face with the frame

Waiting for Analyzing and Getting result

(See details in the portal)

Step 2.2: Example of mobile flow

Mobile flow: start session in browser, continue in mobile, back to browser.

Browser steps
Authenticate with your access tokenControl your settings and Choose to scan through mobileScan QR code by mobile and access the link

 

 

 

   
Mobile steps
  Open link from QR codeFollow instructions
1- Make a photo of document’s front side 
2- Confirm and start face analysis
=>Align your face with the frame
Waiting for Analyzing and Getting result
(See details in the portal)
  

Step 3: Get analysis result

To get result of scanning you need to call API Get result.