orb-billing 0.10.0 → 0.12.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 +32 -0
- data/README.md +1 -1
- data/lib/orb/internal/type/union.rb +3 -8
- data/lib/orb/internal/util.rb +8 -9
- data/lib/orb/models/amount_discount.rb +65 -1
- data/lib/orb/models/beta/external_plan_id_create_plan_version_params.rb +1437 -15
- data/lib/orb/models/beta_create_plan_version_params.rb +1435 -15
- data/lib/orb/models/percentage_discount.rb +65 -1
- data/lib/orb/models/subscription_create_params.rb +1435 -15
- data/lib/orb/models/subscription_price_intervals_params.rb +715 -5
- data/lib/orb/models/subscription_redeem_coupon_params.rb +17 -9
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +1435 -15
- data/lib/orb/models/trial_discount.rb +65 -1
- data/lib/orb/models/usage_discount.rb +65 -1
- data/lib/orb/resources/subscriptions.rb +6 -4
- data/lib/orb/version.rb +1 -1
- data/rbi/orb/internal/util.rbi +2 -0
- data/rbi/orb/models/amount_discount.rbi +117 -0
- data/rbi/orb/models/beta/external_plan_id_create_plan_version_params.rbi +6145 -3045
- data/rbi/orb/models/beta_create_plan_version_params.rbi +6096 -2996
- data/rbi/orb/models/percentage_discount.rbi +131 -0
- data/rbi/orb/models/subscription_create_params.rbi +6037 -2937
- data/rbi/orb/models/subscription_price_intervals_params.rbi +1633 -83
- data/rbi/orb/models/subscription_redeem_coupon_params.rbi +16 -8
- data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +6948 -3848
- data/rbi/orb/models/trial_discount.rbi +109 -0
- data/rbi/orb/models/usage_discount.rbi +109 -0
- data/rbi/orb/resources/subscriptions.rbi +7 -4
- data/sig/orb/models/amount_discount.rbs +58 -0
- data/sig/orb/models/beta/external_plan_id_create_plan_version_params.rbs +1130 -20
- data/sig/orb/models/beta_create_plan_version_params.rbs +1130 -20
- data/sig/orb/models/percentage_discount.rbs +58 -0
- data/sig/orb/models/subscription_create_params.rbs +1130 -20
- data/sig/orb/models/subscription_price_intervals_params.rbs +565 -10
- data/sig/orb/models/subscription_redeem_coupon_params.rbs +11 -6
- data/sig/orb/models/subscription_schedule_plan_change_params.rbs +1130 -20
- data/sig/orb/models/trial_discount.rbs +58 -0
- data/sig/orb/models/usage_discount.rbs +58 -0
- data/sig/orb/resources/subscriptions.rbs +2 -1
- metadata +2 -2
@@ -370,12 +370,44 @@ module Orb
|
|
370
370
|
# @return [Float]
|
371
371
|
required :percentage_discount, Float
|
372
372
|
|
373
|
+
# @!attribute applies_to_all
|
374
|
+
# If set, the adjustment will apply to every price on the subscription.
|
375
|
+
#
|
376
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::AppliesToAll, nil]
|
377
|
+
optional :applies_to_all,
|
378
|
+
enum: -> {
|
379
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::AppliesToAll
|
380
|
+
},
|
381
|
+
nil?: true
|
382
|
+
|
383
|
+
# @!attribute applies_to_item_ids
|
384
|
+
# The set of item IDs to which this adjustment applies.
|
385
|
+
#
|
386
|
+
# @return [Array<String>, nil]
|
387
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
388
|
+
|
373
389
|
# @!attribute applies_to_price_ids
|
374
390
|
# The set of price IDs to which this adjustment applies.
|
375
391
|
#
|
376
392
|
# @return [Array<String>, nil]
|
377
393
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
378
394
|
|
395
|
+
# @!attribute currency
|
396
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
397
|
+
#
|
398
|
+
# @return [String, nil]
|
399
|
+
optional :currency, String, nil?: true
|
400
|
+
|
401
|
+
# @!attribute filters
|
402
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
403
|
+
#
|
404
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter>, nil]
|
405
|
+
optional :filters,
|
406
|
+
-> {
|
407
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter]
|
408
|
+
},
|
409
|
+
nil?: true
|
410
|
+
|
379
411
|
# @!attribute is_invoice_level
|
380
412
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
381
413
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -383,18 +415,128 @@ module Orb
|
|
383
415
|
# @return [Boolean, nil]
|
384
416
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
385
417
|
|
386
|
-
# @!
|
418
|
+
# @!attribute price_type
|
419
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
420
|
+
#
|
421
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::PriceType, nil]
|
422
|
+
optional :price_type,
|
423
|
+
enum: -> {
|
424
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::PriceType
|
425
|
+
},
|
426
|
+
nil?: true
|
427
|
+
|
428
|
+
# @!method initialize(percentage_discount:, 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, adjustment_type: :percentage_discount)
|
387
429
|
# Some parameter documentations has been truncated, see
|
388
430
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount}
|
389
431
|
# for more details.
|
390
432
|
#
|
391
433
|
# @param percentage_discount [Float]
|
392
434
|
#
|
435
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
436
|
+
#
|
437
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
438
|
+
#
|
393
439
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
394
440
|
#
|
441
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
442
|
+
#
|
443
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
444
|
+
#
|
395
445
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
396
446
|
#
|
447
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
448
|
+
#
|
397
449
|
# @param adjustment_type [Symbol, :percentage_discount]
|
450
|
+
|
451
|
+
# If set, the adjustment will apply to every price on the subscription.
|
452
|
+
#
|
453
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount#applies_to_all
|
454
|
+
module AppliesToAll
|
455
|
+
extend Orb::Internal::Type::Enum
|
456
|
+
|
457
|
+
TRUE = true
|
458
|
+
|
459
|
+
# @!method self.values
|
460
|
+
# @return [Array<Boolean>]
|
461
|
+
end
|
462
|
+
|
463
|
+
class Filter < Orb::Internal::Type::BaseModel
|
464
|
+
# @!attribute field
|
465
|
+
# The property of the price to filter on.
|
466
|
+
#
|
467
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter::Field]
|
468
|
+
required :field,
|
469
|
+
enum: -> {
|
470
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter::Field
|
471
|
+
}
|
472
|
+
|
473
|
+
# @!attribute operator
|
474
|
+
# Should prices that match the filter be included or excluded.
|
475
|
+
#
|
476
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter::Operator]
|
477
|
+
required :operator,
|
478
|
+
enum: -> {
|
479
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter::Operator
|
480
|
+
}
|
481
|
+
|
482
|
+
# @!attribute values
|
483
|
+
# The IDs or values that match this filter.
|
484
|
+
#
|
485
|
+
# @return [Array<String>]
|
486
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
487
|
+
|
488
|
+
# @!method initialize(field:, operator:, values:)
|
489
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter::Field] The property of the price to filter on.
|
490
|
+
#
|
491
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
492
|
+
#
|
493
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
494
|
+
|
495
|
+
# The property of the price to filter on.
|
496
|
+
#
|
497
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter#field
|
498
|
+
module Field
|
499
|
+
extend Orb::Internal::Type::Enum
|
500
|
+
|
501
|
+
PRICE_ID = :price_id
|
502
|
+
ITEM_ID = :item_id
|
503
|
+
PRICE_TYPE = :price_type
|
504
|
+
CURRENCY = :currency
|
505
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
506
|
+
|
507
|
+
# @!method self.values
|
508
|
+
# @return [Array<Symbol>]
|
509
|
+
end
|
510
|
+
|
511
|
+
# Should prices that match the filter be included or excluded.
|
512
|
+
#
|
513
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount::Filter#operator
|
514
|
+
module Operator
|
515
|
+
extend Orb::Internal::Type::Enum
|
516
|
+
|
517
|
+
INCLUDES = :includes
|
518
|
+
EXCLUDES = :excludes
|
519
|
+
|
520
|
+
# @!method self.values
|
521
|
+
# @return [Array<Symbol>]
|
522
|
+
end
|
523
|
+
end
|
524
|
+
|
525
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
526
|
+
#
|
527
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::PercentageDiscount#price_type
|
528
|
+
module PriceType
|
529
|
+
extend Orb::Internal::Type::Enum
|
530
|
+
|
531
|
+
USAGE = :usage
|
532
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
533
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
534
|
+
FIXED = :fixed
|
535
|
+
IN_ARREARS = :in_arrears
|
536
|
+
|
537
|
+
# @!method self.values
|
538
|
+
# @return [Array<Symbol>]
|
539
|
+
end
|
398
540
|
end
|
399
541
|
|
400
542
|
class UsageDiscount < Orb::Internal::Type::BaseModel
|
@@ -408,12 +550,44 @@ module Orb
|
|
408
550
|
# @return [Float]
|
409
551
|
required :usage_discount, Float
|
410
552
|
|
553
|
+
# @!attribute applies_to_all
|
554
|
+
# If set, the adjustment will apply to every price on the subscription.
|
555
|
+
#
|
556
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::AppliesToAll, nil]
|
557
|
+
optional :applies_to_all,
|
558
|
+
enum: -> {
|
559
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::AppliesToAll
|
560
|
+
},
|
561
|
+
nil?: true
|
562
|
+
|
563
|
+
# @!attribute applies_to_item_ids
|
564
|
+
# The set of item IDs to which this adjustment applies.
|
565
|
+
#
|
566
|
+
# @return [Array<String>, nil]
|
567
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
568
|
+
|
411
569
|
# @!attribute applies_to_price_ids
|
412
570
|
# The set of price IDs to which this adjustment applies.
|
413
571
|
#
|
414
572
|
# @return [Array<String>, nil]
|
415
573
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
416
574
|
|
575
|
+
# @!attribute currency
|
576
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
577
|
+
#
|
578
|
+
# @return [String, nil]
|
579
|
+
optional :currency, String, nil?: true
|
580
|
+
|
581
|
+
# @!attribute filters
|
582
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
583
|
+
#
|
584
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter>, nil]
|
585
|
+
optional :filters,
|
586
|
+
-> {
|
587
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter]
|
588
|
+
},
|
589
|
+
nil?: true
|
590
|
+
|
417
591
|
# @!attribute is_invoice_level
|
418
592
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
419
593
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -421,18 +595,128 @@ module Orb
|
|
421
595
|
# @return [Boolean, nil]
|
422
596
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
423
597
|
|
424
|
-
# @!
|
598
|
+
# @!attribute price_type
|
599
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
600
|
+
#
|
601
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::PriceType, nil]
|
602
|
+
optional :price_type,
|
603
|
+
enum: -> {
|
604
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::PriceType
|
605
|
+
},
|
606
|
+
nil?: true
|
607
|
+
|
608
|
+
# @!method initialize(usage_discount:, 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, adjustment_type: :usage_discount)
|
425
609
|
# Some parameter documentations has been truncated, see
|
426
610
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount}
|
427
611
|
# for more details.
|
428
612
|
#
|
429
613
|
# @param usage_discount [Float]
|
430
614
|
#
|
615
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
616
|
+
#
|
617
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
618
|
+
#
|
431
619
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
432
620
|
#
|
621
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
622
|
+
#
|
623
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
624
|
+
#
|
433
625
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
434
626
|
#
|
627
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
628
|
+
#
|
435
629
|
# @param adjustment_type [Symbol, :usage_discount]
|
630
|
+
|
631
|
+
# If set, the adjustment will apply to every price on the subscription.
|
632
|
+
#
|
633
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount#applies_to_all
|
634
|
+
module AppliesToAll
|
635
|
+
extend Orb::Internal::Type::Enum
|
636
|
+
|
637
|
+
TRUE = true
|
638
|
+
|
639
|
+
# @!method self.values
|
640
|
+
# @return [Array<Boolean>]
|
641
|
+
end
|
642
|
+
|
643
|
+
class Filter < Orb::Internal::Type::BaseModel
|
644
|
+
# @!attribute field
|
645
|
+
# The property of the price to filter on.
|
646
|
+
#
|
647
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter::Field]
|
648
|
+
required :field,
|
649
|
+
enum: -> {
|
650
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter::Field
|
651
|
+
}
|
652
|
+
|
653
|
+
# @!attribute operator
|
654
|
+
# Should prices that match the filter be included or excluded.
|
655
|
+
#
|
656
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter::Operator]
|
657
|
+
required :operator,
|
658
|
+
enum: -> {
|
659
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter::Operator
|
660
|
+
}
|
661
|
+
|
662
|
+
# @!attribute values
|
663
|
+
# The IDs or values that match this filter.
|
664
|
+
#
|
665
|
+
# @return [Array<String>]
|
666
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
667
|
+
|
668
|
+
# @!method initialize(field:, operator:, values:)
|
669
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter::Field] The property of the price to filter on.
|
670
|
+
#
|
671
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
672
|
+
#
|
673
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
674
|
+
|
675
|
+
# The property of the price to filter on.
|
676
|
+
#
|
677
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter#field
|
678
|
+
module Field
|
679
|
+
extend Orb::Internal::Type::Enum
|
680
|
+
|
681
|
+
PRICE_ID = :price_id
|
682
|
+
ITEM_ID = :item_id
|
683
|
+
PRICE_TYPE = :price_type
|
684
|
+
CURRENCY = :currency
|
685
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
686
|
+
|
687
|
+
# @!method self.values
|
688
|
+
# @return [Array<Symbol>]
|
689
|
+
end
|
690
|
+
|
691
|
+
# Should prices that match the filter be included or excluded.
|
692
|
+
#
|
693
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount::Filter#operator
|
694
|
+
module Operator
|
695
|
+
extend Orb::Internal::Type::Enum
|
696
|
+
|
697
|
+
INCLUDES = :includes
|
698
|
+
EXCLUDES = :excludes
|
699
|
+
|
700
|
+
# @!method self.values
|
701
|
+
# @return [Array<Symbol>]
|
702
|
+
end
|
703
|
+
end
|
704
|
+
|
705
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
706
|
+
#
|
707
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::UsageDiscount#price_type
|
708
|
+
module PriceType
|
709
|
+
extend Orb::Internal::Type::Enum
|
710
|
+
|
711
|
+
USAGE = :usage
|
712
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
713
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
714
|
+
FIXED = :fixed
|
715
|
+
IN_ARREARS = :in_arrears
|
716
|
+
|
717
|
+
# @!method self.values
|
718
|
+
# @return [Array<Symbol>]
|
719
|
+
end
|
436
720
|
end
|
437
721
|
|
438
722
|
class AmountDiscount < Orb::Internal::Type::BaseModel
|
@@ -446,12 +730,44 @@ module Orb
|
|
446
730
|
# @return [String]
|
447
731
|
required :amount_discount, String
|
448
732
|
|
733
|
+
# @!attribute applies_to_all
|
734
|
+
# If set, the adjustment will apply to every price on the subscription.
|
735
|
+
#
|
736
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::AppliesToAll, nil]
|
737
|
+
optional :applies_to_all,
|
738
|
+
enum: -> {
|
739
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::AppliesToAll
|
740
|
+
},
|
741
|
+
nil?: true
|
742
|
+
|
743
|
+
# @!attribute applies_to_item_ids
|
744
|
+
# The set of item IDs to which this adjustment applies.
|
745
|
+
#
|
746
|
+
# @return [Array<String>, nil]
|
747
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
748
|
+
|
449
749
|
# @!attribute applies_to_price_ids
|
450
750
|
# The set of price IDs to which this adjustment applies.
|
451
751
|
#
|
452
752
|
# @return [Array<String>, nil]
|
453
753
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
454
754
|
|
755
|
+
# @!attribute currency
|
756
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
757
|
+
#
|
758
|
+
# @return [String, nil]
|
759
|
+
optional :currency, String, nil?: true
|
760
|
+
|
761
|
+
# @!attribute filters
|
762
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
763
|
+
#
|
764
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter>, nil]
|
765
|
+
optional :filters,
|
766
|
+
-> {
|
767
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter]
|
768
|
+
},
|
769
|
+
nil?: true
|
770
|
+
|
455
771
|
# @!attribute is_invoice_level
|
456
772
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
457
773
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -459,18 +775,128 @@ module Orb
|
|
459
775
|
# @return [Boolean, nil]
|
460
776
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
461
777
|
|
462
|
-
# @!
|
778
|
+
# @!attribute price_type
|
779
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
780
|
+
#
|
781
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::PriceType, nil]
|
782
|
+
optional :price_type,
|
783
|
+
enum: -> {
|
784
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::PriceType
|
785
|
+
},
|
786
|
+
nil?: true
|
787
|
+
|
788
|
+
# @!method initialize(amount_discount:, 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, adjustment_type: :amount_discount)
|
463
789
|
# Some parameter documentations has been truncated, see
|
464
790
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount}
|
465
791
|
# for more details.
|
466
792
|
#
|
467
793
|
# @param amount_discount [String]
|
468
794
|
#
|
795
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
796
|
+
#
|
797
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
798
|
+
#
|
469
799
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
470
800
|
#
|
801
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
802
|
+
#
|
803
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
804
|
+
#
|
471
805
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
472
806
|
#
|
807
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
808
|
+
#
|
473
809
|
# @param adjustment_type [Symbol, :amount_discount]
|
810
|
+
|
811
|
+
# If set, the adjustment will apply to every price on the subscription.
|
812
|
+
#
|
813
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount#applies_to_all
|
814
|
+
module AppliesToAll
|
815
|
+
extend Orb::Internal::Type::Enum
|
816
|
+
|
817
|
+
TRUE = true
|
818
|
+
|
819
|
+
# @!method self.values
|
820
|
+
# @return [Array<Boolean>]
|
821
|
+
end
|
822
|
+
|
823
|
+
class Filter < Orb::Internal::Type::BaseModel
|
824
|
+
# @!attribute field
|
825
|
+
# The property of the price to filter on.
|
826
|
+
#
|
827
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter::Field]
|
828
|
+
required :field,
|
829
|
+
enum: -> {
|
830
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter::Field
|
831
|
+
}
|
832
|
+
|
833
|
+
# @!attribute operator
|
834
|
+
# Should prices that match the filter be included or excluded.
|
835
|
+
#
|
836
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter::Operator]
|
837
|
+
required :operator,
|
838
|
+
enum: -> {
|
839
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter::Operator
|
840
|
+
}
|
841
|
+
|
842
|
+
# @!attribute values
|
843
|
+
# The IDs or values that match this filter.
|
844
|
+
#
|
845
|
+
# @return [Array<String>]
|
846
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
847
|
+
|
848
|
+
# @!method initialize(field:, operator:, values:)
|
849
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter::Field] The property of the price to filter on.
|
850
|
+
#
|
851
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
852
|
+
#
|
853
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
854
|
+
|
855
|
+
# The property of the price to filter on.
|
856
|
+
#
|
857
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter#field
|
858
|
+
module Field
|
859
|
+
extend Orb::Internal::Type::Enum
|
860
|
+
|
861
|
+
PRICE_ID = :price_id
|
862
|
+
ITEM_ID = :item_id
|
863
|
+
PRICE_TYPE = :price_type
|
864
|
+
CURRENCY = :currency
|
865
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
866
|
+
|
867
|
+
# @!method self.values
|
868
|
+
# @return [Array<Symbol>]
|
869
|
+
end
|
870
|
+
|
871
|
+
# Should prices that match the filter be included or excluded.
|
872
|
+
#
|
873
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount::Filter#operator
|
874
|
+
module Operator
|
875
|
+
extend Orb::Internal::Type::Enum
|
876
|
+
|
877
|
+
INCLUDES = :includes
|
878
|
+
EXCLUDES = :excludes
|
879
|
+
|
880
|
+
# @!method self.values
|
881
|
+
# @return [Array<Symbol>]
|
882
|
+
end
|
883
|
+
end
|
884
|
+
|
885
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
886
|
+
#
|
887
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::AmountDiscount#price_type
|
888
|
+
module PriceType
|
889
|
+
extend Orb::Internal::Type::Enum
|
890
|
+
|
891
|
+
USAGE = :usage
|
892
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
893
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
894
|
+
FIXED = :fixed
|
895
|
+
IN_ARREARS = :in_arrears
|
896
|
+
|
897
|
+
# @!method self.values
|
898
|
+
# @return [Array<Symbol>]
|
899
|
+
end
|
474
900
|
end
|
475
901
|
|
476
902
|
class Minimum < Orb::Internal::Type::BaseModel
|
@@ -490,12 +916,44 @@ module Orb
|
|
490
916
|
# @return [String]
|
491
917
|
required :minimum_amount, String
|
492
918
|
|
919
|
+
# @!attribute applies_to_all
|
920
|
+
# If set, the adjustment will apply to every price on the subscription.
|
921
|
+
#
|
922
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::AppliesToAll, nil]
|
923
|
+
optional :applies_to_all,
|
924
|
+
enum: -> {
|
925
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::AppliesToAll
|
926
|
+
},
|
927
|
+
nil?: true
|
928
|
+
|
929
|
+
# @!attribute applies_to_item_ids
|
930
|
+
# The set of item IDs to which this adjustment applies.
|
931
|
+
#
|
932
|
+
# @return [Array<String>, nil]
|
933
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
934
|
+
|
493
935
|
# @!attribute applies_to_price_ids
|
494
936
|
# The set of price IDs to which this adjustment applies.
|
495
937
|
#
|
496
938
|
# @return [Array<String>, nil]
|
497
939
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
498
940
|
|
941
|
+
# @!attribute currency
|
942
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
943
|
+
#
|
944
|
+
# @return [String, nil]
|
945
|
+
optional :currency, String, nil?: true
|
946
|
+
|
947
|
+
# @!attribute filters
|
948
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
949
|
+
#
|
950
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter>, nil]
|
951
|
+
optional :filters,
|
952
|
+
-> {
|
953
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter]
|
954
|
+
},
|
955
|
+
nil?: true
|
956
|
+
|
499
957
|
# @!attribute is_invoice_level
|
500
958
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
501
959
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -503,7 +961,17 @@ module Orb
|
|
503
961
|
# @return [Boolean, nil]
|
504
962
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
505
963
|
|
506
|
-
# @!
|
964
|
+
# @!attribute price_type
|
965
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
966
|
+
#
|
967
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::PriceType, nil]
|
968
|
+
optional :price_type,
|
969
|
+
enum: -> {
|
970
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::PriceType
|
971
|
+
},
|
972
|
+
nil?: true
|
973
|
+
|
974
|
+
# @!method initialize(item_id:, minimum_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, adjustment_type: :minimum)
|
507
975
|
# Some parameter documentations has been truncated, see
|
508
976
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum}
|
509
977
|
# for more details.
|
@@ -512,30 +980,162 @@ module Orb
|
|
512
980
|
#
|
513
981
|
# @param minimum_amount [String]
|
514
982
|
#
|
983
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
984
|
+
#
|
985
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
986
|
+
#
|
515
987
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
516
988
|
#
|
989
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
990
|
+
#
|
991
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
992
|
+
#
|
517
993
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
518
994
|
#
|
995
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
996
|
+
#
|
519
997
|
# @param adjustment_type [Symbol, :minimum]
|
520
|
-
end
|
521
998
|
|
522
|
-
|
523
|
-
# @!attribute adjustment_type
|
999
|
+
# If set, the adjustment will apply to every price on the subscription.
|
524
1000
|
#
|
525
|
-
#
|
526
|
-
|
1001
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum#applies_to_all
|
1002
|
+
module AppliesToAll
|
1003
|
+
extend Orb::Internal::Type::Enum
|
1004
|
+
|
1005
|
+
TRUE = true
|
1006
|
+
|
1007
|
+
# @!method self.values
|
1008
|
+
# @return [Array<Boolean>]
|
1009
|
+
end
|
1010
|
+
|
1011
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1012
|
+
# @!attribute field
|
1013
|
+
# The property of the price to filter on.
|
1014
|
+
#
|
1015
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter::Field]
|
1016
|
+
required :field,
|
1017
|
+
enum: -> {
|
1018
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter::Field
|
1019
|
+
}
|
1020
|
+
|
1021
|
+
# @!attribute operator
|
1022
|
+
# Should prices that match the filter be included or excluded.
|
1023
|
+
#
|
1024
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter::Operator]
|
1025
|
+
required :operator,
|
1026
|
+
enum: -> {
|
1027
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter::Operator
|
1028
|
+
}
|
1029
|
+
|
1030
|
+
# @!attribute values
|
1031
|
+
# The IDs or values that match this filter.
|
1032
|
+
#
|
1033
|
+
# @return [Array<String>]
|
1034
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1035
|
+
|
1036
|
+
# @!method initialize(field:, operator:, values:)
|
1037
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter::Field] The property of the price to filter on.
|
1038
|
+
#
|
1039
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter::Operator] Should prices that match the filter be included or excluded.
|
1040
|
+
#
|
1041
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1042
|
+
|
1043
|
+
# The property of the price to filter on.
|
1044
|
+
#
|
1045
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter#field
|
1046
|
+
module Field
|
1047
|
+
extend Orb::Internal::Type::Enum
|
1048
|
+
|
1049
|
+
PRICE_ID = :price_id
|
1050
|
+
ITEM_ID = :item_id
|
1051
|
+
PRICE_TYPE = :price_type
|
1052
|
+
CURRENCY = :currency
|
1053
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1054
|
+
|
1055
|
+
# @!method self.values
|
1056
|
+
# @return [Array<Symbol>]
|
1057
|
+
end
|
1058
|
+
|
1059
|
+
# Should prices that match the filter be included or excluded.
|
1060
|
+
#
|
1061
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum::Filter#operator
|
1062
|
+
module Operator
|
1063
|
+
extend Orb::Internal::Type::Enum
|
1064
|
+
|
1065
|
+
INCLUDES = :includes
|
1066
|
+
EXCLUDES = :excludes
|
1067
|
+
|
1068
|
+
# @!method self.values
|
1069
|
+
# @return [Array<Symbol>]
|
1070
|
+
end
|
1071
|
+
end
|
1072
|
+
|
1073
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
1074
|
+
#
|
1075
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Minimum#price_type
|
1076
|
+
module PriceType
|
1077
|
+
extend Orb::Internal::Type::Enum
|
1078
|
+
|
1079
|
+
USAGE = :usage
|
1080
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
1081
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
1082
|
+
FIXED = :fixed
|
1083
|
+
IN_ARREARS = :in_arrears
|
1084
|
+
|
1085
|
+
# @!method self.values
|
1086
|
+
# @return [Array<Symbol>]
|
1087
|
+
end
|
1088
|
+
end
|
1089
|
+
|
1090
|
+
class Maximum < Orb::Internal::Type::BaseModel
|
1091
|
+
# @!attribute adjustment_type
|
1092
|
+
#
|
1093
|
+
# @return [Symbol, :maximum]
|
1094
|
+
required :adjustment_type, const: :maximum
|
527
1095
|
|
528
1096
|
# @!attribute maximum_amount
|
529
1097
|
#
|
530
1098
|
# @return [String]
|
531
1099
|
required :maximum_amount, String
|
532
1100
|
|
1101
|
+
# @!attribute applies_to_all
|
1102
|
+
# If set, the adjustment will apply to every price on the subscription.
|
1103
|
+
#
|
1104
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::AppliesToAll, nil]
|
1105
|
+
optional :applies_to_all,
|
1106
|
+
enum: -> {
|
1107
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::AppliesToAll
|
1108
|
+
},
|
1109
|
+
nil?: true
|
1110
|
+
|
1111
|
+
# @!attribute applies_to_item_ids
|
1112
|
+
# The set of item IDs to which this adjustment applies.
|
1113
|
+
#
|
1114
|
+
# @return [Array<String>, nil]
|
1115
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
1116
|
+
|
533
1117
|
# @!attribute applies_to_price_ids
|
534
1118
|
# The set of price IDs to which this adjustment applies.
|
535
1119
|
#
|
536
1120
|
# @return [Array<String>, nil]
|
537
1121
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
538
1122
|
|
1123
|
+
# @!attribute currency
|
1124
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
1125
|
+
#
|
1126
|
+
# @return [String, nil]
|
1127
|
+
optional :currency, String, nil?: true
|
1128
|
+
|
1129
|
+
# @!attribute filters
|
1130
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
1131
|
+
#
|
1132
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter>, nil]
|
1133
|
+
optional :filters,
|
1134
|
+
-> {
|
1135
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter]
|
1136
|
+
},
|
1137
|
+
nil?: true
|
1138
|
+
|
539
1139
|
# @!attribute is_invoice_level
|
540
1140
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
541
1141
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -543,18 +1143,128 @@ module Orb
|
|
543
1143
|
# @return [Boolean, nil]
|
544
1144
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
545
1145
|
|
546
|
-
# @!
|
1146
|
+
# @!attribute price_type
|
1147
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
1148
|
+
#
|
1149
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::PriceType, nil]
|
1150
|
+
optional :price_type,
|
1151
|
+
enum: -> {
|
1152
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::PriceType
|
1153
|
+
},
|
1154
|
+
nil?: true
|
1155
|
+
|
1156
|
+
# @!method initialize(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, adjustment_type: :maximum)
|
547
1157
|
# Some parameter documentations has been truncated, see
|
548
1158
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum}
|
549
1159
|
# for more details.
|
550
1160
|
#
|
551
1161
|
# @param maximum_amount [String]
|
552
1162
|
#
|
1163
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
1164
|
+
#
|
1165
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
1166
|
+
#
|
553
1167
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
554
1168
|
#
|
1169
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
1170
|
+
#
|
1171
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
1172
|
+
#
|
555
1173
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
556
1174
|
#
|
1175
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
1176
|
+
#
|
557
1177
|
# @param adjustment_type [Symbol, :maximum]
|
1178
|
+
|
1179
|
+
# If set, the adjustment will apply to every price on the subscription.
|
1180
|
+
#
|
1181
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum#applies_to_all
|
1182
|
+
module AppliesToAll
|
1183
|
+
extend Orb::Internal::Type::Enum
|
1184
|
+
|
1185
|
+
TRUE = true
|
1186
|
+
|
1187
|
+
# @!method self.values
|
1188
|
+
# @return [Array<Boolean>]
|
1189
|
+
end
|
1190
|
+
|
1191
|
+
class Filter < Orb::Internal::Type::BaseModel
|
1192
|
+
# @!attribute field
|
1193
|
+
# The property of the price to filter on.
|
1194
|
+
#
|
1195
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter::Field]
|
1196
|
+
required :field,
|
1197
|
+
enum: -> {
|
1198
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter::Field
|
1199
|
+
}
|
1200
|
+
|
1201
|
+
# @!attribute operator
|
1202
|
+
# Should prices that match the filter be included or excluded.
|
1203
|
+
#
|
1204
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter::Operator]
|
1205
|
+
required :operator,
|
1206
|
+
enum: -> {
|
1207
|
+
Orb::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter::Operator
|
1208
|
+
}
|
1209
|
+
|
1210
|
+
# @!attribute values
|
1211
|
+
# The IDs or values that match this filter.
|
1212
|
+
#
|
1213
|
+
# @return [Array<String>]
|
1214
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
1215
|
+
|
1216
|
+
# @!method initialize(field:, operator:, values:)
|
1217
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter::Field] The property of the price to filter on.
|
1218
|
+
#
|
1219
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter::Operator] Should prices that match the filter be included or excluded.
|
1220
|
+
#
|
1221
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
1222
|
+
|
1223
|
+
# The property of the price to filter on.
|
1224
|
+
#
|
1225
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter#field
|
1226
|
+
module Field
|
1227
|
+
extend Orb::Internal::Type::Enum
|
1228
|
+
|
1229
|
+
PRICE_ID = :price_id
|
1230
|
+
ITEM_ID = :item_id
|
1231
|
+
PRICE_TYPE = :price_type
|
1232
|
+
CURRENCY = :currency
|
1233
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
1234
|
+
|
1235
|
+
# @!method self.values
|
1236
|
+
# @return [Array<Symbol>]
|
1237
|
+
end
|
1238
|
+
|
1239
|
+
# Should prices that match the filter be included or excluded.
|
1240
|
+
#
|
1241
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum::Filter#operator
|
1242
|
+
module Operator
|
1243
|
+
extend Orb::Internal::Type::Enum
|
1244
|
+
|
1245
|
+
INCLUDES = :includes
|
1246
|
+
EXCLUDES = :excludes
|
1247
|
+
|
1248
|
+
# @!method self.values
|
1249
|
+
# @return [Array<Symbol>]
|
1250
|
+
end
|
1251
|
+
end
|
1252
|
+
|
1253
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
1254
|
+
#
|
1255
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::AddAdjustment::Adjustment::Maximum#price_type
|
1256
|
+
module PriceType
|
1257
|
+
extend Orb::Internal::Type::Enum
|
1258
|
+
|
1259
|
+
USAGE = :usage
|
1260
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
1261
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
1262
|
+
FIXED = :fixed
|
1263
|
+
IN_ARREARS = :in_arrears
|
1264
|
+
|
1265
|
+
# @!method self.values
|
1266
|
+
# @return [Array<Symbol>]
|
1267
|
+
end
|
558
1268
|
end
|
559
1269
|
|
560
1270
|
# @!method self.variants
|
@@ -9706,12 +10416,44 @@ module Orb
|
|
9706
10416
|
# @return [Float]
|
9707
10417
|
required :percentage_discount, Float
|
9708
10418
|
|
10419
|
+
# @!attribute applies_to_all
|
10420
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10421
|
+
#
|
10422
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::AppliesToAll, nil]
|
10423
|
+
optional :applies_to_all,
|
10424
|
+
enum: -> {
|
10425
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::AppliesToAll
|
10426
|
+
},
|
10427
|
+
nil?: true
|
10428
|
+
|
10429
|
+
# @!attribute applies_to_item_ids
|
10430
|
+
# The set of item IDs to which this adjustment applies.
|
10431
|
+
#
|
10432
|
+
# @return [Array<String>, nil]
|
10433
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
10434
|
+
|
9709
10435
|
# @!attribute applies_to_price_ids
|
9710
10436
|
# The set of price IDs to which this adjustment applies.
|
9711
10437
|
#
|
9712
10438
|
# @return [Array<String>, nil]
|
9713
10439
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
9714
10440
|
|
10441
|
+
# @!attribute currency
|
10442
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
10443
|
+
#
|
10444
|
+
# @return [String, nil]
|
10445
|
+
optional :currency, String, nil?: true
|
10446
|
+
|
10447
|
+
# @!attribute filters
|
10448
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
10449
|
+
#
|
10450
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter>, nil]
|
10451
|
+
optional :filters,
|
10452
|
+
-> {
|
10453
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter]
|
10454
|
+
},
|
10455
|
+
nil?: true
|
10456
|
+
|
9715
10457
|
# @!attribute is_invoice_level
|
9716
10458
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
9717
10459
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -9719,18 +10461,128 @@ module Orb
|
|
9719
10461
|
# @return [Boolean, nil]
|
9720
10462
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
9721
10463
|
|
9722
|
-
# @!
|
10464
|
+
# @!attribute price_type
|
10465
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
10466
|
+
#
|
10467
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::PriceType, nil]
|
10468
|
+
optional :price_type,
|
10469
|
+
enum: -> {
|
10470
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::PriceType
|
10471
|
+
},
|
10472
|
+
nil?: true
|
10473
|
+
|
10474
|
+
# @!method initialize(percentage_discount:, 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, adjustment_type: :percentage_discount)
|
9723
10475
|
# Some parameter documentations has been truncated, see
|
9724
10476
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount}
|
9725
10477
|
# for more details.
|
9726
10478
|
#
|
9727
10479
|
# @param percentage_discount [Float]
|
9728
10480
|
#
|
10481
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
10482
|
+
#
|
10483
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
10484
|
+
#
|
9729
10485
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
9730
10486
|
#
|
10487
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
10488
|
+
#
|
10489
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
10490
|
+
#
|
9731
10491
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
9732
10492
|
#
|
10493
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
10494
|
+
#
|
9733
10495
|
# @param adjustment_type [Symbol, :percentage_discount]
|
10496
|
+
|
10497
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10498
|
+
#
|
10499
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount#applies_to_all
|
10500
|
+
module AppliesToAll
|
10501
|
+
extend Orb::Internal::Type::Enum
|
10502
|
+
|
10503
|
+
TRUE = true
|
10504
|
+
|
10505
|
+
# @!method self.values
|
10506
|
+
# @return [Array<Boolean>]
|
10507
|
+
end
|
10508
|
+
|
10509
|
+
class Filter < Orb::Internal::Type::BaseModel
|
10510
|
+
# @!attribute field
|
10511
|
+
# The property of the price to filter on.
|
10512
|
+
#
|
10513
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter::Field]
|
10514
|
+
required :field,
|
10515
|
+
enum: -> {
|
10516
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter::Field
|
10517
|
+
}
|
10518
|
+
|
10519
|
+
# @!attribute operator
|
10520
|
+
# Should prices that match the filter be included or excluded.
|
10521
|
+
#
|
10522
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter::Operator]
|
10523
|
+
required :operator,
|
10524
|
+
enum: -> {
|
10525
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter::Operator
|
10526
|
+
}
|
10527
|
+
|
10528
|
+
# @!attribute values
|
10529
|
+
# The IDs or values that match this filter.
|
10530
|
+
#
|
10531
|
+
# @return [Array<String>]
|
10532
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
10533
|
+
|
10534
|
+
# @!method initialize(field:, operator:, values:)
|
10535
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter::Field] The property of the price to filter on.
|
10536
|
+
#
|
10537
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
10538
|
+
#
|
10539
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
10540
|
+
|
10541
|
+
# The property of the price to filter on.
|
10542
|
+
#
|
10543
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter#field
|
10544
|
+
module Field
|
10545
|
+
extend Orb::Internal::Type::Enum
|
10546
|
+
|
10547
|
+
PRICE_ID = :price_id
|
10548
|
+
ITEM_ID = :item_id
|
10549
|
+
PRICE_TYPE = :price_type
|
10550
|
+
CURRENCY = :currency
|
10551
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
10552
|
+
|
10553
|
+
# @!method self.values
|
10554
|
+
# @return [Array<Symbol>]
|
10555
|
+
end
|
10556
|
+
|
10557
|
+
# Should prices that match the filter be included or excluded.
|
10558
|
+
#
|
10559
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount::Filter#operator
|
10560
|
+
module Operator
|
10561
|
+
extend Orb::Internal::Type::Enum
|
10562
|
+
|
10563
|
+
INCLUDES = :includes
|
10564
|
+
EXCLUDES = :excludes
|
10565
|
+
|
10566
|
+
# @!method self.values
|
10567
|
+
# @return [Array<Symbol>]
|
10568
|
+
end
|
10569
|
+
end
|
10570
|
+
|
10571
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
10572
|
+
#
|
10573
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::PercentageDiscount#price_type
|
10574
|
+
module PriceType
|
10575
|
+
extend Orb::Internal::Type::Enum
|
10576
|
+
|
10577
|
+
USAGE = :usage
|
10578
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
10579
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
10580
|
+
FIXED = :fixed
|
10581
|
+
IN_ARREARS = :in_arrears
|
10582
|
+
|
10583
|
+
# @!method self.values
|
10584
|
+
# @return [Array<Symbol>]
|
10585
|
+
end
|
9734
10586
|
end
|
9735
10587
|
|
9736
10588
|
class UsageDiscount < Orb::Internal::Type::BaseModel
|
@@ -9744,12 +10596,44 @@ module Orb
|
|
9744
10596
|
# @return [Float]
|
9745
10597
|
required :usage_discount, Float
|
9746
10598
|
|
10599
|
+
# @!attribute applies_to_all
|
10600
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10601
|
+
#
|
10602
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::AppliesToAll, nil]
|
10603
|
+
optional :applies_to_all,
|
10604
|
+
enum: -> {
|
10605
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::AppliesToAll
|
10606
|
+
},
|
10607
|
+
nil?: true
|
10608
|
+
|
10609
|
+
# @!attribute applies_to_item_ids
|
10610
|
+
# The set of item IDs to which this adjustment applies.
|
10611
|
+
#
|
10612
|
+
# @return [Array<String>, nil]
|
10613
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
10614
|
+
|
9747
10615
|
# @!attribute applies_to_price_ids
|
9748
10616
|
# The set of price IDs to which this adjustment applies.
|
9749
10617
|
#
|
9750
10618
|
# @return [Array<String>, nil]
|
9751
10619
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
9752
10620
|
|
10621
|
+
# @!attribute currency
|
10622
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
10623
|
+
#
|
10624
|
+
# @return [String, nil]
|
10625
|
+
optional :currency, String, nil?: true
|
10626
|
+
|
10627
|
+
# @!attribute filters
|
10628
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
10629
|
+
#
|
10630
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter>, nil]
|
10631
|
+
optional :filters,
|
10632
|
+
-> {
|
10633
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter]
|
10634
|
+
},
|
10635
|
+
nil?: true
|
10636
|
+
|
9753
10637
|
# @!attribute is_invoice_level
|
9754
10638
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
9755
10639
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -9757,18 +10641,128 @@ module Orb
|
|
9757
10641
|
# @return [Boolean, nil]
|
9758
10642
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
9759
10643
|
|
9760
|
-
# @!
|
10644
|
+
# @!attribute price_type
|
10645
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
10646
|
+
#
|
10647
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::PriceType, nil]
|
10648
|
+
optional :price_type,
|
10649
|
+
enum: -> {
|
10650
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::PriceType
|
10651
|
+
},
|
10652
|
+
nil?: true
|
10653
|
+
|
10654
|
+
# @!method initialize(usage_discount:, 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, adjustment_type: :usage_discount)
|
9761
10655
|
# Some parameter documentations has been truncated, see
|
9762
10656
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount}
|
9763
10657
|
# for more details.
|
9764
10658
|
#
|
9765
10659
|
# @param usage_discount [Float]
|
9766
10660
|
#
|
10661
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
10662
|
+
#
|
10663
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
10664
|
+
#
|
9767
10665
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
9768
10666
|
#
|
10667
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
10668
|
+
#
|
10669
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
10670
|
+
#
|
9769
10671
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
9770
10672
|
#
|
10673
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
10674
|
+
#
|
9771
10675
|
# @param adjustment_type [Symbol, :usage_discount]
|
10676
|
+
|
10677
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10678
|
+
#
|
10679
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount#applies_to_all
|
10680
|
+
module AppliesToAll
|
10681
|
+
extend Orb::Internal::Type::Enum
|
10682
|
+
|
10683
|
+
TRUE = true
|
10684
|
+
|
10685
|
+
# @!method self.values
|
10686
|
+
# @return [Array<Boolean>]
|
10687
|
+
end
|
10688
|
+
|
10689
|
+
class Filter < Orb::Internal::Type::BaseModel
|
10690
|
+
# @!attribute field
|
10691
|
+
# The property of the price to filter on.
|
10692
|
+
#
|
10693
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter::Field]
|
10694
|
+
required :field,
|
10695
|
+
enum: -> {
|
10696
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter::Field
|
10697
|
+
}
|
10698
|
+
|
10699
|
+
# @!attribute operator
|
10700
|
+
# Should prices that match the filter be included or excluded.
|
10701
|
+
#
|
10702
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter::Operator]
|
10703
|
+
required :operator,
|
10704
|
+
enum: -> {
|
10705
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter::Operator
|
10706
|
+
}
|
10707
|
+
|
10708
|
+
# @!attribute values
|
10709
|
+
# The IDs or values that match this filter.
|
10710
|
+
#
|
10711
|
+
# @return [Array<String>]
|
10712
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
10713
|
+
|
10714
|
+
# @!method initialize(field:, operator:, values:)
|
10715
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter::Field] The property of the price to filter on.
|
10716
|
+
#
|
10717
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
10718
|
+
#
|
10719
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
10720
|
+
|
10721
|
+
# The property of the price to filter on.
|
10722
|
+
#
|
10723
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter#field
|
10724
|
+
module Field
|
10725
|
+
extend Orb::Internal::Type::Enum
|
10726
|
+
|
10727
|
+
PRICE_ID = :price_id
|
10728
|
+
ITEM_ID = :item_id
|
10729
|
+
PRICE_TYPE = :price_type
|
10730
|
+
CURRENCY = :currency
|
10731
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
10732
|
+
|
10733
|
+
# @!method self.values
|
10734
|
+
# @return [Array<Symbol>]
|
10735
|
+
end
|
10736
|
+
|
10737
|
+
# Should prices that match the filter be included or excluded.
|
10738
|
+
#
|
10739
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount::Filter#operator
|
10740
|
+
module Operator
|
10741
|
+
extend Orb::Internal::Type::Enum
|
10742
|
+
|
10743
|
+
INCLUDES = :includes
|
10744
|
+
EXCLUDES = :excludes
|
10745
|
+
|
10746
|
+
# @!method self.values
|
10747
|
+
# @return [Array<Symbol>]
|
10748
|
+
end
|
10749
|
+
end
|
10750
|
+
|
10751
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
10752
|
+
#
|
10753
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::UsageDiscount#price_type
|
10754
|
+
module PriceType
|
10755
|
+
extend Orb::Internal::Type::Enum
|
10756
|
+
|
10757
|
+
USAGE = :usage
|
10758
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
10759
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
10760
|
+
FIXED = :fixed
|
10761
|
+
IN_ARREARS = :in_arrears
|
10762
|
+
|
10763
|
+
# @!method self.values
|
10764
|
+
# @return [Array<Symbol>]
|
10765
|
+
end
|
9772
10766
|
end
|
9773
10767
|
|
9774
10768
|
class AmountDiscount < Orb::Internal::Type::BaseModel
|
@@ -9782,12 +10776,44 @@ module Orb
|
|
9782
10776
|
# @return [String]
|
9783
10777
|
required :amount_discount, String
|
9784
10778
|
|
10779
|
+
# @!attribute applies_to_all
|
10780
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10781
|
+
#
|
10782
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::AppliesToAll, nil]
|
10783
|
+
optional :applies_to_all,
|
10784
|
+
enum: -> {
|
10785
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::AppliesToAll
|
10786
|
+
},
|
10787
|
+
nil?: true
|
10788
|
+
|
10789
|
+
# @!attribute applies_to_item_ids
|
10790
|
+
# The set of item IDs to which this adjustment applies.
|
10791
|
+
#
|
10792
|
+
# @return [Array<String>, nil]
|
10793
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
10794
|
+
|
9785
10795
|
# @!attribute applies_to_price_ids
|
9786
10796
|
# The set of price IDs to which this adjustment applies.
|
9787
10797
|
#
|
9788
10798
|
# @return [Array<String>, nil]
|
9789
10799
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
9790
10800
|
|
10801
|
+
# @!attribute currency
|
10802
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
10803
|
+
#
|
10804
|
+
# @return [String, nil]
|
10805
|
+
optional :currency, String, nil?: true
|
10806
|
+
|
10807
|
+
# @!attribute filters
|
10808
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
10809
|
+
#
|
10810
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter>, nil]
|
10811
|
+
optional :filters,
|
10812
|
+
-> {
|
10813
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter]
|
10814
|
+
},
|
10815
|
+
nil?: true
|
10816
|
+
|
9791
10817
|
# @!attribute is_invoice_level
|
9792
10818
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
9793
10819
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -9795,18 +10821,128 @@ module Orb
|
|
9795
10821
|
# @return [Boolean, nil]
|
9796
10822
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
9797
10823
|
|
9798
|
-
# @!
|
10824
|
+
# @!attribute price_type
|
10825
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
10826
|
+
#
|
10827
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::PriceType, nil]
|
10828
|
+
optional :price_type,
|
10829
|
+
enum: -> {
|
10830
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::PriceType
|
10831
|
+
},
|
10832
|
+
nil?: true
|
10833
|
+
|
10834
|
+
# @!method initialize(amount_discount:, 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, adjustment_type: :amount_discount)
|
9799
10835
|
# Some parameter documentations has been truncated, see
|
9800
10836
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount}
|
9801
10837
|
# for more details.
|
9802
10838
|
#
|
9803
10839
|
# @param amount_discount [String]
|
9804
10840
|
#
|
10841
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
10842
|
+
#
|
10843
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
10844
|
+
#
|
9805
10845
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
9806
10846
|
#
|
10847
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
10848
|
+
#
|
10849
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
10850
|
+
#
|
9807
10851
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
9808
10852
|
#
|
10853
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
10854
|
+
#
|
9809
10855
|
# @param adjustment_type [Symbol, :amount_discount]
|
10856
|
+
|
10857
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10858
|
+
#
|
10859
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount#applies_to_all
|
10860
|
+
module AppliesToAll
|
10861
|
+
extend Orb::Internal::Type::Enum
|
10862
|
+
|
10863
|
+
TRUE = true
|
10864
|
+
|
10865
|
+
# @!method self.values
|
10866
|
+
# @return [Array<Boolean>]
|
10867
|
+
end
|
10868
|
+
|
10869
|
+
class Filter < Orb::Internal::Type::BaseModel
|
10870
|
+
# @!attribute field
|
10871
|
+
# The property of the price to filter on.
|
10872
|
+
#
|
10873
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter::Field]
|
10874
|
+
required :field,
|
10875
|
+
enum: -> {
|
10876
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter::Field
|
10877
|
+
}
|
10878
|
+
|
10879
|
+
# @!attribute operator
|
10880
|
+
# Should prices that match the filter be included or excluded.
|
10881
|
+
#
|
10882
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter::Operator]
|
10883
|
+
required :operator,
|
10884
|
+
enum: -> {
|
10885
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter::Operator
|
10886
|
+
}
|
10887
|
+
|
10888
|
+
# @!attribute values
|
10889
|
+
# The IDs or values that match this filter.
|
10890
|
+
#
|
10891
|
+
# @return [Array<String>]
|
10892
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
10893
|
+
|
10894
|
+
# @!method initialize(field:, operator:, values:)
|
10895
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter::Field] The property of the price to filter on.
|
10896
|
+
#
|
10897
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter::Operator] Should prices that match the filter be included or excluded.
|
10898
|
+
#
|
10899
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
10900
|
+
|
10901
|
+
# The property of the price to filter on.
|
10902
|
+
#
|
10903
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter#field
|
10904
|
+
module Field
|
10905
|
+
extend Orb::Internal::Type::Enum
|
10906
|
+
|
10907
|
+
PRICE_ID = :price_id
|
10908
|
+
ITEM_ID = :item_id
|
10909
|
+
PRICE_TYPE = :price_type
|
10910
|
+
CURRENCY = :currency
|
10911
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
10912
|
+
|
10913
|
+
# @!method self.values
|
10914
|
+
# @return [Array<Symbol>]
|
10915
|
+
end
|
10916
|
+
|
10917
|
+
# Should prices that match the filter be included or excluded.
|
10918
|
+
#
|
10919
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount::Filter#operator
|
10920
|
+
module Operator
|
10921
|
+
extend Orb::Internal::Type::Enum
|
10922
|
+
|
10923
|
+
INCLUDES = :includes
|
10924
|
+
EXCLUDES = :excludes
|
10925
|
+
|
10926
|
+
# @!method self.values
|
10927
|
+
# @return [Array<Symbol>]
|
10928
|
+
end
|
10929
|
+
end
|
10930
|
+
|
10931
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
10932
|
+
#
|
10933
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::AmountDiscount#price_type
|
10934
|
+
module PriceType
|
10935
|
+
extend Orb::Internal::Type::Enum
|
10936
|
+
|
10937
|
+
USAGE = :usage
|
10938
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
10939
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
10940
|
+
FIXED = :fixed
|
10941
|
+
IN_ARREARS = :in_arrears
|
10942
|
+
|
10943
|
+
# @!method self.values
|
10944
|
+
# @return [Array<Symbol>]
|
10945
|
+
end
|
9810
10946
|
end
|
9811
10947
|
|
9812
10948
|
class Minimum < Orb::Internal::Type::BaseModel
|
@@ -9826,12 +10962,44 @@ module Orb
|
|
9826
10962
|
# @return [String]
|
9827
10963
|
required :minimum_amount, String
|
9828
10964
|
|
10965
|
+
# @!attribute applies_to_all
|
10966
|
+
# If set, the adjustment will apply to every price on the subscription.
|
10967
|
+
#
|
10968
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::AppliesToAll, nil]
|
10969
|
+
optional :applies_to_all,
|
10970
|
+
enum: -> {
|
10971
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::AppliesToAll
|
10972
|
+
},
|
10973
|
+
nil?: true
|
10974
|
+
|
10975
|
+
# @!attribute applies_to_item_ids
|
10976
|
+
# The set of item IDs to which this adjustment applies.
|
10977
|
+
#
|
10978
|
+
# @return [Array<String>, nil]
|
10979
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
10980
|
+
|
9829
10981
|
# @!attribute applies_to_price_ids
|
9830
10982
|
# The set of price IDs to which this adjustment applies.
|
9831
10983
|
#
|
9832
10984
|
# @return [Array<String>, nil]
|
9833
10985
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
9834
10986
|
|
10987
|
+
# @!attribute currency
|
10988
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
10989
|
+
#
|
10990
|
+
# @return [String, nil]
|
10991
|
+
optional :currency, String, nil?: true
|
10992
|
+
|
10993
|
+
# @!attribute filters
|
10994
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
10995
|
+
#
|
10996
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter>, nil]
|
10997
|
+
optional :filters,
|
10998
|
+
-> {
|
10999
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter]
|
11000
|
+
},
|
11001
|
+
nil?: true
|
11002
|
+
|
9835
11003
|
# @!attribute is_invoice_level
|
9836
11004
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
9837
11005
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -9839,7 +11007,17 @@ module Orb
|
|
9839
11007
|
# @return [Boolean, nil]
|
9840
11008
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
9841
11009
|
|
9842
|
-
# @!
|
11010
|
+
# @!attribute price_type
|
11011
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
11012
|
+
#
|
11013
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::PriceType, nil]
|
11014
|
+
optional :price_type,
|
11015
|
+
enum: -> {
|
11016
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::PriceType
|
11017
|
+
},
|
11018
|
+
nil?: true
|
11019
|
+
|
11020
|
+
# @!method initialize(item_id:, minimum_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, adjustment_type: :minimum)
|
9843
11021
|
# Some parameter documentations has been truncated, see
|
9844
11022
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum}
|
9845
11023
|
# for more details.
|
@@ -9848,11 +11026,111 @@ module Orb
|
|
9848
11026
|
#
|
9849
11027
|
# @param minimum_amount [String]
|
9850
11028
|
#
|
11029
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
11030
|
+
#
|
11031
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
11032
|
+
#
|
9851
11033
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
9852
11034
|
#
|
11035
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
11036
|
+
#
|
11037
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
11038
|
+
#
|
9853
11039
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
9854
11040
|
#
|
11041
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
11042
|
+
#
|
9855
11043
|
# @param adjustment_type [Symbol, :minimum]
|
11044
|
+
|
11045
|
+
# If set, the adjustment will apply to every price on the subscription.
|
11046
|
+
#
|
11047
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum#applies_to_all
|
11048
|
+
module AppliesToAll
|
11049
|
+
extend Orb::Internal::Type::Enum
|
11050
|
+
|
11051
|
+
TRUE = true
|
11052
|
+
|
11053
|
+
# @!method self.values
|
11054
|
+
# @return [Array<Boolean>]
|
11055
|
+
end
|
11056
|
+
|
11057
|
+
class Filter < Orb::Internal::Type::BaseModel
|
11058
|
+
# @!attribute field
|
11059
|
+
# The property of the price to filter on.
|
11060
|
+
#
|
11061
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter::Field]
|
11062
|
+
required :field,
|
11063
|
+
enum: -> {
|
11064
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter::Field
|
11065
|
+
}
|
11066
|
+
|
11067
|
+
# @!attribute operator
|
11068
|
+
# Should prices that match the filter be included or excluded.
|
11069
|
+
#
|
11070
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter::Operator]
|
11071
|
+
required :operator,
|
11072
|
+
enum: -> {
|
11073
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter::Operator
|
11074
|
+
}
|
11075
|
+
|
11076
|
+
# @!attribute values
|
11077
|
+
# The IDs or values that match this filter.
|
11078
|
+
#
|
11079
|
+
# @return [Array<String>]
|
11080
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
11081
|
+
|
11082
|
+
# @!method initialize(field:, operator:, values:)
|
11083
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter::Field] The property of the price to filter on.
|
11084
|
+
#
|
11085
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter::Operator] Should prices that match the filter be included or excluded.
|
11086
|
+
#
|
11087
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
11088
|
+
|
11089
|
+
# The property of the price to filter on.
|
11090
|
+
#
|
11091
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter#field
|
11092
|
+
module Field
|
11093
|
+
extend Orb::Internal::Type::Enum
|
11094
|
+
|
11095
|
+
PRICE_ID = :price_id
|
11096
|
+
ITEM_ID = :item_id
|
11097
|
+
PRICE_TYPE = :price_type
|
11098
|
+
CURRENCY = :currency
|
11099
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
11100
|
+
|
11101
|
+
# @!method self.values
|
11102
|
+
# @return [Array<Symbol>]
|
11103
|
+
end
|
11104
|
+
|
11105
|
+
# Should prices that match the filter be included or excluded.
|
11106
|
+
#
|
11107
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum::Filter#operator
|
11108
|
+
module Operator
|
11109
|
+
extend Orb::Internal::Type::Enum
|
11110
|
+
|
11111
|
+
INCLUDES = :includes
|
11112
|
+
EXCLUDES = :excludes
|
11113
|
+
|
11114
|
+
# @!method self.values
|
11115
|
+
# @return [Array<Symbol>]
|
11116
|
+
end
|
11117
|
+
end
|
11118
|
+
|
11119
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
11120
|
+
#
|
11121
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Minimum#price_type
|
11122
|
+
module PriceType
|
11123
|
+
extend Orb::Internal::Type::Enum
|
11124
|
+
|
11125
|
+
USAGE = :usage
|
11126
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
11127
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
11128
|
+
FIXED = :fixed
|
11129
|
+
IN_ARREARS = :in_arrears
|
11130
|
+
|
11131
|
+
# @!method self.values
|
11132
|
+
# @return [Array<Symbol>]
|
11133
|
+
end
|
9856
11134
|
end
|
9857
11135
|
|
9858
11136
|
class Maximum < Orb::Internal::Type::BaseModel
|
@@ -9866,12 +11144,44 @@ module Orb
|
|
9866
11144
|
# @return [String]
|
9867
11145
|
required :maximum_amount, String
|
9868
11146
|
|
11147
|
+
# @!attribute applies_to_all
|
11148
|
+
# If set, the adjustment will apply to every price on the subscription.
|
11149
|
+
#
|
11150
|
+
# @return [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::AppliesToAll, nil]
|
11151
|
+
optional :applies_to_all,
|
11152
|
+
enum: -> {
|
11153
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::AppliesToAll
|
11154
|
+
},
|
11155
|
+
nil?: true
|
11156
|
+
|
11157
|
+
# @!attribute applies_to_item_ids
|
11158
|
+
# The set of item IDs to which this adjustment applies.
|
11159
|
+
#
|
11160
|
+
# @return [Array<String>, nil]
|
11161
|
+
optional :applies_to_item_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
11162
|
+
|
9869
11163
|
# @!attribute applies_to_price_ids
|
9870
11164
|
# The set of price IDs to which this adjustment applies.
|
9871
11165
|
#
|
9872
11166
|
# @return [Array<String>, nil]
|
9873
11167
|
optional :applies_to_price_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
9874
11168
|
|
11169
|
+
# @!attribute currency
|
11170
|
+
# If set, only prices in the specified currency will have the adjustment applied.
|
11171
|
+
#
|
11172
|
+
# @return [String, nil]
|
11173
|
+
optional :currency, String, nil?: true
|
11174
|
+
|
11175
|
+
# @!attribute filters
|
11176
|
+
# A list of filters that determine which prices this adjustment will apply to.
|
11177
|
+
#
|
11178
|
+
# @return [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter>, nil]
|
11179
|
+
optional :filters,
|
11180
|
+
-> {
|
11181
|
+
Orb::Internal::Type::ArrayOf[Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter]
|
11182
|
+
},
|
11183
|
+
nil?: true
|
11184
|
+
|
9875
11185
|
# @!attribute is_invoice_level
|
9876
11186
|
# When false, this adjustment will be applied to a single price. Otherwise, it
|
9877
11187
|
# will be applied at the invoice level, possibly to multiple prices.
|
@@ -9879,18 +11189,128 @@ module Orb
|
|
9879
11189
|
# @return [Boolean, nil]
|
9880
11190
|
optional :is_invoice_level, Orb::Internal::Type::Boolean
|
9881
11191
|
|
9882
|
-
# @!
|
11192
|
+
# @!attribute price_type
|
11193
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
11194
|
+
#
|
11195
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::PriceType, nil]
|
11196
|
+
optional :price_type,
|
11197
|
+
enum: -> {
|
11198
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::PriceType
|
11199
|
+
},
|
11200
|
+
nil?: true
|
11201
|
+
|
11202
|
+
# @!method initialize(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, adjustment_type: :maximum)
|
9883
11203
|
# Some parameter documentations has been truncated, see
|
9884
11204
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum}
|
9885
11205
|
# for more details.
|
9886
11206
|
#
|
9887
11207
|
# @param maximum_amount [String]
|
9888
11208
|
#
|
11209
|
+
# @param applies_to_all [Boolean, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::AppliesToAll, nil] If set, the adjustment will apply to every price on the subscription.
|
11210
|
+
#
|
11211
|
+
# @param applies_to_item_ids [Array<String>, nil] The set of item IDs to which this adjustment applies.
|
11212
|
+
#
|
9889
11213
|
# @param applies_to_price_ids [Array<String>, nil] The set of price IDs to which this adjustment applies.
|
9890
11214
|
#
|
11215
|
+
# @param currency [String, nil] If set, only prices in the specified currency will have the adjustment applied.
|
11216
|
+
#
|
11217
|
+
# @param filters [Array<Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter>, nil] A list of filters that determine which prices this adjustment will apply to.
|
11218
|
+
#
|
9891
11219
|
# @param is_invoice_level [Boolean] When false, this adjustment will be applied to a single price. Otherwise, it wil
|
9892
11220
|
#
|
11221
|
+
# @param price_type [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::PriceType, nil] If set, only prices of the specified type will have the adjustment applied.
|
11222
|
+
#
|
9893
11223
|
# @param adjustment_type [Symbol, :maximum]
|
11224
|
+
|
11225
|
+
# If set, the adjustment will apply to every price on the subscription.
|
11226
|
+
#
|
11227
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum#applies_to_all
|
11228
|
+
module AppliesToAll
|
11229
|
+
extend Orb::Internal::Type::Enum
|
11230
|
+
|
11231
|
+
TRUE = true
|
11232
|
+
|
11233
|
+
# @!method self.values
|
11234
|
+
# @return [Array<Boolean>]
|
11235
|
+
end
|
11236
|
+
|
11237
|
+
class Filter < Orb::Internal::Type::BaseModel
|
11238
|
+
# @!attribute field
|
11239
|
+
# The property of the price to filter on.
|
11240
|
+
#
|
11241
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter::Field]
|
11242
|
+
required :field,
|
11243
|
+
enum: -> {
|
11244
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter::Field
|
11245
|
+
}
|
11246
|
+
|
11247
|
+
# @!attribute operator
|
11248
|
+
# Should prices that match the filter be included or excluded.
|
11249
|
+
#
|
11250
|
+
# @return [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter::Operator]
|
11251
|
+
required :operator,
|
11252
|
+
enum: -> {
|
11253
|
+
Orb::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter::Operator
|
11254
|
+
}
|
11255
|
+
|
11256
|
+
# @!attribute values
|
11257
|
+
# The IDs or values that match this filter.
|
11258
|
+
#
|
11259
|
+
# @return [Array<String>]
|
11260
|
+
required :values, Orb::Internal::Type::ArrayOf[String]
|
11261
|
+
|
11262
|
+
# @!method initialize(field:, operator:, values:)
|
11263
|
+
# @param field [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter::Field] The property of the price to filter on.
|
11264
|
+
#
|
11265
|
+
# @param operator [Symbol, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter::Operator] Should prices that match the filter be included or excluded.
|
11266
|
+
#
|
11267
|
+
# @param values [Array<String>] The IDs or values that match this filter.
|
11268
|
+
|
11269
|
+
# The property of the price to filter on.
|
11270
|
+
#
|
11271
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter#field
|
11272
|
+
module Field
|
11273
|
+
extend Orb::Internal::Type::Enum
|
11274
|
+
|
11275
|
+
PRICE_ID = :price_id
|
11276
|
+
ITEM_ID = :item_id
|
11277
|
+
PRICE_TYPE = :price_type
|
11278
|
+
CURRENCY = :currency
|
11279
|
+
PRICING_UNIT_ID = :pricing_unit_id
|
11280
|
+
|
11281
|
+
# @!method self.values
|
11282
|
+
# @return [Array<Symbol>]
|
11283
|
+
end
|
11284
|
+
|
11285
|
+
# Should prices that match the filter be included or excluded.
|
11286
|
+
#
|
11287
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum::Filter#operator
|
11288
|
+
module Operator
|
11289
|
+
extend Orb::Internal::Type::Enum
|
11290
|
+
|
11291
|
+
INCLUDES = :includes
|
11292
|
+
EXCLUDES = :excludes
|
11293
|
+
|
11294
|
+
# @!method self.values
|
11295
|
+
# @return [Array<Symbol>]
|
11296
|
+
end
|
11297
|
+
end
|
11298
|
+
|
11299
|
+
# If set, only prices of the specified type will have the adjustment applied.
|
11300
|
+
#
|
11301
|
+
# @see Orb::Models::SubscriptionSchedulePlanChangeParams::ReplaceAdjustment::Adjustment::Maximum#price_type
|
11302
|
+
module PriceType
|
11303
|
+
extend Orb::Internal::Type::Enum
|
11304
|
+
|
11305
|
+
USAGE = :usage
|
11306
|
+
FIXED_IN_ADVANCE = :fixed_in_advance
|
11307
|
+
FIXED_IN_ARREARS = :fixed_in_arrears
|
11308
|
+
FIXED = :fixed
|
11309
|
+
IN_ARREARS = :in_arrears
|
11310
|
+
|
11311
|
+
# @!method self.values
|
11312
|
+
# @return [Array<Symbol>]
|
11313
|
+
end
|
9894
11314
|
end
|
9895
11315
|
|
9896
11316
|
# @!method self.variants
|