Class: Orb::Models::Price::PackageWithAllocation

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/orb/models/price.rb,
sig/orb/models/price.rbs

Defined Under Namespace

Modules: BillingMode, Cadence, PriceType Classes: CompositePriceFilter, LicenseType, PackageWithAllocationConfig

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(allocation:, package_amount:, package_size:) ⇒ Object

Configuration for package_with_allocation pricing

Parameters:

  • allocation (String)
  • package_amount (String)
  • package_size (String)


# File 'lib/orb/models/price.rb', line 5045

Instance Attribute Details

#billable_metric ⇒ Orb::Models::BillableMetricTiny?

Parameters:

Returns:



4882
# File 'lib/orb/models/price.rb', line 4882

required :billable_metric, -> { Orb::BillableMetricTiny }, nil?: true

#billing_cycle_configuration ⇒ Orb::Models::BillingCycleConfiguration



4887
# File 'lib/orb/models/price.rb', line 4887

required :billing_cycle_configuration, -> { Orb::BillingCycleConfiguration }

#billing_mode ⇒ Symbol, Orb::Models::Price::PackageWithAllocation::BillingMode

Parameters:

  • value (Orb::Models::Price::PackageWithAllocation::billing_mode)

Returns:



4892
# File 'lib/orb/models/price.rb', line 4892

required :billing_mode, enum: -> { Orb::Price::PackageWithAllocation::BillingMode }

#cadence ⇒ Symbol, Orb::Models::Price::PackageWithAllocation::Cadence

Parameters:

  • value (Orb::Models::Price::PackageWithAllocation::cadence)

Returns:



4897
# File 'lib/orb/models/price.rb', line 4897

required :cadence, enum: -> { Orb::Price::PackageWithAllocation::Cadence }

#composite_price_filters ⇒ Array<Orb::Models::Price::PackageWithAllocation::CompositePriceFilter>?

Parameters:

  • value (::Array[Orb::Price::PackageWithAllocation::CompositePriceFilter], nil)

Returns:



4902
4903
4904
# File 'lib/orb/models/price.rb', line 4902

required :composite_price_filters,
-> { Orb::Internal::Type::ArrayOf[Orb::Price::PackageWithAllocation::CompositePriceFilter] },
nil?: true

#conversion_rate ⇒ Float?

Parameters:

  • value (Float, nil)

Returns:

  • (Float, nil)


4909
# File 'lib/orb/models/price.rb', line 4909

required :conversion_rate, Float, nil?: true

#conversion_rate_config ⇒ Orb::Models::UnitConversionRateConfig, ...

Parameters:

  • value (Orb::Models::conversion_rate_config, nil)

Returns:



4914
# File 'lib/orb/models/price.rb', line 4914

required :conversion_rate_config, union: -> { Orb::ConversionRateConfig }, nil?: true

#created_at ⇒ Time

Parameters:

  • value (Time)

Returns:

  • (Time)


4919
# File 'lib/orb/models/price.rb', line 4919

required :created_at, Time

#credit_allocation ⇒ Orb::Models::Allocation?

Parameters:

Returns:



4924
# File 'lib/orb/models/price.rb', line 4924

required :credit_allocation, -> { Orb::Allocation }, nil?: true

#currency ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


4929
# File 'lib/orb/models/price.rb', line 4929

required :currency, String

#dimensional_price_configuration ⇒ Orb::Models::DimensionalPriceConfiguration?



5035
# File 'lib/orb/models/price.rb', line 5035

optional :dimensional_price_configuration, -> { Orb::DimensionalPriceConfiguration }, nil?: true

#discount ⇒ Orb::Models::PercentageDiscount, ...

Deprecated.


4935
# File 'lib/orb/models/price.rb', line 4935

required :discount, union: -> { Orb::Discount }, nil?: true

#external_price_id ⇒ String?

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


4940
# File 'lib/orb/models/price.rb', line 4940

required :external_price_id, String, nil?: true

#fixed_price_quantity ⇒ Float?

Parameters:

  • value (Float, nil)

Returns:

  • (Float, nil)


4945
# File 'lib/orb/models/price.rb', line 4945

required :fixed_price_quantity, Float, nil?: true

#id ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


4877
# File 'lib/orb/models/price.rb', line 4877

required :id, String

#invoice_grouping_key ⇒ String?

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


4950
# File 'lib/orb/models/price.rb', line 4950

required :invoice_grouping_key, String, nil?: true

#invoicing_cycle_configuration ⇒ Orb::Models::BillingCycleConfiguration?



4955
# File 'lib/orb/models/price.rb', line 4955

required :invoicing_cycle_configuration, -> { Orb::BillingCycleConfiguration }, nil?: true

#item ⇒ Orb::Models::ItemSlim

A minimal representation of an Item containing only the essential identifying information.

Parameters:

Returns:



4962
# File 'lib/orb/models/price.rb', line 4962

required :item, -> { Orb::ItemSlim }

#license_type ⇒ Orb::Models::Price::PackageWithAllocation::LicenseType?

The LicenseType resource represents a type of license that can be assigned to users. License types are used during billing by grouping metrics on the configured grouping key.

Parameters:

  • value (Orb::Price::PackageWithAllocation::LicenseType, nil)

Returns:



5043
# File 'lib/orb/models/price.rb', line 5043

optional :license_type, -> { Orb::Price::PackageWithAllocation::LicenseType }, nil?: true

#maximum ⇒ Orb::Models::Maximum?

Deprecated.

Parameters:

Returns:



4968
# File 'lib/orb/models/price.rb', line 4968

required :maximum, -> { Orb::Maximum }, nil?: true

#maximum_amount ⇒ String?

Deprecated.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


4974
# File 'lib/orb/models/price.rb', line 4974

required :maximum_amount, String, nil?: true

#metadata ⇒ Hash{Symbol=>String}

User specified key-value pairs for the resource. If not present, this defaults to an empty dictionary. Individual keys can be removed by setting the value to null, and the entire metadata mapping can be cleared by setting metadata to null.

Parameters:

  • value (::Hash[Symbol, String])

Returns:

  • (Hash{Symbol=>String})


4983
# File 'lib/orb/models/price.rb', line 4983

required :metadata, Orb::Internal::Type::HashOf[String]

#minimum ⇒ Orb::Models::Minimum?

Deprecated.

Parameters:

Returns:



4989
# File 'lib/orb/models/price.rb', line 4989

required :minimum, -> { Orb::Minimum }, nil?: true

#minimum_amount ⇒ String?

Deprecated.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


4995
# File 'lib/orb/models/price.rb', line 4995

required :minimum_amount, String, nil?: true

#model_type ⇒ Symbol, :package_with_allocation

The pricing model type

Parameters:

  • value (:package_with_allocation)

Returns:

  • (Symbol, :package_with_allocation)


5001
# File 'lib/orb/models/price.rb', line 5001

required :model_type, const: :package_with_allocation

#name ⇒ String

Parameters:

  • value (String)

Returns:

  • (String)


5006
# File 'lib/orb/models/price.rb', line 5006

required :name, String

#package_with_allocation_config ⇒ Orb::Models::Price::PackageWithAllocation::PackageWithAllocationConfig

Configuration for package_with_allocation pricing

Parameters:

  • value (Orb::Price::PackageWithAllocation::PackageWithAllocationConfig)

Returns:



5012
5013
# File 'lib/orb/models/price.rb', line 5012

required :package_with_allocation_config,
-> { Orb::Price::PackageWithAllocation::PackageWithAllocationConfig }

#plan_phase_order ⇒ Integer?

Parameters:

  • value (Integer, nil)

Returns:

  • (Integer, nil)


5018
# File 'lib/orb/models/price.rb', line 5018

required :plan_phase_order, Integer, nil?: true

#price_type ⇒ Symbol, Orb::Models::Price::PackageWithAllocation::PriceType

Parameters:

  • value (Orb::Models::Price::PackageWithAllocation::price_type)

Returns:



5023
# File 'lib/orb/models/price.rb', line 5023

required :price_type, enum: -> { Orb::Price::PackageWithAllocation::PriceType }

#replaces_price_id ⇒ String?

The price id this price replaces. This price will take the place of the replaced price in plan version migrations.

Parameters:

  • value (String, nil)

Returns:

  • (String, nil)


5030
# File 'lib/orb/models/price.rb', line 5030

required :replaces_price_id, String, nil?: true

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/orb/models/price.rb', line 5116

Instance Method Details

#to_hash ⇒ {

Returns:

  • ({)


3754
# File 'sig/orb/models/price.rbs', line 3754

def to_hash: -> {