Skip to content

Commit 49c2213

Browse files
feat(api): api update
1 parent 357d2d4 commit 49c2213

29 files changed

+332
-31
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 139
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-77e112caf7b2a2c7b0248b7245b5730bc72ab0ea84ba5d0777e7d0604ae04d26.yml
3-
openapi_spec_hash: 966568dd08f34db64ba0ebace678268a
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-3c7ee3ec9931aaeeb5e015a598812cde9edc09f114adb8759ef4c2054c90f7dc.yml
3+
openapi_spec_hash: a14720041156fe4f353449142edacf0d
44
config_hash: 3279841440b02d4e8303c961d6983492

lib/orb/models/billable_metric.rb

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,14 @@ class BillableMetric < Orb::Internal::Type::BaseModel
4141
# @return [Symbol, Orb::Models::BillableMetric::Status]
4242
required :status, enum: -> { Orb::BillableMetric::Status }
4343

44-
# @!method initialize(id:, description:, item:, metadata:, name:, status:)
44+
# @!attribute parameter_definitions
45+
#
46+
# @return [Array<Hash{Symbol=>Object}>, nil]
47+
optional :parameter_definitions,
48+
Orb::Internal::Type::ArrayOf[Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown]],
49+
nil?: true
50+
51+
# @!method initialize(id:, description:, item:, metadata:, name:, status:, parameter_definitions: nil)
4552
# Some parameter documentations has been truncated, see
4653
# {Orb::Models::BillableMetric} for more details.
4754
#
@@ -60,6 +67,8 @@ class BillableMetric < Orb::Internal::Type::BaseModel
6067
# @param name [String]
6168
#
6269
# @param status [Symbol, Orb::Models::BillableMetric::Status]
70+
#
71+
# @param parameter_definitions [Array<Hash{Symbol=>Object}>, nil]
6372

6473
# @see Orb::Models::BillableMetric#status
6574
module Status

lib/orb/models/price_evaluate_multiple_params.rb

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,15 @@ class PriceEvaluation < Orb::Internal::Type::BaseModel
7474
# @return [Array<String>, nil]
7575
optional :grouping_keys, Orb::Internal::Type::ArrayOf[String]
7676

77+
# @!attribute metric_parameter_overrides
78+
# Optional overrides for parameterized billable metric parameters. If the metric
79+
# has parameter definitions and no overrides are provided, defaults will be used.
80+
#
81+
# @return [Hash{Symbol=>Object}, nil]
82+
optional :metric_parameter_overrides,
83+
Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown],
84+
nil?: true
85+
7786
# @!attribute price
7887
# New floating price request body params.
7988
#
@@ -86,7 +95,7 @@ class PriceEvaluation < Orb::Internal::Type::BaseModel
8695
# @return [String, nil]
8796
optional :price_id, String, nil?: true
8897

89-
# @!method initialize(external_price_id: nil, filter: nil, grouping_keys: nil, price: nil, price_id: nil)
98+
# @!method initialize(external_price_id: nil, filter: nil, grouping_keys: nil, metric_parameter_overrides: nil, price: nil, price_id: nil)
9099
# Some parameter documentations has been truncated, see
91100
# {Orb::Models::PriceEvaluateMultipleParams::PriceEvaluation} for more details.
92101
#
@@ -96,6 +105,8 @@ class PriceEvaluation < Orb::Internal::Type::BaseModel
96105
#
97106
# @param grouping_keys [Array<String>] Properties (or [computed properties](/extensibility/advanced-metrics#computed-pr
98107
#
108+
# @param metric_parameter_overrides [Hash{Symbol=>Object}, nil] Optional overrides for parameterized billable metric parameters. If the metric h
109+
#
99110
# @param price [Orb::Models::NewFloatingUnitPrice, Orb::Models::NewFloatingTieredPrice, Orb::Models::NewFloatingBulkPrice, Orb::Models::PriceEvaluateMultipleParams::PriceEvaluation::Price::BulkWithFilters, Orb::Models::NewFloatingPackagePrice, Orb::Models::NewFloatingMatrixPrice, Orb::Models::NewFloatingThresholdTotalAmountPrice, Orb::Models::NewFloatingTieredPackagePrice, Orb::Models::NewFloatingTieredWithMinimumPrice, Orb::Models::NewFloatingGroupedTieredPrice, Orb::Models::NewFloatingTieredPackageWithMinimumPrice, Orb::Models::NewFloatingPackageWithAllocationPrice, Orb::Models::NewFloatingUnitWithPercentPrice, Orb::Models::NewFloatingMatrixWithAllocationPrice, Orb::Models::NewFloatingTieredWithProrationPrice, Orb::Models::NewFloatingUnitWithProrationPrice, Orb::Models::NewFloatingGroupedAllocationPrice, Orb::Models::NewFloatingBulkWithProrationPrice, Orb::Models::NewFloatingGroupedWithProratedMinimumPrice, Orb::Models::NewFloatingGroupedWithMeteredMinimumPrice, Orb::Models::PriceEvaluateMultipleParams::PriceEvaluation::Price::GroupedWithMinMaxThresholds, Orb::Models::NewFloatingMatrixWithDisplayNamePrice, Orb::Models::NewFloatingGroupedTieredPackagePrice, Orb::Models::NewFloatingMaxGroupTieredPackagePrice, Orb::Models::NewFloatingScalableMatrixWithUnitPricingPrice, Orb::Models::NewFloatingScalableMatrixWithTieredPricingPrice, Orb::Models::NewFloatingCumulativeGroupedBulkPrice, Orb::Models::PriceEvaluateMultipleParams::PriceEvaluation::Price::CumulativeGroupedAllocation, Orb::Models::NewFloatingMinimumCompositePrice, Orb::Models::PriceEvaluateMultipleParams::PriceEvaluation::Price::Percent, Orb::Models::PriceEvaluateMultipleParams::PriceEvaluation::Price::EventOutput, nil] New floating price request body params.
100111
#
101112
# @param price_id [String, nil] The ID of a price to evaluate that exists in your Orb account.

lib/orb/models/price_evaluate_params.rb

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,16 @@ class PriceEvaluateParams < Orb::Internal::Type::BaseModel
4747
# @return [Array<String>, nil]
4848
optional :grouping_keys, Orb::Internal::Type::ArrayOf[String]
4949

50-
# @!method initialize(timeframe_end:, timeframe_start:, customer_id: nil, external_customer_id: nil, filter: nil, grouping_keys: nil, request_options: {})
50+
# @!attribute metric_parameter_overrides
51+
# Optional overrides for parameterized billable metric parameters. If the metric
52+
# has parameter definitions and no overrides are provided, defaults will be used.
53+
#
54+
# @return [Hash{Symbol=>Object}, nil]
55+
optional :metric_parameter_overrides,
56+
Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown],
57+
nil?: true
58+
59+
# @!method initialize(timeframe_end:, timeframe_start:, customer_id: nil, external_customer_id: nil, filter: nil, grouping_keys: nil, metric_parameter_overrides: nil, request_options: {})
5160
# Some parameter documentations has been truncated, see
5261
# {Orb::Models::PriceEvaluateParams} for more details.
5362
#
@@ -63,6 +72,8 @@ class PriceEvaluateParams < Orb::Internal::Type::BaseModel
6372
#
6473
# @param grouping_keys [Array<String>] Properties (or [computed properties](/extensibility/advanced-metrics#computed-pr
6574
#
75+
# @param metric_parameter_overrides [Hash{Symbol=>Object}, nil] Optional overrides for parameterized billable metric parameters. If the metric h
76+
#
6677
# @param request_options [Orb::RequestOptions, Hash{Symbol=>Object}]
6778
end
6879
end

lib/orb/models/price_evaluate_preview_events_params.rb

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,15 @@ class PriceEvaluation < Orb::Internal::Type::BaseModel
132132
# @return [Array<String>, nil]
133133
optional :grouping_keys, Orb::Internal::Type::ArrayOf[String]
134134

135+
# @!attribute metric_parameter_overrides
136+
# Optional overrides for parameterized billable metric parameters. If the metric
137+
# has parameter definitions and no overrides are provided, defaults will be used.
138+
#
139+
# @return [Hash{Symbol=>Object}, nil]
140+
optional :metric_parameter_overrides,
141+
Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown],
142+
nil?: true
143+
135144
# @!attribute price
136145
# New floating price request body params.
137146
#
@@ -148,7 +157,7 @@ class PriceEvaluation < Orb::Internal::Type::BaseModel
148157
# @return [String, nil]
149158
optional :price_id, String, nil?: true
150159

151-
# @!method initialize(external_price_id: nil, filter: nil, grouping_keys: nil, price: nil, price_id: nil)
160+
# @!method initialize(external_price_id: nil, filter: nil, grouping_keys: nil, metric_parameter_overrides: nil, price: nil, price_id: nil)
152161
# Some parameter documentations has been truncated, see
153162
# {Orb::Models::PriceEvaluatePreviewEventsParams::PriceEvaluation} for more
154163
# details.
@@ -159,6 +168,8 @@ class PriceEvaluation < Orb::Internal::Type::BaseModel
159168
#
160169
# @param grouping_keys [Array<String>] Properties (or [computed properties](/extensibility/advanced-metrics#computed-pr
161170
#
171+
# @param metric_parameter_overrides [Hash{Symbol=>Object}, nil] Optional overrides for parameterized billable metric parameters. If the metric h
172+
#
162173
# @param price [Orb::Models::NewFloatingUnitPrice, Orb::Models::NewFloatingTieredPrice, Orb::Models::NewFloatingBulkPrice, Orb::Models::PriceEvaluatePreviewEventsParams::PriceEvaluation::Price::BulkWithFilters, Orb::Models::NewFloatingPackagePrice, Orb::Models::NewFloatingMatrixPrice, Orb::Models::NewFloatingThresholdTotalAmountPrice, Orb::Models::NewFloatingTieredPackagePrice, Orb::Models::NewFloatingTieredWithMinimumPrice, Orb::Models::NewFloatingGroupedTieredPrice, Orb::Models::NewFloatingTieredPackageWithMinimumPrice, Orb::Models::NewFloatingPackageWithAllocationPrice, Orb::Models::NewFloatingUnitWithPercentPrice, Orb::Models::NewFloatingMatrixWithAllocationPrice, Orb::Models::NewFloatingTieredWithProrationPrice, Orb::Models::NewFloatingUnitWithProrationPrice, Orb::Models::NewFloatingGroupedAllocationPrice, Orb::Models::NewFloatingBulkWithProrationPrice, Orb::Models::NewFloatingGroupedWithProratedMinimumPrice, Orb::Models::NewFloatingGroupedWithMeteredMinimumPrice, Orb::Models::PriceEvaluatePreviewEventsParams::PriceEvaluation::Price::GroupedWithMinMaxThresholds, Orb::Models::NewFloatingMatrixWithDisplayNamePrice, Orb::Models::NewFloatingGroupedTieredPackagePrice, Orb::Models::NewFloatingMaxGroupTieredPackagePrice, Orb::Models::NewFloatingScalableMatrixWithUnitPricingPrice, Orb::Models::NewFloatingScalableMatrixWithTieredPricingPrice, Orb::Models::NewFloatingCumulativeGroupedBulkPrice, Orb::Models::PriceEvaluatePreviewEventsParams::PriceEvaluation::Price::CumulativeGroupedAllocation, Orb::Models::NewFloatingMinimumCompositePrice, Orb::Models::PriceEvaluatePreviewEventsParams::PriceEvaluation::Price::Percent, Orb::Models::PriceEvaluatePreviewEventsParams::PriceEvaluation::Price::EventOutput, nil] New floating price request body params.
163174
#
164175
# @param price_id [String, nil] The ID of a price to evaluate that exists in your Orb account.

lib/orb/models/price_interval.rb

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,16 @@ class PriceInterval < Orb::Internal::Type::BaseModel
8989
# @return [Array<String>, nil]
9090
required :usage_customer_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
9191

92-
# @!method initialize(id:, billing_cycle_day:, can_defer_billing:, current_billing_period_end_date:, current_billing_period_start_date:, end_date:, filter:, fixed_fee_quantity_transitions:, price:, start_date:, usage_customer_ids:)
92+
# @!attribute metric_parameter_overrides
93+
# Override values for parameterized billable metric variables. Keys are parameter
94+
# names, values are the override values.
95+
#
96+
# @return [Hash{Symbol=>Object}, nil]
97+
optional :metric_parameter_overrides,
98+
Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown],
99+
nil?: true
100+
101+
# @!method initialize(id:, billing_cycle_day:, can_defer_billing:, current_billing_period_end_date:, current_billing_period_start_date:, end_date:, filter:, fixed_fee_quantity_transitions:, price:, start_date:, usage_customer_ids:, metric_parameter_overrides: nil)
93102
# Some parameter documentations has been truncated, see
94103
# {Orb::Models::PriceInterval} for more details.
95104
#
@@ -118,6 +127,8 @@ class PriceInterval < Orb::Internal::Type::BaseModel
118127
# @param start_date [Time] The start date of the price interval. This is the date that Orb starts billing f
119128
#
120129
# @param usage_customer_ids [Array<String>, nil] A list of customer IDs whose usage events will be aggregated and billed under th
130+
#
131+
# @param metric_parameter_overrides [Hash{Symbol=>Object}, nil] Override values for parameterized billable metric variables. Keys are parameter
121132
end
122133
end
123134
end

lib/orb/models/subscription_create_params.rb

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,15 @@ class AddPrice < Orb::Internal::Type::BaseModel
422422
# @return [String, nil]
423423
optional :maximum_amount, String, nil?: true
424424

425+
# @!attribute metric_parameter_overrides
426+
# Override values for parameterized billable metric variables. Keys are parameter
427+
# names, values are the override values.
428+
#
429+
# @return [Hash{Symbol=>Object}, nil]
430+
optional :metric_parameter_overrides,
431+
Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown],
432+
nil?: true
433+
425434
# @!attribute minimum_amount
426435
# @deprecated
427436
#
@@ -457,7 +466,7 @@ class AddPrice < Orb::Internal::Type::BaseModel
457466
# @return [Time, nil]
458467
optional :start_date, Time, nil?: true
459468

460-
# @!method initialize(allocation_price: nil, discounts: nil, end_date: nil, external_price_id: nil, maximum_amount: nil, minimum_amount: nil, plan_phase_order: nil, price: nil, price_id: nil, start_date: nil)
469+
# @!method initialize(allocation_price: nil, discounts: nil, end_date: nil, external_price_id: nil, maximum_amount: nil, metric_parameter_overrides: nil, minimum_amount: nil, plan_phase_order: nil, price: nil, price_id: nil, start_date: nil)
461470
# Some parameter documentations has been truncated, see
462471
# {Orb::Models::SubscriptionCreateParams::AddPrice} for more details.
463472
#
@@ -471,6 +480,8 @@ class AddPrice < Orb::Internal::Type::BaseModel
471480
#
472481
# @param maximum_amount [String, nil] [DEPRECATED] Use add_adjustments instead. The subscription's maximum amount for
473482
#
483+
# @param metric_parameter_overrides [Hash{Symbol=>Object}, nil] Override values for parameterized billable metric variables. Keys are parameter
484+
#
474485
# @param minimum_amount [String, nil] [DEPRECATED] Use add_adjustments instead. The subscription's minimum amount for
475486
#
476487
# @param plan_phase_order [Integer, nil] The phase to add this price to.
@@ -2085,6 +2096,15 @@ class ReplacePrice < Orb::Internal::Type::BaseModel
20852096
# @return [String, nil]
20862097
optional :maximum_amount, String, nil?: true
20872098

2099+
# @!attribute metric_parameter_overrides
2100+
# Override values for parameterized billable metric variables. Keys are parameter
2101+
# names, values are the override values.
2102+
#
2103+
# @return [Hash{Symbol=>Object}, nil]
2104+
optional :metric_parameter_overrides,
2105+
Orb::Internal::Type::HashOf[Orb::Internal::Type::Unknown],
2106+
nil?: true
2107+
20882108
# @!attribute minimum_amount
20892109
# @deprecated
20902110
#
@@ -2106,7 +2126,7 @@ class ReplacePrice < Orb::Internal::Type::BaseModel
21062126
# @return [String, nil]
21072127
optional :price_id, String, nil?: true
21082128

2109-
# @!method initialize(replaces_price_id:, allocation_price: nil, discounts: nil, external_price_id: nil, fixed_price_quantity: nil, maximum_amount: nil, minimum_amount: nil, price: nil, price_id: nil)
2129+
# @!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)
21102130
# Some parameter documentations has been truncated, see
21112131
# {Orb::Models::SubscriptionCreateParams::ReplacePrice} for more details.
21122132
#
@@ -2122,6 +2142,8 @@ class ReplacePrice < Orb::Internal::Type::BaseModel
21222142
#
21232143
# @param maximum_amount [String, nil] [DEPRECATED] Use add_adjustments instead. The subscription's maximum amount for
21242144
#
2145+
# @param metric_parameter_overrides [Hash{Symbol=>Object}, nil] Override values for parameterized billable metric variables. Keys are parameter
2146+
#
21252147
# @param minimum_amount [String, nil] [DEPRECATED] Use add_adjustments instead. The subscription's minimum amount for
21262148
#
21272149
# @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::NewSubscriptionTieredPackageWithMinimumPrice, Orb::Models::NewSubscriptionPackageWithAllocationPrice, Orb::Models::NewSubscriptionUnitWithPercentPrice, Orb::Models::NewSubscriptionMatrixWithAllocationPrice, 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::NewSubscriptionMinimumCompositePrice, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::Percent, Orb::Models::SubscriptionCreateParams::ReplacePrice::Price::EventOutput, nil] New subscription price request body params.

0 commit comments

Comments
 (0)