Detect Face Liveness

This method helps you to detect liveness from a face image

Recommendation

  1. Only one face exist in the image sent (Holding an identity card is not recommended).
  2. The face in the image must not be blocked by anything, i.e. take off masks
  3. No editing on the image.
  • prioritize for users to directly capture face image from mobile phone camera
  • do not compress or crop the image
  • do not add any elements to the image, i.e. padding
  1. Make sure the image have good quality (avoid blur & dark).
  2. Avoid backlight.
  3. Avoid taking image in a dark environment.

You will receive a response consists of message and an error code if the request fails to process. The following is a list of error codes.

Error StatusError CodeDescription
200FAIL_ON_2fail on attribute
200FAIL_ON_4fail on quality
200FAIL_ON_6fail on attribute and quality
200FAIL_ON_8fail on fail on number of face (nface)
200FAIL_ON_10fail on fail on number of face (nface) and attribute
200FAIL_ON_12fail on fail on number of face (nface) and quality
200FAIL_ON_14fail on fail on number of face (nface), quality, and attribute
400INVALID PAYLOADno value in payload or empty string more than 1
400INVALID_PAYLOAD_IMAGE_MISSINGinvalid payload image not a standard b64/url or image empty string
400INVALID_PAYLOAD_IMAGE_SIZEinvalid payload image size too large
400MISSING_PAYLOAD_IMAGEmissing payload image
400INVALID_PAYLOAD_IMAGE_TIMEOUTtimeout getting image from url in 15 seconds
400INVALID_PAYLOAD_IMAGE_FORMATimage unable to be decoded/got from url OR invalid image extension
400FACE_NOT_DETECTEDface not detected from image
400INVALID_PAYLOAD_QUALITY_VALIDATION_DEPENDENCYis_quality must be true if validate_quality true
400INVALID_PAYLOAD_ATTRIBUTE_VALIDATION_DEPENDENCYis_attribute must be true if validate_attribute true
403INSUFFICIENT_QUOTA_LIVENESSusage reach it quota limit for liveness (only appears on testing mode)
500INTERNAL_SERVER_ERRORinternal server error
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Body Params
string
required

A base64 or URL image file.

boolean
Defaults to true

A flag to determine whether Image Quality (blur, dark, grayscale) will be computed and return as result

boolean
Defaults to true

A flag to determine whether Image Attribute (sunglasses, mask, veil, hat) will be detected and return as result

boolean
Defaults to false

Determines whether Quality validation will be executed. The validation consists of checking blur and dark with threshold, and also checking whether the image is a black & white image (grayscale is true). It is highly recommended to set validate_quality to true as Liveness is influenced by Quality.

boolean
Defaults to false

Determines whether Attribute validation will be executed. The validation consists of checking whether sunglasses or mask is detected in the input image.

boolean
Defaults to false

Determines whether the number of faces validation will be executed. The validation checks whether the input image consists of more than one face.

Headers
string
required
string
required
Responses

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json