# Create a new customer Creates a new customer record in the system. Endpoint: POST /v1/api/customers Version: 1.0.0 Security: api-key ## Request fields (application/json): - `companyId` (string) Company ID associated with the customer Example: "a1b2c3d4e5f6g7h8i9j0" - `externalId` (string) External ID from third-party system Example: "x1y2z3a4b5c6d7e8f9g0" - `email` (string, required) Email address of the customer Example: "customer@example.com" - `firstName` (string, required) First name of the customer Example: "John" - `lastName` (string, required) Last name of the customer Example: "Doe" - `phone` (string) Phone number of the customer Example: "+1234567890" - `tags` (array) Tags associated with the customer Example: ["vip","returning"] - `fromOliver` (boolean) Flag to indicate if the customer is from Oliver Example: true - `metadata` (object) Metadata associated with the customer - `notes` (array) Notes associated with the customer Example: [{"message":"Customer prefers email communication","createdAt":"2024-01-15T10:30:00Z"},{"message":"VIP customer - handle with priority","createdAt":"2024-01-20T14:00:00Z"}] - `notes.message` (string, required) Note message Example: "Customer prefers email communication" - `notes.createdAt` (string) Date when the note was created Example: "2024-01-15T10:30:00Z" - `billing` (object) Billing address of the customer Example: {"firstName":"John","lastName":"Doe","company":"Acme Corp","address1":"123 Main St","address2":"Suite 100","city":"New York","state":"NY","country":"USA","postCode":"10001"} - `billing.firstName` (string) First name Example: "John" - `billing.lastName` (string) Last name Example: "Doe" - `billing.company` (string) Company name Example: "Acme Corp" - `billing.address1` (string) Address line 1 Example: "123 Main St" - `billing.address2` (string) Address line 2 Example: "Suite 100" - `billing.city` (string) City Example: "New York" - `billing.state` (string) State or province Example: "NY" - `billing.country` (string) Country Example: "USA" - `billing.postCode` (string) Postal code Example: "10001" - `shipping` (object) Shipping address of the customer Example: {"firstName":"Jane","lastName":"Smith","address1":"456 Oak Avenue","address2":"Apt 4B","city":"Los Angeles","state":"CA","country":"USA","postCode":"90001"} - `totalSpent` (string) Total amount the customer has spent Example: "500.00" - `lastAction` (string) Date of last action Example: "2024-06-10T08:00:00Z" - `outletId` (string) Outlet ID associated with the customer Example: "o1p2q3r4s5t6u7v8w9x0y1z2" ## Response 201 fields ## Response 400 fields