Creates a new customer group with specified settings. The customer group name must be unique. Returns the full list of customer groups including the newly created one.
Note: To use wholesale features (registrationAllowed, wholesale, tableLayout, fullProfileRequired), the wholesale module must be active in the e-shop.
Security
shoptetAccessToken or shoptetPrivateApiToken
- Mock serverhttps://api.docs.shoptet.com/_mock/shoptet-api/openapi/api/customers/groups
- https://api.myshoptet.comhttps://api.myshoptet.com/api/customers/groups
- shoptetAccessToken
- shoptetPrivateApiToken
curl -i -X POST \
https://api.docs.shoptet.com/_mock/shoptet-api/openapi/api/customers/groups \
-H 'Content-Type: application/json' \
-H 'Shoptet-Access-Token: YOUR_API_KEY_HERE' \
-d '{
"data": {
"name": "Wholesale customers",
"description": "Wholesale customers are the best customers",
"defaultPricelistId": 1,
"emailNotification": true,
"authRequired": true,
"maxDiscount": "0.5500",
"defaultDueDays": 14,
"registrationAllowed": true,
"wholesale": true,
"tableLayout": true,
"fullProfileRequired": true,
"defaultOrderStatusId": -2
}
}'Response
- typePriceRatio
- null
{ "data": { "customerGroups": [ … ] }, "errors": [ { … } ] }