Class: Stripe::V2::Billing::IntentService::CreateParams::Action::Apply::InvoiceDiscountRule::PercentOff

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/services/v2/billing/intent_service.rb

Defined Under Namespace

Classes: MaximumApplications

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(maximum_applications: nil, percent_off: nil) ⇒ PercentOff

Returns a new instance of PercentOff.



42
43
44
45
# File 'lib/stripe/services/v2/billing/intent_service.rb', line 42

def initialize(maximum_applications: nil, percent_off: nil)
  @maximum_applications = maximum_applications
  @percent_off = percent_off
end

Instance Attribute Details

#maximum_applicationsObject

The maximum number of times this discount can be applied for this cadence.



38
39
40
# File 'lib/stripe/services/v2/billing/intent_service.rb', line 38

def maximum_applications
  @maximum_applications
end

#percent_offObject

Percent that will be taken off of the amount. For example, percent_off of 50.0 will make $100 amount $50 instead.



40
41
42
# File 'lib/stripe/services/v2/billing/intent_service.rb', line 40

def percent_off
  @percent_off
end