Item Object
Cart Items
Cart Items represent the products in a customer's shopping cart in serB2B system. These products are temporarily stored when a customer adds items to their cart or considers making a purchase, and they are linked with other product data in the system. Each cart item contains the product's ID, name, price, quantity, and other important details. This information ensures that the correct products and prices are displayed during the checkout process.
This document explains how the "Item Object" properties used for Cart Items work and how they should be configured. Proper use of these features is crucial for ensuring correct product information, efficiently managing inventory, and improving the customer experience during cart management. Additionally, the role of each Cart Item in managing pricing, discounts, tax information, and product quantities is discussed here.
Each feature in the "Item Objects" structure ensures the proper management and processing of cart items. This document helps you understand the specific features and functions of Cart Items, enabling you to manage your products and shopping carts more effectively.
Cart Item Object Properties
The following table details these properties:
Feature Name | Type | Description |
---|---|---|
product | \Serenay\B2B\Data\Product | Data object containing product-related information. |
variant_id | string | Product variant ID. |
measure_qty | int | Quantity of the unit of measurement. |
price | float | Product price. |
currency | string | Currency of the price (e.g., TRY, USD). |
price_override | float | Special price set by the admin; overrides the default price. |
amounts | array | List of payment price calculations for the product in the cart. |
measure_id | int | Unit of measurement ID. |
package_qty | int | The package quantity of the product if it’s in the main unit; otherwise, 1 . |
sepet_id | string | Unique cart ID. |
sepet_renk_dosya | string | Name of the color file for the product in the cart. |
sepet_renk | string | Color name of the product in the cart. |
adet | int | Quantity of the product. |
urun_id | string | Unique product ID. |
product_original_price | float | The actual price of the product that is not tied to the user. |
product_original_price_with_text | string | Formatted actual price of the product. |
has_discount | bool | Indicates if the product is discounted in the cart. |
product_name | string | Name of the product. |
measure | ProductMeasure | Contains unit of measurement details. |
discount_amount | float | Discount amount applied to the product. |
Frequently Asked Questions (FAQs)
-
What is
price_override
and how is it used?price_override
represents a special price set by the admin. This value overrides the default price and changes the price of the product in the cart. If this field is left empty, the normal price of the product will apply. For example, during promotions or special offers, a specific price discount may be applied to a product. -
What is
discount_amount
and what does it do?discount_amount
indicates the discount applied to the product. This value represents the amount discounted from the product's original price. For example, if a product's original price is 100 TRY and thediscount_amount
is 20 TRY, the discounted price of the product will be 80 TRY. This feature is used to accurately calculate discounted product prices.
Resources
Contact and Support
If you encounter any issues or need assistance, please contact our support team. We are happy to assist you as soon as possible.