URL: /api/ninapi
Methods: POST, GET
This endpoint verifies a Nigerian National Identification Number (NIN). This is strictly a verification service.No NIN data is stored after verification. Clients are advised to save the response immediately.
To access this endpoint, users must include their API key and secret key in the request headers.
See usage example in the code snippets below:
POST request to verify NIN:
Content-Type: application/json
api-key: your-api-key
secret-key: your-secret-key
{
"number": "12345678901",
"firstLevel": "NIN Basic", // value of this key can either be firstLevel or fId, e.g. "nin-basic" to avoid whitespace issue
}
Response:
- Status Code: 200
{
"message": "Transaction successful",
"data": {
"status": "VERIFIED",
"profile": {
"nin": "12345678901",
"surname": "DOE",
"firstname": "JOHN",
"middlename": "OLUWASEUN",
"gender": "Male",
"dateOfBirth": "1995-08-14"
}
}}
- The `amountUsed` field represents the actual amount deducted from the user's balance based on user level.
{
"message": "Transaction failed",
"data": {
"transactionId": "1234567890",
"email": "user@example.com",
"activity": "NIN Basic",
"status": "Failed",
"recipient": "12345678901",
"amount": 100,
"initialBalance": 500,
"finalBalance": 500
"Method": API,
}
}
See usage example in the code snippets below:
GET request for available firstLevel:
Content-Type: application/json
api-key: your-api-key
secret-key: your-secret-key
Response:
- Status Code: 200
[
{
"available": true,
"firstLevel": "NIN Basic",
"fId": "nin-basic",
"amounts": [100],
"secondLevels": []
},
{
"available": true,
"firstLevel": "NIN Advanced",
"fId": "nin-advanced",
"amounts": [150],
"secondLevels": []
}
]