# OCR02

## OCR

<mark style="color:green;">`POST`</mark> `https://biometrid.com/api/providers/custom/ocr02/ocr?processId={{processId}}`

This enpoint allows you to perform an OCR validation

#### Query Parameters

| Name      | Type   | Description                      |
| --------- | ------ | -------------------------------- |
| processId | String | ID of process to save the result |

#### Headers

| Name                                            | Type   | Description                          |
| ----------------------------------------------- | ------ | ------------------------------------ |
| Acccept-Language                                | String | en (default), pt                     |
| Content-type<mark style="color:red;">\*</mark>  | String | application/json                     |
| Authorization<mark style="color:red;">\*</mark> | String | Authentication account or user token |

#### Request Body

| Name                                      | Type   | Description               |
| ----------------------------------------- | ------ | ------------------------- |
| doctype<mark style="color:red;">\*</mark> | String | Options: idcard, passport |
| front<mark style="color:red;">\*</mark>   | String | Base64 string             |
| back                                      | String | Base64 string             |

{% tabs %}
{% tab title="200: OK " %}

```
{
  "data": {
    "message": "DOCUMENT_VALIDATED_WITH_SUCCESS",
    "frontCut": "base64-string",
    "backCut": "base64-string",
    "photo": "base64-string",
    "signature": "base64-string",
    "result": "Ok",
    "reference": "string",
    "side": "string",
    "fields": {
      "normal": {
        "TYPE": "string",
        "SIDE": "string",
        "EXPEDITOR": "string",
        "NATIONALITY": "string",
        "NAME": "string",
        "SURNAME": "string",
        "ID_NUMBER": "string",
        "DOC_NUMBER": "string",
        "PARENTS": "string",
        "BIRTHDATE": "string",
        "EXPIRY": "string",
        "SEX": "string",
        "TAX_NUMBER": "string",
        "SOCIAL_SECURITY_NUMBER": "string",
        "HEALTH_NUMBER": "string",
        "MRZ": "string",
        "MODEL_ID": "string",
        "SIDES_NUMBER": string",
        "ICAR_RESULT_DOCUMENT_ID": "string"
      },
      "validation": {
        "TEST_MRZ_GLOBAL_INTEGRITY": "OK",
        "TEST_MRZ_FIELDS_INTEGRITY DOC_NUMBER": "OK",
        "TEST_MRZ_FIELDS_INTEGRITY BIRTHDATE": "OK",
        "TEST_MRZ_FIELDS_INTEGRITY EXPIRY": "OK",
        "TEST_COLOR_IMAGE": "OK",
        "TEST_OVERLAPPED_PHOTO_DETECTION": "OK",
        "TEST_EXPIRY_DATE": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ NAME": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ SURNAME": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ DOC_NUMBER": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ ID_NUMBER": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ EXPIRY": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ BIRTHDATE": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ NATIONALITY": "OK",
        "TEST_CORRESPONDENCE_VISIBLE_MRZ SEX": "OK",
        "TEST_SIDE_CORRESPONDENCE": "OK",
        "TEST_GLOBAL_AUTHENTICITY_RATIO": "0.990000",
        "TEST_GLOBAL_AUTHENTICITY_VALUE": "OK",
        "QUALITY_IMAGE_COMPRESSION": "IQ_GOOD 90 90",
        "QUALITY_IMAGE_SIZE": "IQ_GOOD 1000x635 1000x631",
        "QUALITY_IMAGE_RESOLUTION": "IQ_GOOD 256dpi 263dpi",
        "QUALITY_IMAGE_LUMINANCE": "IQ_GOOD [0.11, 0.00] [0.00, 0.00]",
        "QUALITY_IMAGE_HIGHLIGHTS": "IQ_GOOD",
        "QUALITY_IMAGE_BLURRING": "IQ_GOOD 0% 19%"
      }
    }
  },
  "meta": {
    "message": "Success."
  },
  "status": true
}
```

{% endtab %}
{% endtabs %}
