Class: Stripe::V2::Billing::ServiceActionCreateParams::CreditGrant::Amount

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

Defined Under Namespace

Classes: CustomPricingUnit, Monetary

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(type: nil, custom_pricing_unit: nil, monetary: nil) ⇒ Amount

Returns a new instance of Amount.



40
41
42
43
44
# File 'lib/stripe/params/v2/billing/service_action_create_params.rb', line 40

def initialize(type: nil, custom_pricing_unit: nil, monetary: nil)
  @type = type
  @custom_pricing_unit = custom_pricing_unit
  @monetary = monetary
end

Instance Attribute Details

#custom_pricing_unitObject

The custom pricing unit amount of the credit grant. Required if ‘type` is `custom_pricing_unit`.



36
37
38
# File 'lib/stripe/params/v2/billing/service_action_create_params.rb', line 36

def custom_pricing_unit
  @custom_pricing_unit
end

#monetaryObject

The monetary amount of the credit grant. Required if ‘type` is `monetary`.



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

def monetary
  @monetary
end

#typeObject

The type of the credit grant amount. We currently support ‘monetary` and `custom_pricing_unit` billing credits.



34
35
36
# File 'lib/stripe/params/v2/billing/service_action_create_params.rb', line 34

def type
  @type
end