# National Identification Number(NIN)

{% hint style="info" %}
Please note that when using your test key, Our test persona is **John Doe** and his National Identity Number is **10000000001.** Hence all matching done with your test keys with details other than our Test Persona would simulate a failed identity matching.&#x20;
{% endhint %}

## Verify National Identity Number

<mark style="color:green;">`POST`</mark> `https://vapi.verifyme.ng/v1/verifications/identities/nin/:ref`

Use this endpoint to verify the identity of a person using their national identity number issued by NIMC.

#### Path Parameters

| Name | Type   | Description |
| ---- | ------ | ----------- |
| ref  | string | NIN number  |

#### Headers

| Name          | Type   | Description         |
| ------------- | ------ | ------------------- |
| Authorization | string | Authorization token |

#### Request Body

| Name      | Type   | Description   |
| --------- | ------ | ------------- |
| dob       | string | Date of Birth |
| firstname | string | first name    |
| lastname  | string | last name     |

{% tabs %}
{% tab title="201 " %}

```
{
  "status": "success",
  "data": {
    "fieldMatches":{
      "firsname":false,
      "lastname":false,
      "dob":false
    },
    "nin": 1000000001,
    "firstname": "John",
    "lastname": "Doe",
    "middlename": "Jane"
    "phone": "08066676673",
    "gender": "female"
    "birthdate": "04-04-1944",
    "photo": "Base64 Encoded"
  } 
}

```

{% endtab %}

{% tab title="404 " %}

```
{
    "code":"NOT_FOUND_ERROR",
    "message":"NIN provided is not found. Please provide a valid nin"
}
```

{% endtab %}
{% endtabs %}

#### Sample Request

{% tabs %}
{% tab title="Curl" %}

```
curl --location --request POST 'https://vapi.verifyme.ng/v1/verifications/identities/nin/10000000001' \
--header 'Authorization: Bearer <your secret key>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "firstname":"John",
    "lastname":"Doe",
    "dob":"04-04-1944"
}'
```

{% endtab %}
{% endtabs %}

## Verify National ID with Registered Phone Number

<mark style="color:green;">`POST`</mark> `https://vapi.verifyme.ng/v1/verifications/identities/nin_phone/:ref`

Use this endpoint to verify the identity of a person using the phone number used in registering the national Identity with NIMC.<br>

#### Path Parameters

| Name | Type   | Description                                |
| ---- | ------ | ------------------------------------------ |
| ref  | string | NIMC Registered Phone number eg 0800000000 |

#### Headers

| Name          | Type   | Description         |
| ------------- | ------ | ------------------- |
| Authorization | string | Authorization token |

#### Request Body

| Name      | Type   | Description   |
| --------- | ------ | ------------- |
| dob       | string | Date of Birth |
| firstname | string | first name    |
| lastname  | string | last name     |

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

```
{
  "status": "success",
  "data": {
    "fieldMatches":{
      "firsname":false,
      "lastname":false,
      "dob":false
    },
    "nin": 1000000001,
    "firstname": "John",
    "lastname": "Doe",
    "middlename": "Jane"
    "phone": "08066676673",
    "gender": "female"
    "birthdate": "17/01/1988",
    "photo": "Base64 Encoded"
  } 
}

```

{% endtab %}

{% tab title="404 " %}

```
{
    "code":"NOT_FOUND_ERROR",
    "message":"NIN provided is not found. Please provide a valid nin"
}
```

{% endtab %}
{% endtabs %}

#### Sample Response

{% tabs %}
{% tab title="Curl" %}

```
{
   "status": "success",
    "data": {
        "nin": "22515263226",
        "firstname": "JOHN",
        "lastname": "DOE",
        "middlename": "JAMES",
        "birthdate": "31-05-2000",
        "gender": "Male",
        "phone": "08100000000",
        "photo": "<base64 image>",
        }
    }
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.verifyme.ng/identity-verifications/national-identification-number.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
