Manage Customer Groups of Customer
POST
/admin/customers/{id}/customer-groups
Customers
Request Request Example
JavaScript
Shell
Java
Swift
curl --location -g --request POST '{{BASE_URL}}/admin/customers//customer-groups' \
--header 'Content-Type: application/json' \
--data-raw '{
"add": [
"string"
],
"remove": [
"string"
]
}'
Response Response Example
200 - Example 1
{
"customer": {
"id": "string",
"has_account": true,
"groups": [
{
"id": "string",
"name": "string",
"metadata": {},
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"customers": [
{}
]
}
],
"email": "user@example.com",
"default_billing_address_id": "string",
"default_shipping_address_id": "string",
"company_name": "string",
"first_name": "string",
"last_name": "string",
"addresses": [
{
"id": "string",
"address_name": "string",
"is_default_shipping": true,
"is_default_billing": true,
"customer_id": "string",
"company": "string",
"first_name": "string",
"last_name": "string",
"address_1": "string",
"address_2": "string",
"city": "string",
"country_code": "us",
"postal_code": "string",
"phone": "string",
"metadata": {},
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"province": "us-ca"
}
],
"phone": "string",
"metadata": {},
"created_by": "string",
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z",
"deleted_at": "2019-08-24T14:15:22Z"
}
}
Request
Path Params
id
stringÂ
required
Query Params
fields
stringÂ
fields
if a field is prefixed with
+
it will be added to the default fields, using -
will remove it from the default fields.without prefix it will replace the entire default fields. This API route restricts the fields that can be selected. Learn how to override the retrievable fields in
the Retrieve Custom Links documentation.
Body Params application/json
Responses
Modified at 2025-06-17 04:10:32