orb-billing 1.52.0 → 1.54.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 +17 -0
- data/README.md +1 -1
- data/lib/orb/models/billable_metric_edited_webhook_event.rb +33 -1
- data/lib/orb/models/metric_create_params.rb +24 -1
- data/lib/orb/models/metric_list_params.rb +1 -1
- data/lib/orb/models/metric_publish_params.rb +20 -0
- data/lib/orb/models/metric_update_params.rb +20 -1
- data/lib/orb/models/plan.rb +9 -1
- data/lib/orb/models/plan_version_phase.rb +9 -1
- data/lib/orb/models/plans/migration_cancel_response.rb +19 -1
- data/lib/orb/models/plans/migration_list_response.rb +19 -1
- data/lib/orb/models/plans/migration_retrieve_response.rb +19 -1
- data/lib/orb/models/subscription_create_params.rb +18 -2
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +18 -2
- data/lib/orb/models/webhooks/billable_metric_edited_standard_webhook_event.rb +35 -1
- data/lib/orb/models.rb +2 -0
- data/lib/orb/resources/metrics.rb +34 -2
- data/lib/orb/version.rb +1 -1
- data/lib/orb.rb +1 -0
- data/rbi/orb/models/billable_metric_edited_webhook_event.rbi +76 -3
- data/rbi/orb/models/metric_create_params.rbi +37 -0
- data/rbi/orb/models/metric_list_params.rbi +1 -1
- data/rbi/orb/models/metric_publish_params.rbi +33 -0
- data/rbi/orb/models/metric_update_params.rbi +22 -0
- data/rbi/orb/models/plan.rbi +11 -3
- data/rbi/orb/models/plan_version_phase.rbi +11 -3
- data/rbi/orb/models/plans/migration_cancel_response.rbi +20 -0
- data/rbi/orb/models/plans/migration_list_response.rbi +20 -0
- data/rbi/orb/models/plans/migration_retrieve_response.rbi +20 -0
- data/rbi/orb/models/subscription_create_params.rbi +16 -0
- data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +16 -0
- data/rbi/orb/models/webhooks/billable_metric_edited_standard_webhook_event.rbi +76 -3
- data/rbi/orb/models.rbi +2 -0
- data/rbi/orb/resources/metrics.rbi +31 -0
- data/sig/orb/models/billable_metric_edited_webhook_event.rbs +30 -3
- data/sig/orb/models/metric_create_params.rbs +21 -1
- data/sig/orb/models/metric_list_params.rbs +2 -2
- data/sig/orb/models/metric_publish_params.rbs +23 -0
- data/sig/orb/models/metric_update_params.rbs +11 -1
- data/sig/orb/models/plan.rbs +8 -3
- data/sig/orb/models/plan_version_phase.rbs +8 -3
- data/sig/orb/models/plans/migration_cancel_response.rbs +10 -0
- data/sig/orb/models/plans/migration_list_response.rbs +10 -0
- data/sig/orb/models/plans/migration_retrieve_response.rbs +10 -0
- data/sig/orb/models/subscription_create_params.rbs +19 -2
- data/sig/orb/models/subscription_schedule_plan_change_params.rbs +19 -2
- data/sig/orb/models/webhooks/billable_metric_edited_standard_webhook_event.rbs +30 -3
- data/sig/orb/models.rbs +2 -0
- data/sig/orb/resources/metrics.rbs +8 -0
- metadata +5 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 99fdf468dc06b64b4fa219b5c118aece61cb9bf7d16d04815e1b0c230512f0c9
|
|
4
|
+
data.tar.gz: 7f93d9f201c438f84e17c7f0e0f28ca52a0b50392acaea339803c5ebf7088b8a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2594f9dcd46317cd9121047b0b8fd27745ad69db9bee68e4b59b17d28c328414274109b1dd332b52d686289266fb4db6a5e9dbdea812646ffb85de87ddab28a9
|
|
7
|
+
data.tar.gz: a8758963dd4525858f1b8227e60c4b89286b9016ba761d99b4b90eeb2a899642549977be871c0cd70aef87193eeacafd522e4c935c5eff5a27b396dd8dea381a
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.54.0](https://github.com/orbcorp/orb-ruby/compare/v1.53.0...v1.54.0) (2026-11-06)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **api:** add plan migration started, completed, and canceled webhooks ([9616c3b](https://github.com/orbcorp/orb-ruby/commit/9616c3be737b19de232b98199cba7f4c8a02d893))
|
|
9
|
+
* **api:** add started_at and ended_at to plan migration resource ([9616c3b](https://github.com/orbcorp/orb-ruby/commit/9616c3be737b19de232b98199cba7f4c8a02d893))
|
|
10
|
+
* **api:** api update ([9616c3b](https://github.com/orbcorp/orb-ruby/commit/9616c3be737b19de232b98199cba7f4c8a02d893))
|
|
11
|
+
|
|
12
|
+
## [1.53.0](https://github.com/orbcorp/orb-ruby/compare/v1.52.0...v1.53.0) (2026-11-04)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Features
|
|
16
|
+
|
|
17
|
+
* **api:** add price_ids to plan phases in plan responses ([31c53a7](https://github.com/orbcorp/orb-ruby/commit/31c53a746d3a58bf1c5e2af1a17e0ec609d2632b))
|
|
18
|
+
* **api:** support draft billable metrics with SQL/item edits and publish ([d101f75](https://github.com/orbcorp/orb-ruby/commit/d101f751084628d14727d0be016bec21f21b4853))
|
|
19
|
+
|
|
3
20
|
## [1.52.0](https://github.com/orbcorp/orb-ruby/compare/v1.51.0...v1.52.0) (2026-10-31)
|
|
4
21
|
|
|
5
22
|
|
data/README.md
CHANGED
|
@@ -92,6 +92,11 @@ module Orb
|
|
|
92
92
|
# @return [String, nil]
|
|
93
93
|
optional :description, String, nil?: true
|
|
94
94
|
|
|
95
|
+
# @!attribute item_id
|
|
96
|
+
#
|
|
97
|
+
# @return [String, nil]
|
|
98
|
+
optional :item_id, String, nil?: true
|
|
99
|
+
|
|
95
100
|
# @!attribute metadata
|
|
96
101
|
#
|
|
97
102
|
# @return [Hash{Symbol=>String}, nil]
|
|
@@ -102,12 +107,39 @@ module Orb
|
|
|
102
107
|
# @return [String, nil]
|
|
103
108
|
optional :name, String, nil?: true
|
|
104
109
|
|
|
105
|
-
# @!
|
|
110
|
+
# @!attribute sql
|
|
111
|
+
#
|
|
112
|
+
# @return [String, nil]
|
|
113
|
+
optional :sql, String, nil?: true
|
|
114
|
+
|
|
115
|
+
# @!attribute status
|
|
116
|
+
#
|
|
117
|
+
# @return [Symbol, Orb::Models::BillableMetricEditedWebhookEvent::Properties::PreviousAttributes::Status, nil]
|
|
118
|
+
optional :status,
|
|
119
|
+
enum: -> { Orb::BillableMetricEditedWebhookEvent::Properties::PreviousAttributes::Status },
|
|
120
|
+
nil?: true
|
|
121
|
+
|
|
122
|
+
# @!method initialize(description: nil, item_id: nil, metadata: nil, name: nil, sql: nil, status: nil)
|
|
106
123
|
# metadata values are non-null on the wire, as on the price event.
|
|
107
124
|
#
|
|
108
125
|
# @param description [String, nil]
|
|
126
|
+
# @param item_id [String, nil]
|
|
109
127
|
# @param metadata [Hash{Symbol=>String}, nil]
|
|
110
128
|
# @param name [String, nil]
|
|
129
|
+
# @param sql [String, nil]
|
|
130
|
+
# @param status [Symbol, Orb::Models::BillableMetricEditedWebhookEvent::Properties::PreviousAttributes::Status, nil]
|
|
131
|
+
|
|
132
|
+
# @see Orb::Models::BillableMetricEditedWebhookEvent::Properties::PreviousAttributes#status
|
|
133
|
+
module Status
|
|
134
|
+
extend Orb::Internal::Type::Enum
|
|
135
|
+
|
|
136
|
+
ACTIVE = :active
|
|
137
|
+
ARCHIVED = :archived
|
|
138
|
+
DRAFT = :draft
|
|
139
|
+
|
|
140
|
+
# @!method self.values
|
|
141
|
+
# @return [Array<Symbol>]
|
|
142
|
+
end
|
|
111
143
|
end
|
|
112
144
|
end
|
|
113
145
|
|
|
@@ -39,7 +39,15 @@ module Orb
|
|
|
39
39
|
# @return [Hash{Symbol=>String, nil}, nil]
|
|
40
40
|
optional :metadata, Orb::Internal::Type::HashOf[String, nil?: true], nil?: true
|
|
41
41
|
|
|
42
|
-
# @!
|
|
42
|
+
# @!attribute status
|
|
43
|
+
# The status of the metric to create (either active or draft). If not specified,
|
|
44
|
+
# this defaults to active. A draft metric's `sql` and `item_id` can be changed
|
|
45
|
+
# until it's published.
|
|
46
|
+
#
|
|
47
|
+
# @return [Symbol, Orb::Models::MetricCreateParams::Status, nil]
|
|
48
|
+
optional :status, enum: -> { Orb::MetricCreateParams::Status }
|
|
49
|
+
|
|
50
|
+
# @!method initialize(description:, item_id:, name:, sql:, metadata: nil, status: nil, request_options: {})
|
|
43
51
|
# Some parameter documentations has been truncated, see
|
|
44
52
|
# {Orb::Models::MetricCreateParams} for more details.
|
|
45
53
|
#
|
|
@@ -53,7 +61,22 @@ module Orb
|
|
|
53
61
|
#
|
|
54
62
|
# @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
|
|
55
63
|
#
|
|
64
|
+
# @param status [Symbol, Orb::Models::MetricCreateParams::Status] The status of the metric to create (either active or draft). If not specified, t
|
|
65
|
+
#
|
|
56
66
|
# @param request_options [Orb::RequestOptions, Hash{Symbol=>Object}]
|
|
67
|
+
|
|
68
|
+
# The status of the metric to create (either active or draft). If not specified,
|
|
69
|
+
# this defaults to active. A draft metric's `sql` and `item_id` can be changed
|
|
70
|
+
# until it's published.
|
|
71
|
+
module Status
|
|
72
|
+
extend Orb::Internal::Type::Enum
|
|
73
|
+
|
|
74
|
+
ACTIVE = :active
|
|
75
|
+
DRAFT = :draft
|
|
76
|
+
|
|
77
|
+
# @!method self.values
|
|
78
|
+
# @return [Array<Symbol>]
|
|
79
|
+
end
|
|
57
80
|
end
|
|
58
81
|
end
|
|
59
82
|
end
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Orb
|
|
4
|
+
module Models
|
|
5
|
+
# @see Orb::Resources::Metrics#publish
|
|
6
|
+
class MetricPublishParams < Orb::Internal::Type::BaseModel
|
|
7
|
+
extend Orb::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Orb::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
# @!attribute metric_id
|
|
11
|
+
#
|
|
12
|
+
# @return [String]
|
|
13
|
+
required :metric_id, String
|
|
14
|
+
|
|
15
|
+
# @!method initialize(metric_id:, request_options: {})
|
|
16
|
+
# @param metric_id [String]
|
|
17
|
+
# @param request_options [Orb::RequestOptions, Hash{Symbol=>Object}]
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
@@ -18,6 +18,13 @@ module Orb
|
|
|
18
18
|
# @return [String, nil]
|
|
19
19
|
optional :description, String, nil?: true
|
|
20
20
|
|
|
21
|
+
# @!attribute item_id
|
|
22
|
+
# The id of the item to associate the metric with. Can only be changed while the
|
|
23
|
+
# metric is in `draft` status.
|
|
24
|
+
#
|
|
25
|
+
# @return [String, nil]
|
|
26
|
+
optional :item_id, String, nil?: true
|
|
27
|
+
|
|
21
28
|
# @!attribute metadata
|
|
22
29
|
# User-specified key/value pairs for the resource. Individual keys can be removed
|
|
23
30
|
# by setting the value to `null`, and the entire metadata mapping can be cleared
|
|
@@ -32,7 +39,15 @@ module Orb
|
|
|
32
39
|
# @return [String, nil]
|
|
33
40
|
optional :name, String, nil?: true
|
|
34
41
|
|
|
35
|
-
# @!
|
|
42
|
+
# @!attribute sql
|
|
43
|
+
# A new sql string defining the metric. Can only be changed while the metric is in
|
|
44
|
+
# `draft` status and no price uses it. If the metric has parameters, the new sql
|
|
45
|
+
# must use the same ones.
|
|
46
|
+
#
|
|
47
|
+
# @return [String, nil]
|
|
48
|
+
optional :sql, String, nil?: true
|
|
49
|
+
|
|
50
|
+
# @!method initialize(metric_id:, description: nil, item_id: nil, metadata: nil, name: nil, sql: nil, request_options: {})
|
|
36
51
|
# Some parameter documentations has been truncated, see
|
|
37
52
|
# {Orb::Models::MetricUpdateParams} for more details.
|
|
38
53
|
#
|
|
@@ -40,10 +55,14 @@ module Orb
|
|
|
40
55
|
#
|
|
41
56
|
# @param description [String, nil] A description of the metric.
|
|
42
57
|
#
|
|
58
|
+
# @param item_id [String, nil] The id of the item to associate the metric with. Can only be changed while the m
|
|
59
|
+
#
|
|
43
60
|
# @param metadata [Hash{Symbol=>String, nil}, nil] User-specified key/value pairs for the resource. Individual keys can be removed
|
|
44
61
|
#
|
|
45
62
|
# @param name [String, nil] The name of the metric.
|
|
46
63
|
#
|
|
64
|
+
# @param sql [String, nil] A new sql string defining the metric. Can only be changed while the metric is in
|
|
65
|
+
#
|
|
47
66
|
# @param request_options [Orb::RequestOptions, Hash{Symbol=>Object}]
|
|
48
67
|
end
|
|
49
68
|
end
|
data/lib/orb/models/plan.rb
CHANGED
|
@@ -512,7 +512,13 @@ module Orb
|
|
|
512
512
|
# @return [Integer]
|
|
513
513
|
required :order, Integer
|
|
514
514
|
|
|
515
|
-
# @!
|
|
515
|
+
# @!attribute price_ids
|
|
516
|
+
# The IDs of the prices active in this phase.
|
|
517
|
+
#
|
|
518
|
+
# @return [Array<String>]
|
|
519
|
+
required :price_ids, Orb::Internal::Type::ArrayOf[String]
|
|
520
|
+
|
|
521
|
+
# @!method initialize(id:, description:, discount:, duration:, duration_unit:, maximum:, maximum_amount:, minimum:, minimum_amount:, name:, order:, price_ids:)
|
|
516
522
|
# Some parameter documentations has been truncated, see
|
|
517
523
|
# {Orb::Models::Plan::PlanPhase} for more details.
|
|
518
524
|
#
|
|
@@ -537,6 +543,8 @@ module Orb
|
|
|
537
543
|
# @param name [String]
|
|
538
544
|
#
|
|
539
545
|
# @param order [Integer] Determines the ordering of the phase in a plan's lifecycle. 1 = first phase.
|
|
546
|
+
#
|
|
547
|
+
# @param price_ids [Array<String>] The IDs of the prices active in this phase.
|
|
540
548
|
|
|
541
549
|
# @see Orb::Models::Plan::PlanPhase#duration_unit
|
|
542
550
|
module DurationUnit
|
|
@@ -36,7 +36,13 @@ module Orb
|
|
|
36
36
|
# @return [Integer]
|
|
37
37
|
required :order, Integer
|
|
38
38
|
|
|
39
|
-
# @!
|
|
39
|
+
# @!attribute price_ids
|
|
40
|
+
# The IDs of the prices active in this phase.
|
|
41
|
+
#
|
|
42
|
+
# @return [Array<String>]
|
|
43
|
+
required :price_ids, Orb::Internal::Type::ArrayOf[String]
|
|
44
|
+
|
|
45
|
+
# @!method initialize(id:, description:, duration:, duration_unit:, name:, order:, price_ids:)
|
|
40
46
|
# Some parameter documentations has been truncated, see
|
|
41
47
|
# {Orb::Models::PlanVersionPhase} for more details.
|
|
42
48
|
#
|
|
@@ -51,6 +57,8 @@ module Orb
|
|
|
51
57
|
# @param name [String]
|
|
52
58
|
#
|
|
53
59
|
# @param order [Integer] Determines the ordering of the phase in a plan's lifecycle. 1 = first phase.
|
|
60
|
+
#
|
|
61
|
+
# @param price_ids [Array<String>] The IDs of the prices active in this phase.
|
|
54
62
|
|
|
55
63
|
# @see Orb::Models::PlanVersionPhase#duration_unit
|
|
56
64
|
module DurationUnit
|
|
@@ -21,12 +21,26 @@ module Orb
|
|
|
21
21
|
union: -> { Orb::Models::Plans::MigrationCancelResponse::EffectiveTime },
|
|
22
22
|
nil?: true
|
|
23
23
|
|
|
24
|
+
# @!attribute ended_at
|
|
25
|
+
# When the migration completed or was canceled, or null if it is still in
|
|
26
|
+
# progress.
|
|
27
|
+
#
|
|
28
|
+
# @return [Time, nil]
|
|
29
|
+
required :ended_at, Time, nil?: true
|
|
30
|
+
|
|
24
31
|
# @!attribute plan_id
|
|
25
32
|
# The ID of the plan being migrated.
|
|
26
33
|
#
|
|
27
34
|
# @return [String]
|
|
28
35
|
required :plan_id, String
|
|
29
36
|
|
|
37
|
+
# @!attribute started_at
|
|
38
|
+
# When Orb began migrating the plan's subscriptions. Null if the migration has not
|
|
39
|
+
# begun, or was canceled before it began.
|
|
40
|
+
#
|
|
41
|
+
# @return [Time, nil]
|
|
42
|
+
required :started_at, Time, nil?: true
|
|
43
|
+
|
|
30
44
|
# @!attribute status
|
|
31
45
|
# Current status of the migration: 'not_started', 'in_progress', 'completed',
|
|
32
46
|
# 'action_needed', or 'canceled'.
|
|
@@ -34,7 +48,7 @@ module Orb
|
|
|
34
48
|
# @return [Symbol, Orb::Models::Plans::MigrationCancelResponse::Status]
|
|
35
49
|
required :status, enum: -> { Orb::Models::Plans::MigrationCancelResponse::Status }
|
|
36
50
|
|
|
37
|
-
# @!method initialize(id:, effective_time:, plan_id:, status:)
|
|
51
|
+
# @!method initialize(id:, effective_time:, ended_at:, plan_id:, started_at:, status:)
|
|
38
52
|
# Some parameter documentations has been truncated, see
|
|
39
53
|
# {Orb::Models::Plans::MigrationCancelResponse} for more details.
|
|
40
54
|
#
|
|
@@ -42,8 +56,12 @@ module Orb
|
|
|
42
56
|
#
|
|
43
57
|
# @param effective_time [Date, Time, Symbol, Orb::Models::Plans::MigrationCancelResponse::EffectiveTime, nil] When the migration takes effect. Can be a specific date/time, 'end_of_term' when
|
|
44
58
|
#
|
|
59
|
+
# @param ended_at [Time, nil] When the migration completed or was canceled, or null if it is still in progress
|
|
60
|
+
#
|
|
45
61
|
# @param plan_id [String] The ID of the plan being migrated.
|
|
46
62
|
#
|
|
63
|
+
# @param started_at [Time, nil] When Orb began migrating the plan's subscriptions. Null if the migration has not
|
|
64
|
+
#
|
|
47
65
|
# @param status [Symbol, Orb::Models::Plans::MigrationCancelResponse::Status] Current status of the migration: 'not_started', 'in_progress', 'completed', 'act
|
|
48
66
|
|
|
49
67
|
# When the migration takes effect. Can be a specific date/time, 'end_of_term' when
|
|
@@ -21,12 +21,26 @@ module Orb
|
|
|
21
21
|
union: -> { Orb::Models::Plans::MigrationListResponse::EffectiveTime },
|
|
22
22
|
nil?: true
|
|
23
23
|
|
|
24
|
+
# @!attribute ended_at
|
|
25
|
+
# When the migration completed or was canceled, or null if it is still in
|
|
26
|
+
# progress.
|
|
27
|
+
#
|
|
28
|
+
# @return [Time, nil]
|
|
29
|
+
required :ended_at, Time, nil?: true
|
|
30
|
+
|
|
24
31
|
# @!attribute plan_id
|
|
25
32
|
# The ID of the plan being migrated.
|
|
26
33
|
#
|
|
27
34
|
# @return [String]
|
|
28
35
|
required :plan_id, String
|
|
29
36
|
|
|
37
|
+
# @!attribute started_at
|
|
38
|
+
# When Orb began migrating the plan's subscriptions. Null if the migration has not
|
|
39
|
+
# begun, or was canceled before it began.
|
|
40
|
+
#
|
|
41
|
+
# @return [Time, nil]
|
|
42
|
+
required :started_at, Time, nil?: true
|
|
43
|
+
|
|
30
44
|
# @!attribute status
|
|
31
45
|
# Current status of the migration: 'not_started', 'in_progress', 'completed',
|
|
32
46
|
# 'action_needed', or 'canceled'.
|
|
@@ -34,7 +48,7 @@ module Orb
|
|
|
34
48
|
# @return [Symbol, Orb::Models::Plans::MigrationListResponse::Status]
|
|
35
49
|
required :status, enum: -> { Orb::Models::Plans::MigrationListResponse::Status }
|
|
36
50
|
|
|
37
|
-
# @!method initialize(id:, effective_time:, plan_id:, status:)
|
|
51
|
+
# @!method initialize(id:, effective_time:, ended_at:, plan_id:, started_at:, status:)
|
|
38
52
|
# Some parameter documentations has been truncated, see
|
|
39
53
|
# {Orb::Models::Plans::MigrationListResponse} for more details.
|
|
40
54
|
#
|
|
@@ -42,8 +56,12 @@ module Orb
|
|
|
42
56
|
#
|
|
43
57
|
# @param effective_time [Date, Time, Symbol, Orb::Models::Plans::MigrationListResponse::EffectiveTime, nil] When the migration takes effect. Can be a specific date/time, 'end_of_term' when
|
|
44
58
|
#
|
|
59
|
+
# @param ended_at [Time, nil] When the migration completed or was canceled, or null if it is still in progress
|
|
60
|
+
#
|
|
45
61
|
# @param plan_id [String] The ID of the plan being migrated.
|
|
46
62
|
#
|
|
63
|
+
# @param started_at [Time, nil] When Orb began migrating the plan's subscriptions. Null if the migration has not
|
|
64
|
+
#
|
|
47
65
|
# @param status [Symbol, Orb::Models::Plans::MigrationListResponse::Status] Current status of the migration: 'not_started', 'in_progress', 'completed', 'act
|
|
48
66
|
|
|
49
67
|
# When the migration takes effect. Can be a specific date/time, 'end_of_term' when
|
|
@@ -21,12 +21,26 @@ module Orb
|
|
|
21
21
|
union: -> { Orb::Models::Plans::MigrationRetrieveResponse::EffectiveTime },
|
|
22
22
|
nil?: true
|
|
23
23
|
|
|
24
|
+
# @!attribute ended_at
|
|
25
|
+
# When the migration completed or was canceled, or null if it is still in
|
|
26
|
+
# progress.
|
|
27
|
+
#
|
|
28
|
+
# @return [Time, nil]
|
|
29
|
+
required :ended_at, Time, nil?: true
|
|
30
|
+
|
|
24
31
|
# @!attribute plan_id
|
|
25
32
|
# The ID of the plan being migrated.
|
|
26
33
|
#
|
|
27
34
|
# @return [String]
|
|
28
35
|
required :plan_id, String
|
|
29
36
|
|
|
37
|
+
# @!attribute started_at
|
|
38
|
+
# When Orb began migrating the plan's subscriptions. Null if the migration has not
|
|
39
|
+
# begun, or was canceled before it began.
|
|
40
|
+
#
|
|
41
|
+
# @return [Time, nil]
|
|
42
|
+
required :started_at, Time, nil?: true
|
|
43
|
+
|
|
30
44
|
# @!attribute status
|
|
31
45
|
# Current status of the migration: 'not_started', 'in_progress', 'completed',
|
|
32
46
|
# 'action_needed', or 'canceled'.
|
|
@@ -34,7 +48,7 @@ module Orb
|
|
|
34
48
|
# @return [Symbol, Orb::Models::Plans::MigrationRetrieveResponse::Status]
|
|
35
49
|
required :status, enum: -> { Orb::Models::Plans::MigrationRetrieveResponse::Status }
|
|
36
50
|
|
|
37
|
-
# @!method initialize(id:, effective_time:, plan_id:, status:)
|
|
51
|
+
# @!method initialize(id:, effective_time:, ended_at:, plan_id:, started_at:, status:)
|
|
38
52
|
# Some parameter documentations has been truncated, see
|
|
39
53
|
# {Orb::Models::Plans::MigrationRetrieveResponse} for more details.
|
|
40
54
|
#
|
|
@@ -42,8 +56,12 @@ module Orb
|
|
|
42
56
|
#
|
|
43
57
|
# @param effective_time [Date, Time, Symbol, Orb::Models::Plans::MigrationRetrieveResponse::EffectiveTime, nil] When the migration takes effect. Can be a specific date/time, 'end_of_term' when
|
|
44
58
|
#
|
|
59
|
+
# @param ended_at [Time, nil] When the migration completed or was canceled, or null if it is still in progress
|
|
60
|
+
#
|
|
45
61
|
# @param plan_id [String] The ID of the plan being migrated.
|
|
46
62
|
#
|
|
63
|
+
# @param started_at [Time, nil] When Orb began migrating the plan's subscriptions. Null if the migration has not
|
|
64
|
+
#
|
|
47
65
|
# @param status [Symbol, Orb::Models::Plans::MigrationRetrieveResponse::Status] Current status of the migration: 'not_started', 'in_progress', 'completed', 'act
|
|
48
66
|
|
|
49
67
|
# When the migration takes effect. Can be a specific date/time, 'end_of_term' when
|
|
@@ -3654,15 +3654,23 @@ module Orb
|
|
|
3654
3654
|
# @return [String, nil]
|
|
3655
3655
|
optional :external_price_id, String, nil?: true
|
|
3656
3656
|
|
|
3657
|
+
# @!attribute plan_phase_order
|
|
3658
|
+
# The phase to remove this price from.
|
|
3659
|
+
#
|
|
3660
|
+
# @return [Integer, nil]
|
|
3661
|
+
optional :plan_phase_order, Integer, nil?: true
|
|
3662
|
+
|
|
3657
3663
|
# @!attribute price_id
|
|
3658
3664
|
# The id of the price to remove on the subscription.
|
|
3659
3665
|
#
|
|
3660
3666
|
# @return [String, nil]
|
|
3661
3667
|
optional :price_id, String, nil?: true
|
|
3662
3668
|
|
|
3663
|
-
# @!method initialize(external_price_id: nil, price_id: nil)
|
|
3669
|
+
# @!method initialize(external_price_id: nil, plan_phase_order: nil, price_id: nil)
|
|
3664
3670
|
# @param external_price_id [String, nil] The external price id of the price to remove on the subscription.
|
|
3665
3671
|
#
|
|
3672
|
+
# @param plan_phase_order [Integer, nil] The phase to remove this price from.
|
|
3673
|
+
#
|
|
3666
3674
|
# @param price_id [String, nil] The id of the price to remove on the subscription.
|
|
3667
3675
|
end
|
|
3668
3676
|
|
|
@@ -3975,6 +3983,12 @@ module Orb
|
|
|
3975
3983
|
# @return [String, nil]
|
|
3976
3984
|
optional :minimum_amount, String, nil?: true
|
|
3977
3985
|
|
|
3986
|
+
# @!attribute plan_phase_order
|
|
3987
|
+
# The phase to replace this price in.
|
|
3988
|
+
#
|
|
3989
|
+
# @return [Integer, nil]
|
|
3990
|
+
optional :plan_phase_order, Integer, nil?: true
|
|
3991
|
+
|
|
3978
3992
|
# @!attribute price
|
|
3979
3993
|
# New subscription price request body params.
|
|
3980
3994
|
#
|
|
@@ -3987,7 +4001,7 @@ module Orb
|
|
|
3987
4001
|
# @return [String, nil]
|
|
3988
4002
|
optional :price_id, String, nil?: true
|
|
3989
4003
|
|
|
3990
|
-
# @!method initialize(replaces_price_id:, allocation_price: nil, discounts: nil, external_price_id: nil, fixed_price_quantity: nil, maximum_amount: nil, metric_parameter_overrides: nil, minimum_amount: nil, price: nil, price_id: nil)
|
|
4004
|
+
# @!method initialize(replaces_price_id:, allocation_price: nil, discounts: nil, external_price_id: nil, fixed_price_quantity: nil, maximum_amount: nil, metric_parameter_overrides: nil, minimum_amount: nil, plan_phase_order: nil, price: nil, price_id: nil)
|
|
3991
4005
|
# Some parameter documentations has been truncated, see
|
|
3992
4006
|
# {Orb::Models::SubscriptionCreateParams::ReplacePrice} for more details.
|
|
3993
4007
|
#
|
|
@@ -4007,6 +4021,8 @@ module Orb
|
|
|
4007
4021
|
#
|
|
4008
4022
|
# @param minimum_amount [String, nil] [DEPRECATED] Use add_adjustments instead. The subscription's minimum amount for
|
|
4009
4023
|
#
|
|
4024
|
+
# @param plan_phase_order [Integer, nil] The phase to replace this price in.
|
|
4025
|
+
#
|
|
4010
4026
|
# @param price [Orb::Models::NewSubscriptionUnitPrice, Orb::Models::NewSubscriptionTieredPrice, Orb::Models::NewSubscriptionBulkPrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewSubscriptionPackagePrice, Orb::Models::NewSubscriptionMatrixPrice, Orb::Models::NewSubscriptionThresholdTotalAmountPrice, Orb::Models::NewSubscriptionTieredPackagePrice, Orb::Models::NewSubscriptionTieredWithMinimumPrice, Orb::Models::NewSubscriptionGroupedTieredPrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::GroupedTieredMatrix, Orb::Models::NewSubscriptionTieredPackageWithMinimumPrice, Orb::Models::NewSubscriptionPackageWithAllocationPrice, Orb::Models::NewSubscriptionUnitWithPercentPrice, Orb::Models::NewSubscriptionMatrixWithAllocationPrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::TieredMatrixWithAllocation, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::MatrixWithThresholdDiscounts, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewSubscriptionUnitWithProrationPrice, Orb::Models::NewSubscriptionGroupedAllocationPrice, Orb::Models::NewSubscriptionBulkWithProrationPrice, Orb::Models::NewSubscriptionGroupedWithProratedMinimumPrice, Orb::Models::NewSubscriptionGroupedWithMeteredMinimumPrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewSubscriptionMatrixWithDisplayNamePrice, Orb::Models::NewSubscriptionGroupedTieredPackagePrice, Orb::Models::NewSubscriptionMaxGroupTieredPackagePrice, Orb::Models::NewSubscriptionScalableMatrixWithUnitPricingPrice, Orb::Models::NewSubscriptionScalableMatrixWithTieredPricingPrice, Orb::Models::NewSubscriptionCumulativeGroupedBulkPrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::DailyCreditAllowance, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::MeteredAllowance, Orb::Models::NewSubscriptionMinimumCompositePrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::Percent, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::EventOutput, nil] New subscription price request body params.
|
|
4011
4027
|
#
|
|
4012
4028
|
# @param price_id [String, nil] The id of the price to add to the subscription.
|
|
@@ -3645,15 +3645,23 @@ module Orb
|
|
|
3645
3645
|
# @return [String, nil]
|
|
3646
3646
|
optional :external_price_id, String, nil?: true
|
|
3647
3647
|
|
|
3648
|
+
# @!attribute plan_phase_order
|
|
3649
|
+
# The phase to remove this price from.
|
|
3650
|
+
#
|
|
3651
|
+
# @return [Integer, nil]
|
|
3652
|
+
optional :plan_phase_order, Integer, nil?: true
|
|
3653
|
+
|
|
3648
3654
|
# @!attribute price_id
|
|
3649
3655
|
# The id of the price to remove on the subscription.
|
|
3650
3656
|
#
|
|
3651
3657
|
# @return [String, nil]
|
|
3652
3658
|
optional :price_id, String, nil?: true
|
|
3653
3659
|
|
|
3654
|
-
# @!method initialize(external_price_id: nil, price_id: nil)
|
|
3660
|
+
# @!method initialize(external_price_id: nil, plan_phase_order: nil, price_id: nil)
|
|
3655
3661
|
# @param external_price_id [String, nil] The external price id of the price to remove on the subscription.
|
|
3656
3662
|
#
|
|
3663
|
+
# @param plan_phase_order [Integer, nil] The phase to remove this price from.
|
|
3664
|
+
#
|
|
3657
3665
|
# @param price_id [String, nil] The id of the price to remove on the subscription.
|
|
3658
3666
|
end
|
|
3659
3667
|
|
|
@@ -3967,6 +3975,12 @@ module Orb
|
|
|
3967
3975
|
# @return [String, nil]
|
|
3968
3976
|
optional :minimum_amount, String, nil?: true
|
|
3969
3977
|
|
|
3978
|
+
# @!attribute plan_phase_order
|
|
3979
|
+
# The phase to replace this price in.
|
|
3980
|
+
#
|
|
3981
|
+
# @return [Integer, nil]
|
|
3982
|
+
optional :plan_phase_order, Integer, nil?: true
|
|
3983
|
+
|
|
3970
3984
|
# @!attribute price
|
|
3971
3985
|
# New subscription price request body params.
|
|
3972
3986
|
#
|
|
@@ -3983,7 +3997,7 @@ module Orb
|
|
|
3983
3997
|
# @return [String, nil]
|
|
3984
3998
|
optional :price_id, String, nil?: true
|
|
3985
3999
|
|
|
3986
|
-
# @!method initialize(replaces_price_id:, allocation_price: nil, discounts: nil, external_price_id: nil, fixed_price_quantity: nil, maximum_amount: nil, metric_parameter_overrides: nil, minimum_amount: nil, price: nil, price_id: nil)
|
|
4000
|
+
# @!method initialize(replaces_price_id:, allocation_price: nil, discounts: nil, external_price_id: nil, fixed_price_quantity: nil, maximum_amount: nil, metric_parameter_overrides: nil, minimum_amount: nil, plan_phase_order: nil, price: nil, price_id: nil)
|
|
3987
4001
|
# Some parameter documentations has been truncated, see
|
|
3988
4002
|
# {Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice} for more
|
|
3989
4003
|
# details.
|
|
@@ -4004,6 +4018,8 @@ module Orb
|
|
|
4004
4018
|
#
|
|
4005
4019
|
# @param minimum_amount [String, nil] [DEPRECATED] Use add_adjustments instead. The subscription's minimum amount for
|
|
4006
4020
|
#
|
|
4021
|
+
# @param plan_phase_order [Integer, nil] The phase to replace this price in.
|
|
4022
|
+
#
|
|
4007
4023
|
# @param price [Orb::Models::NewSubscriptionUnitPrice, Orb::Models::NewSubscriptionTieredPrice, Orb::Models::NewSubscriptionBulkPrice, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::BulkWithFilters, Orb::Models::NewSubscriptionPackagePrice, Orb::Models::NewSubscriptionMatrixPrice, Orb::Models::NewSubscriptionThresholdTotalAmountPrice, Orb::Models::NewSubscriptionTieredPackagePrice, Orb::Models::NewSubscriptionTieredWithMinimumPrice, Orb::Models::NewSubscriptionGroupedTieredPrice, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::GroupedTieredMatrix, Orb::Models::NewSubscriptionTieredPackageWithMinimumPrice, Orb::Models::NewSubscriptionPackageWithAllocationPrice, Orb::Models::NewSubscriptionUnitWithPercentPrice, Orb::Models::NewSubscriptionMatrixWithAllocationPrice, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::TieredMatrixWithAllocation, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::MatrixWithThresholdDiscounts, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::TieredWithProration, Orb::Models::NewSubscriptionUnitWithProrationPrice, Orb::Models::NewSubscriptionGroupedAllocationPrice, Orb::Models::NewSubscriptionBulkWithProrationPrice, Orb::Models::NewSubscriptionGroupedWithProratedMinimumPrice, Orb::Models::NewSubscriptionGroupedWithMeteredMinimumPrice, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::GroupedWithMinMaxThresholds, Orb::Models::NewSubscriptionMatrixWithDisplayNamePrice, Orb::Models::NewSubscriptionGroupedTieredPackagePrice, Orb::Models::NewSubscriptionMaxGroupTieredPackagePrice, Orb::Models::NewSubscriptionScalableMatrixWithUnitPricingPrice, Orb::Models::NewSubscriptionScalableMatrixWithTieredPricingPrice, Orb::Models::NewSubscriptionCumulativeGroupedBulkPrice, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::CumulativeGroupedAllocation, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::DailyCreditAllowance, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::MeteredAllowance, Orb::Models::NewSubscriptionMinimumCompositePrice, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::Percent, Orb::Models::SubscriptionSchedulePlanChangeParams::ReplacePrice::Price::EventOutput, nil] New subscription price request body params.
|
|
4008
4024
|
#
|
|
4009
4025
|
# @param price_id [String, nil] The id of the price to add to the subscription.
|
|
@@ -95,6 +95,11 @@ module Orb
|
|
|
95
95
|
# @return [String, nil]
|
|
96
96
|
optional :description, String, nil?: true
|
|
97
97
|
|
|
98
|
+
# @!attribute item_id
|
|
99
|
+
#
|
|
100
|
+
# @return [String, nil]
|
|
101
|
+
optional :item_id, String, nil?: true
|
|
102
|
+
|
|
98
103
|
# @!attribute metadata
|
|
99
104
|
#
|
|
100
105
|
# @return [Hash{Symbol=>String}, nil]
|
|
@@ -105,12 +110,41 @@ module Orb
|
|
|
105
110
|
# @return [String, nil]
|
|
106
111
|
optional :name, String, nil?: true
|
|
107
112
|
|
|
108
|
-
# @!
|
|
113
|
+
# @!attribute sql
|
|
114
|
+
#
|
|
115
|
+
# @return [String, nil]
|
|
116
|
+
optional :sql, String, nil?: true
|
|
117
|
+
|
|
118
|
+
# @!attribute status
|
|
119
|
+
#
|
|
120
|
+
# @return [Symbol, Orb::Models::Webhooks::BillableMetricEditedStandardWebhookEvent::Properties::PreviousAttributes::Status, nil]
|
|
121
|
+
optional :status,
|
|
122
|
+
enum: -> {
|
|
123
|
+
Orb::Webhooks::BillableMetricEditedStandardWebhookEvent::Properties::PreviousAttributes::Status
|
|
124
|
+
},
|
|
125
|
+
nil?: true
|
|
126
|
+
|
|
127
|
+
# @!method initialize(description: nil, item_id: nil, metadata: nil, name: nil, sql: nil, status: nil)
|
|
109
128
|
# metadata values are non-null on the wire, as on the price event.
|
|
110
129
|
#
|
|
111
130
|
# @param description [String, nil]
|
|
131
|
+
# @param item_id [String, nil]
|
|
112
132
|
# @param metadata [Hash{Symbol=>String}, nil]
|
|
113
133
|
# @param name [String, nil]
|
|
134
|
+
# @param sql [String, nil]
|
|
135
|
+
# @param status [Symbol, Orb::Models::Webhooks::BillableMetricEditedStandardWebhookEvent::Properties::PreviousAttributes::Status, nil]
|
|
136
|
+
|
|
137
|
+
# @see Orb::Models::Webhooks::BillableMetricEditedStandardWebhookEvent::Properties::PreviousAttributes#status
|
|
138
|
+
module Status
|
|
139
|
+
extend Orb::Internal::Type::Enum
|
|
140
|
+
|
|
141
|
+
ACTIVE = :active
|
|
142
|
+
ARCHIVED = :archived
|
|
143
|
+
DRAFT = :draft
|
|
144
|
+
|
|
145
|
+
# @!method self.values
|
|
146
|
+
# @return [Array<Symbol>]
|
|
147
|
+
end
|
|
114
148
|
end
|
|
115
149
|
end
|
|
116
150
|
|
data/lib/orb/models.rb
CHANGED
|
@@ -403,6 +403,8 @@ module Orb
|
|
|
403
403
|
|
|
404
404
|
MetricListParams = Orb::Models::MetricListParams
|
|
405
405
|
|
|
406
|
+
MetricPublishParams = Orb::Models::MetricPublishParams
|
|
407
|
+
|
|
406
408
|
MetricUnarchiveParams = Orb::Models::MetricUnarchiveParams
|
|
407
409
|
|
|
408
410
|
MetricUpdateParams = Orb::Models::MetricUpdateParams
|