Class: Stripe::V2::Billing::RateCardModifyRatesParams::RatesToCreate::Tier
- Inherits:
-
RequestParams
- Object
- RequestParams
- Stripe::V2::Billing::RateCardModifyRatesParams::RatesToCreate::Tier
- Defined in:
- lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb
Instance Attribute Summary collapse
-
#flat_amount ⇒ Object
Price for the entire tier, represented as a decimal string in minor currency units with at most 12 decimal places.
-
#unit_amount ⇒ Object
Per-unit price for units included in this tier, represented as a decimal string in minor currency units with at most 12 decimal places.
-
#up_to_decimal ⇒ Object
Up to and including this quantity will be contained in the tier.
-
#up_to_inf ⇒ Object
No upper bound to this tier.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(flat_amount: nil, unit_amount: nil, up_to_decimal: nil, up_to_inf: nil) ⇒ Tier
constructor
A new instance of Tier.
Methods inherited from RequestParams
attr_accessor, coerce_params, coerce_value, new, #to_h
Constructor Details
#initialize(flat_amount: nil, unit_amount: nil, up_to_decimal: nil, up_to_inf: nil) ⇒ Tier
Returns a new instance of Tier.
65 66 67 68 69 70 |
# File 'lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb', line 65 def initialize(flat_amount: nil, unit_amount: nil, up_to_decimal: nil, up_to_inf: nil) @flat_amount = flat_amount @unit_amount = unit_amount @up_to_decimal = up_to_decimal @up_to_inf = up_to_inf end |
Instance Attribute Details
#flat_amount ⇒ Object
Price for the entire tier, represented as a decimal string in minor currency units with at most 12 decimal places.
55 56 57 |
# File 'lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb', line 55 def flat_amount @flat_amount end |
#unit_amount ⇒ Object
Per-unit price for units included in this tier, represented as a decimal string in minor currency units with at most 12 decimal places.
58 59 60 |
# File 'lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb', line 58 def unit_amount @unit_amount end |
#up_to_decimal ⇒ Object
Up to and including this quantity will be contained in the tier. Only one of ‘up_to_decimal` and `up_to_inf` may be set.
61 62 63 |
# File 'lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb', line 61 def up_to_decimal @up_to_decimal end |
#up_to_inf ⇒ Object
No upper bound to this tier. Only one of ‘up_to_decimal` and `up_to_inf` may be set.
63 64 65 |
# File 'lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb', line 63 def up_to_inf @up_to_inf end |
Class Method Details
.field_encodings ⇒ Object
72 73 74 |
# File 'lib/stripe/params/v2/billing/rate_card_modify_rates_params.rb', line 72 def self.field_encodings @field_encodings = { up_to_decimal: :decimal_string } end |