- Welcome 👋
- Get Started
- Create Your First App
- Authorization
- Webhooks
- Conditional Webhooks
- Security Considerations
- Multi-Language Support
- Responses
- Pagination
- Rate Limiting
- Versioning
- Change Log
- Support
- APIs
- Orders
- Order Status
- Order Histories
- Order Tags
- Order Invoice
- Order Reservations
- Order Items
- Products
- Product Options
- Product Quantity
- Product Variants
- Product Tags
- Product Images
- Product Option Values
- Abandoned Carts
- Customer Groups
- Customers
- Digitals Product
- Categories
- Exports
- Shipments
- Shipping Companies
- Shipping Zones
- Shipping Rules
- Countries
- Product Option Templates
- Taxes
- Coupons
- Affiliates
- Order Assignment
- Special Offers
- Transactions
- Payments
- Settlements
- Settings
- Merchant
- Brands
- Reviews
- Branches
- Currencies
- SEO
- Cities
- DNS Records
- Languages
- Employees
- Advertisements
- Webhooks
- Custom URLs
- Loyalty Points
- Webhooks - Store Events
Create Customer Group
Production
Production
POST
https://api.salla.dev/admin/v2/customers/groups
Customer Groups
Last modified:2025-02-05 13:21:46
Note
"total_sales" |
"total_orders" |
"store_rating" |
"doesnt_have_orders" |
> |
< |
between |
Information
Scopes
customers.read_write
- Customers Read & WriteRequest
Authorization
Add the parameter
Authorization
to Headers,whose value is to concatenate the Token after the Bearer.Example:
Authorization: Bearer ********************
Body Params application/json
name
stringÂ
optional
conditions
array [object {5}]Â
optional
type
stringÂ
optional
symbol
enum<string>Â
optional
Allowed values:
><between
value
numberÂ
optional
min_value
numberÂ
optional
symbol
equals between
.max_value
numberÂ
optional
symbol
equals between
Example
{
"name": "VIPCustomers",
"conditions": [
{
"type": "total_sales",
"symbol": ">",
"value": 100
}
],
"features": {
"payment_method": [
"credit_card",
"mada",
"bank",
"cod",
"apple_pay",
"stc_pay"
],
"shipping": [
"all"
]
}
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.salla.dev/admin/v2/customers/groups' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "VIPCustomers",
"conditions": [
{
"type": "total_sales",
"symbol": ">",
"value": 100
}
],
"features": {
"payment_method": [
"credit_card",
"mada",
"bank",
"cod",
"apple_pay",
"stc_pay"
],
"shipping": [
"all"
]
}
}'
Responses
🟢200Success
application/json
Body
status
numberÂ
optional
success
booleanÂ
optional
data
object (CustomerGroup)Â
optional
id
numberÂ
required
name
stringÂ
required
conditions
objectÂ
required
total_sales > 100
, determine auto-assignment. For example, customers with sales exceeding 100 are added to the group automatically.features
objectÂ
required
Examples
{
"status": 200,
"success": true,
"data": {
"id": 1394760126,
"name": "VIPCustomers"
}
}
🟠422Error Validation
🟠401Unauthorized
Modified at 2025-02-05 13:21:46