Exam Details

  • Exam Code
    :B2C-COMMERCE-DEVELOPER
  • Exam Name
    :Salesforce Certified B2C Commerce Developer
  • Certification
    :Salesforce Developer
  • Vendor
    :Salesforce
  • Total Questions
    :148 Q&As
  • Last Updated
    :May 05, 2024

Salesforce Salesforce Developer B2C-COMMERCE-DEVELOPER Questions & Answers

  • Question 31:

    To ensure SFRA best practices and protect against request forgery, the developer introduced CSRF token generation in the customer address form.

    To implement CSRF protection when the form is submitted, the developer needs to introduce the CSRF validation using one or both of these methods as applicable:

    1.

    validateRequest

    2.

    validateAjaxRequest

    Where in the code does the developer need to add this CSRF validation check?

    A. In the middleware chain of the controller post route

    B. In the controller function that displays the form

    C. In the model function that persists the form data

    D. In the view function that handles the submitted form

  • Question 32:

    A developer is tasked with the development of a new Page Designer Page Type, as requested by the merchant.

    How should they define the rendering logic of the page?

    A. Implement an XML file with a node

    B. Implement a JavaScript file with a render() function

    C. Implement a Controller file with a "render" route

    D. Implement a metadata JSON file with a "render" property

  • Question 33:

    A developer needs to perform the same additional checks before completing multiple routes in a custom controller, in order to decide whether to render a template or redirect the user to a different page.

    According to SFRA best practices, what is the correct approach to improve code reusability in this scenario?

    A. Replace the existing routes by creating a controller in separate new cartridge

    B. Use the superModule property in the existing routes to extend their functionality

    C. Append a new function to all the existing routes with the server module

    D. Define a new middleware function and use it in the existing routes

  • Question 34:

    A client has two B2C Commerce sites in the same instance: one for the U.S. market, the other for the European market. They offer free gift wrapping on a selection of products. For each order, five products can be wrapped in the U.S., but only three products can be wrapped in the European region. How should a developer allow the merchant to independently adjust this number?

    A. Create a new custom preference by extending the Site Preference object type

    B. Add a new Campaign using the Online Marketing section of the Business Manager

    C. Configure a new localizable content slot with a market-specific value

    D. Select the corresponding option in the system preference for Orders

  • Question 35:

    Given the sandbox with:

    1.

    Service configured and assigned to its profile and credential

    2.

    A code version that uses that service

    And given the requirement to limit the number of success or error calls the code can perform to a restricted number of calls per second.

    Which configuration should the developer perform?

    A. Set the service as limited and change the services profile site preferences with the required values

    B. Set a new quota limit for the service profile with the required values

    C. Set the rate limiter in the service profile and configure its values with the ones required

    D. Set a new quota limit for the service profile and assign the service to it

  • Question 36:

    Given the following ISML example, how should a developer reference the product object in the current iteration of the basket?

    A. loopstatus.product

    B. pdict.Basket.products[loopstatus]

    C. product

    D. pdict.product

  • Question 37:

    A developer working on a simple web service integration is asked to add appropriate logging to allow future troubleshooting.

    According to logging best practices, which code should the developer write to log when an operation succeeds, but has an unexpected outcome that may produce side effects?

    A. Logger.info(`Unexpected service response.')

    B. Logger.warn(`Unexpected service response.')

    C. Logger.error(`Unexpected service response.')

    D. Logger.debug(`Unexpected service response.')

  • Question 38:

    A developer customized the Cart-Show controller route with a LINK cartridge that adds social media data. There is a new requirement to add a dataLayer object to the Cart-Show controller route. How should the developer achieve this to ensure that no code change will be needed if the client decides to remove the LINK cartridge?

    A. Replace the existing viewData variable with the dataLayer object in the Cart-Show controller route

    B. Replace the Cart-Show controller route in client cartridge and add dataLayer object to the viewData variable

    C. Replace the Cart-Show controller route in client cartridge and add dataLayer object to the viewData variable. Ensure that the client cartridge is on the left of the LINK cartridge in cartridge path

    D. Append Cart-Show controller route in the client cartridge and add dataLayer object to the viewData variable

  • Question 39:

    A developer configures the dw.json file and needs to fill in the necessary parameters to complete the task. Which three parameters are required when using npm scripts? (Choose three.)

    A. Username/Password

    B. Code Version

    C. Site ID

    D. CSRF Token

    E. Hostname

  • Question 40:

    A developer has a sandbox with code to log a message during execution, and the following code:

    var Logger = require(`dw/system/Logger');

    Logger.info(message);

    After the code executes, the developer does not see any log file with the message in the WebDAV folder.

    Which task does the developer need to perform to correct this issue?

    A. Set the logging global preference to true

    B. Set the log retention to a value higher than 0

    C. Request that the developer's account be given permission to the Log Center of the current realm

    D. Set the root log level to debug

Tips on How to Prepare for the Exams

Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Salesforce exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your B2C-COMMERCE-DEVELOPER exam preparations and Salesforce certification application, do not hesitate to visit our Vcedump.com to find your solutions here.