Class: Orb::Models::Plan
Overview
Defined Under Namespace
Modules: Adjustment, Status
Classes: BasePlan, PlanPhase, Product, TrialConfig
Instance Attribute Summary collapse
-
#adjustments ⇒ Array<Orb::Models::PlanPhaseUsageDiscountAdjustment, Orb::Models::PlanPhaseAmountDiscountAdjustment, Orb::Models::PlanPhasePercentageDiscountAdjustment, Orb::Models::PlanPhaseMinimumAdjustment, Orb::Models::PlanPhaseMaximumAdjustment>
Adjustments for this plan.
-
#base_plan ⇒ Orb::Models::Plan::BasePlan?
-
#base_plan_id ⇒ String?
The parent plan id if the given plan was created by overriding one or more of the parent’s prices.
-
#created_at ⇒ Time
-
#currency ⇒ String
deprecated
Deprecated.
-
#default_invoice_memo ⇒ String?
The default memo text on the invoices corresponding to subscriptions on this plan.
-
#description ⇒ String
-
#discount ⇒ Orb::Models::PercentageDiscount, ...
deprecated
Deprecated.
-
#external_plan_id ⇒ String?
An optional user-defined ID for this plan resource, used throughout the system as an alias for this Plan.
-
#id ⇒ String
-
#invoicing_currency ⇒ String
An ISO 4217 currency string for which this plan is billed in.
-
#maximum ⇒ Orb::Models::Maximum?
deprecated
Deprecated.
-
#maximum_amount ⇒ String?
deprecated
Deprecated.
-
#metadata ⇒ Hash{Symbol=>String}
User specified key-value pairs for the resource.
-
#minimum ⇒ Orb::Models::Minimum?
deprecated
Deprecated.
-
#minimum_amount ⇒ String?
deprecated
Deprecated.
-
#name ⇒ String
-
#net_terms ⇒ Integer?
Determines the difference between the invoice issue date and the due date.
-
#plan_phases ⇒ Array<Orb::Models::Plan::PlanPhase>?
-
#prices ⇒ Array<Orb::Models::Price::Unit, Orb::Models::Price::Package, Orb::Models::Price::Matrix, Orb::Models::Price::Tiered, Orb::Models::Price::TieredBPS, Orb::Models::Price::BPS, Orb::Models::Price::BulkBPS, Orb::Models::Price::Bulk, Orb::Models::Price::ThresholdTotalAmount, Orb::Models::Price::TieredPackage, Orb::Models::Price::GroupedTiered, Orb::Models::Price::TieredWithMinimum, Orb::Models::Price::TieredPackageWithMinimum, Orb::Models::Price::PackageWithAllocation, Orb::Models::Price::UnitWithPercent, Orb::Models::Price::MatrixWithAllocation, Orb::Models::Price::TieredWithProration, Orb::Models::Price::UnitWithProration, Orb::Models::Price::GroupedAllocation, Orb::Models::Price::GroupedWithProratedMinimum, Orb::Models::Price::GroupedWithMeteredMinimum, Orb::Models::Price::MatrixWithDisplayName, Orb::Models::Price::BulkWithProration, Orb::Models::Price::GroupedTieredPackage, Orb::Models::Price::MaxGroupTieredPackage, Orb::Models::Price::ScalableMatrixWithUnitPricing, Orb::Models::Price::ScalableMatrixWithTieredPricing, Orb::Models::Price::CumulativeGroupedBulk, Orb::Models::Price::GroupedWithMinMaxThresholds>
-
#product ⇒ Orb::Models::Plan::Product
-
#status ⇒ Symbol, Orb::Models::Plan::Status
-
#trial_config ⇒ Orb::Models::Plan::TrialConfig
-
#version ⇒ Integer
Class Method Summary
collapse
Instance Method Summary
collapse
==, #==, #[], 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
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(id: , created_at: , name: ) ⇒ Object
|
# File 'lib/orb/models/plan.rb', line 254
|
Instance Attribute Details
Adjustments for this plan. If the plan has phases, this includes adjustments across all phases of the plan.
22
|
# File 'lib/orb/models/plan.rb', line 22
required :base_plan, -> { Orb::Plan::BasePlan }, nil?: true
|
#base_plan_id ⇒ String?
The parent plan id if the given plan was created by overriding one or more of the parent’s prices
29
|
# File 'lib/orb/models/plan.rb', line 29
required :base_plan_id, String, nil?: true
|
#created_at ⇒ Time
34
|
# File 'lib/orb/models/plan.rb', line 34
required :created_at, Time
|
#currency ⇒ String
An ISO 4217 currency string or custom pricing unit (‘credits`) for this plan’s prices.
43
|
# File 'lib/orb/models/plan.rb', line 43
required :currency, String
|
#default_invoice_memo ⇒ String?
The default memo text on the invoices corresponding to subscriptions on this plan. Note that each subscription may configure its own memo.
50
|
# File 'lib/orb/models/plan.rb', line 50
required :default_invoice_memo, String, nil?: true
|
#description ⇒ String
55
|
# File 'lib/orb/models/plan.rb', line 55
required :description, String
|
61
|
# File 'lib/orb/models/plan.rb', line 61
required :discount, union: -> { Orb::Discount }, nil?: true
|
#external_plan_id ⇒ String?
An optional user-defined ID for this plan resource, used throughout the system as an alias for this Plan. Use this field to identify a plan by an existing identifier in your system.
69
|
# File 'lib/orb/models/plan.rb', line 69
required :external_plan_id, String, nil?: true
|
#id ⇒ String
10
|
# File 'lib/orb/models/plan.rb', line 10
required :id, String
|
#invoicing_currency ⇒ String
An ISO 4217 currency string for which this plan is billed in. Matches ‘currency` unless `currency` is a custom pricing unit.
76
|
# File 'lib/orb/models/plan.rb', line 76
required :invoicing_currency, String
|
82
|
# File 'lib/orb/models/plan.rb', line 82
required :maximum, -> { Orb::Maximum }, nil?: true
|
#maximum_amount ⇒ String?
88
|
# File 'lib/orb/models/plan.rb', line 88
required :maximum_amount, String, nil?: true
|
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`.
103
|
# File 'lib/orb/models/plan.rb', line 103
required :minimum, -> { Orb::Minimum }, nil?: true
|
#minimum_amount ⇒ String?
109
|
# File 'lib/orb/models/plan.rb', line 109
required :minimum_amount, String, nil?: true
|
#name ⇒ String
114
|
# File 'lib/orb/models/plan.rb', line 114
required :name, String
|
#net_terms ⇒ Integer?
Determines the difference between the invoice issue date and the due date. A value of “0” here signifies that invoices are due on issue, whereas a value of “30” means that the customer has a month to pay the invoice before its overdue. Note that individual subscriptions or invoices may set a different net terms configuration.
124
|
# File 'lib/orb/models/plan.rb', line 124
required :net_terms, Integer, nil?: true
|
Prices for this plan. If the plan has phases, this includes prices across all phases of the plan.
141
|
# File 'lib/orb/models/plan.rb', line 141
required :product, -> { Orb::Plan::Product }
|
146
|
# File 'lib/orb/models/plan.rb', line 146
required :status, enum: -> { Orb::Plan::Status }
|
151
|
# File 'lib/orb/models/plan.rb', line 151
required :trial_config, -> { Orb::Plan::TrialConfig }
|
#version ⇒ Integer
156
|
# File 'lib/orb/models/plan.rb', line 156
required :version, Integer
|
Class Method Details
.values ⇒ Array<Symbol>
|
# File 'lib/orb/models/plan.rb', line 360
|
|
# File 'lib/orb/models/plan.rb', line 230
|