Skip to content

Commit df68e3b

Browse files
feat(api): api update
1 parent 1586bae commit df68e3b

14 files changed

+1929
-46
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: 118
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-9e751a2aefff382af949380b5979a80cb02743eca1583cf5146325fb400ba87f.yml
3-
openapi_spec_hash: 219a1008f47d3293f64f1baebe2d6eb5
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/orb%2Forb-947253d9be505473c1c2cb0193d2602fa6b017e221f482be3f4f374c6156b350.yml
3+
openapi_spec_hash: 1b40d1a85b4b846a1c14634fbbc65da3
44
config_hash: e6db17547fe854b1c240407cf4c6dc9e

src/orb/resources/prices/prices.py

Lines changed: 208 additions & 0 deletions
Large diffs are not rendered by default.

src/orb/types/beta/external_plan_id_create_plan_version_params.py

Lines changed: 212 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,9 @@
6161
"AddPricePriceNewPlanGroupedWithMinMaxThresholdsPrice",
6262
"AddPricePriceNewPlanGroupedWithMinMaxThresholdsPriceGroupedWithMinMaxThresholdsConfig",
6363
"AddPricePriceNewPlanGroupedWithMinMaxThresholdsPriceConversionRateConfig",
64+
"AddPricePriceNewPlanCumulativeGroupedAllocationPrice",
65+
"AddPricePriceNewPlanCumulativeGroupedAllocationPriceCumulativeGroupedAllocationConfig",
66+
"AddPricePriceNewPlanCumulativeGroupedAllocationPriceConversionRateConfig",
6467
"AddPricePriceNewPlanPercentCompositePrice",
6568
"AddPricePriceNewPlanPercentCompositePricePercentConfig",
6669
"AddPricePriceNewPlanPercentCompositePriceConversionRateConfig",
@@ -85,6 +88,9 @@
8588
"ReplacePricePriceNewPlanGroupedWithMinMaxThresholdsPrice",
8689
"ReplacePricePriceNewPlanGroupedWithMinMaxThresholdsPriceGroupedWithMinMaxThresholdsConfig",
8790
"ReplacePricePriceNewPlanGroupedWithMinMaxThresholdsPriceConversionRateConfig",
91+
"ReplacePricePriceNewPlanCumulativeGroupedAllocationPrice",
92+
"ReplacePricePriceNewPlanCumulativeGroupedAllocationPriceCumulativeGroupedAllocationConfig",
93+
"ReplacePricePriceNewPlanCumulativeGroupedAllocationPriceConversionRateConfig",
8894
"ReplacePricePriceNewPlanPercentCompositePrice",
8995
"ReplacePricePriceNewPlanPercentCompositePricePercentConfig",
9096
"ReplacePricePriceNewPlanPercentCompositePriceConversionRateConfig",
@@ -447,6 +453,108 @@ class AddPricePriceNewPlanGroupedWithMinMaxThresholdsPrice(TypedDict, total=Fals
447453
"""
448454

449455

456+
class AddPricePriceNewPlanCumulativeGroupedAllocationPriceCumulativeGroupedAllocationConfig(TypedDict, total=False):
457+
cumulative_allocation: Required[str]
458+
"""The overall allocation across all groups"""
459+
460+
group_allocation: Required[str]
461+
"""The allocation per individual group"""
462+
463+
grouping_key: Required[str]
464+
"""The event property used to group usage before applying allocations"""
465+
466+
unit_amount: Required[str]
467+
"""The amount to charge for each unit outside of the allocation"""
468+
469+
470+
AddPricePriceNewPlanCumulativeGroupedAllocationPriceConversionRateConfig: TypeAlias = Union[
471+
UnitConversionRateConfig, TieredConversionRateConfig
472+
]
473+
474+
475+
class AddPricePriceNewPlanCumulativeGroupedAllocationPrice(TypedDict, total=False):
476+
cadence: Required[Literal["annual", "semi_annual", "monthly", "quarterly", "one_time", "custom"]]
477+
"""The cadence to bill for this price on."""
478+
479+
cumulative_grouped_allocation_config: Required[
480+
AddPricePriceNewPlanCumulativeGroupedAllocationPriceCumulativeGroupedAllocationConfig
481+
]
482+
"""Configuration for cumulative_grouped_allocation pricing"""
483+
484+
item_id: Required[str]
485+
"""The id of the item the price will be associated with."""
486+
487+
model_type: Required[Literal["cumulative_grouped_allocation"]]
488+
"""The pricing model type"""
489+
490+
name: Required[str]
491+
"""The name of the price."""
492+
493+
billable_metric_id: Optional[str]
494+
"""The id of the billable metric for the price.
495+
496+
Only needed if the price is usage-based.
497+
"""
498+
499+
billed_in_advance: Optional[bool]
500+
"""
501+
If the Price represents a fixed cost, the price will be billed in-advance if
502+
this is true, and in-arrears if this is false.
503+
"""
504+
505+
billing_cycle_configuration: Optional[NewBillingCycleConfiguration]
506+
"""
507+
For custom cadence: specifies the duration of the billing period in days or
508+
months.
509+
"""
510+
511+
conversion_rate: Optional[float]
512+
"""The per unit conversion rate of the price currency to the invoicing currency."""
513+
514+
conversion_rate_config: Optional[AddPricePriceNewPlanCumulativeGroupedAllocationPriceConversionRateConfig]
515+
"""The configuration for the rate of the price currency to the invoicing currency."""
516+
517+
currency: Optional[str]
518+
"""
519+
An ISO 4217 currency string, or custom pricing unit identifier, in which this
520+
price is billed.
521+
"""
522+
523+
dimensional_price_configuration: Optional[NewDimensionalPriceConfiguration]
524+
"""For dimensional price: specifies a price group and dimension values"""
525+
526+
external_price_id: Optional[str]
527+
"""An alias for the price."""
528+
529+
fixed_price_quantity: Optional[float]
530+
"""
531+
If the Price represents a fixed cost, this represents the quantity of units
532+
applied.
533+
"""
534+
535+
invoice_grouping_key: Optional[str]
536+
"""The property used to group this price on an invoice"""
537+
538+
invoicing_cycle_configuration: Optional[NewBillingCycleConfiguration]
539+
"""Within each billing cycle, specifies the cadence at which invoices are produced.
540+
541+
If unspecified, a single invoice is produced per billing cycle.
542+
"""
543+
544+
metadata: Optional[Dict[str, Optional[str]]]
545+
"""User-specified key/value pairs for the resource.
546+
547+
Individual keys can be removed by setting the value to `null`, and the entire
548+
metadata mapping can be cleared by setting `metadata` to `null`.
549+
"""
550+
551+
reference_id: Optional[str]
552+
"""
553+
A transient ID that can be used to reference this price when adding adjustments
554+
in the same API call.
555+
"""
556+
557+
450558
class AddPricePriceNewPlanPercentCompositePricePercentConfig(TypedDict, total=False):
451559
percent: Required[float]
452560
"""What percent of the component subtotals to charge"""
@@ -670,6 +778,7 @@ class AddPricePriceNewPlanEventOutputPrice(TypedDict, total=False):
670778
NewPlanScalableMatrixWithUnitPricingPrice,
671779
NewPlanScalableMatrixWithTieredPricingPrice,
672780
NewPlanCumulativeGroupedBulkPrice,
781+
AddPricePriceNewPlanCumulativeGroupedAllocationPrice,
673782
NewPlanMinimumCompositePrice,
674783
AddPricePriceNewPlanPercentCompositePrice,
675784
AddPricePriceNewPlanEventOutputPrice,
@@ -1033,6 +1142,108 @@ class ReplacePricePriceNewPlanGroupedWithMinMaxThresholdsPrice(TypedDict, total=
10331142
"""
10341143

10351144

1145+
class ReplacePricePriceNewPlanCumulativeGroupedAllocationPriceCumulativeGroupedAllocationConfig(TypedDict, total=False):
1146+
cumulative_allocation: Required[str]
1147+
"""The overall allocation across all groups"""
1148+
1149+
group_allocation: Required[str]
1150+
"""The allocation per individual group"""
1151+
1152+
grouping_key: Required[str]
1153+
"""The event property used to group usage before applying allocations"""
1154+
1155+
unit_amount: Required[str]
1156+
"""The amount to charge for each unit outside of the allocation"""
1157+
1158+
1159+
ReplacePricePriceNewPlanCumulativeGroupedAllocationPriceConversionRateConfig: TypeAlias = Union[
1160+
UnitConversionRateConfig, TieredConversionRateConfig
1161+
]
1162+
1163+
1164+
class ReplacePricePriceNewPlanCumulativeGroupedAllocationPrice(TypedDict, total=False):
1165+
cadence: Required[Literal["annual", "semi_annual", "monthly", "quarterly", "one_time", "custom"]]
1166+
"""The cadence to bill for this price on."""
1167+
1168+
cumulative_grouped_allocation_config: Required[
1169+
ReplacePricePriceNewPlanCumulativeGroupedAllocationPriceCumulativeGroupedAllocationConfig
1170+
]
1171+
"""Configuration for cumulative_grouped_allocation pricing"""
1172+
1173+
item_id: Required[str]
1174+
"""The id of the item the price will be associated with."""
1175+
1176+
model_type: Required[Literal["cumulative_grouped_allocation"]]
1177+
"""The pricing model type"""
1178+
1179+
name: Required[str]
1180+
"""The name of the price."""
1181+
1182+
billable_metric_id: Optional[str]
1183+
"""The id of the billable metric for the price.
1184+
1185+
Only needed if the price is usage-based.
1186+
"""
1187+
1188+
billed_in_advance: Optional[bool]
1189+
"""
1190+
If the Price represents a fixed cost, the price will be billed in-advance if
1191+
this is true, and in-arrears if this is false.
1192+
"""
1193+
1194+
billing_cycle_configuration: Optional[NewBillingCycleConfiguration]
1195+
"""
1196+
For custom cadence: specifies the duration of the billing period in days or
1197+
months.
1198+
"""
1199+
1200+
conversion_rate: Optional[float]
1201+
"""The per unit conversion rate of the price currency to the invoicing currency."""
1202+
1203+
conversion_rate_config: Optional[ReplacePricePriceNewPlanCumulativeGroupedAllocationPriceConversionRateConfig]
1204+
"""The configuration for the rate of the price currency to the invoicing currency."""
1205+
1206+
currency: Optional[str]
1207+
"""
1208+
An ISO 4217 currency string, or custom pricing unit identifier, in which this
1209+
price is billed.
1210+
"""
1211+
1212+
dimensional_price_configuration: Optional[NewDimensionalPriceConfiguration]
1213+
"""For dimensional price: specifies a price group and dimension values"""
1214+
1215+
external_price_id: Optional[str]
1216+
"""An alias for the price."""
1217+
1218+
fixed_price_quantity: Optional[float]
1219+
"""
1220+
If the Price represents a fixed cost, this represents the quantity of units
1221+
applied.
1222+
"""
1223+
1224+
invoice_grouping_key: Optional[str]
1225+
"""The property used to group this price on an invoice"""
1226+
1227+
invoicing_cycle_configuration: Optional[NewBillingCycleConfiguration]
1228+
"""Within each billing cycle, specifies the cadence at which invoices are produced.
1229+
1230+
If unspecified, a single invoice is produced per billing cycle.
1231+
"""
1232+
1233+
metadata: Optional[Dict[str, Optional[str]]]
1234+
"""User-specified key/value pairs for the resource.
1235+
1236+
Individual keys can be removed by setting the value to `null`, and the entire
1237+
metadata mapping can be cleared by setting `metadata` to `null`.
1238+
"""
1239+
1240+
reference_id: Optional[str]
1241+
"""
1242+
A transient ID that can be used to reference this price when adding adjustments
1243+
in the same API call.
1244+
"""
1245+
1246+
10361247
class ReplacePricePriceNewPlanPercentCompositePricePercentConfig(TypedDict, total=False):
10371248
percent: Required[float]
10381249
"""What percent of the component subtotals to charge"""
@@ -1256,6 +1467,7 @@ class ReplacePricePriceNewPlanEventOutputPrice(TypedDict, total=False):
12561467
NewPlanScalableMatrixWithUnitPricingPrice,
12571468
NewPlanScalableMatrixWithTieredPricingPrice,
12581469
NewPlanCumulativeGroupedBulkPrice,
1470+
ReplacePricePriceNewPlanCumulativeGroupedAllocationPrice,
12591471
NewPlanMinimumCompositePrice,
12601472
ReplacePricePriceNewPlanPercentCompositePrice,
12611473
ReplacePricePriceNewPlanEventOutputPrice,

0 commit comments

Comments
 (0)