Class: Clerk::Models::Components::CreateBillingPriceRequest

Inherits:
Object
  • Object
show all
Includes:
Crystalline::MetadataFields
Defined in:
lib/clerk/models/components/createbillingpricerequest.rb

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(plan_id:, amount: nil, description: nil, supported_billing_periods: nil, currency: 'USD', annual_monthly_amount: nil) ⇒ CreateBillingPriceRequest

Returns a new instance of CreateBillingPriceRequest.



29
30
31
32
33
34
35
36
# File 'lib/clerk/models/components/createbillingpricerequest.rb', line 29

def initialize(plan_id:, amount: nil, description: nil, supported_billing_periods: nil, currency: 'USD', annual_monthly_amount: nil)
  @plan_id = plan_id
  @amount = amount
  @description = description
  @supported_billing_periods = supported_billing_periods
  @currency = currency
  @annual_monthly_amount = annual_monthly_amount
end

Instance Method Details

#==(other) ⇒ Object



39
40
41
42
43
44
45
46
47
48
# File 'lib/clerk/models/components/createbillingpricerequest.rb', line 39

def ==(other)
  return false unless other.is_a? self.class
  return false unless @plan_id == other.plan_id
  return false unless @amount == other.amount
  return false unless @description == other.description
  return false unless @supported_billing_periods == other.supported_billing_periods
  return false unless @currency == other.currency
  return false unless @annual_monthly_amount == other.annual_monthly_amount
  true
end