Class: Orb::Models::NewMaximum

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/orb/models/new_maximum.rb

Defined Under Namespace

Modules: AdjustmentType, AppliesToAll, PriceType

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(adjustment_type: , maximum_amount: , applies_to_all: nil, applies_to_item_ids: nil, applies_to_price_ids: nil, currency: nil, filters: nil, is_invoice_level: nil, price_type: nil) ⇒ Object

Some parameter documentations has been truncated, see Orb::Models::NewMaximum for more details.

Parameters:

  • adjustment_type (Symbol, Orb::Models::NewMaximum::AdjustmentType) (defaults to: )
  • maximum_amount (String) (defaults to: )
  • applies_to_all (Boolean, Orb::Models::NewMaximum::AppliesToAll, nil) (defaults to: nil)

    If set, the adjustment will apply to every price on the subscription.

  • applies_to_item_ids (Array<String>, nil) (defaults to: nil)

    The set of item IDs to which this adjustment applies.

  • applies_to_price_ids (Array<String>, nil) (defaults to: nil)

    The set of price IDs to which this adjustment applies.

  • currency (String, nil) (defaults to: nil)

    If set, only prices in the specified currency will have the adjustment applied.

  • filters (Array<Orb::Models::TransformPriceFilter>, nil) (defaults to: nil)

    A list of filters that determine which prices this adjustment will apply to.

  • is_invoice_level (Boolean) (defaults to: nil)

    When false, this adjustment will be applied to a single price. Otherwise, it wil

  • price_type (Symbol, Orb::Models::NewMaximum::PriceType, nil) (defaults to: nil)

    If set, only prices of the specified type will have the adjustment applied.



# File 'lib/orb/models/new_maximum.rb', line 59

Instance Attribute Details

#adjustment_typeSymbol, Orb::Models::NewMaximum::AdjustmentType



9
# File 'lib/orb/models/new_maximum.rb', line 9

required :adjustment_type, enum: -> { Orb::NewMaximum::AdjustmentType }

#applies_to_allBoolean, ...

If set, the adjustment will apply to every price on the subscription.

Returns:



20
# File 'lib/orb/models/new_maximum.rb', line 20

optional :applies_to_all, enum: -> { Orb::NewMaximum::AppliesToAll }, nil?: true

#applies_to_item_idsArray<String>?

The set of item IDs to which this adjustment applies.

Returns:

  • (Array<String>, nil)


26
# File 'lib/orb/models/new_maximum.rb', line 26

optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true

#applies_to_price_idsArray<String>?

The set of price IDs to which this adjustment applies.

Returns:

  • (Array<String>, nil)


32
# File 'lib/orb/models/new_maximum.rb', line 32

optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true

#currencyString?

If set, only prices in the specified currency will have the adjustment applied.

Returns:

  • (String, nil)


38
# File 'lib/orb/models/new_maximum.rb', line 38

optional :currency, String, nil?: true

#filtersArray<Orb::Models::TransformPriceFilter>?

A list of filters that determine which prices this adjustment will apply to.

Returns:



44
# File 'lib/orb/models/new_maximum.rb', line 44

optional :filters, -> { Orb::Internal::Type::ArrayOf[Orb::TransformPriceFilter] }, nil?: true

#is_invoice_levelBoolean?

When false, this adjustment will be applied to a single price. Otherwise, it will be applied at the invoice level, possibly to multiple prices.

Returns:

  • (Boolean, nil)


51
# File 'lib/orb/models/new_maximum.rb', line 51

optional :is_invoice_level, Orb::Internal::Type::Boolean

#maximum_amountString

Returns:

  • (String)


14
# File 'lib/orb/models/new_maximum.rb', line 14

required :maximum_amount, String

#price_typeSymbol, ...

If set, only prices of the specified type will have the adjustment applied.

Returns:



57
# File 'lib/orb/models/new_maximum.rb', line 57

optional :price_type, enum: -> { Orb::NewMaximum::PriceType }, nil?: true

Class Method Details

.valuesArray<Boolean>

Returns:

  • (Array<Boolean>)


# File 'lib/orb/models/new_maximum.rb', line 87