B2C-Commerce-Developer Practice Test Questions

Total 202 Questions


Last Updated On : 2-Jun-2025



Preparing with B2C-Commerce-Developer practice test is essential to ensure success on the exam. This Salesforce SP25 test allows you to familiarize yourself with the B2C-Commerce-Developer exam questions format and identify your strengths and weaknesses. By practicing thoroughly, you can maximize your chances of passing the Salesforce certification spring 2025 release exam on your first attempt.

Surveys from different platforms and user-reported pass rates suggest B2C-Commerce-Developer practice exam users are ~30-40% more likely to pass.

A developer set up a new site with Taxation: Net. However, the business requirements changed and the site now needs to be Taxation:Gross. The Business Manager interface does not give this option.
Which sequence of steps is necessary to change the site to gross taxation?



A.

Make sure that the developer has “Administrator” Access, then change the Taxation
setting to Gross


B.

Unlock the site preferences and then change the Taxation setting to Gross


C.

Change the global setting,”Enable Taxation Methods” to true, then change the Taxation
setting to Gross


D.

Create a new site with Taxation set to Gross, then delete the old site.





D.
  

Create a new site with Taxation set to Gross, then delete the old site.



A Digital Developer needs to store information temporarily and decides to create a custom object.
Which code creates a custom object?



A.

CustomObject.createCustomObject(CustomObjectType,primaryKey);


B.

CustomObject.createCustomObject(primaryKey,CustomObjectType);


C.

CustomObjectMgr.createCustomObject(primaryKey);


D.

CustomObjectMgr.createCustomObject(CustomObjectType,primaryKey)





A.
  

CustomObject.createCustomObject(CustomObjectType,primaryKey);



A retailer notices that the Account Addresses page is showing the wrong shopper’s address.
Which tool should the developer start with to identify the issue?



A.

Pipeline profiler


B.

Code Profiler


C.

Storefront Toolkit


D.

Reports and Dashboards Module





C.
  

Storefront Toolkit



Given the customer basket described below:
• A customer has an existing basket that consists of multiple items.
• One of the items is identified as a gift ítem by an attribute at the product line ítem.
The developer needs to write custom code to fetch the customer basket and then modify the basket based
upon the items in the cart. If the basket contains any gift items, modify the basket and create a separate
shipment for the gift item.
Four hooks are required to make the modification, beginning with modifyGETRespone and ending with
validatebasket.
• Dw.ocapi.shop.basket.modifyGETResponse
• - missing hook –
• - missing hook -
• dw.ocapi.shop.basket.validateBasket
What are the two missing hooks in the middle?



A.

dw.ocapi.shop.basket.shipment.afterDELETE


B.

dw.ocapi.shop.basket.shipment.beforePATCH


C.

dw.ocapi.shop.basket.shipment.beforeDELETE


D.

dw.ocapi.shop.baskep.shopment.beforePOST


E.

Estos indican antes de actualizar y antes de introducir





B.
  

dw.ocapi.shop.basket.shipment.beforePATCH



D.
  

dw.ocapi.shop.baskep.shopment.beforePOST



A business user wants to add a link to a content page from within the body of another content asset. The target
content asset ID is: terms-and-conditions.
Which link function generates the correct link?



A.

$include(‘Page-Include’, ‘cid’, ‘terms-and-conditions’)$


B.

$http(‘Content-Page’, ‘cid’, ‘terms-and-conditions’)$


C.

$httpUrl(‘Content-Show’, ‘cid’, ‘terms-and-conditions’)$


D.

$url(‘Page-Show’, ‘cid’, ‘terms-and-conditions’)$





C.
  

$httpUrl(‘Content-Show’, ‘cid’, ‘terms-and-conditions’)$



Given the following conditions:
• Site export file with a copy of the Storefront data for a custom site
• Sandbox with the custom site code, but no Storefront data
• Requirement for a working copy of SFRA for development reference
A developer is assigned the following Business manager tasks:
• A. Import the custom Site using Site Import/Export
• B. Import the SFRA Demo Sites using Site Import/Export
C. Rebuild the custom Site search indexes
In what sequence should the developer perform the tasks, so that the custom Site displays the products as
intended?



A.

Task A, then C, then B


B.

Task B, then C, then A


C.

Task A, then B, then C


D.

Task B, then A, then C





D.
  

Task B, then A, then C



A developer has custom debug statements in a script, but the messages are not showing up in the
Storefront Toolkit Request Log.
Which step needs to be completed to get the messages to appear in the Request Log?



A.

In Global preferences, check the box for Enable custom logging in Request Log.


B.

In Site Preferences, check the box for Enable custom Logging in Request Log


C.

In Custom Log Settings, check the DEBUG box for Select Log Levels Written to Files.


D.

In custom Log Settings, activate the loggin category at DEBUG level





C.
  

In Custom Log Settings, check the DEBUG box for Select Log Levels Written to Files.



The following code ensures that an address ID CANNOT be used if it is already in use by another address in the customer’s address book. There is a problem with the code. The error message for an invalid address ID is never shown to the user on the form field.

How should the Digital Developer resolve this issue so that the error message is displayed on the address ID form field?



A.

addressForm.invalidateFormElement("addressid");


B.

addressForm.addresssid.invalidateFormElement = true;


C.

addressForm.invalidateFormElement(addressForm.addressid);


D.

addressForm.addresssid.invalidateFormElement();





D.
  

addressForm.addresssid.invalidateFormElement();



Universal Containers wants to associate a region code value with an order to indicate the general area of its destination. This region code must be accessible whenever the order history is displayed.
What is required to accomplish this?



A.

Store the region code value in a session variable.


B.

Define a custom attribute on the Order system object type to store the region code value.


C.

Define a custom object type to store the username with the region code.


D.

Store the region code value in the geolocation system attribute of the Order





B.
  

Define a custom attribute on the Order system object type to store the region code value.



A developer is writing a server side script that needs to maintain state across calls. The persistent
information needed includes these items.
• The current customer
• Whether or not the customer is authenticated
• The privacy attributes (such as tracking consent or cookie policy)
Which technique should the developer use to maintain state in an efficient and scalable manner that
follows best practice?



A.

Use a non-replicable Custom Object to store the information temporarily.


B.

Use the Session class in the B2C Commerce api.


C.

Use an SFRA controller, because it runs server-side, the state is automatically maintained


D.

Use a client-side cookie to store the information for the session duration.





B.
  

Use the Session class in the B2C Commerce api.



Page 8 out of 21 Pages
B2C-Commerce-Developer Practice Test Home Previous