Dynamically assign buyers to buyer groups for a B2B store by using a custom Apex logics. Review the considerations to understand the factors that influence how these assignments take place in your store.
Which Salesforce Commerce Product Do I Have?
- Considerations for Buyer Group Extension
As you turn on buyer group extension, keep these considerations in mind. - Dynamically Assign Buyer Groups by Using Apex Logics
Dynamically assign guest and authenticated buyers to buyer groups for a B2B store by using custom Apex logics. When buyers visit the store pages, the Apex logic adds them to a buyer group based on the defined criteria. Assigning buyers dynamically when they visit a storefront ensures timely, personalized shopping experiences including targeted product visibility, pricing, and promotions, without manual intervention. - Create a Shareable URL for Your Store
Customers can use a shareable URL to access your B2B store. The shareable URL contains a special URL parameter that's associated with a buyer group that has its own price book and discounts. Customers who get to the store using the shareable URL are automatically assigned to the associated buyer group, either in addition to the buyer group the customer is already part of or instead of that buyer group, depending on how your developer set up buyer group extensions.