orb-billing 1.1.0 → 1.2.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.
Files changed (38) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +13 -0
  3. data/README.md +1 -1
  4. data/lib/orb/models/monetary_amount_discount_adjustment.rb +10 -1
  5. data/lib/orb/models/monetary_maximum_adjustment.rb +10 -1
  6. data/lib/orb/models/monetary_minimum_adjustment.rb +10 -1
  7. data/lib/orb/models/monetary_percentage_discount_adjustment.rb +10 -1
  8. data/lib/orb/models/monetary_usage_discount_adjustment.rb +10 -1
  9. data/lib/orb/models/plan_phase_amount_discount_adjustment.rb +10 -1
  10. data/lib/orb/models/plan_phase_maximum_adjustment.rb +10 -1
  11. data/lib/orb/models/plan_phase_minimum_adjustment.rb +10 -1
  12. data/lib/orb/models/plan_phase_percentage_discount_adjustment.rb +10 -1
  13. data/lib/orb/models/plan_phase_usage_discount_adjustment.rb +10 -1
  14. data/lib/orb/models/price.rb +280 -28
  15. data/lib/orb/version.rb +1 -1
  16. data/rbi/orb/models/monetary_amount_discount_adjustment.rbi +13 -3
  17. data/rbi/orb/models/monetary_maximum_adjustment.rbi +13 -3
  18. data/rbi/orb/models/monetary_minimum_adjustment.rbi +13 -3
  19. data/rbi/orb/models/monetary_percentage_discount_adjustment.rbi +13 -3
  20. data/rbi/orb/models/monetary_usage_discount_adjustment.rbi +10 -0
  21. data/rbi/orb/models/plan_phase_amount_discount_adjustment.rbi +13 -3
  22. data/rbi/orb/models/plan_phase_maximum_adjustment.rbi +13 -3
  23. data/rbi/orb/models/plan_phase_minimum_adjustment.rbi +13 -3
  24. data/rbi/orb/models/plan_phase_percentage_discount_adjustment.rbi +13 -3
  25. data/rbi/orb/models/plan_phase_usage_discount_adjustment.rbi +10 -0
  26. data/rbi/orb/models/price.rbi +280 -0
  27. data/sig/orb/models/monetary_amount_discount_adjustment.rbs +8 -3
  28. data/sig/orb/models/monetary_maximum_adjustment.rbs +8 -3
  29. data/sig/orb/models/monetary_minimum_adjustment.rbs +8 -3
  30. data/sig/orb/models/monetary_percentage_discount_adjustment.rbs +8 -3
  31. data/sig/orb/models/monetary_usage_discount_adjustment.rbs +5 -0
  32. data/sig/orb/models/plan_phase_amount_discount_adjustment.rbs +8 -3
  33. data/sig/orb/models/plan_phase_maximum_adjustment.rbs +8 -3
  34. data/sig/orb/models/plan_phase_minimum_adjustment.rbs +8 -3
  35. data/sig/orb/models/plan_phase_percentage_discount_adjustment.rbs +8 -3
  36. data/sig/orb/models/plan_phase_usage_discount_adjustment.rbs +5 -0
  37. data/sig/orb/models/price.rbs +140 -0
  38. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 72bf8cc708079b89812a37a34a92505d31c7a8e4fb7be72449ef1cefa3a68433
4
- data.tar.gz: c94583819d1a3c5e6544dc35378a645f5b823e6591a6fc8a18e0a02c070e68da
3
+ metadata.gz: 4f4ae521bd8d9d4275a40fa934cf549e2eb6cbcbca223e029b346e30ddf8a944
4
+ data.tar.gz: 24fa3c6a5e0e8122fa51b318b0d3c5873d314512cfbf5b662affd52a7b54128a
5
5
  SHA512:
6
- metadata.gz: 3955626d5164c7909179bd3d87b0bdea7660cc532390ecff4586642a79072014f039fe0e1ecf05a9c1a52ed2a5088800bac24bea9ae02fe0110692c6579cf0f1
7
- data.tar.gz: b440576069f58911b5fb0640bdd8e92a0210b8027b9cf7640aee6c2094d94ff56b8285e3e870630c825684b3902f8eb4085ec8b79a233b5eb4d3ca9557e9f898
6
+ metadata.gz: a6fa4cc817ea442fbb900eed43c07bb83ab8ff177fdec5678b7dc361f48c8bb1a3ed980c704ee8e6efea2922f970d62655fa5a4e5603dd520fba979a03158533
7
+ data.tar.gz: a88704dc4577925662b94caff23d0bfe56ffe6a4b00f67415cd3afd1eb72d46a5d9cf36123f33cbbc1f8ac12ada9203667597ef1843e1e742d2a2397a77a5268
data/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.2.0 (2025-06-26)
4
+
5
+ Full Changelog: [v1.1.0...v1.2.0](https://github.com/orbcorp/orb-ruby/compare/v1.1.0...v1.2.0)
6
+
7
+ ### Features
8
+
9
+ * **api:** api update ([5a73526](https://github.com/orbcorp/orb-ruby/commit/5a73526b78e0eeb8b440b94b885fce49f6b28006))
10
+
11
+
12
+ ### Chores
13
+
14
+ * **internal:** version bump ([9c3718b](https://github.com/orbcorp/orb-ruby/commit/9c3718b58f8bba10548e2897448d908588c6ea02))
15
+
3
16
  ## 1.1.0 (2025-06-18)
4
17
 
5
18
  Full Changelog: [v1.0.1...v1.1.0](https://github.com/orbcorp/orb-ruby/compare/v1.0.1...v1.1.0)
data/README.md CHANGED
@@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application
15
15
  <!-- x-release-please-start-version -->
16
16
 
17
17
  ```ruby
18
- gem "orb-billing", "~> 1.1.0"
18
+ gem "orb-billing", "~> 1.2.0"
19
19
  ```
20
20
 
21
21
  <!-- x-release-please-end -->
@@ -53,7 +53,14 @@ module Orb
53
53
  # @return [String, nil]
54
54
  required :reason, String, nil?: true
55
55
 
56
- # @!method initialize(id:, adjustment_type:, amount:, amount_discount:, applies_to_price_ids:, filters:, is_invoice_level:, reason:)
56
+ # @!attribute replaces_adjustment_id
57
+ # The adjustment id this adjustment replaces. This adjustment will take the place
58
+ # of the replaced adjustment in plan version migrations.
59
+ #
60
+ # @return [String, nil]
61
+ required :replaces_adjustment_id, String, nil?: true
62
+
63
+ # @!method initialize(id:, adjustment_type:, amount:, amount_discount:, applies_to_price_ids:, filters:, is_invoice_level:, reason:, replaces_adjustment_id:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::MonetaryAmountDiscountAdjustment} for more details.
59
66
  #
@@ -72,6 +79,8 @@ module Orb
72
79
  # @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
73
80
  #
74
81
  # @param reason [String, nil] The reason for the adjustment.
82
+ #
83
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
75
84
 
76
85
  # @see Orb::Models::MonetaryAmountDiscountAdjustment#adjustment_type
77
86
  module AdjustmentType
@@ -53,7 +53,14 @@ module Orb
53
53
  # @return [String, nil]
54
54
  required :reason, String, nil?: true
55
55
 
56
- # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, maximum_amount:, reason:)
56
+ # @!attribute replaces_adjustment_id
57
+ # The adjustment id this adjustment replaces. This adjustment will take the place
58
+ # of the replaced adjustment in plan version migrations.
59
+ #
60
+ # @return [String, nil]
61
+ required :replaces_adjustment_id, String, nil?: true
62
+
63
+ # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, maximum_amount:, reason:, replaces_adjustment_id:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::MonetaryMaximumAdjustment} for more details.
59
66
  #
@@ -72,6 +79,8 @@ module Orb
72
79
  # @param maximum_amount [String] The maximum amount to charge in a given billing period for the prices this adjus
73
80
  #
74
81
  # @param reason [String, nil] The reason for the adjustment.
82
+ #
83
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
75
84
 
76
85
  # @see Orb::Models::MonetaryMaximumAdjustment#adjustment_type
77
86
  module AdjustmentType
@@ -59,7 +59,14 @@ module Orb
59
59
  # @return [String, nil]
60
60
  required :reason, String, nil?: true
61
61
 
62
- # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, item_id:, minimum_amount:, reason:)
62
+ # @!attribute replaces_adjustment_id
63
+ # The adjustment id this adjustment replaces. This adjustment will take the place
64
+ # of the replaced adjustment in plan version migrations.
65
+ #
66
+ # @return [String, nil]
67
+ required :replaces_adjustment_id, String, nil?: true
68
+
69
+ # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, item_id:, minimum_amount:, reason:, replaces_adjustment_id:)
63
70
  # Some parameter documentations has been truncated, see
64
71
  # {Orb::Models::MonetaryMinimumAdjustment} for more details.
65
72
  #
@@ -80,6 +87,8 @@ module Orb
80
87
  # @param minimum_amount [String] The minimum amount to charge in a given billing period for the prices this adjus
81
88
  #
82
89
  # @param reason [String, nil] The reason for the adjustment.
90
+ #
91
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
83
92
 
84
93
  # @see Orb::Models::MonetaryMinimumAdjustment#adjustment_type
85
94
  module AdjustmentType
@@ -53,7 +53,14 @@ module Orb
53
53
  # @return [String, nil]
54
54
  required :reason, String, nil?: true
55
55
 
56
- # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, percentage_discount:, reason:)
56
+ # @!attribute replaces_adjustment_id
57
+ # The adjustment id this adjustment replaces. This adjustment will take the place
58
+ # of the replaced adjustment in plan version migrations.
59
+ #
60
+ # @return [String, nil]
61
+ required :replaces_adjustment_id, String, nil?: true
62
+
63
+ # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, percentage_discount:, reason:, replaces_adjustment_id:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::MonetaryPercentageDiscountAdjustment} for more details.
59
66
  #
@@ -72,6 +79,8 @@ module Orb
72
79
  # @param percentage_discount [Float] The percentage (as a value between 0 and 1) by which to discount the price inter
73
80
  #
74
81
  # @param reason [String, nil] The reason for the adjustment.
82
+ #
83
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
75
84
 
76
85
  # @see Orb::Models::MonetaryPercentageDiscountAdjustment#adjustment_type
77
86
  module AdjustmentType
@@ -46,6 +46,13 @@ module Orb
46
46
  # @return [String, nil]
47
47
  required :reason, String, nil?: true
48
48
 
49
+ # @!attribute replaces_adjustment_id
50
+ # The adjustment id this adjustment replaces. This adjustment will take the place
51
+ # of the replaced adjustment in plan version migrations.
52
+ #
53
+ # @return [String, nil]
54
+ required :replaces_adjustment_id, String, nil?: true
55
+
49
56
  # @!attribute usage_discount
50
57
  # The number of usage units by which to discount the price this adjustment applies
51
58
  # to in a given billing period.
@@ -53,7 +60,7 @@ module Orb
53
60
  # @return [Float]
54
61
  required :usage_discount, Float
55
62
 
56
- # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, reason:, usage_discount:)
63
+ # @!method initialize(id:, adjustment_type:, amount:, applies_to_price_ids:, filters:, is_invoice_level:, reason:, replaces_adjustment_id:, usage_discount:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::MonetaryUsageDiscountAdjustment} for more details.
59
66
  #
@@ -71,6 +78,8 @@ module Orb
71
78
  #
72
79
  # @param reason [String, nil] The reason for the adjustment.
73
80
  #
81
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
82
+ #
74
83
  # @param usage_discount [Float] The number of usage units by which to discount the price this adjustment applies
75
84
 
76
85
  # @see Orb::Models::MonetaryUsageDiscountAdjustment#adjustment_type
@@ -53,7 +53,14 @@ module Orb
53
53
  # @return [String, nil]
54
54
  required :reason, String, nil?: true
55
55
 
56
- # @!method initialize(id:, adjustment_type:, amount_discount:, applies_to_price_ids:, filters:, is_invoice_level:, plan_phase_order:, reason:)
56
+ # @!attribute replaces_adjustment_id
57
+ # The adjustment id this adjustment replaces. This adjustment will take the place
58
+ # of the replaced adjustment in plan version migrations.
59
+ #
60
+ # @return [String, nil]
61
+ required :replaces_adjustment_id, String, nil?: true
62
+
63
+ # @!method initialize(id:, adjustment_type:, amount_discount:, applies_to_price_ids:, filters:, is_invoice_level:, plan_phase_order:, reason:, replaces_adjustment_id:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::PlanPhaseAmountDiscountAdjustment} for more details.
59
66
  #
@@ -72,6 +79,8 @@ module Orb
72
79
  # @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
73
80
  #
74
81
  # @param reason [String, nil] The reason for the adjustment.
82
+ #
83
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
75
84
 
76
85
  # @see Orb::Models::PlanPhaseAmountDiscountAdjustment#adjustment_type
77
86
  module AdjustmentType
@@ -53,7 +53,14 @@ module Orb
53
53
  # @return [String, nil]
54
54
  required :reason, String, nil?: true
55
55
 
56
- # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, maximum_amount:, plan_phase_order:, reason:)
56
+ # @!attribute replaces_adjustment_id
57
+ # The adjustment id this adjustment replaces. This adjustment will take the place
58
+ # of the replaced adjustment in plan version migrations.
59
+ #
60
+ # @return [String, nil]
61
+ required :replaces_adjustment_id, String, nil?: true
62
+
63
+ # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, maximum_amount:, plan_phase_order:, reason:, replaces_adjustment_id:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::PlanPhaseMaximumAdjustment} for more details.
59
66
  #
@@ -72,6 +79,8 @@ module Orb
72
79
  # @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
73
80
  #
74
81
  # @param reason [String, nil] The reason for the adjustment.
82
+ #
83
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
75
84
 
76
85
  # @see Orb::Models::PlanPhaseMaximumAdjustment#adjustment_type
77
86
  module AdjustmentType
@@ -59,7 +59,14 @@ module Orb
59
59
  # @return [String, nil]
60
60
  required :reason, String, nil?: true
61
61
 
62
- # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, item_id:, minimum_amount:, plan_phase_order:, reason:)
62
+ # @!attribute replaces_adjustment_id
63
+ # The adjustment id this adjustment replaces. This adjustment will take the place
64
+ # of the replaced adjustment in plan version migrations.
65
+ #
66
+ # @return [String, nil]
67
+ required :replaces_adjustment_id, String, nil?: true
68
+
69
+ # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, item_id:, minimum_amount:, plan_phase_order:, reason:, replaces_adjustment_id:)
63
70
  # Some parameter documentations has been truncated, see
64
71
  # {Orb::Models::PlanPhaseMinimumAdjustment} for more details.
65
72
  #
@@ -80,6 +87,8 @@ module Orb
80
87
  # @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
81
88
  #
82
89
  # @param reason [String, nil] The reason for the adjustment.
90
+ #
91
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
83
92
 
84
93
  # @see Orb::Models::PlanPhaseMinimumAdjustment#adjustment_type
85
94
  module AdjustmentType
@@ -53,7 +53,14 @@ module Orb
53
53
  # @return [String, nil]
54
54
  required :reason, String, nil?: true
55
55
 
56
- # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, percentage_discount:, plan_phase_order:, reason:)
56
+ # @!attribute replaces_adjustment_id
57
+ # The adjustment id this adjustment replaces. This adjustment will take the place
58
+ # of the replaced adjustment in plan version migrations.
59
+ #
60
+ # @return [String, nil]
61
+ required :replaces_adjustment_id, String, nil?: true
62
+
63
+ # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, percentage_discount:, plan_phase_order:, reason:, replaces_adjustment_id:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::PlanPhasePercentageDiscountAdjustment} for more details.
59
66
  #
@@ -72,6 +79,8 @@ module Orb
72
79
  # @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
73
80
  #
74
81
  # @param reason [String, nil] The reason for the adjustment.
82
+ #
83
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
75
84
 
76
85
  # @see Orb::Models::PlanPhasePercentageDiscountAdjustment#adjustment_type
77
86
  module AdjustmentType
@@ -46,6 +46,13 @@ module Orb
46
46
  # @return [String, nil]
47
47
  required :reason, String, nil?: true
48
48
 
49
+ # @!attribute replaces_adjustment_id
50
+ # The adjustment id this adjustment replaces. This adjustment will take the place
51
+ # of the replaced adjustment in plan version migrations.
52
+ #
53
+ # @return [String, nil]
54
+ required :replaces_adjustment_id, String, nil?: true
55
+
49
56
  # @!attribute usage_discount
50
57
  # The number of usage units by which to discount the price this adjustment applies
51
58
  # to in a given billing period.
@@ -53,7 +60,7 @@ module Orb
53
60
  # @return [Float]
54
61
  required :usage_discount, Float
55
62
 
56
- # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, plan_phase_order:, reason:, usage_discount:)
63
+ # @!method initialize(id:, adjustment_type:, applies_to_price_ids:, filters:, is_invoice_level:, plan_phase_order:, reason:, replaces_adjustment_id:, usage_discount:)
57
64
  # Some parameter documentations has been truncated, see
58
65
  # {Orb::Models::PlanPhaseUsageDiscountAdjustment} for more details.
59
66
  #
@@ -71,6 +78,8 @@ module Orb
71
78
  #
72
79
  # @param reason [String, nil] The reason for the adjustment.
73
80
  #
81
+ # @param replaces_adjustment_id [String, nil] The adjustment id this adjustment replaces. This adjustment will take the place
82
+ #
74
83
  # @param usage_discount [Float] The number of usage units by which to discount the price this adjustment applies
75
84
 
76
85
  # @see Orb::Models::PlanPhaseUsageDiscountAdjustment#adjustment_type