Class: Dodopayments::Models::ProductCollection

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/dodopayments/models/product_collection.rb

Overview

Defined Under Namespace

Modules: EffectiveAtOnDowngrade, EffectiveAtOnUpgrade, OnPaymentFailure, ProrationBillingModeOnDowngrade, ProrationBillingModeOnUpgrade

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(id:, brand_id:, created_at:, groups:, name:, updated_at:, description: nil, effective_at_on_downgrade: nil, effective_at_on_upgrade: nil, image: nil, on_payment_failure: nil, proration_billing_mode_on_downgrade: nil, proration_billing_mode_on_upgrade: nil) ⇒ Object

Some parameter documentations has been truncated, see Dodopayments::Models::ProductCollection for more details.

Parameters:



# File 'lib/dodopayments/models/product_collection.rb', line 99

Instance Attribute Details

#brand_idString

Brand ID for the collection

Returns:

  • (String)


17
# File 'lib/dodopayments/models/product_collection.rb', line 17

required :brand_id, String

#created_atTime

Timestamp when the collection was created

Returns:

  • (Time)


23
# File 'lib/dodopayments/models/product_collection.rb', line 23

required :created_at, Time

#descriptionString?

Description of the collection

Returns:

  • (String, nil)


48
# File 'lib/dodopayments/models/product_collection.rb', line 48

optional :description, String, nil?: true

#effective_at_on_downgradeSymbol, ...

Default effective_at setting for subscription plan downgrades (null = inherit from business)



55
56
57
# File 'lib/dodopayments/models/product_collection.rb', line 55

optional :effective_at_on_downgrade,
enum: -> { Dodopayments::ProductCollection::EffectiveAtOnDowngrade },
nil?: true

#effective_at_on_upgradeSymbol, ...

Default effective_at setting for subscription plan upgrades (null = inherit from business)



64
65
66
# File 'lib/dodopayments/models/product_collection.rb', line 64

optional :effective_at_on_upgrade,
enum: -> { Dodopayments::ProductCollection::EffectiveAtOnUpgrade },
nil?: true

#groupsArray<Dodopayments::Models::ProductCollections::ProductCollectionGroupResponse>

Groups in this collection



29
30
# File 'lib/dodopayments/models/product_collection.rb', line 29

required :groups,
-> { Dodopayments::Internal::Type::ArrayOf[Dodopayments::ProductCollections::ProductCollectionGroupResponse] }

#idString

Unique identifier for the product collection

Returns:

  • (String)


11
# File 'lib/dodopayments/models/product_collection.rb', line 11

required :id, String

#imageString?

URL of the collection image

Returns:

  • (String, nil)


72
# File 'lib/dodopayments/models/product_collection.rb', line 72

optional :image, String, nil?: true

#nameString

Name of the collection

Returns:

  • (String)


36
# File 'lib/dodopayments/models/product_collection.rb', line 36

required :name, String

#on_payment_failureSymbol, ...

Default behavior for subscription plan changes on payment failure (null = inherit from business)



79
# File 'lib/dodopayments/models/product_collection.rb', line 79

optional :on_payment_failure, enum: -> { Dodopayments::ProductCollection::OnPaymentFailure }, nil?: true

#proration_billing_mode_on_downgradeSymbol, ...

Default proration billing mode for subscription plan downgrades (null = inherit from business)



86
87
88
# File 'lib/dodopayments/models/product_collection.rb', line 86

optional :proration_billing_mode_on_downgrade,
enum: -> { Dodopayments::ProductCollection::ProrationBillingModeOnDowngrade },
nil?: true

#proration_billing_mode_on_upgradeSymbol, ...

Default proration billing mode for subscription plan upgrades (null = inherit from business)



95
96
97
# File 'lib/dodopayments/models/product_collection.rb', line 95

optional :proration_billing_mode_on_upgrade,
enum: -> { Dodopayments::ProductCollection::ProrationBillingModeOnUpgrade },
nil?: true

#updated_atTime

Timestamp when the collection was last updated

Returns:

  • (Time)


42
# File 'lib/dodopayments/models/product_collection.rb', line 42

required :updated_at, Time

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/dodopayments/models/product_collection.rb', line 139