2

Our team is developing a store using Magento 2 as the backend, with a decoupled client-side layer using Node.js/Express/React/Redux. So obviously we are relying heavily on the REST API, which is far from being well documented.

I am now developing the cart operations, and I noticed there are different endpoints for carts:

  • /V1/carts/

  • /V1/guest-carts/

Which is strange, because:

  • the cart objects that they provide as responses are identical
  • their responses have a customer key (why would guest-carts have this?)
  • their responses have a customer_is_guest key (why would both have this, since the endpoints already provide this distinction?)

Anyway, how should I deal with both endpoints? Should I necessarily use both, since most of the logic is handled by ourselves in the frontend/middlewares?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.