---
title: Basic Forgery Check
slug: v2/basic-forgery-check
description: Learn how to use the forgery detection API to analyze images and verification data. Our document includes a cURL example for making a POST request with headers and data. Discover the API response, containing crucial information like forgery and match stat
createdAt: 2023-04-07T17:53:20.000Z
---

## Introduction

&#x20;The API allows users to perform various tasks related to forgery detection using a set of essential images and verification data.

# Sample cURL

:::CodeblockTabs
Curl

```curl
curl --request POST \
  --url https://signzy.tech/api/v2/patrons/...patronID.../forgeries \
  --header 'Accept: */*' \
  --header 'Accept-Language: en-US,en;q=0.8' \
  --header 'Authorization: <Access-Token>' \
  --header 'content-type: application/json' \
  --data '{"task":"basicForgery","essentials":{"images":["...url of the images..."],"verifyData":{"identityCard":{"type":"aadhaar | individualPan | businessPan | dl | passport"},"textMatch":{"fields":{"..field1..":"..it'\''s value..","..field2..":"..it'\''s value..","..fieldN..":"..it'\''s value.."}}}}}'
```
:::

| Parameter    | Type   | Description                                                                                                                        |
| ------------ | ------ | ---------------------------------------------------------------------------------------------------------------------------------- |
| task         | string | Required. The type of forgery detection task to perform. Possible values: basicForgery.                                            |
| images       | array  | Required. An array of image URLs to be used for forgery detection.                                                                 |
| identityCard | object | Required. An object containing the type of identity card and corresponding field values to match.                                  |
| type         | string | Required. The type of identity card to be matched. Possible values: aadhaar, individualPan, businessPan, dl, passport.             |
| textMatch    | object | Required. An object containing the fields and values to be matched for the identity card.                                          |
| fields       | object | Required. An object containing the fields and values to be matched for the identity card. Possible fields: name, gender, dob, etc. |

# Sample API REsponse

```javascript
{
    "essentials": {
        "images": [
            "...url..to..the..image..."
        ],
        "verifyData":{
            "identityCard":{
                "type":"aadhaar | individualPan | businessPan | dl | passport | voterId | unknown"
            },
            "textMatch":{
                "fields": {

                   "..field1..":"..it's value..",
                   "..field2..":"..it's value..",
                   "..fieldN..":"..it's value.."
                }
            }
        }
    },
    "id": "5bxxxxxxxxxx474",
    "patronId": "5a9xxxxxxxxxxxx119d8",
    "task":"basicForgery",
    "result": {
        "forgery": "NOT FORGED | FORGED",
        "message": "message about issue if found any.",
        "identityCard": {
            "match": "yes | no",
            "predictedType": "aadhaar | individualPan | businessPan | dl | passport | voterId | unknown"
        },
        "color": {
            "forgery": "NOT FORGED | FORGED",
            "message": "message about the file.",
            "dominantColors": [
                "#colorCode",
                "#colorCode",
                ..
                ..
                ..
                "#colorCode"
            ]
        },
        "textMatch": {
            "field1": {
                "score": "score between 0-1",
                "verb": "NO MATCH/MATCH/PARTIAL MATCH",
                "bestMatch": "Best Match found"
            },
            "field2": {
                "score":  "score between 0-1",
                "verb": "NO MATCH/MATCH/PARTIAL MATCH",
                "bestMatch": "Best Match found"
            },
            ..
            ..
            ..
            ..
            "fieldN": {
                "score": "score between 0-1",
                "verb": "NO MATCH/MATCH/PARTIAL MATCH",
                "bestMatch": "Best Match found"
            }
        }
    }
}
```

| Parameter      | Type   | Description                                                                                                                    |
| -------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------ |
| task           | string | The type of forgery detection task performed.                                                                                  |
| essentials     | object | An object containing the input data for the forgery detection.                                                                 |
| images         | array  | An array of image URLs used for forgery detection.                                                                             |
| identityCard   | object | An object containing the type of identity card and corresponding field values to match.                                        |
| type           | string | The type of identity card to be matched. Possible values: aadhaar, individualPan, businessPan, dl, passport, voterId, unknown. |
| textMatch      | object | An object containing the fields and values to be matched for the identity card.                                                |
| fields         | object | An object containing the fields and values to be matched for the identity card. Possible fields: name, gender, dob, etc.       |
| result         | object | An object containing the result of the forgery detection.                                                                      |
| forgery        | string | The forgery status of the image(s). Possible values: NOT FORGED, FORGED.                                                       |
| message        | string | Any additional message about the forgery detection.                                                                            |
| match          | string | The match status of the identity card. Possible values: yes, no.                                                               |
| predictedType  | string | The predicted type of the identity card. Possible values: aadhaar, individualPan, businessPan, dl, passport, voterId, unknown. |
| dominantColors | array  | An array of the dominant colors in the image.                                                                                  |
| score          | float  | The score of the matched field value.                                                                                          |
| verb           | string | The verb indicating the match status. Possible values: NO MATCH, MATCH, PARTIAL MATCH.                                         |
| bestMatch      | string | The best match for the field value.                                                                                            |

