> For the complete documentation index, see [llms.txt](https://doc.youverify.co/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.youverify.co/guides-and-solutions/onboard-a-customer-you-only-know-by-government-id.md).

# Onboard a customer you only know by Government ID

This guide covers the full onboarding path, from creating an entity with whatever data you hold, through identity verification, to the automatic risk screening that runs behind the scenes.

{% stepper %}
{% step %}

### Complete authentication and connection check

Before creating any entity, authenticate your API session and confirm connectivity. Every request carries your API secret token in the header; a failed auth check here is the most common cause of downstream 401 errors that look like data problems but aren't.
{% endstep %}

{% step %}

### Add the entity

You have three ways to create the entity, depending on what identifier you hold. These are alternatives, choose the one that matches the data you have.

* **Add with PII (first name, last name, country, phone)**. Use when you hold basic personal information but no government identifier yet. The entity is created on this data alone and enriched later.

```json
POST {{baseUrl}}/v2/api/entities
{
  "entityType": "individual",
  "firstName": "Jane",
  "lastName": "Doe",
  "nationality": "NG",
  "phone": "+2348012345678",
  "isSubjectConsent": true
}
```

* **Add with a Nigerian eIDv identifier (Phone Number / NIN-by-phone)**. Use when you hold a Nigeria-specific electronic identity value. The platform resolves the underlying identity record, so the entity starts more complete.

```json
POST {{baseUrl}}/v2/api/entities/:entityId/identity
{
  "entityType": "individual",
  "isSubjectConsent": true,
  "identity": {
    "countryCode": "NG",
    "idType": "nin_phone",
    "mobile": "+2348012345678"
  }
}
```

* **Add with a South African eIDv identifier (SAID number)**. Use when onboarding in South Africa with a national ID number. The SAID resolves the identity against the South African source.

```json
POST {{baseUrl}}/v2/api/entities/:entityId/identity
{
  "entityType": "individual",
  "isSubjectConsent": true,
  "identity": {
    "countryCode": "ZA",
    "idType": "zaSAID",
    "id": "8001015009087"
  }
}
```

References: [Create Entity](/api-reference/api-reference/entity-management/create-entity.md), [Verify Entity (KYC)](/api-reference/api-reference/entity-management/verify-entity-kyc.md)
{% endstep %}

{% step %}

### Verify identity with a government-issued ID

For entities created via PII, run a KYC check to confirm identity against an authoritative source. Cross-validate the supplied name and date of birth against the ID record, a mismatch is a fraud signal.

```json
POST {{baseUrl}}/v2/api/entities/:entityId/identity
{
  "entityType": "individual",
  "isSubjectConsent": true,
  "identity": {
    "countryCode": "NG",
    "idType": "bvn",
    "mobile": "11111111111"
  }
}
```

{% endstep %}

{% step %}

### What happens in the background?

The moment the entity is created, the platform automatically runs a full AML screen — Sanctions, PEP, Watchlist, and Adverse Media — against it. This always runs, on every plan, and produces the entity's initial risk score.

At this stage the score reflects AML data only. A newly created entity has no session or behavioral history yet, so Fraud Insight — which scores device and behavioral signals — has nothing to evaluate. As the customer transacts and generates signals, Fraud Insight enriches the profile into a fuller risk score on the same entity record. This enrichment happens over the customer's lifecycle, not at creation.

```mermaid
flowchart TD
    B[POST /entities<br/>create from PII]
    B --> C{{Auto AML screen<br/>Sanctions·PEP·Watchlist·Adverse Media}}
    C --> D[Initial risk score<br/>AML data only]
    B --> E[POST /entities/:id/identity<br/>BVN + validations]
    E --> F{Name/DOB match?}
    F -->|Yes| G[GET /entities/:id<br/>verified profile]
    F -->|No| H[Fraud signal — review]
    G --> I[GET /activities?entityId<br/>audit trail]

```

{% endstep %}
{% endstepper %}


---

# 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://doc.youverify.co/guides-and-solutions/onboard-a-customer-you-only-know-by-government-id.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.
