
[May-2024] Salesforce B2B-Commerce-Developer Official Cert Guide PDF
Exam B2B-Commerce-Developer: Salesforce Accredited B2B Commerce Developer - TestkingPDF
NEW QUESTION # 105
What is likely to happen if a developer leaves debug mode turned on in an environment?
- A. The org will turn off debug mode after 72 hours
- B. A banner will be displayed to the user indicating that the org is in debug mode
- C. The performance of the org will become slower each day
- D. The user will begin getting JavaScript limit exceptions
Answer: B
Explanation:
If a developer leaves debug mode turned on in an environment, the user will begin getting JavaScript limit exceptions. Debug mode is a setting that enables more detailed logging and error reporting for Lightning web components. However, it also increases the size and complexity of the JavaScript code that is delivered to the browser, which can cause performance issues and JavaScript limit exceptions. The JavaScript limit exceptions are errors that occur when the browser reaches its maximum capacity for executing JavaScript code, such as memory heap size or script execution time. The performance of the org will not become slower each day, as debug mode only affects the client-side performance, not the server-side performance. The org will not turn off debug mode after 72 hours, as debug mode is a persistent setting that can only be changed manually by an administrator. A banner will not be displayed to the userindicating that the org is in debug mode, as debug mode is a transparent setting that does not affect the user interface. Salesforce References: Lightning Web Components Developer Guide: Debug Your Code, Lightning Web Components Developer Guide: JavaScript Limit Exceptions
NEW QUESTION # 106
What is default behavior for how theSalesforce B2B Commerce Global APIs transform Salesforce data?
- A. Fields names can be mapped to any naming convention desired
- B. Fields names are returned with a lowercase first letter,camelcase convention
- C. Fields names are returned with ;c." prepended in their name.
- D. Fields names are returned using the Salesforce naming convention.
Answer: B
Explanation:
The default behavior for how the Salesforce B2B Commerce Global APIs transform Salesforce data is to return field names with a lowercase first letter, camelcase convention. For example, the field name ccrz__E_Product__c in Salesforce will be transformed to eProduct in the API. This is done to follow the JavaScript naming convention and to avoid conflicts with the standard Salesforce fields and relationships. Salesforce Reference: B2B Commerce and D2C Commerce Developer Guide, Query Transformation
NEW QUESTION # 107
What is true regarding adding more Configuration Settings
to Salesforce B2B Commerce?
- A. Metadata can be added to existing modules, but you cannot add new modules.
- B. More modules and metadata can be added to Salesforce B2B Commerce.
- C. Select "New"in your storefront's Configuration Settings and create a custom setting.
- D. Configuration settings can only be extended through API's
Answer: B
Explanation:
Explanation
More modules and metadata can be added to Salesforce B2B Commerce by creating custom configuration settings. Configuration settings are custom settings that store various values and parameters that affect the functionality and appearance of the storefront. They are organized into modules, which group related settings together. To create a custom configuration setting, the user needs to create a custom setting record in Salesforce and specify its module, name, value, and description. The custom setting will then appear in CCAdmin under the specified module. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Configuration Settings
NEW QUESTION # 108
Which method is used to override when extending the Salesforce B2B Commerce logic providers?
- A. fetch
- B. process
- C. doLogic
- D. doAction
Answer: D
Explanation:
Explanation
The method that is used to override when extending the Salesforce B2B Commerce logic providers is doLogic.
This method is responsible for executing the business logic for each logic provider class, such as validating inputs, performing calculations, applying rules, or updating data. By overriding this method, the user can modify or extend the existing logic or add their own custom logic. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Logic Classes
NEW QUESTION # 109
Which two steps are necessary to enable Salesforce B2B Commerce
logging in the managed package?
- A. Set a cookie with the Id of the user accessing the storefront in CC Admin
- B. Ensure you save a value in the Logging Token input field in the Global Settings section of CC Admin.
- C. Ensure the value saved in the Logging token field is appended to the ccLog query parameter.
- D. Turn On the Checkbox "Cloudcraze Logging" in CC Admin.
Answer: B,C
NEW QUESTION # 110
Based on error emails flowing in, a developer suspects that recent edits made to a checkout flow have created a defect. The developer has data points available to use as inputs in reproducing the scenario.
What should the developer do next?
- A. Open the flow, select Debug, provide the Input values, and select Run.
- B. Open the flow, select Attach to Live Session, provide the session ID, and select Attach.
- C. Open the flow, select Debug, provide the session ID for replay, and select Run.
- D. Open the flow, select Debug with Inputs, provide the Input values, and select Run.
Answer: A
Explanation:
Explanation
The next step that the developer should do after suspecting that recent edits made to a checkout flow have created a defect and having data points available to use as inputs in reproducing the scenario is to open the flow, select Debug, provide the Input values, and select Run. A flow is a type of application that automates a business process by collecting data and performing actions in Salesforce or an external system. A flow can be used to customize the checkout process in the storefront by defining the steps and logic that are executed when a customer places an order. A flow can be edited or modified using Flow Builder, a point-and-click tool that allows developers to create and manage flows. Flow Builder also provides debugging and testing tools that allow developers to run and troubleshoot flows before deploying them. To debug or test a flow, the developer can open the flow in Flow Builder, select Debug from the toolbar, provide the Input values for the flow variables, and select Run. This will execute the flow in debug mode, which simulates how the flow runs in the org with real data. The developer can use debug mode to verify if the flow works as expected or if there are any errors or issues with the flow logic or actions. Open the flow, select Attach to Live Session, provide the session ID, and select Attach is not a valid next step, as it is not a feature or option available in Flow Builder or Salesforce CLI. Attach to Live Session is a feature that allows developers to attach a debugger to a running Apex session and inspect the state of the code execution. Open the flow, select Debug with Inputs, provide the Input values, and select Run is not a valid next step either, as it is not a feature or option available in Flow Builder or Salesforce CLI. Debug with Inputs is a feature that allows developers to debug an Apex class or trigger with predefined input values and breakpoints. Open the flow, select Debug, provide the session ID for replay, and select Run is not a valid next step either, as it is not a feature or option available in Flow Builder or Salesforce CLI. Replay is a feature that allows developers to replay an Apex log file and inspect the state of the code execution at each line. Salesforce References: [B2B Commerce Developer Guide: Customize Checkout Flows], [Salesforce Help: Flow Builder], [Salesforce Help: Debug Your Flows], [Salesforce Developer Blog: Apex Replay Debugger]
NEW QUESTION # 111
Northern Trail Outfitters (NTO) has a B2B Commerce store for its resellers. It has received many customer service calls involving questions about the delivery date of customer orders.
How should a developer expose delivery time estimates to NTO's customers in the storefront to reduce call volume?
- A. Add a Desired Delivery Date input field during the checkout flow.
- B. Configure an email alert to the customer when the Expected Delivery Date changes.
- C. Add the Expected Delivery Date field to the order confirmation email.
- D. Display the Expected Delivery Date on the order page with a Lightning web component.
Answer: D
Explanation:
Explanation
To expose delivery time estimates to NTO's customers in the storefront, a developer should display the Expected Delivery Date on the order page with a Lightning web component. The Expected Delivery Date is a custom field on the Order object that stores the date when the order is expected to be delivered to the customer. The developer can use the @wire decorator to get the current order object and use its properties, such as order number, status, total amount, and expected delivery date, to display them on the order page. The developer can also use Apex methods or third-party APIs to calculate and update the expected deliverydate based on various factors, such as inventory availability, shipping method, shipping address, and carrier service level. Displaying the expected delivery date on the order page allows the customer to see their delivery time estimate at any time and reduce their need to call customer service. Adding the Expected Delivery Date field to the order confirmation email is not a good solution, as it does not allow the customer to see their delivery time estimate if they lose or delete their email. Adding a Desired Delivery Date input field during the checkout flow is not a good solution either, as it does not guarantee that the customer's desired delivery date will be met or reflect any changes in delivery time due to unforeseen circumstances. Configuring an email alert to the customer when the Expected Delivery Date changes is not a good solution either, as it can create confusion or frustration for the customer if they receive multiple or conflicting emails about their delivery date. Salesforce References: B2B Commerce Developer Guide: Order Object, [B2B Commerce Developer Guide: Order Page],
[Lightning Web Components Developer Guide: Call an Apex Method Imperatively]
NEW QUESTION # 112
A developer is implementing an Inventory class for checkout. All the error states have been handled and now the developer needs to take the next step to indicate that inventory is available for all of the items and amounts in the cart. What should the next step be?
- A. Return sfde_checkout.InventoryStatus. SUCCESS
- B. Return TRUE
- C. Return sfdc_checkout.IntegrationStatus. Status. SUCCESS
- D. Return sfdc_checkout.InventoryStatus.Status. SUCCESS
Answer: D
Explanation:
When implementing an Inventory class for checkout and indicating that inventory is available for all items and amounts in the cart, the correct step is to returnsfdc_checkout.InventoryStatus.Status.SUCCESS. This indicates to the checkout process that the inventory check has passed and the items are available. Salesforce documentation on customizing inventory validation in the checkout process would detail the expected return types and values, ensuring that developers implement the inventory checks in a manner consistent with the platform's requirements.
NEW QUESTION # 113
What is the difference between Gross Layout Overrides and Subscriber Templates?
- A. Gross Layout Overrides allow for the modification of the footer, while Subscriber Templates allow for modification of everything inside the header and footer.
- B. Subscriber Templates allows for modification of the header, the footer and the content in between them.
Gross Layout Overrides only allow for modification of the header and footer. - C. Subscriber Templates allow for modification of the header and the footer, while Gross Layout Overrides allow for modification everything inside the header and footer.
- D. Gross Layout Overrides allow modification to CSS of a page, while Subscriber Templates allows for modification of the entire page including header and footer.
Answer: A
NEW QUESTION # 114
Which two Salesforce B2B Commerce visualforce pages must be enabled at a Salesforce Community level to make the out of the box SEO functionality available? (2 answers)
- A. CCCatSiteMap
- B. ProductMap
- C. SizeMap
- D. CCSizeIndex
Answer: A,D
Explanation:
Explanation
Two Salesforce B2B Commerce Visualforce pages that must be enabled at a Salesforce Community level to make the out of the box SEO functionality available are:
* CCSizeIndex: This page generates a sitemap.xml file, which is a file that lists all the pages and resources on a site that can be crawled by web crawlers. The page uses the configuration settings CO.SiteMapIncludeProducts and CO.SiteMapIncludeCategories to specify which products and categories should be included in the sitemap.
* CCCatSiteMap: This page generates a category sitemap file, which is a file that lists all the categories on a site that can be crawled by web crawlers. The page uses the configuration setting
* CO.SiteMapCategoryDepth to specify how many levels of subcategories should be included in the category sitemap. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Sitemap Files
NEW QUESTION # 115
Which two scoped modules should a developer import in Lightning web components to check user permissions?
- A. @salesforce/customPermission
- B. @salesforce/permission
- C. @salesforce/hasPermission
- D. @salesforce/userPermission
Answer: A,B
Explanation:
To check user permissions in Lightning web components, a developer should import two scoped modules: @salesforce/permission and @salesforce/customPermission. The @salesforce/permission module allows the developer to check if the user has access to a standard permission, such as View Setup or Modify All Data. The @salesforce/customPermission module allows the developer to check if the user has access to a custom permission, such as Enable Debug Mode or Manage Orders. The other modules do not exist or are not related to user permissions. Salesforce Reference: Lightning Web Components Developer Guide: Check User Permissions, Lightning Web Components Developer Guide: Import Salesforce Modules
NEW QUESTION # 116
Although Salesforce B2B Commerce and Salesforce recommend against using
"without sharing classes" whenever possible, sometimes it is unavoidable. Which three items will open up a major security hole? (3 answers)
- A. Executing dynamic SOQL inside a without sharing class with a bind variable fromccAPI.CURRENT_VERSION.
- B. Executing dynamic SOQL inside a without sharing class with a bind variable fromPageReference.getParameters().
- C. Executing dynamic SOQL inside a without sharing class with a bind variable from theUserInfo class.
- D. Executing dynamic SOQL inside a without sharing class with a bind variable fromcc_RemoteActionContentex class.
- E. Executing dynamic SOQL inside a without sharing class with a bind variable fromPageReference.getCookies().
Answer: B,D,E
Explanation:
Explanation
Executing dynamic SOQL inside a without sharing class with a bind variable from PageReference.getParameters(), PageReference.getCookies(), or cc_RemoteActionContext class will open up a major security hole because these sources of input are not sanitized and can be manipulated by malicious users to inject SOQL queries that bypass the sharing rules and access data that they are not supposed to see.
For example, a user can modify the URL parameters or cookies to include a SOQL query that returns sensitive data from the database. To prevent this, it is recommended to use static SOQL or escape the bind variables before executing dynamic SOQL.
NEW QUESTION # 117
While in the process of gathering requirements from a customer about how they would like to set up their net new storefront checkout experience, a consultant learns that the customer needs the ability to add new shipping and billing addresses during checkout.
Which approach should a developer take to meet this requirement?
- A. Enable Buyer Managed Contact Point Addresses within Commerce Administration.
- B. Create a new shipping address checkout subflow that utilizes the Buyer Managed Contact Point Addresses component.
- C. Enable Buyer Managed Contact Point Addresses within the Shipping Address standard component in the Checkout subflow.
- D. Create a Lightning web component that enables this functionality and replaces the current shipping address screen within the Checkout subflow.
Answer: C
Explanation:
To enable the ability to add new shipping and billing addresses during checkout, a developer should enable Buyer Managed Contact Point Addresses within the Shipping Address standard component in the Checkout subflow. The Buyer Managed Contact Point Addresses is a feature that allows customers to add, edit, or delete their shipping and billing addresses during checkout. The developer can enable this feature by setting the buyerManagedContactPointAddressesEnabled attribute to true in the Shipping Address standard component in the Checkout subflow. The Shipping Address standard component is a component that displays and collects the shipping address information for the cart or order. The Checkout subflow is a subflow that defines the steps and components for the checkout process in the storefront. Creating a new shipping address checkout subflow that utilizes the Buyer Managed Contact Point Addresses component is not a valid way to enable this feature, as there is no such component as Buyer Managed Contact Point Addresses. Enabling Buyer Managed Contact Point Addresses within Commerce Administration is not a valid way either, as this feature is not configurable in Commerce Administration. Creating a Lightning web component that enables this functionality and replaces the current shipping address screen within the Checkout subflow is not a valid way either, as this is unnecessary and complicated when there is already a standard component that supports this feature. Salesforce References: [B2B Commerce Developer Guide: Buyer Managed Contact Point Addresses],
[B2B Commerce Developer Guide: Shipping Address Component], [B2B Commerce Developer Guide:
Checkout Subflow]
NEW QUESTION # 118
How does a project implement the process to persist payment information datain the Checkout flow for Salesforce B2B Commerce version 4.2 and beyond?
- A. Trigger the processPayment event and pass in the payment information object as an argument.
- B. Trigger a remote action to store the payment information in the URL query parameters.
- C. Trigger the externalprocessedPayment and pass in the payment information object as an argument.
- D. Trigger a remote action when the process payment button is selected to capture the payment.
Answer: A
Explanation:
To persist payment information data in the Checkout flow for Salesforce B2B Commerce version 4.2 and beyond, the project needs to trigger the processPayment event and pass in the payment information object as an argument. This event will invoke the processPayment method of the ccServicePayment class, which will validate and process the payment information and return a payment result object. The payment result object will contain the status and details of the payment transaction.
NEW QUESTION # 119
What is a best practice when passing query parameters from user interface to an apex controller?
- A. String parameters should be trimmed using String.trim().
- B. Query parameters should be passed only to Salesforce B2B Commerce classes that you are extending.
- C. Query parameters should be stored on a backbone model prior to passing them to the server
- D. Query parameters should be properly sanitized by using JSINHTMLENCODE within the VisualForce Page or Component.
Answer: D
Explanation:
A best practice when passing query parameters from user interface to an apex controller is to query parameters should be properly sanitized by using JSINHTMLENCODE within the VisualForce Page or Component. This function will encode any special characters in the query parameters to prevent cross-site scripting (XSS) attacks or SOQL injection attacks. For example, ccrz.ccRemoteActions.getProducts('{!JSINHTMLENCODE(searchTerm)}') will encode the searchTerm parameter before passing it to the apex controller. Salesforce Reference: B2B Commerce and D2C Commerce Developer Guide, Security
NEW QUESTION # 120
Which three steps are necessary to have subscriberpage added to Salesforce B2B Commerce after creating a custom Visualforce page? (3 answers)
- A. Enable the Subscriber Page in CC Admin.
- B. Create a new CC Subscriber Page record that points to your custom Visualforce page.
- C. Create a new Visualforce page, and manually import the Salesforce B2BCommerce JavaScript libraries. Run in Anonymous Apex ccrz.cc_util_Reflection.upsertPageUIKey([arg1],[arg2],[arg3]);
- D. Refresh the Page Keys Index in CC Admin.
Answer: A,B,D
Explanation:
Three steps that are necessary to have a subscriber page added to Salesforce B2B Commerce after creating a custom Visualforce page are:
Create a new CC Subscriber Page record that points to your custom Visualforce page. This record will store information about the subscriber page, such as the name, description, URL, and Visualforce page. For example, you can create a new record named MySubscriberPage that points to your custom Visualforce page named MyPage.
Refresh the Page Keys Index in CC Admin. This action will update the page keys index, which is a cache that stores the mapping between the page keys and the subscriber pages. You need to do this whenever you create or modify a subscriber page record.
Enable the Subscriber Page in CC Admin. This action will allow you to select the subscriber page from the CC Page Settings configuration and assign it to a CC Page. For example, you can enable MySubscriberPage and assign it to the Home page. Salesforce Reference: B2B Commerce and D2C Commerce Developer Guide, Subscriber Pages
NEW QUESTION # 121
What are two purposes of the Shadow DOM in a Lightning web component?
- A. It encapsulates the internal document object model (DOM) structure of a web component
- B. It allows older JavaScript libraries to manipulate the tagging structure
- C. It allows direct access to the document object model of the component
- D. It allow components to be shared while protecting them from being manipulated by arbitrary code
Answer: A,D
Explanation:
Explanation
According to the Lightning Web Components Developer Guide, Shadow DOM is a standard that encapsulates the internal document object model (DOM) structure of a web component. Encapsulating the DOM gives developers the ability to share a component and protect the component from being manipulated by arbitrary HTML, CSS, and JavaScript. Shadow DOM also provides style and behavior isolation for a web component, which means that the styles and scripts defined inside a component do not affect the rest of the page, and vice versa. Therefore, the purposes of the Shadow DOM in a Lightning web component are to encapsulate the internal DOM structure of a web component (A) and to allow components to be shared while protecting them from being manipulated by arbitrary code (B). The other options are incorrect because Shadow DOM does not allow direct access to the document object model of the component, nor does it allow older JavaScript libraries to manipulate the tagging structure (D). References: Lightning Web Components Developer Guide, Understand the Shadow DOM Unit
NEW QUESTION # 122
In which two ways can events fired from Lightning web components be handled?
- A. Adding callbacks to components
- B. Listening for all possible events at the document root
- C. Attaching handlers to DOM elements
- D. Programmatically adding event listeners
Answer: C,D
Explanation:
Two ways that events fired from Lightning web components can be handled are programmatically adding event listeners and attaching handlers to DOM elements. Programmatically adding event listeners is a way of handling events by using JavaScript code to register functions that are invoked when an event occurs. The developer can use methods such as addEventListener or @wire to add event listeners to components or services that fire events. Attaching handlers to DOM elements is a way of handling events by using HTML attributes to bind functions that are invoked when an event occurs. The developer can use attributes such as onclick or onchange to attach handlers to DOM elements that fire events. Adding callbacks to components is not a valid way of handling events fired from Lightning web components, as it is not related to event handling, but rather to asynchronous programming. Listening for all possible events at the document root is not a valid way either, as it is not efficient or recommended for event handling, as it can cause performance issues or conflicts with other event listeners. Salesforce Reference: [Lightning Web Components Developer Guide: Handle Events], [Lightning Web Components Developer Guide: Communicate with Events]
NEW QUESTION # 123
A developer is working on a storefront and is seeing unexpected Ul behavior in one of the custom Lightning web components (LWCs) their team has built.
How should the developer investigate the issue?
- A. Enable Debug Mode for a storefront user, log in to the storefront, and use Browser Inspection tools and debugger points.
- B. Enable Debug Mode for a storefront user, load the LWC in Visual Studio (VS) Code, attach to session, and view debug logs in VS Code.
- C. Identify the user, inputs, and failure, then ask Salesforce support to investigate the issue with the custom LWC.
- D. Enable debug logs for a storefront user, log in to storefront and perform action, and view debug logs in Setup.
Answer: A
Explanation:
To investigate the issue of seeing unexpected UI behavior in one of the custom Lightning web components (LWCs) their team has built, the developer should enable Debug Mode for a storefront user, log in to the storefront, and use Browser Inspection tools and debugger points. Debug Mode is a feature that allows developers to debug and troubleshoot custom LWCs in the storefront by disabling performance optimizations and enabling source maps. Source maps are files that map the minified or obfuscated code to the original source code, making it easier to read and debug. To enable Debug Mode for a storefront user, the developer can go to Setup, enter Users in the Quick Find box, select Users, click Edit next to the user name, and select Debug Mode. After enabling Debug Mode, the developer can log in to the storefront as the user and use Browser Inspection tools and debugger points to inspect and debug the custom LWC. Browser Inspection tools are tools that are built into web browsers that allow developers to examine and modify the HTML, CSS, JavaScript, and other aspects of a web page. Debugger points are statements that are added to the JavaScript code of a LWC that pause the execution of the code at a certain point and allow the developer to inspect the values of variables, expressions, and other elements. Enable Debug Mode for a storefront user, load the LWC in Visual Studio (VS) Code, attach to session, and view debug logs in VS Code is not a valid way to investigate the issue of seeing unexpected UI behavior in one of the custom LWCs their team has built, as it is not possible to attach to a session or view debug logs for LWCs in VS Code. Enable debug logs for a storefront user, log in to storefront and perform action, and view debug logs in Setup is not a valid way either, as debug logs do not capture information about LWCs or UI behavior. Debug logs are records of database operations, system processes, and errors that occur when executing a transaction or running unit tests. Identify the user, inputs, and failure, then ask Salesforce support to investigate the issue with the custom LWC is not a valid way either, as it is not a recommended or efficient way of debugging or troubleshooting custom LWCs.
Salesforce support may not be able to provide assistance or guidance for custom LWCs that are developed by third-party developers. Salesforce References: B2B Commerce Developer Guide: Debug Lightning Web Components, Lightning Web Components Developer Guide: Debug Your Code, Salesforce Help: Debug Logs
NEW QUESTION # 124
Numerous flags ... have a directimpact on the result set provided by the Global API's. What Global API Data-Sizing convention flag prevents an API request from propagating to further requests when provided as a Boolean parameter with a value of true?
- A. ccrz.ccAPISizing.ASSC
- B. ccrz.ccAPISizing.REL
- C. ccrz.ccAPI.SZ_ASSC
- D. ccrz.ccAPI.SZ_REL
Answer: C
Explanation:
The Global API Data-Sizing convention flag that prevents an API request from propagating to further requests when provided as a Boolean parameter with a value of true is ccrz.ccAPI.SZ_ASSC. This flag indicates that only one API request should be executed with the specified sizing block, and any subsequent requests should use their own default sizing blocks. For example, ccrz.ccServiceCart.getCart(ccrz.ccAPI.SZ_L,true) will use the SZ_L sizing block for retrieving the cart data, but any other requests that are triggered by this method will use their own default sizing blocks. Salesforce References: B2B Commerce and D2C Commerce Developer Guide, Data Sizing Conventions
NEW QUESTION # 125
......
Free B2B-Commerce-Developer Exam Dumps to Improve Exam Score: https://examtorrent.testkingpdf.com/B2B-Commerce-Developer-testking-pdf-torrent.html

