> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dojah.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Verify NIN with Selfie Image

> Lookup and Verify Users NIN with their Selfie Image.

To ensure that your customer is who they say they are, you can allow them take a selfie photo which you can pass on to the Dojah for the verification process

This helps to significantly reduce the possibility of fraud by confirming the person who is inputting the National ID number is who they say they really are.

### Request

```http [POST] theme={null}
{{baseUrl}}/api/v1/kyc/nin/verify
```

### Header

| Header        | Type   | Description                                                                                         |
| ------------- | ------ | --------------------------------------------------------------------------------------------------- |
| AppId         | string | Create an app to get your app ID on dashboard [here](https://app.dojah.io/developers/configuration) |
| Authorization | string | Private/secret key. Use `<key>` not `Bearer <key>`                                                  |

### Body Parameters

| Parameter                 | Type   | Description                                                                                                                                                    | Required |
| ------------------------- | ------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- |
| last\_name *OPTIONAL*     | string | Last Name                                                                                                                                                      | optional |
| first\_name  *OPTIONAL*   | string | First Name                                                                                                                                                     | optional |
| selfie\_image  *REQUIRED* | string | Base64 value of the selfie image. NB: Kindly truncate **data:image/jpeg;base64,** from the selfie\_image object and pass only the buffer starting with **/9**. | required |
| nin *REQUIRED*            | string | National Identity Verification Number.                                                                                                                         | required |

<Info>
  **Confidence Values range from 0% to 100%**

  * 0% - 90% denote match value is false
  * 90% - 100% denote match value is true
</Info>

### Response

```json Response theme={null}
{
    "entity": {
         "first_name": "John",
         "last_name": "Musa",
         "middle_name": "Doe",
         "gender": "M",
         "image": "/9j/4AAQScXJSgBBAgAAAQABAAD/2wBDAAgGBgcGBQgHBwcJCQgKDBQNDAsLDBkSEw8UHRofHh0aHBwg...",
         "phone_number": "0812345678",
         "date_of_birth": "1993-05-06",
         "nin": "7*****56789",
         "selfie_verification": {
             "confidence_value": 99.90354919433594,
             "match": true
         }
    }
}
```

### Response Fields

| Field                                         | Type    | Description                                                                     |
| --------------------------------------------- | ------- | ------------------------------------------------------------------------------- |
| entity                                        | object  | Contains the NIN verification response data                                     |
| entity.first\_name                            | string  | First name of the NIN holder                                                    |
| entity.last\_name                             | string  | Last name of the NIN holder                                                     |
| entity.middle\_name                           | string  | Middle name of the NIN holder                                                   |
| entity.gender                                 | string  | Gender of the NIN holder                                                        |
| entity.image                                  | string  | Base64-encoded photo from the NIN record                                        |
| entity.phone\_number                          | string  | Phone number associated with the NIN record                                     |
| entity.date\_of\_birth                        | string  | Date of birth of the NIN holder (YYYY-MM-DD)                                    |
| entity.nin                                    | string  | The National Identification Number                                              |
| entity.selfie\_verification                   | object  | Selfie verification result comparing the submitted selfie to the NIN photo      |
| entity.selfie\_verification.confidence\_value | number  | Confidence score of the selfie match (0–100). Values below 90 indicate no match |
| entity.selfie\_verification.match             | boolean | Whether the selfie matches the NIN photo (`true` if confidence ≥ 90)            |

### Test Credentials for Sandbox

Kindly use this Test NIN in sandbox Environment

nin = `70123456789`
