Order processing tutorial
Step 4. Create a quote
- Track each item the customer wants to buy, including the quantity and base cost
- Gather information about the customer, including billing and shipping addresses
- Determine shipping costs
- Calculate the subtotal, add costs (shipping fees, taxes, etc.) and apply coupons to determine the grand total
- Determine the payment method
- Place the order so that the merchant can fulfill it.
Types of carts
Magento identifies three types of users that can create a shopping cart:
- An admin user can create a cart on behalf of a customer. For all admin requests, you must provide an admin authorization token in the call’s authorization header.
- A logged-in customer. Calls to create a cart and add items must contain the customer’s authorization token in the authorization header.
- A guest user. These users could be customers who haven’t logged in yet, or they could be users who have no intention of creating an account. An anonymous user’s cart is called a guest cart.
Create a cart for a logged-in customer
All calls for a logged in customer must specify customer’s token
q0u66k8h42yaevtchv09uyy3y9gaj2ap in the header.
V1/guest-carts endpoint to create a cart on behalf of a guest. Do not include an authorization token. The
quoteId for the guest customer quote will be masked.
Authorization: Bearer <customer token>
The response is the
Some calls refer to this parameter as the
Verify this step
There are no additional verification steps.
quoteId values are not displayed on the website or in Admin.