QuestionQ6

Customizing Sales Operations

An Adobe Commerce developer has created a new shipping carrier. All components have been implemented, and the collectRates() and getAllowedMethods() functions are shown below:

Question Image

Question Image

Based on this code, what cost will be displayed for the shipping method, and what final amount will the customer be charged?

  • A The shipping method would display $0 but customers would pay a $10 handling fee for their order.
  • B The shipping method would display $0 and customers would pay $0 for using the new shipping method.
  • C The shipping method would display $10 and customers would pay $10 for using the new shipping method.
Explanation

setPrice(0) sets the shipping rate charged to the customer, so the method displays as $0 and adds $0 to the order total. setCost(10) records the carrier’s internal cost and does not itself create a customer-facing handling fee or surcharge. Adobe Commerce documents that the shipping price is the amount charged to the customer, while handling fees must be separately configured or applied.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!