orb-billing 0.5.5 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -0
- data/README.md +1 -1
- data/lib/orb/internal/type/base_model.rb +2 -2
- data/lib/orb/internal/type/union.rb +6 -6
- data/lib/orb/models/alert.rb +33 -1
- data/lib/orb/models/amount_discount.rb +10 -10
- data/lib/orb/models/credit_note_create_params.rb +9 -9
- data/lib/orb/models/customer_create_params.rb +21 -3
- data/lib/orb/models/customer_update_by_external_id_params.rb +21 -3
- data/lib/orb/models/customer_update_params.rb +21 -3
- data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rb +9 -1
- data/lib/orb/models/customers/credits/ledger_create_entry_response.rb +9 -1
- data/lib/orb/models/customers/credits/ledger_list_by_external_id_response.rb +9 -1
- data/lib/orb/models/customers/credits/ledger_list_response.rb +9 -1
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_params.rb +1 -1
- data/lib/orb/models/customers/credits/top_up_create_params.rb +1 -1
- data/lib/orb/models/invoice.rb +626 -9
- data/lib/orb/models/invoice_fetch_upcoming_response.rb +624 -9
- data/lib/orb/models/invoice_line_item_create_response.rb +486 -7
- data/lib/orb/models/item.rb +18 -1
- data/lib/orb/models/item_archive_params.rb +14 -0
- data/lib/orb/models/item_create_params.rb +14 -1
- data/lib/orb/models/item_update_params.rb +16 -1
- data/lib/orb/models/percentage_discount.rb +10 -10
- data/lib/orb/models/plan.rb +618 -9
- data/lib/orb/models/plan_create_params.rb +2066 -30
- data/lib/orb/models/plan_set_default_version_params.rb +22 -0
- data/lib/orb/models/plans/external_plan_id/version_create_params.rb +17948 -0
- data/lib/orb/models/plans/external_plan_id/version_create_response.rb +819 -0
- data/lib/orb/models/plans/external_plan_id/version_retrieve_params.rb +24 -0
- data/lib/orb/models/plans/external_plan_id/version_retrieve_response.rb +819 -0
- data/lib/orb/models/plans/external_plan_id_set_default_version_params.rb +24 -0
- data/lib/orb/models/plans/version_create_params.rb +17794 -0
- data/lib/orb/models/plans/version_create_response.rb +814 -0
- data/lib/orb/models/plans/version_retrieve_params.rb +22 -0
- data/lib/orb/models/plans/version_retrieve_response.rb +814 -0
- data/lib/orb/models/price.rb +4124 -70
- data/lib/orb/models/price_create_params.rb +45 -1
- data/lib/orb/models/price_evaluate_params.rb +8529 -21
- data/lib/orb/models/price_evaluate_response.rb +38 -3
- data/lib/orb/models/subscription.rb +730 -54
- data/lib/orb/models/subscription_cancel_response.rb +706 -54
- data/lib/orb/models/subscription_change_apply_response.rb +728 -54
- data/lib/orb/models/subscription_change_cancel_response.rb +728 -54
- data/lib/orb/models/subscription_change_retrieve_response.rb +728 -54
- data/lib/orb/models/subscription_create_params.rb +5992 -1698
- data/lib/orb/models/subscription_create_response.rb +706 -54
- data/lib/orb/models/subscription_fetch_schedule_response.rb +3 -3
- data/lib/orb/models/subscription_price_intervals_params.rb +1392 -76
- data/lib/orb/models/subscription_price_intervals_response.rb +712 -54
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +6005 -1723
- data/lib/orb/models/subscription_schedule_plan_change_response.rb +716 -54
- data/lib/orb/models/subscription_trigger_phase_response.rb +708 -54
- data/lib/orb/models/subscription_unschedule_cancellation_response.rb +720 -54
- data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rb +728 -54
- data/lib/orb/models/subscription_unschedule_pending_plan_changes_response.rb +728 -54
- data/lib/orb/models/subscription_update_fixed_fee_quantity_params.rb +1 -1
- data/lib/orb/models/subscription_update_fixed_fee_quantity_response.rb +720 -54
- data/lib/orb/models/subscription_update_trial_response.rb +706 -54
- data/lib/orb/models/trial_discount.rb +10 -10
- data/lib/orb/models/usage_discount.rb +10 -10
- data/lib/orb/models.rb +4 -0
- data/lib/orb/resources/credit_notes.rb +3 -3
- data/lib/orb/resources/customers/balance_transactions.rb +0 -7
- data/lib/orb/resources/customers.rb +4 -7
- data/lib/orb/resources/dimensional_price_groups.rb +1 -1
- data/lib/orb/resources/items.rb +34 -2
- data/lib/orb/resources/plans/external_plan_id/versions.rb +88 -0
- data/lib/orb/resources/plans/external_plan_id.rb +32 -1
- data/lib/orb/resources/plans/versions.rb +86 -0
- data/lib/orb/resources/plans.rb +33 -2
- data/lib/orb/resources/prices.rb +23 -17
- data/lib/orb/resources/subscriptions.rb +5 -1
- data/lib/orb/version.rb +1 -1
- data/lib/orb.rb +13 -0
- data/rbi/orb/models/alert.rbi +50 -3
- data/rbi/orb/models/amount_discount.rbi +8 -8
- data/rbi/orb/models/credit_note_create_params.rbi +8 -8
- data/rbi/orb/models/customer_create_params.rbi +38 -4
- data/rbi/orb/models/customer_update_by_external_id_params.rbi +38 -4
- data/rbi/orb/models/customer_update_params.rbi +38 -4
- data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbi +9 -1
- data/rbi/orb/models/customers/credits/ledger_create_entry_response.rbi +9 -1
- data/rbi/orb/models/customers/credits/ledger_list_by_external_id_response.rbi +9 -1
- data/rbi/orb/models/customers/credits/ledger_list_response.rbi +9 -1
- data/rbi/orb/models/customers/credits/top_up_create_by_external_id_params.rbi +2 -2
- data/rbi/orb/models/customers/credits/top_up_create_params.rbi +2 -2
- data/rbi/orb/models/invoice.rbi +1451 -35
- data/rbi/orb/models/invoice_fetch_upcoming_response.rbi +1524 -4
- data/rbi/orb/models/invoice_line_item_create_response.rbi +1184 -2
- data/rbi/orb/models/item.rbi +20 -1
- data/rbi/orb/models/item_archive_params.rbi +25 -0
- data/rbi/orb/models/item_create_params.rbi +18 -1
- data/rbi/orb/models/item_update_params.rbi +17 -1
- data/rbi/orb/models/percentage_discount.rbi +10 -10
- data/rbi/orb/models/plan.rbi +1339 -4
- data/rbi/orb/models/plan_create_params.rbi +3833 -29
- data/rbi/orb/models/plan_set_default_version_params.rbi +40 -0
- data/rbi/orb/models/plans/external_plan_id/version_create_params.rbi +32668 -0
- data/rbi/orb/models/plans/external_plan_id/version_create_response.rbi +1562 -0
- data/rbi/orb/models/plans/external_plan_id/version_retrieve_params.rbi +42 -0
- data/rbi/orb/models/plans/external_plan_id/version_retrieve_response.rbi +1562 -0
- data/rbi/orb/models/plans/external_plan_id_set_default_version_params.rbi +45 -0
- data/rbi/orb/models/plans/version_create_params.rbi +32607 -0
- data/rbi/orb/models/plans/version_create_response.rbi +1556 -0
- data/rbi/orb/models/plans/version_retrieve_params.rbi +37 -0
- data/rbi/orb/models/plans/version_retrieve_response.rbi +1558 -0
- data/rbi/orb/models/price.rbi +9447 -441
- data/rbi/orb/models/price_create_params.rbi +80 -0
- data/rbi/orb/models/price_evaluate_params.rbi +15684 -25
- data/rbi/orb/models/price_evaluate_response.rbi +68 -5
- data/rbi/orb/models/subscription.rbi +1654 -44
- data/rbi/orb/models/subscription_cancel_response.rbi +1692 -44
- data/rbi/orb/models/subscription_change_apply_response.rbi +1692 -44
- data/rbi/orb/models/subscription_change_cancel_response.rbi +1692 -44
- data/rbi/orb/models/subscription_change_retrieve_response.rbi +1692 -44
- data/rbi/orb/models/subscription_create_params.rbi +10400 -2710
- data/rbi/orb/models/subscription_create_response.rbi +1692 -44
- data/rbi/orb/models/subscription_fetch_schedule_response.rbi +13 -4
- data/rbi/orb/models/subscription_price_intervals_params.rbi +2401 -49
- data/rbi/orb/models/subscription_price_intervals_response.rbi +1692 -44
- data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +10423 -2753
- data/rbi/orb/models/subscription_schedule_plan_change_response.rbi +1692 -44
- data/rbi/orb/models/subscription_trigger_phase_response.rbi +1692 -44
- data/rbi/orb/models/subscription_unschedule_cancellation_response.rbi +1692 -44
- data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbi +1692 -44
- data/rbi/orb/models/subscription_unschedule_pending_plan_changes_response.rbi +1692 -44
- data/rbi/orb/models/subscription_update_fixed_fee_quantity_params.rbi +2 -2
- data/rbi/orb/models/subscription_update_fixed_fee_quantity_response.rbi +1692 -44
- data/rbi/orb/models/subscription_update_trial_response.rbi +1692 -44
- data/rbi/orb/models/trial_discount.rbi +8 -8
- data/rbi/orb/models/usage_discount.rbi +10 -10
- data/rbi/orb/models.rbi +4 -0
- data/rbi/orb/resources/credit_notes.rbi +3 -3
- data/rbi/orb/resources/customers/balance_transactions.rbi +0 -7
- data/rbi/orb/resources/customers/credits/top_ups.rbi +2 -2
- data/rbi/orb/resources/customers.rbi +7 -7
- data/rbi/orb/resources/dimensional_price_groups.rbi +1 -1
- data/rbi/orb/resources/items.rbi +20 -0
- data/rbi/orb/resources/plans/external_plan_id/versions.rbi +103 -0
- data/rbi/orb/resources/plans/external_plan_id.rbi +23 -1
- data/rbi/orb/resources/plans/versions.rbi +91 -0
- data/rbi/orb/resources/plans.rbi +27 -2
- data/rbi/orb/resources/prices.rbi +27 -17
- data/rbi/orb/resources/subscriptions.rbi +9 -1
- data/sig/orb/models/alert.rbs +20 -3
- data/sig/orb/models/amount_discount.rbs +5 -5
- data/sig/orb/models/credit_note_create_params.rbs +6 -6
- data/sig/orb/models/customer_create_params.rbs +13 -0
- data/sig/orb/models/customer_update_by_external_id_params.rbs +13 -0
- data/sig/orb/models/customer_update_params.rbs +13 -0
- data/sig/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbs +7 -2
- data/sig/orb/models/customers/credits/ledger_create_entry_response.rbs +7 -2
- data/sig/orb/models/customers/credits/ledger_list_by_external_id_response.rbs +7 -2
- data/sig/orb/models/customers/credits/ledger_list_response.rbs +7 -2
- data/sig/orb/models/invoice.rbs +558 -4
- data/sig/orb/models/invoice_fetch_upcoming_response.rbs +558 -4
- data/sig/orb/models/invoice_line_item_create_response.rbs +414 -2
- data/sig/orb/models/item.rbs +5 -0
- data/sig/orb/models/item_archive_params.rbs +14 -0
- data/sig/orb/models/item_create_params.rbs +10 -2
- data/sig/orb/models/item_update_params.rbs +5 -0
- data/sig/orb/models/percentage_discount.rbs +5 -5
- data/sig/orb/models/plan.rbs +538 -4
- data/sig/orb/models/plan_create_params.rbs +1460 -3
- data/sig/orb/models/plan_set_default_version_params.rbs +20 -0
- data/sig/orb/models/plans/external_plan_id/version_create_params.rbs +12923 -0
- data/sig/orb/models/plans/external_plan_id/version_create_response.rbs +664 -0
- data/sig/orb/models/plans/external_plan_id/version_retrieve_params.rbs +27 -0
- data/sig/orb/models/plans/external_plan_id/version_retrieve_response.rbs +664 -0
- data/sig/orb/models/plans/external_plan_id_set_default_version_params.rbs +25 -0
- data/sig/orb/models/plans/version_create_params.rbs +12898 -0
- data/sig/orb/models/plans/version_create_response.rbs +662 -0
- data/sig/orb/models/plans/version_retrieve_params.rbs +25 -0
- data/sig/orb/models/plans/version_retrieve_response.rbs +662 -0
- data/sig/orb/models/price.rbs +3512 -96
- data/sig/orb/models/price_create_params.rbs +32 -0
- data/sig/orb/models/price_evaluate_params.rbs +6187 -10
- data/sig/orb/models/price_evaluate_response.rbs +41 -4
- data/sig/orb/models/subscription.rbs +609 -29
- data/sig/orb/models/subscription_cancel_response.rbs +609 -29
- data/sig/orb/models/subscription_change_apply_response.rbs +621 -29
- data/sig/orb/models/subscription_change_cancel_response.rbs +621 -29
- data/sig/orb/models/subscription_change_retrieve_response.rbs +621 -29
- data/sig/orb/models/subscription_create_params.rbs +4450 -1466
- data/sig/orb/models/subscription_create_response.rbs +609 -29
- data/sig/orb/models/subscription_fetch_schedule_response.rbs +4 -4
- data/sig/orb/models/subscription_price_intervals_params.rbs +920 -24
- data/sig/orb/models/subscription_price_intervals_response.rbs +609 -29
- data/sig/orb/models/subscription_schedule_plan_change_params.rbs +4440 -1466
- data/sig/orb/models/subscription_schedule_plan_change_response.rbs +609 -29
- data/sig/orb/models/subscription_trigger_phase_response.rbs +609 -29
- data/sig/orb/models/subscription_unschedule_cancellation_response.rbs +609 -29
- data/sig/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbs +609 -29
- data/sig/orb/models/subscription_unschedule_pending_plan_changes_response.rbs +609 -29
- data/sig/orb/models/subscription_update_fixed_fee_quantity_response.rbs +609 -29
- data/sig/orb/models/subscription_update_trial_response.rbs +609 -29
- data/sig/orb/models/trial_discount.rbs +5 -5
- data/sig/orb/models/usage_discount.rbs +5 -5
- data/sig/orb/models.rbs +4 -0
- data/sig/orb/resources/credit_notes.rbs +1 -1
- data/sig/orb/resources/items.rbs +7 -0
- data/sig/orb/resources/plans/external_plan_id/versions.rbs +30 -0
- data/sig/orb/resources/plans/external_plan_id.rbs +8 -0
- data/sig/orb/resources/plans/versions.rbs +28 -0
- data/sig/orb/resources/plans.rbs +8 -0
- data/sig/orb/resources/prices.rbs +3 -3
- data/sig/orb/resources/subscriptions.rbs +2 -0
- metadata +40 -1
@@ -99,6 +99,8 @@ module Orb
|
|
99
99
|
required :default_invoice_memo, String, nil?: true
|
100
100
|
|
101
101
|
# @!attribute discount_intervals
|
102
|
+
# @deprecated
|
103
|
+
#
|
102
104
|
# The discount intervals for this subscription sorted by the start_date.
|
103
105
|
#
|
104
106
|
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage>]
|
@@ -123,6 +125,8 @@ module Orb
|
|
123
125
|
required :invoicing_threshold, String, nil?: true
|
124
126
|
|
125
127
|
# @!attribute maximum_intervals
|
128
|
+
# @deprecated
|
129
|
+
#
|
126
130
|
# The maximum intervals for this subscription sorted by the start_date.
|
127
131
|
#
|
128
132
|
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval>]
|
@@ -139,12 +143,20 @@ module Orb
|
|
139
143
|
required :metadata, Orb::Internal::Type::HashOf[String]
|
140
144
|
|
141
145
|
# @!attribute minimum_intervals
|
146
|
+
# @deprecated
|
147
|
+
#
|
142
148
|
# The minimum intervals for this subscription sorted by the start_date.
|
143
149
|
#
|
144
150
|
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval>]
|
145
151
|
required :minimum_intervals,
|
146
152
|
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval] }
|
147
153
|
|
154
|
+
# @!attribute name
|
155
|
+
# The name of the subscription.
|
156
|
+
#
|
157
|
+
# @return [String]
|
158
|
+
required :name, String
|
159
|
+
|
148
160
|
# @!attribute net_terms
|
149
161
|
# Determines the difference between the invoice issue date for subscription
|
150
162
|
# invoices as the date that they are due. A value of `0` here represents that the
|
@@ -168,8 +180,8 @@ module Orb
|
|
168
180
|
# subscription. You can see more about how to configure prices in the
|
169
181
|
# [Price resource](/reference/price).
|
170
182
|
#
|
171
|
-
# @return [Orb::Models::Plan]
|
172
|
-
required :plan, -> { Orb::Plan }
|
183
|
+
# @return [Orb::Models::Plan, nil]
|
184
|
+
required :plan, -> { Orb::Plan }, nil?: true
|
173
185
|
|
174
186
|
# @!attribute price_intervals
|
175
187
|
# The price intervals for this subscription.
|
@@ -211,7 +223,7 @@ module Orb
|
|
211
223
|
-> { Orb::Models::SubscriptionPriceIntervalsResponse::ChangedResources },
|
212
224
|
nil?: true
|
213
225
|
|
214
|
-
# @!method 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:, net_terms:, pending_subscription_change:, plan:, price_intervals:, redeemed_coupon:, start_date:, status:, trial_info:, changed_resources: nil)
|
226
|
+
# @!method 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)
|
215
227
|
# Some parameter documentations has been truncated, see
|
216
228
|
# {Orb::Models::SubscriptionPriceIntervalsResponse} for more details.
|
217
229
|
#
|
@@ -251,11 +263,13 @@ module Orb
|
|
251
263
|
#
|
252
264
|
# @param minimum_intervals [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval>] The minimum intervals for this subscription sorted by the start_date.
|
253
265
|
#
|
266
|
+
# @param name [String] The name of the subscription.
|
267
|
+
#
|
254
268
|
# @param net_terms [Integer] Determines the difference between the invoice issue date for subscription invoic
|
255
269
|
#
|
256
270
|
# @param pending_subscription_change [Orb::Models::SubscriptionPriceIntervalsResponse::PendingSubscriptionChange, nil] A pending subscription change if one exists on this subscription.
|
257
271
|
#
|
258
|
-
# @param plan [Orb::Models::Plan] The [Plan](/core-concepts#plan-and-price) resource represents a plan that can be
|
272
|
+
# @param plan [Orb::Models::Plan, nil] The [Plan](/core-concepts#plan-and-price) resource represents a plan that can be
|
259
273
|
#
|
260
274
|
# @param price_intervals [Array<Orb::Models::SubscriptionPriceIntervalsResponse::PriceInterval>] The price intervals for this subscription.
|
261
275
|
#
|
@@ -343,11 +357,20 @@ module Orb
|
|
343
357
|
required :adjustment_type, const: :usage_discount
|
344
358
|
|
345
359
|
# @!attribute applies_to_price_ids
|
360
|
+
# @deprecated
|
361
|
+
#
|
346
362
|
# The price IDs that this adjustment applies to.
|
347
363
|
#
|
348
364
|
# @return [Array<String>]
|
349
365
|
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
350
366
|
|
367
|
+
# @!attribute filters
|
368
|
+
# The filters that determine which prices to apply this adjustment to.
|
369
|
+
#
|
370
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter>]
|
371
|
+
required :filters,
|
372
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter] }
|
373
|
+
|
351
374
|
# @!attribute is_invoice_level
|
352
375
|
# True for adjustments that apply to an entire invocice, false for adjustments
|
353
376
|
# that apply to only one price.
|
@@ -374,7 +397,7 @@ module Orb
|
|
374
397
|
# @return [Float]
|
375
398
|
required :usage_discount, Float
|
376
399
|
|
377
|
-
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, plan_phase_order:, reason:, usage_discount:, adjustment_type: :usage_discount)
|
400
|
+
# @!method initialize(id:, applies_to_price_ids:, filters:, is_invoice_level:, plan_phase_order:, reason:, usage_discount:, adjustment_type: :usage_discount)
|
378
401
|
# Some parameter documentations has been truncated, see
|
379
402
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount}
|
380
403
|
# for more details.
|
@@ -383,6 +406,8 @@ module Orb
|
|
383
406
|
#
|
384
407
|
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
385
408
|
#
|
409
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter>] The filters that determine which prices to apply this adjustment to.
|
410
|
+
#
|
386
411
|
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
387
412
|
#
|
388
413
|
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
@@ -392,6 +417,64 @@ module Orb
|
|
392
417
|
# @param usage_discount [Float] The number of usage units by which to discount the price this adjustment applies
|
393
418
|
#
|
394
419
|
# @param adjustment_type [Symbol, :usage_discount]
|
420
|
+
|
421
|
+
class Filter < Orb::Internal::Type::BaseModel
|
422
|
+
# @!attribute field
|
423
|
+
# The property of the price to filter on.
|
424
|
+
#
|
425
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field]
|
426
|
+
required :field,
|
427
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field }
|
428
|
+
|
429
|
+
# @!attribute operator
|
430
|
+
# Should prices that match the filter be included or excluded.
|
431
|
+
#
|
432
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator]
|
433
|
+
required :operator,
|
434
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator }
|
435
|
+
|
436
|
+
# @!attribute values
|
437
|
+
# The IDs or values that match this filter.
|
438
|
+
#
|
439
|
+
# @return [Array<String>]
|
440
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
441
|
+
|
442
|
+
# @!method initialize(field:, operator:, values:)
|
443
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Field] The property of the price to filter on.
|
444
|
+
#
|
445
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
446
|
+
#
|
447
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
448
|
+
|
449
|
+
# The property of the price to filter on.
|
450
|
+
#
|
451
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter#field
|
452
|
+
module Field
|
453
|
+
extend Orb::Internal::Type::Enum
|
454
|
+
|
455
|
+
PRICE_ID = :price_id
|
456
|
+
ITEM_ID = :item_id
|
457
|
+
PRICE_TYPE = :price_type
|
458
|
+
CURRENCY = :currency
|
459
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
460
|
+
|
461
|
+
# @!method self.values
|
462
|
+
# @return [Array<Symbol>]
|
463
|
+
end
|
464
|
+
|
465
|
+
# Should prices that match the filter be included or excluded.
|
466
|
+
#
|
467
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::UsageDiscount::Filter#operator
|
468
|
+
module Operator
|
469
|
+
extend Orb::Internal::Type::Enum
|
470
|
+
|
471
|
+
INCLUDES = :includes
|
472
|
+
EXCLUDES = :excludes
|
473
|
+
|
474
|
+
# @!method self.values
|
475
|
+
# @return [Array<Symbol>]
|
476
|
+
end
|
477
|
+
end
|
395
478
|
end
|
396
479
|
|
397
480
|
class AmountDiscount < Orb::Internal::Type::BaseModel
|
@@ -413,11 +496,20 @@ module Orb
|
|
413
496
|
required :amount_discount, String
|
414
497
|
|
415
498
|
# @!attribute applies_to_price_ids
|
499
|
+
# @deprecated
|
500
|
+
#
|
416
501
|
# The price IDs that this adjustment applies to.
|
417
502
|
#
|
418
503
|
# @return [Array<String>]
|
419
504
|
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
420
505
|
|
506
|
+
# @!attribute filters
|
507
|
+
# The filters that determine which prices to apply this adjustment to.
|
508
|
+
#
|
509
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter>]
|
510
|
+
required :filters,
|
511
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter] }
|
512
|
+
|
421
513
|
# @!attribute is_invoice_level
|
422
514
|
# True for adjustments that apply to an entire invocice, false for adjustments
|
423
515
|
# that apply to only one price.
|
@@ -437,7 +529,7 @@ module Orb
|
|
437
529
|
# @return [String, nil]
|
438
530
|
required :reason, String, nil?: true
|
439
531
|
|
440
|
-
# @!method initialize(id:, amount_discount:, applies_to_price_ids:, is_invoice_level:, plan_phase_order:, reason:, adjustment_type: :amount_discount)
|
532
|
+
# @!method initialize(id:, amount_discount:, applies_to_price_ids:, filters:, is_invoice_level:, plan_phase_order:, reason:, adjustment_type: :amount_discount)
|
441
533
|
# Some parameter documentations has been truncated, see
|
442
534
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount}
|
443
535
|
# for more details.
|
@@ -448,6 +540,8 @@ module Orb
|
|
448
540
|
#
|
449
541
|
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
450
542
|
#
|
543
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter>] The filters that determine which prices to apply this adjustment to.
|
544
|
+
#
|
451
545
|
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
452
546
|
#
|
453
547
|
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
@@ -455,6 +549,64 @@ module Orb
|
|
455
549
|
# @param reason [String, nil] The reason for the adjustment.
|
456
550
|
#
|
457
551
|
# @param adjustment_type [Symbol, :amount_discount]
|
552
|
+
|
553
|
+
class Filter < Orb::Internal::Type::BaseModel
|
554
|
+
# @!attribute field
|
555
|
+
# The property of the price to filter on.
|
556
|
+
#
|
557
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field]
|
558
|
+
required :field,
|
559
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field }
|
560
|
+
|
561
|
+
# @!attribute operator
|
562
|
+
# Should prices that match the filter be included or excluded.
|
563
|
+
#
|
564
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator]
|
565
|
+
required :operator,
|
566
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator }
|
567
|
+
|
568
|
+
# @!attribute values
|
569
|
+
# The IDs or values that match this filter.
|
570
|
+
#
|
571
|
+
# @return [Array<String>]
|
572
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
573
|
+
|
574
|
+
# @!method initialize(field:, operator:, values:)
|
575
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Field] The property of the price to filter on.
|
576
|
+
#
|
577
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
578
|
+
#
|
579
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
580
|
+
|
581
|
+
# The property of the price to filter on.
|
582
|
+
#
|
583
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter#field
|
584
|
+
module Field
|
585
|
+
extend Orb::Internal::Type::Enum
|
586
|
+
|
587
|
+
PRICE_ID = :price_id
|
588
|
+
ITEM_ID = :item_id
|
589
|
+
PRICE_TYPE = :price_type
|
590
|
+
CURRENCY = :currency
|
591
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
592
|
+
|
593
|
+
# @!method self.values
|
594
|
+
# @return [Array<Symbol>]
|
595
|
+
end
|
596
|
+
|
597
|
+
# Should prices that match the filter be included or excluded.
|
598
|
+
#
|
599
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::AmountDiscount::Filter#operator
|
600
|
+
module Operator
|
601
|
+
extend Orb::Internal::Type::Enum
|
602
|
+
|
603
|
+
INCLUDES = :includes
|
604
|
+
EXCLUDES = :excludes
|
605
|
+
|
606
|
+
# @!method self.values
|
607
|
+
# @return [Array<Symbol>]
|
608
|
+
end
|
609
|
+
end
|
458
610
|
end
|
459
611
|
|
460
612
|
class PercentageDiscount < Orb::Internal::Type::BaseModel
|
@@ -469,11 +621,24 @@ module Orb
|
|
469
621
|
required :adjustment_type, const: :percentage_discount
|
470
622
|
|
471
623
|
# @!attribute applies_to_price_ids
|
624
|
+
# @deprecated
|
625
|
+
#
|
472
626
|
# The price IDs that this adjustment applies to.
|
473
627
|
#
|
474
628
|
# @return [Array<String>]
|
475
629
|
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
476
630
|
|
631
|
+
# @!attribute filters
|
632
|
+
# The filters that determine which prices to apply this adjustment to.
|
633
|
+
#
|
634
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter>]
|
635
|
+
required :filters,
|
636
|
+
-> do
|
637
|
+
Orb::Internal::Type::ArrayOf[
|
638
|
+
Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter
|
639
|
+
]
|
640
|
+
end
|
641
|
+
|
477
642
|
# @!attribute is_invoice_level
|
478
643
|
# True for adjustments that apply to an entire invocice, false for adjustments
|
479
644
|
# that apply to only one price.
|
@@ -500,7 +665,7 @@ module Orb
|
|
500
665
|
# @return [String, nil]
|
501
666
|
required :reason, String, nil?: true
|
502
667
|
|
503
|
-
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, percentage_discount:, plan_phase_order:, reason:, adjustment_type: :percentage_discount)
|
668
|
+
# @!method initialize(id:, applies_to_price_ids:, filters:, is_invoice_level:, percentage_discount:, plan_phase_order:, reason:, adjustment_type: :percentage_discount)
|
504
669
|
# Some parameter documentations has been truncated, see
|
505
670
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount}
|
506
671
|
# for more details.
|
@@ -509,6 +674,8 @@ module Orb
|
|
509
674
|
#
|
510
675
|
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
511
676
|
#
|
677
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter>] The filters that determine which prices to apply this adjustment to.
|
678
|
+
#
|
512
679
|
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
513
680
|
#
|
514
681
|
# @param percentage_discount [Float] The percentage (as a value between 0 and 1) by which to discount the price inter
|
@@ -518,6 +685,64 @@ module Orb
|
|
518
685
|
# @param reason [String, nil] The reason for the adjustment.
|
519
686
|
#
|
520
687
|
# @param adjustment_type [Symbol, :percentage_discount]
|
688
|
+
|
689
|
+
class Filter < Orb::Internal::Type::BaseModel
|
690
|
+
# @!attribute field
|
691
|
+
# The property of the price to filter on.
|
692
|
+
#
|
693
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field]
|
694
|
+
required :field,
|
695
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field }
|
696
|
+
|
697
|
+
# @!attribute operator
|
698
|
+
# Should prices that match the filter be included or excluded.
|
699
|
+
#
|
700
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator]
|
701
|
+
required :operator,
|
702
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator }
|
703
|
+
|
704
|
+
# @!attribute values
|
705
|
+
# The IDs or values that match this filter.
|
706
|
+
#
|
707
|
+
# @return [Array<String>]
|
708
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
709
|
+
|
710
|
+
# @!method initialize(field:, operator:, values:)
|
711
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Field] The property of the price to filter on.
|
712
|
+
#
|
713
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
714
|
+
#
|
715
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
716
|
+
|
717
|
+
# The property of the price to filter on.
|
718
|
+
#
|
719
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter#field
|
720
|
+
module Field
|
721
|
+
extend Orb::Internal::Type::Enum
|
722
|
+
|
723
|
+
PRICE_ID = :price_id
|
724
|
+
ITEM_ID = :item_id
|
725
|
+
PRICE_TYPE = :price_type
|
726
|
+
CURRENCY = :currency
|
727
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
728
|
+
|
729
|
+
# @!method self.values
|
730
|
+
# @return [Array<Symbol>]
|
731
|
+
end
|
732
|
+
|
733
|
+
# Should prices that match the filter be included or excluded.
|
734
|
+
#
|
735
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::PercentageDiscount::Filter#operator
|
736
|
+
module Operator
|
737
|
+
extend Orb::Internal::Type::Enum
|
738
|
+
|
739
|
+
INCLUDES = :includes
|
740
|
+
EXCLUDES = :excludes
|
741
|
+
|
742
|
+
# @!method self.values
|
743
|
+
# @return [Array<Symbol>]
|
744
|
+
end
|
745
|
+
end
|
521
746
|
end
|
522
747
|
|
523
748
|
class Minimum < Orb::Internal::Type::BaseModel
|
@@ -532,11 +757,20 @@ module Orb
|
|
532
757
|
required :adjustment_type, const: :minimum
|
533
758
|
|
534
759
|
# @!attribute applies_to_price_ids
|
760
|
+
# @deprecated
|
761
|
+
#
|
535
762
|
# The price IDs that this adjustment applies to.
|
536
763
|
#
|
537
764
|
# @return [Array<String>]
|
538
765
|
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
539
766
|
|
767
|
+
# @!attribute filters
|
768
|
+
# The filters that determine which prices to apply this adjustment to.
|
769
|
+
#
|
770
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter>]
|
771
|
+
required :filters,
|
772
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter] }
|
773
|
+
|
540
774
|
# @!attribute is_invoice_level
|
541
775
|
# True for adjustments that apply to an entire invocice, false for adjustments
|
542
776
|
# that apply to only one price.
|
@@ -569,7 +803,7 @@ module Orb
|
|
569
803
|
# @return [String, nil]
|
570
804
|
required :reason, String, nil?: true
|
571
805
|
|
572
|
-
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, item_id:, minimum_amount:, plan_phase_order:, reason:, adjustment_type: :minimum)
|
806
|
+
# @!method initialize(id:, applies_to_price_ids:, filters:, is_invoice_level:, item_id:, minimum_amount:, plan_phase_order:, reason:, adjustment_type: :minimum)
|
573
807
|
# Some parameter documentations has been truncated, see
|
574
808
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum}
|
575
809
|
# for more details.
|
@@ -578,6 +812,8 @@ module Orb
|
|
578
812
|
#
|
579
813
|
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
580
814
|
#
|
815
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter>] The filters that determine which prices to apply this adjustment to.
|
816
|
+
#
|
581
817
|
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
582
818
|
#
|
583
819
|
# @param item_id [String] The item ID that revenue from this minimum will be attributed to.
|
@@ -589,6 +825,64 @@ module Orb
|
|
589
825
|
# @param reason [String, nil] The reason for the adjustment.
|
590
826
|
#
|
591
827
|
# @param adjustment_type [Symbol, :minimum]
|
828
|
+
|
829
|
+
class Filter < Orb::Internal::Type::BaseModel
|
830
|
+
# @!attribute field
|
831
|
+
# The property of the price to filter on.
|
832
|
+
#
|
833
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field]
|
834
|
+
required :field,
|
835
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field }
|
836
|
+
|
837
|
+
# @!attribute operator
|
838
|
+
# Should prices that match the filter be included or excluded.
|
839
|
+
#
|
840
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator]
|
841
|
+
required :operator,
|
842
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator }
|
843
|
+
|
844
|
+
# @!attribute values
|
845
|
+
# The IDs or values that match this filter.
|
846
|
+
#
|
847
|
+
# @return [Array<String>]
|
848
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
849
|
+
|
850
|
+
# @!method initialize(field:, operator:, values:)
|
851
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Field] The property of the price to filter on.
|
852
|
+
#
|
853
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter::Operator] Should prices that match the filter be included or excluded.
|
854
|
+
#
|
855
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
856
|
+
|
857
|
+
# The property of the price to filter on.
|
858
|
+
#
|
859
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter#field
|
860
|
+
module Field
|
861
|
+
extend Orb::Internal::Type::Enum
|
862
|
+
|
863
|
+
PRICE_ID = :price_id
|
864
|
+
ITEM_ID = :item_id
|
865
|
+
PRICE_TYPE = :price_type
|
866
|
+
CURRENCY = :currency
|
867
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
868
|
+
|
869
|
+
# @!method self.values
|
870
|
+
# @return [Array<Symbol>]
|
871
|
+
end
|
872
|
+
|
873
|
+
# Should prices that match the filter be included or excluded.
|
874
|
+
#
|
875
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Minimum::Filter#operator
|
876
|
+
module Operator
|
877
|
+
extend Orb::Internal::Type::Enum
|
878
|
+
|
879
|
+
INCLUDES = :includes
|
880
|
+
EXCLUDES = :excludes
|
881
|
+
|
882
|
+
# @!method self.values
|
883
|
+
# @return [Array<Symbol>]
|
884
|
+
end
|
885
|
+
end
|
592
886
|
end
|
593
887
|
|
594
888
|
class Maximum < Orb::Internal::Type::BaseModel
|
@@ -603,11 +897,20 @@ module Orb
|
|
603
897
|
required :adjustment_type, const: :maximum
|
604
898
|
|
605
899
|
# @!attribute applies_to_price_ids
|
900
|
+
# @deprecated
|
901
|
+
#
|
606
902
|
# The price IDs that this adjustment applies to.
|
607
903
|
#
|
608
904
|
# @return [Array<String>]
|
609
905
|
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
610
906
|
|
907
|
+
# @!attribute filters
|
908
|
+
# The filters that determine which prices to apply this adjustment to.
|
909
|
+
#
|
910
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter>]
|
911
|
+
required :filters,
|
912
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter] }
|
913
|
+
|
611
914
|
# @!attribute is_invoice_level
|
612
915
|
# True for adjustments that apply to an entire invocice, false for adjustments
|
613
916
|
# that apply to only one price.
|
@@ -634,7 +937,7 @@ module Orb
|
|
634
937
|
# @return [String, nil]
|
635
938
|
required :reason, String, nil?: true
|
636
939
|
|
637
|
-
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, maximum_amount:, plan_phase_order:, reason:, adjustment_type: :maximum)
|
940
|
+
# @!method initialize(id:, applies_to_price_ids:, filters:, is_invoice_level:, maximum_amount:, plan_phase_order:, reason:, adjustment_type: :maximum)
|
638
941
|
# Some parameter documentations has been truncated, see
|
639
942
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum}
|
640
943
|
# for more details.
|
@@ -643,6 +946,8 @@ module Orb
|
|
643
946
|
#
|
644
947
|
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
645
948
|
#
|
949
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter>] The filters that determine which prices to apply this adjustment to.
|
950
|
+
#
|
646
951
|
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
647
952
|
#
|
648
953
|
# @param maximum_amount [String] The maximum amount to charge in a given billing period for the prices this adjus
|
@@ -652,6 +957,64 @@ module Orb
|
|
652
957
|
# @param reason [String, nil] The reason for the adjustment.
|
653
958
|
#
|
654
959
|
# @param adjustment_type [Symbol, :maximum]
|
960
|
+
|
961
|
+
class Filter < Orb::Internal::Type::BaseModel
|
962
|
+
# @!attribute field
|
963
|
+
# The property of the price to filter on.
|
964
|
+
#
|
965
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field]
|
966
|
+
required :field,
|
967
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field }
|
968
|
+
|
969
|
+
# @!attribute operator
|
970
|
+
# Should prices that match the filter be included or excluded.
|
971
|
+
#
|
972
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator]
|
973
|
+
required :operator,
|
974
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator }
|
975
|
+
|
976
|
+
# @!attribute values
|
977
|
+
# The IDs or values that match this filter.
|
978
|
+
#
|
979
|
+
# @return [Array<String>]
|
980
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
981
|
+
|
982
|
+
# @!method initialize(field:, operator:, values:)
|
983
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Field] The property of the price to filter on.
|
984
|
+
#
|
985
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter::Operator] Should prices that match the filter be included or excluded.
|
986
|
+
#
|
987
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
988
|
+
|
989
|
+
# The property of the price to filter on.
|
990
|
+
#
|
991
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter#field
|
992
|
+
module Field
|
993
|
+
extend Orb::Internal::Type::Enum
|
994
|
+
|
995
|
+
PRICE_ID = :price_id
|
996
|
+
ITEM_ID = :item_id
|
997
|
+
PRICE_TYPE = :price_type
|
998
|
+
CURRENCY = :currency
|
999
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1000
|
+
|
1001
|
+
# @!method self.values
|
1002
|
+
# @return [Array<Symbol>]
|
1003
|
+
end
|
1004
|
+
|
1005
|
+
# Should prices that match the filter be included or excluded.
|
1006
|
+
#
|
1007
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::AdjustmentInterval::Adjustment::Maximum::Filter#operator
|
1008
|
+
module Operator
|
1009
|
+
extend Orb::Internal::Type::Enum
|
1010
|
+
|
1011
|
+
INCLUDES = :includes
|
1012
|
+
EXCLUDES = :excludes
|
1013
|
+
|
1014
|
+
# @!method self.values
|
1015
|
+
# @return [Array<Symbol>]
|
1016
|
+
end
|
1017
|
+
end
|
655
1018
|
end
|
656
1019
|
|
657
1020
|
# @!method self.variants
|
@@ -715,12 +1078,6 @@ module Orb
|
|
715
1078
|
# @return [String]
|
716
1079
|
required :amount_discount, String
|
717
1080
|
|
718
|
-
# @!attribute applies_to_price_ids
|
719
|
-
# The price ids that this discount interval applies to.
|
720
|
-
#
|
721
|
-
# @return [Array<String>]
|
722
|
-
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
723
|
-
|
724
1081
|
# @!attribute applies_to_price_interval_ids
|
725
1082
|
# The price interval ids that this discount interval applies to.
|
726
1083
|
#
|
@@ -738,33 +1095,92 @@ module Orb
|
|
738
1095
|
# @return [Time, nil]
|
739
1096
|
required :end_date, Time, nil?: true
|
740
1097
|
|
1098
|
+
# @!attribute filters
|
1099
|
+
# The filters that determine which prices this discount interval applies to.
|
1100
|
+
#
|
1101
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter>]
|
1102
|
+
required :filters,
|
1103
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter] }
|
1104
|
+
|
741
1105
|
# @!attribute start_date
|
742
1106
|
# The start date of the discount interval.
|
743
1107
|
#
|
744
1108
|
# @return [Time]
|
745
1109
|
required :start_date, Time
|
746
1110
|
|
747
|
-
# @!method initialize(amount_discount:,
|
1111
|
+
# @!method initialize(amount_discount:, applies_to_price_interval_ids:, end_date:, filters:, start_date:, discount_type: :amount)
|
748
1112
|
# @param amount_discount [String] Only available if discount_type is `amount`.
|
749
1113
|
#
|
750
|
-
# @param applies_to_price_ids [Array<String>] The price ids that this discount interval applies to.
|
751
|
-
#
|
752
1114
|
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this discount interval applies to.
|
753
1115
|
#
|
754
1116
|
# @param end_date [Time, nil] The end date of the discount interval.
|
755
1117
|
#
|
1118
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter>] The filters that determine which prices this discount interval applies to.
|
1119
|
+
#
|
756
1120
|
# @param start_date [Time] The start date of the discount interval.
|
757
1121
|
#
|
758
1122
|
# @param discount_type [Symbol, :amount]
|
1123
|
+
|
1124
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1125
|
+
# @!attribute field
|
1126
|
+
# The property of the price to filter on.
|
1127
|
+
#
|
1128
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter::Field]
|
1129
|
+
required :field,
|
1130
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter::Field }
|
1131
|
+
|
1132
|
+
# @!attribute operator
|
1133
|
+
# Should prices that match the filter be included or excluded.
|
1134
|
+
#
|
1135
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter::Operator]
|
1136
|
+
required :operator,
|
1137
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter::Operator }
|
1138
|
+
|
1139
|
+
# @!attribute values
|
1140
|
+
# The IDs or values that match this filter.
|
1141
|
+
#
|
1142
|
+
# @return [Array<String>]
|
1143
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1144
|
+
|
1145
|
+
# @!method initialize(field:, operator:, values:)
|
1146
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter::Field] The property of the price to filter on.
|
1147
|
+
#
|
1148
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter::Operator] Should prices that match the filter be included or excluded.
|
1149
|
+
#
|
1150
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1151
|
+
|
1152
|
+
# The property of the price to filter on.
|
1153
|
+
#
|
1154
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter#field
|
1155
|
+
module Field
|
1156
|
+
extend Orb::Internal::Type::Enum
|
1157
|
+
|
1158
|
+
PRICE_ID = :price_id
|
1159
|
+
ITEM_ID = :item_id
|
1160
|
+
PRICE_TYPE = :price_type
|
1161
|
+
CURRENCY = :currency
|
1162
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1163
|
+
|
1164
|
+
# @!method self.values
|
1165
|
+
# @return [Array<Symbol>]
|
1166
|
+
end
|
1167
|
+
|
1168
|
+
# Should prices that match the filter be included or excluded.
|
1169
|
+
#
|
1170
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Amount::Filter#operator
|
1171
|
+
module Operator
|
1172
|
+
extend Orb::Internal::Type::Enum
|
1173
|
+
|
1174
|
+
INCLUDES = :includes
|
1175
|
+
EXCLUDES = :excludes
|
1176
|
+
|
1177
|
+
# @!method self.values
|
1178
|
+
# @return [Array<Symbol>]
|
1179
|
+
end
|
1180
|
+
end
|
759
1181
|
end
|
760
1182
|
|
761
1183
|
class Percentage < Orb::Internal::Type::BaseModel
|
762
|
-
# @!attribute applies_to_price_ids
|
763
|
-
# The price ids that this discount interval applies to.
|
764
|
-
#
|
765
|
-
# @return [Array<String>]
|
766
|
-
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
767
|
-
|
768
1184
|
# @!attribute applies_to_price_interval_ids
|
769
1185
|
# The price interval ids that this discount interval applies to.
|
770
1186
|
#
|
@@ -782,6 +1198,13 @@ module Orb
|
|
782
1198
|
# @return [Time, nil]
|
783
1199
|
required :end_date, Time, nil?: true
|
784
1200
|
|
1201
|
+
# @!attribute filters
|
1202
|
+
# The filters that determine which prices this discount interval applies to.
|
1203
|
+
#
|
1204
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter>]
|
1205
|
+
required :filters,
|
1206
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter] }
|
1207
|
+
|
785
1208
|
# @!attribute percentage_discount
|
786
1209
|
# Only available if discount_type is `percentage`.This is a number between 0
|
787
1210
|
# and 1.
|
@@ -795,31 +1218,83 @@ module Orb
|
|
795
1218
|
# @return [Time]
|
796
1219
|
required :start_date, Time
|
797
1220
|
|
798
|
-
# @!method initialize(
|
1221
|
+
# @!method initialize(applies_to_price_interval_ids:, end_date:, filters:, percentage_discount:, start_date:, discount_type: :percentage)
|
799
1222
|
# Some parameter documentations has been truncated, see
|
800
1223
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage}
|
801
1224
|
# for more details.
|
802
1225
|
#
|
803
|
-
# @param applies_to_price_ids [Array<String>] The price ids that this discount interval applies to.
|
804
|
-
#
|
805
1226
|
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this discount interval applies to.
|
806
1227
|
#
|
807
1228
|
# @param end_date [Time, nil] The end date of the discount interval.
|
808
1229
|
#
|
1230
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter>] The filters that determine which prices this discount interval applies to.
|
1231
|
+
#
|
809
1232
|
# @param percentage_discount [Float] Only available if discount_type is `percentage`.This is a number between 0 and 1
|
810
1233
|
#
|
811
1234
|
# @param start_date [Time] The start date of the discount interval.
|
812
1235
|
#
|
813
1236
|
# @param discount_type [Symbol, :percentage]
|
1237
|
+
|
1238
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1239
|
+
# @!attribute field
|
1240
|
+
# The property of the price to filter on.
|
1241
|
+
#
|
1242
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter::Field]
|
1243
|
+
required :field,
|
1244
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter::Field }
|
1245
|
+
|
1246
|
+
# @!attribute operator
|
1247
|
+
# Should prices that match the filter be included or excluded.
|
1248
|
+
#
|
1249
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter::Operator]
|
1250
|
+
required :operator,
|
1251
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter::Operator }
|
1252
|
+
|
1253
|
+
# @!attribute values
|
1254
|
+
# The IDs or values that match this filter.
|
1255
|
+
#
|
1256
|
+
# @return [Array<String>]
|
1257
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1258
|
+
|
1259
|
+
# @!method initialize(field:, operator:, values:)
|
1260
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter::Field] The property of the price to filter on.
|
1261
|
+
#
|
1262
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter::Operator] Should prices that match the filter be included or excluded.
|
1263
|
+
#
|
1264
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1265
|
+
|
1266
|
+
# The property of the price to filter on.
|
1267
|
+
#
|
1268
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter#field
|
1269
|
+
module Field
|
1270
|
+
extend Orb::Internal::Type::Enum
|
1271
|
+
|
1272
|
+
PRICE_ID = :price_id
|
1273
|
+
ITEM_ID = :item_id
|
1274
|
+
PRICE_TYPE = :price_type
|
1275
|
+
CURRENCY = :currency
|
1276
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1277
|
+
|
1278
|
+
# @!method self.values
|
1279
|
+
# @return [Array<Symbol>]
|
1280
|
+
end
|
1281
|
+
|
1282
|
+
# Should prices that match the filter be included or excluded.
|
1283
|
+
#
|
1284
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Percentage::Filter#operator
|
1285
|
+
module Operator
|
1286
|
+
extend Orb::Internal::Type::Enum
|
1287
|
+
|
1288
|
+
INCLUDES = :includes
|
1289
|
+
EXCLUDES = :excludes
|
1290
|
+
|
1291
|
+
# @!method self.values
|
1292
|
+
# @return [Array<Symbol>]
|
1293
|
+
end
|
1294
|
+
end
|
814
1295
|
end
|
815
1296
|
|
816
1297
|
class Usage < Orb::Internal::Type::BaseModel
|
817
|
-
# @!attribute applies_to_price_ids
|
818
|
-
# The price ids that this discount interval applies to.
|
819
|
-
#
|
820
|
-
# @return [Array<String>]
|
821
|
-
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
822
|
-
|
823
1298
|
# @!attribute applies_to_price_interval_ids
|
824
1299
|
# The price interval ids that this discount interval applies to.
|
825
1300
|
#
|
@@ -837,6 +1312,13 @@ module Orb
|
|
837
1312
|
# @return [Time, nil]
|
838
1313
|
required :end_date, Time, nil?: true
|
839
1314
|
|
1315
|
+
# @!attribute filters
|
1316
|
+
# The filters that determine which prices this discount interval applies to.
|
1317
|
+
#
|
1318
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter>]
|
1319
|
+
required :filters,
|
1320
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter] }
|
1321
|
+
|
840
1322
|
# @!attribute start_date
|
841
1323
|
# The start date of the discount interval.
|
842
1324
|
#
|
@@ -850,22 +1332,80 @@ module Orb
|
|
850
1332
|
# @return [Float]
|
851
1333
|
required :usage_discount, Float
|
852
1334
|
|
853
|
-
# @!method initialize(
|
1335
|
+
# @!method initialize(applies_to_price_interval_ids:, end_date:, filters:, start_date:, usage_discount:, discount_type: :usage)
|
854
1336
|
# Some parameter documentations has been truncated, see
|
855
1337
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage} for
|
856
1338
|
# more details.
|
857
1339
|
#
|
858
|
-
# @param applies_to_price_ids [Array<String>] The price ids that this discount interval applies to.
|
859
|
-
#
|
860
1340
|
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this discount interval applies to.
|
861
1341
|
#
|
862
1342
|
# @param end_date [Time, nil] The end date of the discount interval.
|
863
1343
|
#
|
1344
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter>] The filters that determine which prices this discount interval applies to.
|
1345
|
+
#
|
864
1346
|
# @param start_date [Time] The start date of the discount interval.
|
865
1347
|
#
|
866
1348
|
# @param usage_discount [Float] Only available if discount_type is `usage`. Number of usage units that this disc
|
867
1349
|
#
|
868
1350
|
# @param discount_type [Symbol, :usage]
|
1351
|
+
|
1352
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1353
|
+
# @!attribute field
|
1354
|
+
# The property of the price to filter on.
|
1355
|
+
#
|
1356
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter::Field]
|
1357
|
+
required :field,
|
1358
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter::Field }
|
1359
|
+
|
1360
|
+
# @!attribute operator
|
1361
|
+
# Should prices that match the filter be included or excluded.
|
1362
|
+
#
|
1363
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter::Operator]
|
1364
|
+
required :operator,
|
1365
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter::Operator }
|
1366
|
+
|
1367
|
+
# @!attribute values
|
1368
|
+
# The IDs or values that match this filter.
|
1369
|
+
#
|
1370
|
+
# @return [Array<String>]
|
1371
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1372
|
+
|
1373
|
+
# @!method initialize(field:, operator:, values:)
|
1374
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter::Field] The property of the price to filter on.
|
1375
|
+
#
|
1376
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter::Operator] Should prices that match the filter be included or excluded.
|
1377
|
+
#
|
1378
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1379
|
+
|
1380
|
+
# The property of the price to filter on.
|
1381
|
+
#
|
1382
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter#field
|
1383
|
+
module Field
|
1384
|
+
extend Orb::Internal::Type::Enum
|
1385
|
+
|
1386
|
+
PRICE_ID = :price_id
|
1387
|
+
ITEM_ID = :item_id
|
1388
|
+
PRICE_TYPE = :price_type
|
1389
|
+
CURRENCY = :currency
|
1390
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1391
|
+
|
1392
|
+
# @!method self.values
|
1393
|
+
# @return [Array<Symbol>]
|
1394
|
+
end
|
1395
|
+
|
1396
|
+
# Should prices that match the filter be included or excluded.
|
1397
|
+
#
|
1398
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::DiscountInterval::Usage::Filter#operator
|
1399
|
+
module Operator
|
1400
|
+
extend Orb::Internal::Type::Enum
|
1401
|
+
|
1402
|
+
INCLUDES = :includes
|
1403
|
+
EXCLUDES = :excludes
|
1404
|
+
|
1405
|
+
# @!method self.values
|
1406
|
+
# @return [Array<Symbol>]
|
1407
|
+
end
|
1408
|
+
end
|
869
1409
|
end
|
870
1410
|
|
871
1411
|
# @!method self.variants
|
@@ -901,12 +1441,6 @@ module Orb
|
|
901
1441
|
end
|
902
1442
|
|
903
1443
|
class MaximumInterval < Orb::Internal::Type::BaseModel
|
904
|
-
# @!attribute applies_to_price_ids
|
905
|
-
# The price ids that this maximum interval applies to.
|
906
|
-
#
|
907
|
-
# @return [Array<String>]
|
908
|
-
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
909
|
-
|
910
1444
|
# @!attribute applies_to_price_interval_ids
|
911
1445
|
# The price interval ids that this maximum interval applies to.
|
912
1446
|
#
|
@@ -919,6 +1453,13 @@ module Orb
|
|
919
1453
|
# @return [Time, nil]
|
920
1454
|
required :end_date, Time, nil?: true
|
921
1455
|
|
1456
|
+
# @!attribute filters
|
1457
|
+
# The filters that determine which prices this maximum interval applies to.
|
1458
|
+
#
|
1459
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter>]
|
1460
|
+
required :filters,
|
1461
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter] }
|
1462
|
+
|
922
1463
|
# @!attribute maximum_amount
|
923
1464
|
# The maximum amount to charge in a given billing period for the price intervals
|
924
1465
|
# this transform applies to.
|
@@ -932,29 +1473,81 @@ module Orb
|
|
932
1473
|
# @return [Time]
|
933
1474
|
required :start_date, Time
|
934
1475
|
|
935
|
-
# @!method initialize(
|
1476
|
+
# @!method initialize(applies_to_price_interval_ids:, end_date:, filters:, maximum_amount:, start_date:)
|
936
1477
|
# Some parameter documentations has been truncated, see
|
937
1478
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval} for more
|
938
1479
|
# details.
|
939
1480
|
#
|
940
|
-
# @param applies_to_price_ids [Array<String>] The price ids that this maximum interval applies to.
|
941
|
-
#
|
942
1481
|
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this maximum interval applies to.
|
943
1482
|
#
|
944
1483
|
# @param end_date [Time, nil] The end date of the maximum interval.
|
945
1484
|
#
|
1485
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter>] The filters that determine which prices this maximum interval applies to.
|
1486
|
+
#
|
946
1487
|
# @param maximum_amount [String] The maximum amount to charge in a given billing period for the price intervals t
|
947
1488
|
#
|
948
1489
|
# @param start_date [Time] The start date of the maximum interval.
|
1490
|
+
|
1491
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1492
|
+
# @!attribute field
|
1493
|
+
# The property of the price to filter on.
|
1494
|
+
#
|
1495
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter::Field]
|
1496
|
+
required :field,
|
1497
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter::Field }
|
1498
|
+
|
1499
|
+
# @!attribute operator
|
1500
|
+
# Should prices that match the filter be included or excluded.
|
1501
|
+
#
|
1502
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter::Operator]
|
1503
|
+
required :operator,
|
1504
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter::Operator }
|
1505
|
+
|
1506
|
+
# @!attribute values
|
1507
|
+
# The IDs or values that match this filter.
|
1508
|
+
#
|
1509
|
+
# @return [Array<String>]
|
1510
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1511
|
+
|
1512
|
+
# @!method initialize(field:, operator:, values:)
|
1513
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter::Field] The property of the price to filter on.
|
1514
|
+
#
|
1515
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter::Operator] Should prices that match the filter be included or excluded.
|
1516
|
+
#
|
1517
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1518
|
+
|
1519
|
+
# The property of the price to filter on.
|
1520
|
+
#
|
1521
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter#field
|
1522
|
+
module Field
|
1523
|
+
extend Orb::Internal::Type::Enum
|
1524
|
+
|
1525
|
+
PRICE_ID = :price_id
|
1526
|
+
ITEM_ID = :item_id
|
1527
|
+
PRICE_TYPE = :price_type
|
1528
|
+
CURRENCY = :currency
|
1529
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1530
|
+
|
1531
|
+
# @!method self.values
|
1532
|
+
# @return [Array<Symbol>]
|
1533
|
+
end
|
1534
|
+
|
1535
|
+
# Should prices that match the filter be included or excluded.
|
1536
|
+
#
|
1537
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::MaximumInterval::Filter#operator
|
1538
|
+
module Operator
|
1539
|
+
extend Orb::Internal::Type::Enum
|
1540
|
+
|
1541
|
+
INCLUDES = :includes
|
1542
|
+
EXCLUDES = :excludes
|
1543
|
+
|
1544
|
+
# @!method self.values
|
1545
|
+
# @return [Array<Symbol>]
|
1546
|
+
end
|
1547
|
+
end
|
949
1548
|
end
|
950
1549
|
|
951
1550
|
class MinimumInterval < Orb::Internal::Type::BaseModel
|
952
|
-
# @!attribute applies_to_price_ids
|
953
|
-
# The price ids that this minimum interval applies to.
|
954
|
-
#
|
955
|
-
# @return [Array<String>]
|
956
|
-
required :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String]
|
957
|
-
|
958
1551
|
# @!attribute applies_to_price_interval_ids
|
959
1552
|
# The price interval ids that this minimum interval applies to.
|
960
1553
|
#
|
@@ -967,6 +1560,13 @@ module Orb
|
|
967
1560
|
# @return [Time, nil]
|
968
1561
|
required :end_date, Time, nil?: true
|
969
1562
|
|
1563
|
+
# @!attribute filters
|
1564
|
+
# The filters that determine which prices this minimum interval applies to.
|
1565
|
+
#
|
1566
|
+
# @return [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter>]
|
1567
|
+
required :filters,
|
1568
|
+
-> { Orb::Internal::Type::ArrayOf[Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter] }
|
1569
|
+
|
970
1570
|
# @!attribute minimum_amount
|
971
1571
|
# The minimum amount to charge in a given billing period for the price intervals
|
972
1572
|
# this minimum applies to.
|
@@ -980,20 +1580,78 @@ module Orb
|
|
980
1580
|
# @return [Time]
|
981
1581
|
required :start_date, Time
|
982
1582
|
|
983
|
-
# @!method initialize(
|
1583
|
+
# @!method initialize(applies_to_price_interval_ids:, end_date:, filters:, minimum_amount:, start_date:)
|
984
1584
|
# Some parameter documentations has been truncated, see
|
985
1585
|
# {Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval} for more
|
986
1586
|
# details.
|
987
1587
|
#
|
988
|
-
# @param applies_to_price_ids [Array<String>] The price ids that this minimum interval applies to.
|
989
|
-
#
|
990
1588
|
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this minimum interval applies to.
|
991
1589
|
#
|
992
1590
|
# @param end_date [Time, nil] The end date of the minimum interval.
|
993
1591
|
#
|
1592
|
+
# @param filters [Array<Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter>] The filters that determine which prices this minimum interval applies to.
|
1593
|
+
#
|
994
1594
|
# @param minimum_amount [String] The minimum amount to charge in a given billing period for the price intervals t
|
995
1595
|
#
|
996
1596
|
# @param start_date [Time] The start date of the minimum interval.
|
1597
|
+
|
1598
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1599
|
+
# @!attribute field
|
1600
|
+
# The property of the price to filter on.
|
1601
|
+
#
|
1602
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter::Field]
|
1603
|
+
required :field,
|
1604
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter::Field }
|
1605
|
+
|
1606
|
+
# @!attribute operator
|
1607
|
+
# Should prices that match the filter be included or excluded.
|
1608
|
+
#
|
1609
|
+
# @return [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter::Operator]
|
1610
|
+
required :operator,
|
1611
|
+
enum: -> { Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter::Operator }
|
1612
|
+
|
1613
|
+
# @!attribute values
|
1614
|
+
# The IDs or values that match this filter.
|
1615
|
+
#
|
1616
|
+
# @return [Array<String>]
|
1617
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1618
|
+
|
1619
|
+
# @!method initialize(field:, operator:, values:)
|
1620
|
+
# @param field [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter::Field] The property of the price to filter on.
|
1621
|
+
#
|
1622
|
+
# @param operator [Symbol, Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter::Operator] Should prices that match the filter be included or excluded.
|
1623
|
+
#
|
1624
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1625
|
+
|
1626
|
+
# The property of the price to filter on.
|
1627
|
+
#
|
1628
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter#field
|
1629
|
+
module Field
|
1630
|
+
extend Orb::Internal::Type::Enum
|
1631
|
+
|
1632
|
+
PRICE_ID = :price_id
|
1633
|
+
ITEM_ID = :item_id
|
1634
|
+
PRICE_TYPE = :price_type
|
1635
|
+
CURRENCY = :currency
|
1636
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1637
|
+
|
1638
|
+
# @!method self.values
|
1639
|
+
# @return [Array<Symbol>]
|
1640
|
+
end
|
1641
|
+
|
1642
|
+
# Should prices that match the filter be included or excluded.
|
1643
|
+
#
|
1644
|
+
# @see Orb::Models::SubscriptionPriceIntervalsResponse::MinimumInterval::Filter#operator
|
1645
|
+
module Operator
|
1646
|
+
extend Orb::Internal::Type::Enum
|
1647
|
+
|
1648
|
+
INCLUDES = :includes
|
1649
|
+
EXCLUDES = :excludes
|
1650
|
+
|
1651
|
+
# @!method self.values
|
1652
|
+
# @return [Array<Symbol>]
|
1653
|
+
end
|
1654
|
+
end
|
997
1655
|
end
|
998
1656
|
|
999
1657
|
# @see Orb::Models::SubscriptionPriceIntervalsResponse#pending_subscription_change
|