25 January 2022
Product catalogProject configurationMessages/SubscriptionsGraphQL
Product Selections let you model the availability of your products in different sales channels. Depending on your use case and by leveraging the existing Stores functionality you can create individual catalogs or assortments for your brand sites, regional shops or brick-and-mortar stores.
Currently, the feature allows you to create Product Selections, populate them with Products, add them to any of your Stores and activate them independently for each Store. We also introduced a new endpoint that returns a Product Projection available in a given Store's active Product Selections.
Please note that the focus of this first release lies in scenarios where assortment management happens in a commercetools-external product information management (PIM) system and a commercetools-external search provider is used for product discovery in the shop frontend. As a consequence, you currently can’t filter your search results by Product Selections or Stores in both, Product Projections and the Merchant Center Product list. We plan to close these gaps progressively and add more functionality to Product Selections during the public beta phase.
Read more on Product Selections and how to use them in the API reference.
Read more on how to integrate with an external search service providing product discovery for your Store-specific shop frontends in this guide.
Furthermore, you can now subscribe to Messages triggered when Product Selections are created, deleted, or updated or when the Store's Product Selections have changed.
Changes:
- [API] Added the 
view_product_selectionsandmanage_product_selectionsOAuth scopes. - [API] Added ProductSelections.
 - [API] Added query on Product Selections for a Product.
 - [API] Added Get ProductProjection in Store by ID or by Key.
 - [API] Added ProductSelectionCreated and ProductSelectionDeleted Message.
 - [API] Added ProductSelectionProductAdded and ProductSelectionProductRemoved Message.
 - [API] Added StoreProductSelectionsChanged Message.
 - [GraphQL API] Added the following types to the GraphQL schema: 
AddProductSelectionProduct,AddStoreProductSelection,ChangeProductSelectionName,ChangeStoreProductSelectionActive,CreateProductSelectionDraft,IndividualProductSelectionCreatedPayload,ProductAssignment,ProductAssignmentQueryResult,ProductOfSelection,ProductOfSelectionQueryResult,ProductSelection,ProductSelectionCreated,ProductSelectionCreatedPayload,ProductSelectionDeleted,ProductSelectionProductAdded,ProductSelectionProductRemoved,ProductSelectionQueryInterface,ProductSelectionQueryResult,ProductSelectionSetting,ProductSelectionSettingDraft,ProductSelectionSettingInActionInput,ProductSelectionUpdateAction,RemoveProductSelectionProduct,RemoveStoreProductSelection,SelectionOfProduct,SelectionOfProductQueryResult,SetProductSelectionKey,SetStoreProductSelections,StoreProductSelectionsChanged. - [GraphQL API] Changed the 
CreateStoretype:- Input field 
productSelectionswas added toCreateStoretype 
 - Input field 
 - [GraphQL API] Changed the 
Querytype:- Added the 
productSelectionsfield to theQuerytype. Query.inStoresdescription is changedQueryobject type now implementsProductSelectionQueryInterfaceinterface- Added the 
productSelectionAssignmentsfield to theQuerytype. - Added the 
productSelectionfield to theQuerytype. Query.inStoredescription is changed
 - Added the 
 - [GraphQL API] Changed the 
Mutationtype:- Added the 
updateProductSelectionfield to theMutationtype. - Added the 
deleteProductSelectionfield to theMutationtype. - Added the 
createProductSelectionfield to theMutationtype. 
 - Added the 
 - [GraphQL API] Changed the 
Producttype:- Added the 
productSelectionRefsfield to theProducttype. 
 - Added the 
 - [GraphQL API] Changed the 
StoreCreatedtype:- Added the 
productSelectionsfield to theStoreCreatedtype. - Added the 
productSelectionsReffield to theStoreCreatedtype. 
 - Added the 
 - [GraphQL API] Changed the 
Storetype:- Added the 
productSelectionsfield to theStoretype. 
 - Added the 
 - [GraphQL API] Changed the 
StoreUpdateActiontype:- Input field 
changeProductSelectionActivewas added toStoreUpdateActiontype - Input field 
setProductSelectionswas added toStoreUpdateActiontype - Input field 
addProductSelectionwas added toStoreUpdateActiontype - Input field 
removeProductSelectionwas added toStoreUpdateActiontype 
 - Input field 
 - [GraphQL API] Changed the 
InStoretype:- Added the 
productfield to theInStoretype. - Added the 
productSelectionAssignmentsfield to theInStoretype. 
 - Added the 
 
The following changes were introduced in terms of GraphQL SDL:
extend type InStore {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  product(
    "Queries for a product with specified SKU"
    sku: String,
    "Queries for a product with specified [product variant key](https://docs.commercetools.com/api/projects/products#variant_key)"
    variantKey: String,
    "Queries with specified ID"
    id: String,
    "Queries with specified key"
    key: String): Product
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelectionAssignments(where: String, sort: [String!], limit: Int, offset: Int): ProductAssignmentQueryResult!
}
extend type Query {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelection(
    "Queries with specified ID"
    id: String,
    "Queries with specified key"
    key: String): ProductSelection
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelectionAssignments(where: String, sort: [String!], limit: Int, offset: Int): ProductAssignmentQueryResult!
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelections(where: String, sort: [String!], limit: Int, offset: Int): ProductSelectionQueryResult!
}
extend type Mutation {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  createProductSelection(
    "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
    draft: CreateProductSelectionDraft!): ProductSelection
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  deleteProductSelection(version: Long!,
    "Queries with specified ID"
    id: String,
    "Queries with specified key"
    key: String): ProductSelection
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  updateProductSelection(version: Long!,
    "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
    actions: [ProductSelectionUpdateAction!]!,
    "Queries with specified ID"
    id: String,
    "Queries with specified key"
    key: String): ProductSelection
}
extend type Product {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelectionRefs(where: String, sort: [String!], limit: Int, offset: Int): SelectionOfProductQueryResult!
}
extend type StoreCreated {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelections: [ProductSelectionSetting!]!
}
extend type Store {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelections: [ProductSelectionSetting!]!
}
extend input StoreUpdateAction {
  addProductSelection: AddStoreProductSelection
  changeProductSelectionActive: ChangeStoreProductSelectionActive
  removeProductSelection: RemoveStoreProductSelection
  setProductSelections: SetStoreProductSelections
}
extend input CreateStore {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelections: [ProductSelectionSettingDraft!]
}
input AddProductSelectionProduct {
  product: ResourceIdentifierInput!
}
input AddStoreProductSelection {
  productSelection: ResourceIdentifierInput!
  active: Boolean
}
input ChangeProductSelectionName {
  name: [LocalizedStringItemInputType!]!
}
input ChangeStoreProductSelectionActive {
  productSelection: ResourceIdentifierInput!
  active: Boolean!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
input CreateProductSelectionDraft {
  key: String
  name: [LocalizedStringItemInputType!]!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type IndividualProductSelectionCreatedPayload implements ProductSelectionCreatedPayload {
  name(
    "String is defined for different locales. This argument specifies the desired locale."
    locale: Locale,
    "List of languages the client is able to understand, and which locale variant is preferred."
    acceptLanguage: [Locale!]): String
  nameAllLocales: [LocalizedString!]!
  type: String!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductAssignment {
  productRef: Reference!
  product: Product
  productSelectionRef: Reference!
  productSelection: ProductSelection
}
type ProductAssignmentQueryResult {
  offset: Int!
  count: Int!
  total: Long!
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  exists: Boolean!
  results: [ProductAssignment!]!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductOfSelection {
  productRef: Reference!
  product: Product
}
type ProductOfSelectionQueryResult {
  offset: Int!
  count: Int!
  total: Long!
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  exists: Boolean!
  results: [ProductOfSelection!]!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductSelection implements Versioned {
  key: String
  name(
    "String is defined for different locales. This argument specifies the desired locale."
    locale: Locale,
    "List of languages the client is able to understand, and which locale variant is preferred."
    acceptLanguage: [Locale!]): String
  nameAllLocales: [LocalizedString!]!
  productRefs(where: String, sort: [String!], limit: Int, offset: Int): ProductOfSelectionQueryResult!
  productCount: Int!
  id: String!
  version: Long!
  createdAt: DateTime!
  lastModifiedAt: DateTime!
  createdBy: Initiator
  lastModifiedBy: Initiator
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductSelectionCreated implements MessagePayload {
  productSelection: ProductSelectionCreatedPayload!
  type: String!
}
interface ProductSelectionCreatedPayload {
  name(
    "String is defined for different locales. This argument specifies the desired locale."
    locale: Locale,
    "List of languages the client is able to understand, and which locale variant is preferred."
    acceptLanguage: [Locale!]): String
  nameAllLocales: [LocalizedString!]!
  type: String!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductSelectionDeleted implements MessagePayload {
  type: String!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductSelectionProductAdded implements MessagePayload {
  product: Product
  productRef: Reference!
  type: String!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductSelectionProductRemoved implements MessagePayload {
  product: Product
  productRef: Reference!
  type: String!
}
"Fields to access product selection assignments. BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
interface ProductSelectionQueryInterface {
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  productSelectionAssignments(where: String, sort: [String!], limit: Int, offset: Int): ProductAssignmentQueryResult!
}
type ProductSelectionQueryResult {
  offset: Int!
  count: Int!
  total: Long!
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  exists: Boolean!
  results: [ProductSelection!]!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type ProductSelectionSetting {
  productSelectionRef: Reference!
  productSelection: ProductSelection
  active: Boolean!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
input ProductSelectionSettingDraft {
  productSelection: ResourceIdentifierInput!
  active: Boolean!
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
input ProductSelectionSettingInActionInput {
  productSelection: ResourceIdentifierInput!
  active: Boolean
}
input ProductSelectionUpdateAction {
  addProduct: AddProductSelectionProduct
  changeName: ChangeProductSelectionName
  removeProduct: RemoveProductSelectionProduct
  setKey: SetProductSelectionKey
}
input RemoveProductSelectionProduct {
  product: ResourceIdentifierInput!
}
input RemoveStoreProductSelection {
  productSelection: ResourceIdentifierInput!
}
type SelectionOfProduct {
  productSelectionRef: Reference!
  productSelection: ProductSelection
}
type SelectionOfProductQueryResult {
  offset: Int!
  count: Int!
  total: Long!
  "BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
  exists: Boolean!
  results: [SelectionOfProduct!]!
}
input SetProductSelectionKey {
  key: String
}
input SetStoreProductSelections {
  productSelections: [ProductSelectionSettingInActionInput!]
}
"BETA: This feature can be subject to change and should be used carefully in production. https://docs.commercetools.com/api/contract#public-beta"
type StoreProductSelectionsChanged implements MessagePayload {
  addedProductSelections: [ProductSelectionSetting!]
  removedProductSelections: [ProductSelectionSetting!]
  updatedProductSelections: [ProductSelectionSetting!]
  type: String!
}