Module: Orb::Models::MutatedSubscription::DiscountInterval

Extended by:
Internal::Type::Union
Defined in:
lib/orb/models/mutated_subscription.rb

Instance Method Summary collapse

Methods included from Internal::Type::Union

==, ===, coerce, dump, hash, inspect, to_sorbet_type, variants

Methods included from Internal::Util::SorbetRuntimeSupport

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

Methods included from Internal::Type::Converter

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

Instance Method Details

#initialize(id: , active_plan_phase_order: , adjustment_intervals: , auto_collection: , billing_cycle_anchor_configuration: , billing_cycle_day: , created_at: , current_billing_period_end_date: , current_billing_period_start_date: , customer: , default_invoice_memo: , discount_intervals: , end_date: , fixed_fee_quantity_schedule: , invoicing_threshold: , maximum_intervals: , metadata: , minimum_intervals: , name: , net_terms: , pending_subscription_change: , plan: , price_intervals: , redeemed_coupon: , start_date: , status: , trial_info: , changed_resources: nil) ⇒ Object

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

Parameters:

  • id (String) (defaults to: )
  • active_plan_phase_order (Integer, nil) (defaults to: )

    The current plan phase that is active, only if the subscription’s plan has phase

  • adjustment_intervals (Array<Orb::Models::AdjustmentInterval>) (defaults to: )

    The adjustment intervals for this subscription sorted by the start_date of the a

  • auto_collection (Boolean, nil) (defaults to: )

    Determines whether issued invoices for this subscription will automatically be c

  • billing_cycle_anchor_configuration (Orb::Models::BillingCycleAnchorConfiguration) (defaults to: )
  • billing_cycle_day (Integer) (defaults to: )

    The day of the month on which the billing cycle is anchored. If the maximum numb

  • created_at (Time) (defaults to: )
  • current_billing_period_end_date (Time, nil) (defaults to: )

    The end of the current billing period. This is an exclusive timestamp, such that

  • current_billing_period_start_date (Time, nil) (defaults to: )

    The start date of the current billing period. This is an inclusive timestamp; th

  • customer (Orb::Models::Customer) (defaults to: )

    A customer is a buyer of your products, and the other party to the billing relat

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

    Determines the default memo on this subscriptions’ invoices. Note that if this i

  • discount_intervals (Array<Orb::Models::AmountDiscountInterval, Orb::Models::PercentageDiscountInterval, Orb::Models::UsageDiscountInterval>) (defaults to: )

    The discount intervals for this subscription sorted by the start_date. This fiel

  • end_date (Time, nil) (defaults to: )

    The date Orb stops billing for this subscription.

  • fixed_fee_quantity_schedule (Array<Orb::Models::FixedFeeQuantityScheduleEntry>) (defaults to: )
  • invoicing_threshold (String, nil) (defaults to: )
  • maximum_intervals (Array<Orb::Models::MaximumInterval>) (defaults to: )

    The maximum intervals for this subscription sorted by the start_date. This field

  • metadata (Hash{Symbol=>String}) (defaults to: )

    User specified key-value pairs for the resource. If not present, this defaults t

  • minimum_intervals (Array<Orb::Models::MinimumInterval>) (defaults to: )

    The minimum intervals for this subscription sorted by the start_date. This field

  • name (String) (defaults to: )

    The name of the subscription.

  • net_terms (Integer) (defaults to: )

    Determines the difference between the invoice issue date for subscription invoic

  • pending_subscription_change (Orb::Models::SubscriptionChangeMinified, nil) (defaults to: )

    A pending subscription change if one exists on this subscription.

  • plan (Orb::Models::Plan, nil) (defaults to: )

    The [Plan](/core-concepts#plan-and-price) resource represents a plan that can be

  • price_intervals (Array<Orb::Models::PriceInterval>) (defaults to: )

    The price intervals for this subscription.

  • redeemed_coupon (Orb::Models::CouponRedemption, nil) (defaults to: )
  • start_date (Time) (defaults to: )

    The date Orb starts billing for this subscription.

  • status (Symbol, Orb::Models::MutatedSubscription::Status) (defaults to: )
  • trial_info (Orb::Models::SubscriptionTrialInfo) (defaults to: )
  • changed_resources (Orb::Models::ChangedSubscriptionResources, nil) (defaults to: nil)

    The resources that were changed as part of this operation. Only present when fet



277
278
279
280
281
282
283
284
285
286
287
288
289
290
# File 'lib/orb/models/mutated_subscription.rb', line 277

module DiscountInterval
  extend Orb::Internal::Type::Union

  discriminator :discount_type

  variant :amount, -> { Orb::AmountDiscountInterval }

  variant :percentage, -> { Orb::PercentageDiscountInterval }

  variant :usage, -> { Orb::UsageDiscountInterval }

  # @!method self.variants
  #   @return [Array(Orb::Models::AmountDiscountInterval, Orb::Models::PercentageDiscountInterval, Orb::Models::UsageDiscountInterval)]
end