> For the complete documentation index, see [llms.txt](https://docs.lumiid.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.lumiid.com/api-integration/government-verification/nin-slip-download-api-or-generate-nigerian-nin-pdf-slips.md).

# NIN Slip Download API | Generate Nigerian NIN PDF Slips

## NIN Slip Download API

Generate official Nigerian National Identification Number (NIN) slips as downloadable PDFs. The LumiID NIN Slip Download API supports **Regular**, **Improved**, and **Premium** slips after NIN verification.

Use this API for identity management, fintech, government, HR, and self-service workflows.

***

### API overview

|                     |                              |
| ------------------- | ---------------------------- |
| **Country**         | 🇳🇬 Nigeria                 |
| **Document**        | Official NIN Slip (PDF)      |
| **Slip Types**      | Regular • Improved • Premium |
| **Response Format** | PDF (`application/pdf`)      |
| **Authentication**  | API Key Required             |
| **Sandbox**         | Supported                    |

***

### How NIN slip downloads work

Downloading a NIN slip is a simple two-step process.

#### Verify the NIN

Before requesting a slip, verify the customer's NIN using either:

```http
POST /v1/ng/nin-basic/
```

or

```http
POST /v1/ng/nin-premium/
```

LumiID securely stores the verification record required to generate the official slip.

***

#### Download the NIN slip

Call the NIN Slip Download endpoint with the verified NIN and preferred slip type.

LumiID generates the official PDF and returns it as a downloadable file.

> **Important**
>
> A NIN must be verified before requesting a slip. If no verification record exists, the API returns **404 Not Found**.

***

### Endpoint

**POST**

```http
{{baseUrl}}/v1/ng/nin/slip/download
```

***

### Request headers

| Header        | Description                       |
| ------------- | --------------------------------- |
| Authorization | `Bearer YOUR_SECRET_KEY`          |
| Content-Type  | `application/json`                |
| Accept        | `application/pdf` *(Recommended)* |

***

### Request body

| Field       | Type   | Required | Description                                                    |
| ----------- | ------ | -------- | -------------------------------------------------------------- |
| `nin`       | string | ✅        | Verified 11-digit National Identification Number.              |
| `slip_type` | string | ✅        | Type of slip to generate: `regular`, `improved`, or `premium`. |

#### Example Request

```json
{
    "nin":"89184072280",
    "slip_type":"improved"
}
```

***

### Successful response

When successful, LumiID returns a binary PDF stream.

```http
HTTP/1.1 200 OK

Content-Type: application/pdf
Content-Disposition: attachment; filename="improved_89184072280_slip.pdf"
```

The response body contains the PDF document.

***

### Supported NIN slip types

| Slip Type  | Description                                               |
| ---------- | --------------------------------------------------------- |
| `regular`  | Standard NIN slip.                                        |
| `improved` | Improved NIN slip with enhanced identity information.     |
| `premium`  | Premium NIN slip containing the complete official record. |

***

### Python example

```python
import requests

url = "https://api.lumiid.com/v1/ng/nin/slip/download"

headers = {
    "Authorization": "Bearer YOUR_SECRET_KEY",
    "X-App-ID": "YOUR_APPLICATION_ID",
    "Content-Type": "application/json",
    "Accept": "application/pdf"
}

payload = {
    "nin": "89184072280",
    "slip_type": "improved"
}

response = requests.post(
    url,
    json=payload,
    headers=headers
)

if response.status_code == 200:
    with open("nin_slip.pdf", "wb") as file:
        file.write(response.content)

    print("NIN slip downloaded successfully.")
else:
    print(response.status_code, response.text)
```

***

### Error codes

| HTTP    | Code                     | Description                                                                                  |
| ------- | ------------------------ | -------------------------------------------------------------------------------------------- |
| **400** | `INVALID_REQUEST`        | Missing NIN or invalid `slip_type`.                                                          |
| **401** | `INVALID_API_KEY`        | Authentication failed. Verify your API credentials.                                          |
| **404** | `NIN_NOT_VERIFIED`       | No verification record exists for the supplied NIN. Verify the NIN before requesting a slip. |
| **415** | `UNSUPPORTED_MEDIA_TYPE` | Requests must use `Content-Type: application/json`.                                          |
| **500** | `SERVER_ERROR`           | An unexpected error occurred while generating the PDF. Retry or contact LumiID Support.      |

***

### Best practices

* Verify the customer's NIN before requesting a slip.
* Use **HTTPS** for all API requests.
* Keep your Secret API Key secure and never expose it in client-side applications.
* Set the `Accept` header to `application/pdf` to receive the document as a binary PDF.
* Save the generated PDF securely if your workflow requires future access.
* Store the `request_id` from your verification response for auditing and support purposes.

***

### Common use cases

The NIN Slip Download API is commonly used for:

* Digital identity platforms
* Customer onboarding
* Employee verification
* HR and recruitment systems
* Government services
* Banking and fintech applications
* Customer self-service portals
* Regulatory compliance

***

### Related APIs

Most integrations use the following workflow:

1. [NIN Verification API](/api-integration/government-verification/nin-verification-api-or-nigerian-national-id-lookup.md) — Verify the customer's identity.
2. **NIN Slip Download API** — Generate the official NIN slip.
3. [Liveness Detection API](/api-integration/biometric-checks/liveness-detection-api-or-selfie-anti-spoofing-and-deepfake-checks.md) *(Optional)* — Confirm the customer is physically present.
4. [Government ID Face Match API](broken://spaces/fPBUridvLbwahlba0fcn/pages/WHPUQPxQewAM1A6X4XW) *(Optional)* — Match a selfie with a NIN biometric photo.

This workflow provides a complete identity verification pipeline for secure onboarding and regulatory compliance.

See [API Keys and Authentication](/api-integration/technical-references/lumiid-api-authentication-or-api-keys-sandbox-and-production.md) for request credentials and environments.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.lumiid.com/api-integration/government-verification/nin-slip-download-api-or-generate-nigerian-nin-pdf-slips.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
