Customer
Customer account creation
Customer Account Creation
This API allows you to create and manage user accounts efficiently and securely. With this API, you can streamline the onboarding process, ensuring a seamless experience for your users.
To create an account, make a POST request to the endpoint:
{{baseurl}}/customers/create
These are the parameters of the request body.
Field | Data Type | Description |
---|---|---|
city | String | Required. User’s city of residence. |
country | String | Required. User’s country of residence. |
dateOfBirth | String | Required. User’s date of birth. |
email | String | Required. User’s email address. |
firstName | String | Required. User’s first name |
idType | Object | Required. Type of identification document. |
lastname | String | Required. User’s last name. |
line1 | String | Required. First line of user’s address. |
line2 | String | Required. Second line of user’s address. |
phoneNumber | String | Required. User’s phone number. |
reference | String | Required. Reference identifier for the user. |
state | String | Required. User’s state of residence. |
zipCode | String | Required. User’s postal or ZIP code |
document | String | Optional. Document related to the user. |
house | String | Optional. House or apartment number |
idNumber | String | Optional. Identification document number. |
profileImage | String | Optional. URL to user’s profile image. |
This is what a typical successful response will look like:
{
"success": true,
"statusCode": 201,
"message": "Customer created successfully",
"data": {
"id": "326a18a1-441a-457d-ba28-0538e0717c92",
"email": "test@payshiga.com",
"firstName": "test",
"lastName": "testing",
"city": "Bariga",
"state": "Lagos",
"country": "Nigeria",
"zipCode": "100231",
"line1": "123, Payshiga road",
"line2": null,
"phoneNumber": "+2348123456789",
"house": "Zk9",
"dateOfBirth": "2002-10-29T00:00:00.000Z",
"idType": null,
"idNumber": null,
"document": null,
"imageURL": null,
"reference": "w72hs8shshshshw8s8292ushs",
"createdAt": "2024-05-01T22:10:44.329Z",
"status": "UNVERIFIED",
"reason": null,
"businessId": "0bb1dfc6-a74c-4e53-b41a-4a0c1eab188e"
}
}
Error Responses
Missing API keys
Status Code: 401 Bad Request
The response will include an error message indicating an issue with the request parameters.
// Some code