Class CartAddCustomLineItemActionImpl

java.lang.Object
com.commercetools.api.models.cart.CartAddCustomLineItemActionImpl
All Implemented Interfaces:
CartAddCustomLineItemAction, CartUpdateAction, CustomizableDraft<CartAddCustomLineItemAction>, ResourceUpdateAction<CartUpdateAction>, io.vrap.rmf.base.client.ModelBase

public class CartAddCustomLineItemActionImpl extends Object implements CartAddCustomLineItemAction, io.vrap.rmf.base.client.ModelBase

If the Cart already contains a CustomLineItem with the same slug, name, money, taxCategory, state, and Custom Fields, then only the quantity of the existing Custom Line Item is increased. If CustomLineItem shippingDetails are set, they are merged with the targets that already exist on the ItemShippingDetails of the Custom Line Item. In case of overlapping address keys the ItemShippingTarget quantity is summed up.

If the Cart already contains a Custom Line Item with the same slug that is otherwise not identical, an InvalidOperation error is returned.

If the Tax Rate is not set, a MissingTaxRateForCountry error is returned.