Class ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete

java.lang.Object
io.vrap.rmf.base.client.ApiMethod<T,TResult>
io.vrap.rmf.base.client.TypeApiMethod<ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete,CartDiscount>
com.commercetools.api.client.ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete
All Implemented Interfaces:
ConflictingTrait<ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete>, Deprecatable200Trait<ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete>, ErrorableTrait<ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete>, ExpandableTrait<ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete>, VersionedTrait<ByProjectKeyInStoreKeyByStoreKeyCartDiscountsByIDDelete>, ClientRequestCommand<CartDiscount>, CreateHttpRequestCommand, HttpRequestCommand<CartDiscount>, RequestCommand<CartDiscount>

To delete a CartDiscount, specify the manage_cart_discounts:{projectKey}:{storeKey} scope for all Stores associated with the CartDiscount.

Deleting a Cart Discount produces the CartDiscountDeleted Message.



   CompletableFuture<ApiHttpResponse<com.commercetools.api.models.cart_discount.CartDiscount>> result = apiRoot
            .withProjectKey("{projectKey}")
            .inStoreKeyWithStoreKeyValue("{storeKey}")
            .cartDiscounts()
            .withId("{ID}")
            .delete()
            .withVersion(version)
            .execute()