Repository
CartRepositoryInterface
Magento\Quote\Api\CartRepositoryInterface
What it does
This interface defines the contract for managing shopping cart (quote) data in Magento 2.
Developers use this repository to retrieve, save, and delete carts, including fetching active carts by customer ID or cart ID, and searching for carts using specific criteria.
It's the primary API for cart management operations in both frontend and backend contexts.
Public Methods
- get()
- getList()
- getForCustomer()
- getActive()
- getActiveForCustomer()
- save()
- delete()