Class: Stripe::PaymentPlanCreateParams::Schedule::AmountsDue::Amount

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/params/payment_plan_create_params.rb

Defined Under Namespace

Classes: DueDate, FixedAmount

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

attr_accessor, coerce_params, coerce_value, field_encodings, new, #to_h

Constructor Details

#initialize(description: nil, due_date: nil, fixed_amount: nil, id: nil, percentage: nil, type: nil) ⇒ Amount

Returns a new instance of Amount.



79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/stripe/params/payment_plan_create_params.rb', line 79

def initialize(
  description: nil,
  due_date: nil,
  fixed_amount: nil,
  id: nil,
  percentage: nil,
  type: nil
)
  @description = description
  @due_date = due_date
  @fixed_amount = fixed_amount
  @id = id
  @percentage = percentage
  @type = type
end

Instance Attribute Details

#descriptionObject

Optional description for this installment.



67
68
69
# File 'lib/stripe/params/payment_plan_create_params.rb', line 67

def description
  @description
end

#due_dateObject

When this installment is due.



69
70
71
# File 'lib/stripe/params/payment_plan_create_params.rb', line 69

def due_date
  @due_date
end

#fixed_amountObject

Required when type is 'fixed_amount'.



71
72
73
# File 'lib/stripe/params/payment_plan_create_params.rb', line 71

def fixed_amount
  @fixed_amount
end

#idObject

Optional stable identifier for the installment entry.



73
74
75
# File 'lib/stripe/params/payment_plan_create_params.rb', line 73

def id
  @id
end

#percentageObject

The installment percentage of the total. Required when type is 'percentage'.



75
76
77
# File 'lib/stripe/params/payment_plan_create_params.rb', line 75

def percentage
  @percentage
end

#typeObject

Either 'fixed_amount' or 'percentage'.



77
78
79
# File 'lib/stripe/params/payment_plan_create_params.rb', line 77

def type
  @type
end