Skip to main content

CustomerGroupService

Contains methods relating to CustomerGroup entities.

Signature

constructor

method(connection: TransactionalConnection, listQueryBuilder: ListQueryBuilder, historyService: HistoryService, eventBus: EventBus, customFieldRelationService: CustomFieldRelationService) => CustomerGroupService

findAll

method(ctx: RequestContext, options?: CustomerGroupListOptions, relations: RelationPaths<CustomerGroup> = []) => Promise<PaginatedList<CustomerGroup>>

findOne

method(ctx: RequestContext, customerGroupId: ID, relations: RelationPaths<CustomerGroup> = []) => Promise<CustomerGroup | undefined>

getGroupCustomers

method(ctx: RequestContext, customerGroupId: ID, options?: CustomerListOptions) => Promise<PaginatedList<Customer>>

Returns a PaginatedList of all the Customers in the group.

create

method(ctx: RequestContext, input: CreateCustomerGroupInput) => Promise<CustomerGroup>

update

method(ctx: RequestContext, input: UpdateCustomerGroupInput) => Promise<CustomerGroup>

delete

method(ctx: RequestContext, id: ID) => Promise<DeletionResponse>

addCustomersToGroup

method(ctx: RequestContext, input: MutationAddCustomersToGroupArgs) => Promise<CustomerGroup>

removeCustomersFromGroup

method(ctx: RequestContext, input: MutationRemoveCustomersFromGroupArgs) => Promise<CustomerGroup>
Was this chapter helpful?
Report Issue
Edited Feb 25, 2026ยทEdit this page