POST
/api/public/v1/customersCreate a customer
Create a new customer (account) within a business.
Request Body
| Property | Type | Description |
|---|---|---|
businessId | string | Business that owns the customer. |
fullname | string | Customer full name. |
email | string | Email address. |
phoneNumber | string | Phone number. |
birthday | string | ISO date of birth. |
notes | string | Free-form notes. |
POSTExample request
curl
curl -X POST "https://www.pxb.app/api/public/v1/customers" \
-H "X-Organization-Id: your_org_id" \
-H "X-API-Key: your_api_key" \
-H "Content-Type: application/json" \
-d '{
"businessId": "biz_abc",
"fullname": "John Doe",
"email": "john@example.com"
}'200Example response
json
{
"message": "Customer created successfully!",
"content": {
"customer": {
"id": "cust_1"
}
}
}