m2pfintech

Forensic Check

AI/ML-powered document forensics solution to detect tampering, splicing, copy-move, and text redaction attacks on document IDs.

Forensic Check

Document Forensics Check service is a cutting-edge AI/ML based solution designed to localize and identify various forms of document tampering and malicious alterations performed on document IDs. Our solution aids in unveiling copy-move, splicing, erasing, and text redaction attacks, providing a reliable foundation for digital document verification and integrity assurance.

How It Works

Submit a Base64-encoded document image along with a doctype. The API analyses the image for signs of tampering and returns a prediction label (original or tampered), mask output, confidence statistics, and component-level integrity verification (logo, flag, hologram, barcode).

Request Parameters

ParameterTypeLocationRequiredDescription
apikeystringHeaderYesAPI key provided by Syntizen. Pass 0 to skip encryption.
authkeystringHeaderYesAuthentication token obtained from the /userauthentication endpoint.
rrnstringBodyYesRequest Reference Number — any unique identifier for the transaction.
fscimagestringBodyYesBase64-encoded document image. Supported formats: PNG, JPG, JPEG, WEBP.
doctypestringBodyYesType of document to analyse (e.g., mauritius_forensic).

Image Requirements

For accurate analysis and results, adhere to the following image specifications:

Supported Formats: PNG, JPG, JPEG, WEBP

Resolution:

  • Minimum: No specific limit
  • Maximum: No specific limit
  • Recommended: Full HD (1920 × 1080 pixels)

Image Quality:

  • High-quality images yield the best results.
  • Images with glare, excessive brightness/darkness, low clarity, noise, or artifacts may result in false positives or inaccurate analysis.
  • For optimal results, use high-quality, clear images at Full HD resolution.

Response

On success, the response includes:

  • data.label — forensic prediction result: "original" or "tampered".
  • data.data_stats — pixel-level statistics including mask_percentage and confidence scores.
  • data.doc_integrity_verification_result — component checks for logo, flag, hologram, barcode detection.
  • data.out_mask — Base64-encoded output mask image highlighting tampered regions.
POST
/ForensicCheck

Authorization

AuthKeyAuth
authkey<token>

Authentication token obtained from /userauthentication endpoint

In: header

Header Parameters

apikey*string

API key provided by Syntizen

authkey*string

Authentication token obtained from /userauthentication endpoint

Request Body

application/json

fscimage*string

Base64 of the image

rrn*string

Request Reference Number, any unique number for the identification of transaction.

doctype*string

Type of document

Response Body

application/json

curl -X POST "https://api.syntizen.com/ForensicCheck" \  -H "apikey: 0" \  -H "authkey: string" \  -H "Content-Type: application/json" \  -d '{    "fscimage": "/9j/4AAAAQARITEQQVFhIHGBkTChscHR8OHxQP/Z",    "rrn": "20230606184954501",    "doctype": "mauritius_forensic"  }'

{
  "respcode": "200",
  "respdesc": "Success.",
  "rrn": "20230606184954501",
  "data": {
    "label": "original",
    "data_stats": {
      "mask_percentage": 0,
      "img_width": 1572,
      "img_height": 1001,
      "total_pixels": 1573572,
      "total_non_zero_pixels": 0,
      "pct_above_75": 0,
      "conf_above_75": 0,
      "pct_above_50": 0,
      "conf_above_50": 0
    },
    "transaction_id": "20230606184954501",
    "timings": {
      "card_segmentation": 0.8984442959990702,
      "orientation_correction": 0.02555149399995571,
      "forensic_prediction": 4.8750800599955255,
      "object_detection": 0.8065438460034784,
      "spiral_detection": 0.024841197999194264,
      "pattern_detection": 0.1277801569958683
    },
    "out_mask": "/9Tuah8SRIuSXiNyktJUPlWSVC5U7lTeU7lkoRLEj4iCd9K5S4JKpckvCYJVYWGJCQBQxLocFG5FM1dEn6WwgA2yUl8hCyKR5KNBGhUoMCJDGCSEiksftJAgwsFs4EizU+KJJAFNOEkaS4D0SeUDlUKl4q2Ju/hYqKyqGicqg8n092l6NCpeJF5Wfu+0ZF5Xg8Hhwzw0sOFbZU7C5HxdvbGzNDxVHxzXDMgMpHKioVj8eDmaFC5VB5eT6XJWaG3UXlo91FRaViZqg4VFRo+Mrl9yoqPqr4S6j88ssvHCozg8rMMMTtg//83/4nAf8H2uKb//TNCSsAAAAASUVORK5CYII=",
    "doc_integrity_verification_result": {
      "is_logo_detected": true,
      "is_flag_detected": true,
      "is_hologram_detected": true,
      "is_crop_detected": false,
      "is_barcode_detected": false,
      "logo_detection_confidence": 0.6335949897766113,
      "logo_detection_box": [
        68.76809442043304,
        61.195091056823735,
        340.92110788822174,
        285.31306171417236
      ],
      "flag_detection_confidence": 0.8702448606491089,
      "flag_detection_box": [
        1332.0321407318115,
        65.6007571220398,
        1491.947748184204,
        165.0501729011536
      ],
      "hologram_detection_confidence": 0.9447736144065857,
      "hologram_detection_box": [
        1136.5660099983215,
        632.3521476745606,
        1437.1855090141298,
        833.077575302124
      ],
      "logo_details": {
        "colour_tampered_score": 0.2269112485392216,
        "logo_in_range": true,
        "logo_detection_confidence": 0.9688103795051575,
        "logo_detection_box": [
          68.76809442043304,
          61.195091056823735,
          340.92110788822174,
          285.31306171417236
        ],
        "distance_percentage": {
          "horizontal": 13.026,
          "vertical": 17.302
        }
      },
      "flag_details": {
        "flag_in_range": true,
        "flag_detection_confidence": 0.945360541343689,
        "flag_detection_box": [
          1332.0321407318115,
          65.6007571220398,
          1491.947748184204,
          165.0501729011536
        ],
        "distance_percentage": {
          "horizontal": 89.76,
          "vertical": 11.449
        },
        "colour_tampered_score": 0.25763877791504336
      },
      "hologram_details": {
        "colour_tampered_score": 0.14104848388389463,
        "hologram_in_range": true,
        "hologram_detection_confidence": 0.9447736144065857,
        "hologram_detection_box": [
          1136.5660099983215,
          632.3521476745606,
          1437.1855090141298,
          833.077575302124
        ],
        "distance_percentage": {
          "horizontal": 81.843,
          "vertical": 73.162
        }
      },
      "face_details": {
        "face_in_range": true,
        "face_detection_confidence": 0.8804032802581787,
        "face_detection_box": [
          126.83418273925781,
          417.4122009277344,
          397.73480224609375,
          759.0764770507812
        ],
        "distance_percentage": {
          "horizontal": 16.6560001373291,
          "vertical": 58.68299865722656
        }
      },
      "pattern_movement": false,
      "curve_face_details": {},
      "face_detection": true,
      "spiral_detection_confidence": 0.9998455047607422,
      "is_spiral_lines_detected": true,
      "is_map_pattern_detection": false,
      "is_curve_face_detected": false,
      "is_kenya_logo_detected": false,
      "is_kenya_gk_pattern_detected": false,
      "is_kenya_fingerprint_detected": false,
      "is_kenya_photo_detected": false,
      "is_kenya_mountain_detected": false
    }
  }
}

Empty
Empty

On this page