W054: Create customer segment
Adds a new customer segment (for example, Club, Distributor, Grocery). Triggered from Settings, Customer segments. Same shape as W049.
Steps
-
Check name uniqueness. Case-insensitive, scoped to this org.
-
Insert the segment. Call
Customers.createCustomerSegment.
Returns
The new segment row.
Business rules
- Names are unique per org.
Errors
ValidationError. Duplicate name.