Cart edits during an active checkout and simplified cart cleanup
Key Takeaway
With simplified cart cleanup, a buyer can edit the cart during checkout, and the checkout keeps going instead of canceling.
Simplified cart cleanup lets a buyer change the cart during checkout without starting the checkout over. For developers, checkout screens can offer edits that used to force a restart, and two API status codes change.
What happens when a buyer edits the cart
Before simplified cart cleanup, any change to a cart with the status Checkout canceled the current checkout session and set the cart status back to Active. The buyer had to go back to the cart, make the change, and start checkout again. Because of that restart, checkout screens could not offer options like editing cart item quantities.
With simplified cart cleanup, the cart status can stay Checkout when the buyer modifies the cart. The Cart Calculate API performs checkout calculations like shipping and taxes based on the new cart contents, so the checkout flow continues without interruption.
Dana is on a checkout screen and removes a line she no longer needs. The screen sends a DELETE request to the Commerce Webstore Cart Item resource. With simplified cart cleanup enabled, the checkout is not canceled, and the Cart Calculate API recalculates shipping and taxes from the remaining items. Without simplified cart cleanup, the same change would cancel her checkout session and set the cart back to Active. Dana would then have to start checkout again.