Valid B2B-Commerce-Developer Exam Dumps Ensure you a HIGH SCORE (2026)
Pass B2B-Commerce-Developer Exam with Latest Questions
Salesforce B2B-Commerce-Developer certification exam is designed for professionals who want to demonstrate their skills and knowledge in developing B2B commerce solutions on the Salesforce platform. Salesforce Accredited B2B Commerce Developer certification exam is for those who have experience in developing, implementing, and managing B2B commerce solutions using Salesforce B2B Commerce Cloud.
NEW QUESTION # 93
Which two guidelines should a developer consider when migrating aura components to LWC?
- A. Start with simple components that only render Ul
- B. Start with migrating trees of components (components within components)
- C. Migrate one component and then determine whether additional effort would make sense
- D. Force all developers to write any new components using Lightning web components
Answer: A,C
Explanation:
When migrating aura components to LWC, a developer should consider two guidelines: migrate one component and then determine whether additional effort would make sense and start with simple components that only render UI. Migrating one component and then determining whether additional effort would make sense allows the developer to evaluate the benefits and costs of migration and decide whether to continue or stop. Migrating simple components that only render UI allows the developer to leverage the performance and modern features of LWC without much complexity or dependency on other components or services. Starting with migrating trees of components (components within components) is not a good guideline, as it can introduce more challenges and dependencies that can complicate the migration process. Forcing all developers to write any new components using Lightning web components is not a good guideline either, as it can create inconsistency and confusion among developers and users. Salesforce References: [Lightning Web Components Developer Guide: Migrate Aura Components to Lightning Web Components], [Lightning Web Components Developer Guide: Migration Considerations]
NEW QUESTION # 94
A developer is on a tight timeline and needs to implement a Lightning web component which can read, create and modify single records. What is the recommended path forward?
- A. Use base components
- B. Use Lightning Data Service
- C. Create an Apex Controller
- D. Write custom functions against a wire adapter
Answer: B
Explanation:
To implement a Lightning web component which can read, create and modify single records, the recommended path forward is to use Lightning Data Service. Lightning Data Service is a service that provides access to Salesforce data and metadata, cache management, and data synchronization across components.
Lightning Data Service allows developers to use standard components or base componentsto perform CRUD (create, read, update, delete) operations on single records without writing Apex code or SOQL queries.
Lightning Data Service also handles data caching, performance optimization, and conflict resolution automatically. Using base components is not a sufficient way to implement a Lightning web component which can read, create and modify single records, as base components are only user interface elements that do not provide data access or manipulation functionality by themselves. Base components need to be used with Lightning Data Service or other services to perform CRUD operations on single records. Writing custom functions against a wire adapter is not a recommended way to implement a Lightning web component which can read, create and modify single records, as it involves writing complex and error-prone JavaScript code that may not be efficient or scalable. Writing custom functions against a wire adapter also requires handling data caching, performance optimization, and conflict resolution manually. Creating an Apex controller is not a recommended way either, as it involves writing Apex code that may not be necessary or optimal for performing CRUD operations on single records. Creating an Apex controller also requires exposing Apex methods using @AuraEnabled or @RemoteAction annotations and invoking them from JavaScript code using imperative calls or promises. Salesforce References: Lightning Web Components Developer Guide: Access Salesforce Data, Lightning Web Components Developer Guide: Base Components, [Lightning Web Components Developer Guide: Call Apex Methods]
NEW QUESTION # 95
Which tool is used to retrieve and manipulate Salesforce data in a Lightning Web Component?
- A. Wire adapters
- B. Aura requests
- C. Proxy adapters
- D. XHR requests
Answer: A
Explanation:
In Lightning Web Components, wire adapters are used to retrieve and manipulate Salesforce data. Wire adapters abstract the underlying data access mechanism, providing a declarative way to access Salesforce data and metadata. Salesforce documentation on LWC and the@wiredecorator details how wire adapters can be used to connect components to Salesforce data sources, including standard and custom objects, facilitating reactive data binding and efficient data retrieval.
NEW QUESTION # 96
Which cart item type is created with the Cart Delivery Group Method after the shipping integration?
- A. Shipping
- B. Delivery
- C. Surcharge
- D. Charge
Answer: D
Explanation:
A cart item with a type of Charge is created with the Cart Delivery Group Method after the shipping integration. A shipping integration is an integration that calculates and applies shipping costs and options to a cart or an order based on various factors, such as product weight, dimensions, quantity, location, and carrier service level. A shipping integration can use either an external shipping service provider or custom Apex code to perform the shipping calculation. The Cart Delivery Group Method is a method that determines how products are grouped into delivery groups based on their shipping methods and addresses. A delivery group is a logical grouping of products that are shipped together using the same shipping method and address. After performing the shipping calculation for each delivery group, the shipping integration creates a cart item with a type of Charge and a charge type of Shipping for each delivery group. These cart items represent the shipping costs and options that are applied to each delivery group. A cart item with a type of Surcharge, Shipping, or Delivery does not exist or is not related to the shipping integration. Salesforce References: [B2B Commerce Developer Guide: Shipping Integration], [B2B Commerce Developer Guide: Cart Delivery Group Method]
NEW QUESTION # 97
What are two considerations to keep in mind when including additional JavaScript files in a Lightning web component?
- A. Additional JavaScript files should be minified before deployment
- B. A module can export named functions or variables
- C. Each additional file needs a corresponding .js-meta.xml file.
- D. The files must be ES6 modules and must have names that are unique within the component's folder.
Answer: B,D
Explanation:
When including additional JavaScript files in a Lightning web component, a developer should keep in mind two considerations: the files must be ES6 modules and must have names that are unique within the component's folder and a module can export named functions or variables. The files must be ES6 modules because LWC uses ES6 modules as the standard for modular JavaScript code. The files must have names that are unique within the component's folder because LWC uses the file name as the module identifier and does not allow duplicate identifiers. A module can export named functions or variables because LWC supports named exports, which allow a module to export multiple values with different names. Each additional file does not need a corresponding .js-meta.xml file, as this is only required for the main JavaScript file of the component. Additional JavaScript files should not be minified before deployment, as this is not necessary or recommended for LWC. Salesforce Reference: [Lightning Web Components Developer Guide: Include JavaScript Files], [Lightning Web Components Developer Guide: ES6 Modules]
NEW QUESTION # 98
What are three advantages of using ccLog over the Salesforce
standard System.debug class? (3 answers)
- A. There is no need to manually set a cookie to debug with the Site Guest User.
- B. Append #ccLog=<Logging Token Name> to the end of the storefront URL in order to get logs in the inspector console.
- C. There is no need to use string concatenation to easily tag log statements with a subject.
- D. ccLog can debug syntax errors found in the JavaScript.
- E. There is no need to create a User Trace Flag.
Answer: A,B,C
Explanation:
Three advantages of using ccLog over the Salesforce standard System.debug class are:
There is no need to use string concatenation to easily tag log statements with a subject. ccLog allows passing a subject parameter to the log method, which will prepend the subject to the log message. For example, ccLog.log('This is a message', 'Subject') will log [Subject] This is a message.
There is no need to create a User Trace Flag. ccLog can be enabled by setting the value of CO.logToken to true in CCAdmin, which will activate logging for all users who access the storefront.
There is no need to manually set a cookie to debug with the Site Guest User. ccLog can be enabled for the Site Guest User by appending #ccLog=<Logging Token Name> to the end of the storefront URL in order to get logs in the inspector console. For example, https://my-storefront.com/#ccLog=debug will enable logging for the Site Guest User with the debug level. Salesforce Reference: B2B Commerce and D2C Commerce Developer Guide, Logging
NEW QUESTION # 99
A developer has created a custom Lightning web component for the Cart page that needs to react to changes to cart items from the standard cart component.
How should the developer implement the custom component so changes to cart items and quantities are reflected?
- A. Add a listener for the cartltemUpdate Lightning event.
- B. Subscribe to events on the lightning_commerce_cartChanged channel using the Lightning Message Service.
- C. Add an event listener for the cartchanged DOM (Document Object Model) event.
- D. Listen for events on the lightning_commerce_cartChanged channel with the Lightning Event
"Listener component.
Answer: B
Explanation:
The developer should implement the custom component so that it subscribes to events on the lightning_commerce_cartChanged channel using the Lightning Message Service. This is the recommended way to communicate between custom and standard components on the Cart page, as it allows the custom component to receive updates from the standard cart component whenever the cart items or quantities change.
The Lightning Message Service is a pub/sub mechanism that enables components to communicate across the DOM, regardless of their namespace, technology, or source. The lightning_commerce_cartChanged channel is a predefined channel that carries information about the cart state, such as the cart ID, the cart items, and the cart total. References: Custom Component APIs, Lightning Message Service, Communicate Across the DOM with Lightning Message Service Learn more
1blob:https://www.bing.com/fd286638-e14b-486c-81e8-e8c4e8cdf7c0developer.salesforce.com2blob:https://ww
NEW QUESTION # 100
A developer has made some changes to the products of an existing storefront, but they are unable to see the changes in the products from the store.
Which action did the developer forget to take?
- A. Activate the product list.
- B. Publish the storefront.
- C. Rebuild the search index.
- D. Publish the catalog
Answer: B
Explanation:
Explanation
The developer forgot to publish the storefront after making changes to the products. Publishing the storefront is a necessary step to make the changes visible to the store visitors. Publishing the storefront updates the site's metadata and content, and also triggers the site index and search index rebuilds. If the developer does not publish the storefront, the changes will not be reflected on the live site.
The following actions are not required or relevant for the scenario:
* Activate the product list. This action is only needed when creating a new product list or modifying an existing one. It does not affect the visibility of the products on the storefront.
* Rebuild the search index. This action is automatically performed when the developer publishes the storefront. It is not a separate step that the developer needs to take manually.
* Publish the catalog. This action is not applicable for Salesforce B2B Commerce for Visualforce, which does not use catalogs. Catalogs are only used by Salesforce B2B Commerce for Lightning Experience.
References:
* Finalize and Publish Your Storefront
* Customize the D2C Store Template
* Configure Public Pages for a Storefront
NEW QUESTION # 101
Which two behaviors does a target value of lightning__FlowScreen in metadata allow for a Lightning web component?
- A. It allows the Lightning Web component to be dragged onto a page in Lightning AppBuilder
- B. It automatically generates configuration properties for the Lightning web component
- C. It allows the Lightning web component to be used in guided user experiences to gather input
- D. It allows the Lightning web component to replace standard functionality in flows and subflows
Answer: B,C
Explanation:
A target value of lightning__FlowScreen in metadata allows for a Lightning web component to be used in guided user experiences to gather input and to automatically generate configuration properties for the Lightning web component. The lightning__FlowScreen target value specifies that the component can be used on a flow screen, which is a type of flow element that displays information and collects user input in a flow. A flow is a guided user experience that can automate business processes and guide users through screens, actions, and decisions. By using the lightning__FlowScreen target value, the developer can expose their Lightning web component as a custom screen component that can be added to any flow screen. The developer can also use the @api decorator to expose public properties of their Lightning web component as configuration properties that can be set in Flow Builder. Flow Builder is a tool that allows the developer to create and modify flows using a drag-and-drop interface. A target value of lightning__FlowScreen does not allow the Lightning web component to replace standard functionality in flows and subflows or to be dragged onto a page in Lightning App Builder, as these are not related to the flow screen target value. Salesforce Reference: Lightning Web Components Developer Guide: Configure Components for Flows, Lightning Web Components Developer Guide: Communicate with Flow, Lightning Flow Developer Guide: Screen Components Basics
NEW QUESTION # 102
A developer needs to create an event listener on a parent component programmaticallv. With the script below, what should replace the text <EVENT LISTENER UNE>?
- A. this.template.addEventListener(this.handleNotification);
- B. this.template.addEventListener(handleNotification);
- C. this.template.addEventListenerCnotification1, this.handleNotification);
- D. addEventListener('notifJcatiorV, this.handleNotification);
Answer: C
Explanation:
Explanation
To create an event listener on a parent component programmatically, the developer should use the following line of code:
this.template.addEventListener('notification', this.handleNotification); This line of code adds an event listener to the template element of the parent component, which is the root element that contains all the child elements. The event listener listens for an event named 'notification', which is a custom event that can be dispatched by any child component. The event listener invokes a method named handleNotification, which is an arrow function defined in the parent component class. The handleNotification method receives the event object as a parameter and can perform any logic based on the event data. The other lines of code are either incorrect or incomplete. Salesforce References: Lightning Web Components Developer Guide: Communicate with Events, Lightning Web Components Developer Guide: Create and Dispatch Events
NEW QUESTION # 103
What is true about mapping custom fields from Cart to Order Summary?
- A. A custom field must exist in the Cart and Order Summary objects only to be mapped successfully.
- B. The automatic Cart to Order mapping of custom fields can be disabled.
- C. There is a limit of 25 custom fields on a Cart that can be mapped to Order.
- D. All data types are supported for custom fields to be mapped from Cart to Order.
Answer: B
Explanation:
The correct answer for what is true about mapping custom fields from Cart to Order Summary is that the automatic Cart to Order mapping of custom fields can be disabled. A custom field is a field that is added by a developer or an administrator to an object to store additional information or data. A Cart is an object that represents a collection of products and charges that a customer intends to purchase in the storefront. An Order Summary is an object that represents a confirmed purchase of products and charges by a customer in the storefront. A Cart can be converted to an Order Summary when the customer completes the checkout process and confirms their order. By default, Salesforce B2B Commerce automatically maps custom fields from Cart to Order Summary when converting a Cart to an Order Summary. This means that any custom fields that exist on both Cart and Order Summary objects with identical API names and data types will have their values copied from Cart to Order Summary during the conversion. The automatic Cart to Order mapping of custom fields can be disabled by setting the B2BCommerce.CartToOrderMappingEnabled custom setting to false. This will prevent any custom fields from being copied from Cart to Order Summary during the conversion. A custom field must exist in the Cart and Order Summary objects only to be mapped successfully is not true, as it is not the only requirement for mapping custom fields from Cart to Order Summary. The custom fields must also have identical API names and data types, and the automatic Cart to Order mapping of custom fields must be enabled. All data types are supported for custom fields to be mapped from Cart to Order is not true, as some data types are not supported for mapping custom fields from Cart to Order Summary. The supported data types are Boolean, Date, DateTime, Double, Integer, Long, Percent, String, and TextArea. There is a limit of 25 custom fields on a Cart that can be mapped to Order is not true, as there is no such limit for mapping custom fields from Cart to Order Summary. Any number of custom fields that meet the mapping requirements can be mapped from Cart to Order Summary. Salesforce Reference: [B2B Commerce Developer Guide: Custom Field Mapping], [B2B Commerce Developer Guide: Cart Object], [B2B Commerce Developer Guide: Order Summary Object]
NEW QUESTION # 104
What are two considerations to keep in mind when including additional JavaScript files in a Lightning web component?
- A. Additional JavaScript files should be minified before deployment
- B. A module can export named functions or variables
- C. Each additional file needs a corresponding .js-meta.xml file.
- D. The files must be ES6 modules and must have names that are unique within the component's folder.
Answer: B,D
Explanation:
When including additional JavaScript files in a Lightning web component, a developer should keep in mind two considerations: the files must be ES6 modules and must have names that are unique within the component's folder and a module can export named functions or variables. The files must be ES6 modules because LWC uses ES6 modules as the standard for modular JavaScript code. The files must have names that are unique within the component's folder because LWC uses the file name as the module identifier and does not allow duplicate identifiers. A module can export named functions or variables because LWC supports named exports, which allow a module to export multiple values with different names. Each additional file does not need a corresponding .js-meta.xml file, as this is only required for the main JavaScript file of the component. Additional JavaScript files should not be minified before deployment, asthis is not necessary or recommended for LWC. Salesforce References: [Lightning Web Components Developer Guide: Include JavaScript Files], [Lightning Web Components Developer Guide: ES6 Modules]
NEW QUESTION # 105
Which event is invoked by any CCRZ Salesforce B2B CommeceView after the view is rendered?
- A. view:*:load
- B. view:*:refresh
- C. view:*:rendered
- D. view:*:onload
Answer: C
Explanation:
The event that is invoked by any CCRZ Salesforce B2B Commerce View after the view is rendered is view:*:rendered. This event is triggered by the render method of the CCRZ.View class, which is the base class for all views in the framework. The event can be used to perform any actions or logic that depend on the view being rendered, such as initializing widgets, binding events, or updating the user interface. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Events, View Class
NEW QUESTION # 106
A query containing a subquery is executed. What is appended to the subquery name as part of its transformation by default in Salesforce B2B Commerce?
- A. "__ccrz"
- B. A subscriber-supplied token
- C. The letter "S"
- D. The "*" symbol
Answer: C
NEW QUESTION # 107
Which three pages should be enabled for the Guest user profile for a storefront to have anonymous checkout?
(3 answers)
- A. Checkout
- B. OrderView
- C. OrderConfirmation
- D. CheckoutNew
- E. CCPaymentInfo
Answer: C,D,E
NEW QUESTION # 108
Which two statement are true for Mass Order (2 answers)
- A. Mass Order pricing is done via a batch job.
- B. Mass order works with thedefault wishlists
- C. The variation product is leveraged for SKUs.
- D. Mass Order is mobile ready with the ccrz templates.
Answer: A,C
Explanation:
Mass Order pricing is done via a batch job, which means that the prices are not calculated in real time, but rather at a scheduled time. Mass order works with the variation product, which is a product that has multiple SKUs with different attributes, such as size or color. Mass order does not work with the default wishlists, which are used to store products that the customer wants to buy later. Mass order is not mobile ready with the ccrz templates, which are the default templates for the storefront pages. Salesforce Reference: B2B Commerce Developer Guide: Mass Order, B2B Commerce Developer Guide: Variation Products
NEW QUESTION # 109
A developer is trying to integrate a new shipping provider to use during checkout in a storefront Which two steps must the developer take to make an integration available for selection?
- A. Create an Apex class that uses the integration framework.
- B. Modify the StorelntegratedService to map to an Apex class ID using Workbench.
- C. Enter the integration class name and version in the store administration.
- D. Create a RegisteredExternalService record using Workbench.
Answer: A,D
Explanation:
To make an integration available for selection, a developer must create a RegisteredExternalService record using Workbench and create an Apex class that uses the integration framework. Creating a RegisteredExternalService record using Workbench allows the developer to register their custom integration class as an external service in Salesforce B2B Commerce. The RegisteredExternalService record contains information such as the class name, version, display name, description, and category of the integration class.
The category determines where and how the integration class can be used in B2B Commerce, such as ShippingService or TaxService. Creating an Apex class that uses the integration framework allows the developer to define custom logic for integrating with an external service provider's API or service. The integration framework provides interfaces and classes for various types of integrations, such as shipping, tax, payment, inventory, and freight. The developer can implement these interfaces and classes in their custom Apex class and override their methods with their own logic. Modifying the StoreIntegratedService to map to an Apex class ID using Workbench is not a required step for making an integration available for selection, as it is only used for registering internal services that are provided by Salesforce B2B Commerce out-of-the-box.
Entering the integration class name and version in store administration is not a required step either, as it is only used for selecting an existing integration class that has already been registered as an external service.
Salesforce References: [B2B Commerce Developer Guide: Integration Framework], [B2B Commerce Developer Guide: RegisteredExternalService Object]
NEW QUESTION # 110
Which two aspects are applicable to Page Includes? (2 answers)
- A. Page Includes must be assigned to an OOTB Page, i.e. Home, Product Detail, etc., and enabled
- B. Standard Visualforce controls such as apex:form should not be used within a page include
- C. If a controller is used for an included page, then a merge variable must be present on the page.
- D. Page Includes can be configured as Body Includes Begin.
Answer: B,D
Explanation:
Two aspects that are applicable to Page Includes are:
Standard Visualforce controls such as apex:form should not be used within a page include. This is because the page include is rendered inside an existing Visualforce page that already has a form element. Using another form element inside the page include will cause conflicts and errors. Instead, the page include should use HTML elements or custom components that do not require a form element.
Page Includes can be configured as Body Includes Begin. This means that the page include will be rendered at the beginning of the body section of the page, before any other content or widgets. This can be useful for adding some custom content or functionality that applies to the whole page, such as a banner, a modal, or a script. Salesforce Reference: B2B Commerce and D2C Commerce Developer Guide, Page Includes
NEW QUESTION # 111
In checkout, what event should the developer's code listen for in order to help troubleshoot and respond to actions?
- A. CommerceDiagnosticEvents
- B. CommerceErrorEvents
- C. CommerceBubbleEvents
- D. CommerceActionEvents
Answer: A
Explanation:
To help troubleshoot and respond to actions in checkout, the developer's code should listen for CommerceDiagnosticEvents. CommerceDiagnosticEvents is an event that is fired by Salesforce B2B Commerce when an error occurs in the storefront. CommerceDiagnosticEvents contains information about the error, such as error code, error message, error type, and error details. CommerceDiagnosticEvents can be subscribed by other components or services that want to handle or display the error information in different ways. The developer's code can listen for CommerceDiagnosticEvents using an aura:handler tag in Aura Components or an @wire decorator in Lightning web components. The developer's code can also use the event information to perform custom logic or actions based on the error, such as logging, reporting, or notifying. CommerceBubbleEvents is not an event that the developer's code should listen for in checkout, as it is not related to troubleshooting or responding to actions. CommerceBubbleEvents is an event that is fired by Salesforce B2B Commerce when a user interacts with a bubble component in the storefront. A bubble component is a user interface element that displays information or options in a pop-up window when clicked or hovered over. CommerceBubbleEvents contains information about the user interaction, such as bubble name, bubble type, and bubble value. CommerceErrorEvents is not an event that the developer's code should listen for in checkout either, as it is not related to troubleshooting or responding to actions.
CommerceErrorEvents is an event that is fired by Salesforce B2B Commerce when a validation error occurs in the storefront. CommerceErrorEvents contains information about the validation error, such as field name, field label, and error message. CommerceActionEvents is not an event that the developer's code should listen for in checkout either, as it is not related to troubleshooting or responding to actions. CommerceActionEvents is an event that is fired by Salesforce B2B Commerce when a user performs an action in the storefront.
CommerceActionEvents contains information about the user action, such as action name, action type, and action parameters. Salesforce References: B2B Commerce Developer Guide: Handle Errors, B2B Commerce Developer Guide: Handle User Interactions with Bubble Components, B2B Commerce Developer Guide:
Handle Validation Errors, B2B Commerce Developer Guide: Handle User Actions
NEW QUESTION # 112
Which three statements are true regarding event handling in the Salesforce B2B Commerce managed package?
(3 answers)
- A. Salesforce B2B Commerce relies on a central event channel for communication across various Salesforce B2B Commerce Backbone Views and Models called CCRZ.pubSub.
- B. CCRZ.pubSub defines the following three functions which can be used for event handling: trigger, on, and once.
- C. CCRZ.pubSub extends the Backbone.Events JavaScript object.
- D. Writing directly to your own custom Backbone JS Views and Models automatically integrates that data into the Salesforce B2B Commerce Backbone Views and Models.
- E. Salesforce B2B Commerce relies on a series of Javascript click listener events.
Answer: A,B,C
Explanation:
Three statements that are true regarding event handling in the Salesforce B2B Commerce managed package are:
* Salesforce B2B Commerce relies on a central event channel for communication across various Salesforce B2B Commerce Backbone Views and Models called CCRZ.pubSub. This object allows different components to publish or subscribe to events without being coupled with each other. For example, CCRZ.pubSub.trigger('cartChange') will publish an event named cartChange that can be subscribed by any component that needs to react to it.
* CCRZ.pubSub defines the following three functions which can be used for event handling: trigger, on, and once. The trigger function is used to publish an event with a name and optional arguments. The on function is used to subscribe to an event with a name and a callback function. The once function is similar to on, but it will only execute the callback function once for each event.
* CCRZ.pubSub extends the Backbone.Events JavaScript object. This object provides methods for managing events in Backbone.js, which is a JavaScript framework that provides models, views, collections, and events for building single-page applications. CCRZ.pubSub inherits all the methods and properties of Backbone.Events and adds some custom ones. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Events, PubSub Class
NEW QUESTION # 113
Numerous flags when set, have a direct impact on the result set provided by the Global API's. Which conversion flag allows for sObjects to be returned from the Global API's when provided as a Boolean parameter with a value of true?
- A. ccrz.ccAPISizing.SOBJECT
- B. ccrz.ccAPI.SZ_SOBJECT
- C. ccrz.ccAPISizing.SKIPTRZ
- D. ccrz.ccAPI.SZ_SKIPTRZ
Answer: D
NEW QUESTION # 114
When a user buys 10 units of product B, the user wants 1 unit of Product A to be automatically added to the cart. How can this requirement be fulfilled?
- A. Override the AllowCheckout method in ccrz.cc_api_CartExtension
- B. Override the prepareForSave method in ccrz.cc_api_CartExtension
- C. Override the prepareToAdd method in ccrz.cc_api_CartExtension
- D. Override the preprocess method in ccrz.cc_api_CartExtension
Answer: C
Explanation:
Explanation
To automatically add 1 unit of Product A to the cart when a user buys 10 units of Product B, the requirement can be fulfilled by overriding the prepareToAdd method in ccrz.cc_api_CartExtension. This method is responsible for preparing the cart line items before they are added to the cart. By overriding this method, the user can check the quantity and product ID of the cart line items and add an additional cart line item for Product A if the condition is met. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, API Classes, cc_api_CartExtension Class
NEW QUESTION # 115
Which two usages of ccLog should be avoided in Salesforce B2B Commerce? (2 answers)
- A. crz.ccLog.log(System.LoggingLevel.DEBUG, 'D:myOrderList', myOrderList), where myOrderList is a list of orders
- B. ccrz.ccLog.log(System.LoggingLevel.ERROR, 'D:something', myCallToGetMessage(pl) ), where myCallToGetMessage(pl) is a method invocation
- C. crz.ccLog.log(System.LoggingLevel.DEBUG, 'D:myOrder', myOrder), where myOrder is an order object
- D. crz.ccLog.log(System.LoggingLevel.WARN, 'D:something', 'Something unexpected occurred: The data we were expecting for pl was not there,')
Answer: B,D
NEW QUESTION # 116
A developer is building a custom component in Lightning web components (LWC) that needs to fetch data from an API.
Which lifecycle hook should the developer use to make the API call?
- A. renderedCallback
- B. errorCallback
- C. connectedCallback
- D. disconnectedCallback
Answer: C
Explanation:
To make an API call in a Lightning web component (LWC), a developer should use the connectedCallback lifecycle hook. The connectedCallback lifecycle hook is invoked when the component is inserted into the DOM. This is the ideal time to make an API call, as the component is ready to receive and display data. The developer can use the fetch API or a third-party library, such as axios, to make the API call and handle the response. The renderedCallback lifecycle hook is not a good choice for making an API call, as it is invoked every time the component is rendered or rerendered. This can cause unnecessary or repeated API calls and affect performance. The errorCallback lifecycle hook is not a good choice either, as it is invoked when an error occurs in the component or in one of its children. This is not related to making an API call, but rather to handling errors. The disconnectedCallback lifecycle hook is not a good choice either, as it is invoked when the component is removed from the DOM. This is not a suitable time to make an API call, as the component is no longer visible or active. Salesforce Reference: Lightning Web Components Developer Guide: Lifecycle Hooks, Lightning Web Components Developer Guide: Call an Apex Method Imperatively
NEW QUESTION # 117
......
Salesforce B2B-Commerce-Developer Certification Exam is an accreditation that is designed for individuals who wish to demonstrate their proficiency in developing and implementing solutions within the Salesforce B2B Commerce platform. Salesforce Accredited B2B Commerce Developer certification is ideal for developers who specialize in building B2B Commerce solutions and are looking to enhance their skills and knowledge in this field. Salesforce Accredited B2B Commerce Developer certification exam evaluates the candidate's understanding of the B2B Commerce platform, its features, and its capabilities.
Salesforce B2B-Commerce-Developer exam covers a range of topics related to Salesforce B2B Commerce, including product and catalog management, pricing and promotion configuration, order management, payment gateway integration, and custom development. Candidates are expected to have a thorough understanding of the B2B Commerce platform and be able to apply this knowledge to real-world scenarios.
B2B-Commerce-Developer Exam Practice Questions prepared by Salesforce Professionals: https://www.validbraindumps.com/B2B-Commerce-Developer-exam-prep.html
Use Valid New B2B-Commerce-Developer Questions - Top choice Help You Gain Success: https://drive.google.com/open?id=1f1emudoNPkzIpm6obaq930uIsKOrMJO5