Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Public Member Functions
CouponManagementInterface Interface Reference
Inheritance diagram for CouponManagementInterface:
CouponManagement

Public Member Functions

 get ($cartId)
 
 set ($cartId, $couponCode)
 
 remove ($cartId)
 

Detailed Description

Coupon management service interface. @api

Since
100.0.2

Definition at line 15 of file CouponManagementInterface.php.

Member Function Documentation

◆ get()

get (   $cartId)

Returns information for a coupon in a specified cart.

Parameters
int$cartIdThe cart ID.
Returns
string The coupon code data.
Exceptions

◆ remove()

remove (   $cartId)

Deletes a coupon from a specified cart.

Parameters
int$cartIdThe cart ID.
Returns
bool
Exceptions

◆ set()

set (   $cartId,
  $couponCode 
)

Adds a coupon by code to a specified cart.

Parameters
int$cartIdThe cart ID.
string$couponCodeThe coupon code data.
Returns
bool
Exceptions

The documentation for this interface was generated from the following file: