Class RollbackEngine

java.lang.Object
org.bhn.promotion.voucherify.engine.RollbackEngine

public class RollbackEngine extends Object

RollbackEngine implementation

  • Field Details

  • Constructor Details

    • RollbackEngine

      @Autowired public RollbackEngine(VoucherifyClient voucherifyClient)
      Constructs a RollbackEngine with the specified VoucherifyClient

      This constructor initializes the engine with the necessary services for interacting with the Voucherify API and managing promotion budgets. These services are injected via Spring's Autowired mechanism.

      Parameters:
      voucherifyClient - The client used to interact with the Voucherify API for managing vouchers.
  • Method Details

    • rollbackPromotion

      public RollbackResponseModel rollbackPromotion(RollbackRequest rollbackRequest)

      This method allows you to rollback the promotions which were applied on a cart

      Parameters:
      rollbackRequest - contains redemption id to be rolled back
      Returns:
      RollbackResponseModel Summary of redemptions which were rolled back