v1

latestOpenAPI 3.0.22026-07-2432112226.7 KB
ID Forgery

ID Forgery

This method helps you to to detect if an ID is real or fake. <br> 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. </br>

Error statusError codeDescription
200FAIL_ON_1fail on quality
200FAIL_ON_2forgery detected
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
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
400INVALID_PAYLOAD_QUALITY_VALIDATION_DEPENDENCYis_quality must be true if validate_quality true
403INSUFFICIENT_QUOTAusage reach it quota limit for ID Forgery
500INTERNAL_SERVER_ERRORinternal server error
post/v2/ktp/idforgery

Headers

App-IDstring required
API-Keystring required

Request body

imagestring required

A base64 or URL image file.

is_qualityboolean

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

validate_qualityboolean

Determines whether Quality validation will be executed. The validation consists of checking blur and dark with threshold, and also checking whether the image interrupted by flashlight or detected as graysacale image. When is_liveness is set to true, it is best that validate_quality is set to true, as liveness is influenced by Quality.

Response

Successful Response

Messagestring

Message indicating the status of the request to be processed

error_codestring

This error_code indicates an error that appeared in processing the request from the ID Forgery method

image_forgeryboolean

shows if the ID from uploaded image is detected as forgery

Example response

{
  "Message": "Forgery Detected",
  "error_code": "FAIL_ON_1"
}