12 March 2025
Composable Commerce
HTTP API
Enhancement
B2BCustomersCartsGraphQL

You can now link a Shopping List to a Business Unit. Additionally, you can define permissions related to Shopping List for Associates assigned to the Business Unit and validate them using the new Associate Shopping Lists endpoints. This enhancement helps you, as merchants, to build flows that allows your B2B customers to create and collaborate on shopping lists.

This feature is only available as part of Composable Commerce for B2B and will be subject to additional terms and pricing. To get access to Composable Commerce for B2B, contact the Composable Commerce support team.

Changes:

  • [API] Added businessUnit field to ShoppingList and ShoppingListDraft.
  • [API] Added the Set Business Unit update action to the Shopping Lists API.
  • [API] Added Associate Shopping Lists endpoints.
  • [API] Added Shopping List Permissions.
  • [GraphQL API] Added the businessUnit and businessUnitRef input fields to the ShoppingList type.
  • [GraphQL API] Added the businessUnit input field to the ShoppingListDraft type.
  • [GraphQL API] Added the setBusinessUnit input field to the ShoppingListUpdateAction type.
  • [GraphQL API] Added the SetShoppingListBusinessUnit type to the GraphQL schema.
  • [GraphQL API] Added the shoppingList and shoppingLists fields to the AsAssociate type.
  • [GraphQL API] AsAssociate object type now implements ShoppingListQueryInterface interface.
  • [GraphQL API] Added the asAssociate argument to the Mutation.createShoppingList field.
  • [GraphQL API] Added the asAssociate argument to the Mutation.updateShoppingList field.
  • [GraphQL API] Added the asAssociate argument to the Mutation.deleteShoppingList field.
  • [GraphQL API] Added the CreateMyShoppingLists, CreateOthersShoppingLists, DeleteMyShoppingLists, DeleteOthersShoppingLists, UpdateMyShoppingLists, UpdateOthersShoppingLists, ViewMyShoppingLists, and ViewOthersShoppingLists enum values to the Permission enum.

The following changes were introduced in terms of GraphQL SDL:

extend type AsAssociate {
  shoppingList(
    "Queries with specified ID"
    id: String

    "Queries with specified key"
    key: String
  ): ShoppingList
  shoppingLists(
    where: String
    sort: [String!]
    limit: Int
    offset: Int
  ): ShoppingListQueryResult!
}

extend enum Permission {
  CreateMyShoppingLists
  CreateOthersShoppingLists
  DeleteMyShoppingLists
  DeleteOthersShoppingLists
  UpdateMyShoppingLists
  UpdateOthersShoppingLists
  ViewMyShoppingLists
  ViewOthersShoppingLists
}

input SetShoppingListBusinessUnit {
  businessUnit: ResourceIdentifierInput!
}

extend type ShoppingList {
  businessUnit: BusinessUnit
  businessUnitRef: KeyReference
}

extend input ShoppingListDraft {
  businessUnit: ResourceIdentifierInput
}

extend input ShoppingListUpdateAction {
  setBusinessUnit: SetShoppingListBusinessUnit
}