Class: Stripe::QuoteService::CreateParams::Line::Action::RemoveDiscount

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/services/quote_service.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(coupon: nil, discount: nil, promotion_code: nil) ⇒ RemoveDiscount

Returns a new instance of RemoveDiscount.



325
326
327
328
329
# File 'lib/stripe/services/quote_service.rb', line 325

def initialize(coupon: nil, discount: nil, promotion_code: nil)
  @coupon = coupon
  @discount = discount
  @promotion_code = promotion_code
end

Instance Attribute Details

#couponObject

The coupon code to remove from the ‘discounts` array.



317
318
319
# File 'lib/stripe/services/quote_service.rb', line 317

def coupon
  @coupon
end

#discountObject

The ID of a discount to remove from the ‘discounts` array.



320
321
322
# File 'lib/stripe/services/quote_service.rb', line 320

def discount
  @discount
end

#promotion_codeObject

The ID of a promotion code to remove from the ‘discounts` array.



323
324
325
# File 'lib/stripe/services/quote_service.rb', line 323

def promotion_code
  @promotion_code
end