Class: Stripe::V2::Billing::IntentCreateParams::Action::Apply::InvoiceDiscountRule

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

Defined Under Namespace

Classes: PercentOff

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(applies_to: nil, type: nil, percent_off: nil) ⇒ InvoiceDiscountRule

Returns a new instance of InvoiceDiscountRule.



37
38
39
40
41
# File 'lib/stripe/params/v2/billing/intent_create_params.rb', line 37

def initialize(applies_to: nil, type: nil, percent_off: nil)
  @applies_to = applies_to
  @type = type
  @percent_off = percent_off
end

Instance Attribute Details

#applies_toObject

The entity that the discount rule applies to, for example, the cadence.



31
32
33
# File 'lib/stripe/params/v2/billing/intent_create_params.rb', line 31

def applies_to
  @applies_to
end

#percent_offObject

Configuration for percentage off discount.



35
36
37
# File 'lib/stripe/params/v2/billing/intent_create_params.rb', line 35

def percent_off
  @percent_off
end

#typeObject

Type of the discount rule.



33
34
35
# File 'lib/stripe/params/v2/billing/intent_create_params.rb', line 33

def type
  @type
end