Create Customer

This endpoint allows you to create a new customer in the system.

Endpoint: POST {baseurl}/v1/api/customer

Body Parameters

Parameter Type Required Description
primaryEmail string Yes The primary email address of the customer. Must be a valid email format.
businessName string No The name of the business associated with the customer. Required if type is business.
secondaryEmails array No A list of secondary email addresses for the customer.
primaryPhoneNumber string No The primary phone number of the customer. Must include country code.
type string Yes The type of customer. Possible values: individual, business.
secondaryPhoneNumbers array No A list of secondary phone numbers for the customer. Must include country code.
firstName string Conditional The first name of the customer. Required if type is individual.
lastName string Conditional The last name of the customer. Required if type is individual.
middleName string No The middle name of the customer (optional).
country string Yes The country of the customer. Must be a 3-character country code. If country is not provided the default will be Nigeria
state string No The state of the customer.
dateOfBirth string No The date of birth of the customer in YYYY-MM-DD format. Required if type is individual.
gender string No The gender of the customer. Possible values: male, female, other. Required if type is individual.

Sample Request

curl -X POST "{baseurl}/v1/api/customer" \
-H "Content-Type: application/json" \
-H "x-api-key: {API-KEY}" \
-d '{
    "primaryEmail": "[email protected]",
    "businessName": "Denrox PLC.",
    "secondaryEmails": [
        "[email protected]"
    ],
    "primaryPhoneNumber": "+1234567890",
    "type": "individual",
    "secondaryPhoneNumbers": [
        "+1234567890"
    ],
    "firstName": "John",
    "lastName": "Doe",
    "middleName": "developer",
    "country": "USA",
    "state": "Delaware",
    "dateOfBirth": "2025-01-01",
    "gender": "male"
}'

Sample Response

{
    "sid": "string",
    "customer": {
        "id": "string",
        "primaryEmail": "string",
        "businessName": "string",
        "secondaryEmails": "string",
        "firstName": "string",
        "lastName": "string",
        "dateOfBirth": "string",
        "verified": true
    }
}