Payment Features
Customer
The Customers API allows you create and manage customers on your integration.
Create Customer
Create a customer on your integration
Endpoint: /customer
Method: POST
Header
Param | Type | Required? | Decription |
---|---|---|---|
authorization | string | Yes | Set value to Bearer SECRET_KEY |
content-type | string | Yes | Set value to application/json |
Body Param
Param | Type | Required? | Decription |
---|---|---|---|
string | Yes | Customer's email address | |
first_name | string | Yes | Customer's first name |
last_name | string | Yes | Customer's last name |
phone | string | No | Customer's phone number |
metadata | string | No | A set of key/value pairs that you can attach to the customer. It can be used to store additional information in a structured format. |
Sample Post
curl https://api.budpay.com/api/v2/customer
-H "Authorization: Bearer YOUR_SECRET_KEY"
-H "Content-Type: application/json"
-d '{ "email": "zero@budpay.com",
"first_name": "Zero",
"last_name": "Sum",
"phone": "+2348123456789"
}'
-X POST
Sample Response
{
"status": true,
"message": "Customer created",
"data": {
"email": "zero@sum.com",
"domain": "test",
"customer_code": "CUS_mc85c8hzzwfyowx",
"id": 6,
"created_at": "2022-02-01T00:01:33.000000Z",
"updated_at": "2022-02-01T00:01:33.000000Z"
}
}