@openmeter/sdk 1.0.0-beta-7cf71f2fbc46 → 1.0.0-beta-4a759fce7326

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.
@@ -18596,11 +18596,17 @@ export declare const createCustomerEntitlementV2BodyFeatureKeyMax = 64;
18596
18596
  export declare const createCustomerEntitlementV2BodyFeatureKeyRegExp: RegExp;
18597
18597
  export declare const createCustomerEntitlementV2BodyFeatureIdRegExp: RegExp;
18598
18598
  export declare const createCustomerEntitlementV2BodyIsSoftLimitDefault = false;
18599
- export declare const createCustomerEntitlementV2BodyIsUnlimitedDefault = false;
18599
+ export declare const createCustomerEntitlementV2BodyPreserveOverageAtResetDefault = false;
18600
18600
  export declare const createCustomerEntitlementV2BodyIssueAfterResetMin = 0;
18601
18601
  export declare const createCustomerEntitlementV2BodyIssueAfterResetPriorityDefault = 1;
18602
18602
  export declare const createCustomerEntitlementV2BodyIssueAfterResetPriorityMax = 255;
18603
- export declare const createCustomerEntitlementV2BodyPreserveOverageAtResetDefault = false;
18603
+ export declare const createCustomerEntitlementV2BodyIssueAmountMin = 0;
18604
+ export declare const createCustomerEntitlementV2BodyIssuePriorityDefault = 1;
18605
+ export declare const createCustomerEntitlementV2BodyIssuePriorityMax = 255;
18606
+ export declare const createCustomerEntitlementV2BodyGrantsItemAmountMin = 0;
18607
+ export declare const createCustomerEntitlementV2BodyGrantsItemPriorityMax = 255;
18608
+ export declare const createCustomerEntitlementV2BodyGrantsItemMinRolloverAmountDefault = 0;
18609
+ export declare const createCustomerEntitlementV2BodyGrantsItemExpirationCountMax = 1000;
18604
18610
  export declare const createCustomerEntitlementV2BodyFeatureKeyMaxOne = 64;
18605
18611
  export declare const createCustomerEntitlementV2BodyFeatureKeyRegExpOne: RegExp;
18606
18612
  export declare const createCustomerEntitlementV2BodyFeatureIdRegExpOne: RegExp;
@@ -18610,10 +18616,80 @@ export declare const createCustomerEntitlementV2BodyFeatureIdRegExpTwo: RegExp;
18610
18616
  export declare const createCustomerEntitlementV2Body: zod.ZodUnion<[zod.ZodObject<{
18611
18617
  featureId: zod.ZodOptional<zod.ZodString>;
18612
18618
  featureKey: zod.ZodOptional<zod.ZodString>;
18619
+ grants: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
18620
+ amount: zod.ZodNumber;
18621
+ annotations: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodAny>>;
18622
+ effectiveAt: zod.ZodDate;
18623
+ expiration: zod.ZodOptional<zod.ZodObject<{
18624
+ count: zod.ZodNumber;
18625
+ duration: zod.ZodEnum<["HOUR", "DAY", "WEEK", "MONTH", "YEAR"]>;
18626
+ }, "strip", zod.ZodTypeAny, {
18627
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18628
+ count: number;
18629
+ }, {
18630
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18631
+ count: number;
18632
+ }>>;
18633
+ maxRolloverAmount: zod.ZodOptional<zod.ZodNumber>;
18634
+ metadata: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodString>>;
18635
+ minRolloverAmount: zod.ZodOptional<zod.ZodNumber>;
18636
+ priority: zod.ZodOptional<zod.ZodNumber>;
18637
+ recurrence: zod.ZodOptional<zod.ZodObject<{
18638
+ anchor: zod.ZodOptional<zod.ZodDate>;
18639
+ interval: zod.ZodUnion<[zod.ZodString, zod.ZodEnum<["DAY", "WEEK", "MONTH", "YEAR"]>]>;
18640
+ }, "strip", zod.ZodTypeAny, {
18641
+ interval: string;
18642
+ anchor?: Date | undefined;
18643
+ }, {
18644
+ interval: string;
18645
+ anchor?: Date | undefined;
18646
+ }>>;
18647
+ }, "strip", zod.ZodTypeAny, {
18648
+ amount: number;
18649
+ effectiveAt: Date;
18650
+ metadata?: Record<string, string> | undefined;
18651
+ expiration?: {
18652
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18653
+ count: number;
18654
+ } | undefined;
18655
+ maxRolloverAmount?: number | undefined;
18656
+ minRolloverAmount?: number | undefined;
18657
+ priority?: number | undefined;
18658
+ recurrence?: {
18659
+ interval: string;
18660
+ anchor?: Date | undefined;
18661
+ } | undefined;
18662
+ annotations?: Record<string, any> | undefined;
18663
+ }, {
18664
+ amount: number;
18665
+ effectiveAt: Date;
18666
+ metadata?: Record<string, string> | undefined;
18667
+ expiration?: {
18668
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18669
+ count: number;
18670
+ } | undefined;
18671
+ maxRolloverAmount?: number | undefined;
18672
+ minRolloverAmount?: number | undefined;
18673
+ priority?: number | undefined;
18674
+ recurrence?: {
18675
+ interval: string;
18676
+ anchor?: Date | undefined;
18677
+ } | undefined;
18678
+ annotations?: Record<string, any> | undefined;
18679
+ }>, "many">>;
18613
18680
  isSoftLimit: zod.ZodOptional<zod.ZodBoolean>;
18681
+ issue: zod.ZodOptional<zod.ZodObject<{
18682
+ amount: zod.ZodNumber;
18683
+ priority: zod.ZodDefault<zod.ZodNumber>;
18684
+ }, "strip", zod.ZodTypeAny, {
18685
+ amount: number;
18686
+ priority: number;
18687
+ }, {
18688
+ amount: number;
18689
+ priority?: number | undefined;
18690
+ }>>;
18614
18691
  issueAfterReset: zod.ZodOptional<zod.ZodNumber>;
18615
18692
  issueAfterResetPriority: zod.ZodDefault<zod.ZodNumber>;
18616
- isUnlimited: zod.ZodOptional<zod.ZodBoolean>;
18617
18693
  measureUsageFrom: zod.ZodOptional<zod.ZodUnion<[zod.ZodEnum<["CURRENT_PERIOD_START", "NOW"]>, zod.ZodDate]>>;
18618
18694
  metadata: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodString>>;
18619
18695
  preserveOverageAtReset: zod.ZodOptional<zod.ZodBoolean>;
@@ -18641,8 +18717,28 @@ export declare const createCustomerEntitlementV2Body: zod.ZodUnion<[zod.ZodObjec
18641
18717
  isSoftLimit?: boolean | undefined;
18642
18718
  issueAfterReset?: number | undefined;
18643
18719
  preserveOverageAtReset?: boolean | undefined;
18644
- isUnlimited?: boolean | undefined;
18645
18720
  measureUsageFrom?: Date | "CURRENT_PERIOD_START" | "NOW" | undefined;
18721
+ grants?: {
18722
+ amount: number;
18723
+ effectiveAt: Date;
18724
+ metadata?: Record<string, string> | undefined;
18725
+ expiration?: {
18726
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18727
+ count: number;
18728
+ } | undefined;
18729
+ maxRolloverAmount?: number | undefined;
18730
+ minRolloverAmount?: number | undefined;
18731
+ priority?: number | undefined;
18732
+ recurrence?: {
18733
+ interval: string;
18734
+ anchor?: Date | undefined;
18735
+ } | undefined;
18736
+ annotations?: Record<string, any> | undefined;
18737
+ }[] | undefined;
18738
+ issue?: {
18739
+ amount: number;
18740
+ priority: number;
18741
+ } | undefined;
18646
18742
  }, {
18647
18743
  type: "metered";
18648
18744
  usagePeriod: {
@@ -18656,8 +18752,28 @@ export declare const createCustomerEntitlementV2Body: zod.ZodUnion<[zod.ZodObjec
18656
18752
  issueAfterReset?: number | undefined;
18657
18753
  issueAfterResetPriority?: number | undefined;
18658
18754
  preserveOverageAtReset?: boolean | undefined;
18659
- isUnlimited?: boolean | undefined;
18660
18755
  measureUsageFrom?: Date | "CURRENT_PERIOD_START" | "NOW" | undefined;
18756
+ grants?: {
18757
+ amount: number;
18758
+ effectiveAt: Date;
18759
+ metadata?: Record<string, string> | undefined;
18760
+ expiration?: {
18761
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18762
+ count: number;
18763
+ } | undefined;
18764
+ maxRolloverAmount?: number | undefined;
18765
+ minRolloverAmount?: number | undefined;
18766
+ priority?: number | undefined;
18767
+ recurrence?: {
18768
+ interval: string;
18769
+ anchor?: Date | undefined;
18770
+ } | undefined;
18771
+ annotations?: Record<string, any> | undefined;
18772
+ }[] | undefined;
18773
+ issue?: {
18774
+ amount: number;
18775
+ priority?: number | undefined;
18776
+ } | undefined;
18661
18777
  }>, zod.ZodObject<{
18662
18778
  config: zod.ZodString;
18663
18779
  featureId: zod.ZodOptional<zod.ZodString>;
@@ -18873,13 +18989,13 @@ export declare const createCustomerEntitlementGrantV2Params: zod.ZodObject<{
18873
18989
  }>;
18874
18990
  export declare const createCustomerEntitlementGrantV2BodyAmountMin = 0;
18875
18991
  export declare const createCustomerEntitlementGrantV2BodyPriorityMax = 255;
18876
- export declare const createCustomerEntitlementGrantV2BodyExpirationCountMax = 1000;
18877
- export declare const createCustomerEntitlementGrantV2BodyMaxRolloverAmountDefault = 0;
18878
18992
  export declare const createCustomerEntitlementGrantV2BodyMinRolloverAmountDefault = 0;
18993
+ export declare const createCustomerEntitlementGrantV2BodyExpirationCountMax = 1000;
18879
18994
  export declare const createCustomerEntitlementGrantV2Body: zod.ZodObject<{
18880
18995
  amount: zod.ZodNumber;
18996
+ annotations: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodAny>>;
18881
18997
  effectiveAt: zod.ZodDate;
18882
- expiration: zod.ZodObject<{
18998
+ expiration: zod.ZodOptional<zod.ZodObject<{
18883
18999
  count: zod.ZodNumber;
18884
19000
  duration: zod.ZodEnum<["HOUR", "DAY", "WEEK", "MONTH", "YEAR"]>;
18885
19001
  }, "strip", zod.ZodTypeAny, {
@@ -18888,7 +19004,7 @@ export declare const createCustomerEntitlementGrantV2Body: zod.ZodObject<{
18888
19004
  }, {
18889
19005
  duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18890
19006
  count: number;
18891
- }>;
19007
+ }>>;
18892
19008
  maxRolloverAmount: zod.ZodOptional<zod.ZodNumber>;
18893
19009
  metadata: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodString>>;
18894
19010
  minRolloverAmount: zod.ZodOptional<zod.ZodNumber>;
@@ -18906,11 +19022,11 @@ export declare const createCustomerEntitlementGrantV2Body: zod.ZodObject<{
18906
19022
  }, "strip", zod.ZodTypeAny, {
18907
19023
  amount: number;
18908
19024
  effectiveAt: Date;
18909
- expiration: {
19025
+ metadata?: Record<string, string> | undefined;
19026
+ expiration?: {
18910
19027
  duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18911
19028
  count: number;
18912
- };
18913
- metadata?: Record<string, string> | undefined;
19029
+ } | undefined;
18914
19030
  maxRolloverAmount?: number | undefined;
18915
19031
  minRolloverAmount?: number | undefined;
18916
19032
  priority?: number | undefined;
@@ -18918,14 +19034,15 @@ export declare const createCustomerEntitlementGrantV2Body: zod.ZodObject<{
18918
19034
  interval: string;
18919
19035
  anchor?: Date | undefined;
18920
19036
  } | undefined;
19037
+ annotations?: Record<string, any> | undefined;
18921
19038
  }, {
18922
19039
  amount: number;
18923
19040
  effectiveAt: Date;
18924
- expiration: {
19041
+ metadata?: Record<string, string> | undefined;
19042
+ expiration?: {
18925
19043
  duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
18926
19044
  count: number;
18927
- };
18928
- metadata?: Record<string, string> | undefined;
19045
+ } | undefined;
18929
19046
  maxRolloverAmount?: number | undefined;
18930
19047
  minRolloverAmount?: number | undefined;
18931
19048
  priority?: number | undefined;
@@ -18933,6 +19050,7 @@ export declare const createCustomerEntitlementGrantV2Body: zod.ZodObject<{
18933
19050
  interval: string;
18934
19051
  anchor?: Date | undefined;
18935
19052
  } | undefined;
19053
+ annotations?: Record<string, any> | undefined;
18936
19054
  }>;
18937
19055
  /**
18938
19056
  * Returns historical balance and usage data for the entitlement. The queried history can span accross multiple reset events.
@@ -18991,11 +19109,17 @@ export declare const overrideCustomerEntitlementV2BodyFeatureKeyMax = 64;
18991
19109
  export declare const overrideCustomerEntitlementV2BodyFeatureKeyRegExp: RegExp;
18992
19110
  export declare const overrideCustomerEntitlementV2BodyFeatureIdRegExp: RegExp;
18993
19111
  export declare const overrideCustomerEntitlementV2BodyIsSoftLimitDefault = false;
18994
- export declare const overrideCustomerEntitlementV2BodyIsUnlimitedDefault = false;
19112
+ export declare const overrideCustomerEntitlementV2BodyPreserveOverageAtResetDefault = false;
18995
19113
  export declare const overrideCustomerEntitlementV2BodyIssueAfterResetMin = 0;
18996
19114
  export declare const overrideCustomerEntitlementV2BodyIssueAfterResetPriorityDefault = 1;
18997
19115
  export declare const overrideCustomerEntitlementV2BodyIssueAfterResetPriorityMax = 255;
18998
- export declare const overrideCustomerEntitlementV2BodyPreserveOverageAtResetDefault = false;
19116
+ export declare const overrideCustomerEntitlementV2BodyIssueAmountMin = 0;
19117
+ export declare const overrideCustomerEntitlementV2BodyIssuePriorityDefault = 1;
19118
+ export declare const overrideCustomerEntitlementV2BodyIssuePriorityMax = 255;
19119
+ export declare const overrideCustomerEntitlementV2BodyGrantsItemAmountMin = 0;
19120
+ export declare const overrideCustomerEntitlementV2BodyGrantsItemPriorityMax = 255;
19121
+ export declare const overrideCustomerEntitlementV2BodyGrantsItemMinRolloverAmountDefault = 0;
19122
+ export declare const overrideCustomerEntitlementV2BodyGrantsItemExpirationCountMax = 1000;
18999
19123
  export declare const overrideCustomerEntitlementV2BodyFeatureKeyMaxOne = 64;
19000
19124
  export declare const overrideCustomerEntitlementV2BodyFeatureKeyRegExpOne: RegExp;
19001
19125
  export declare const overrideCustomerEntitlementV2BodyFeatureIdRegExpOne: RegExp;
@@ -19005,10 +19129,80 @@ export declare const overrideCustomerEntitlementV2BodyFeatureIdRegExpTwo: RegExp
19005
19129
  export declare const overrideCustomerEntitlementV2Body: zod.ZodUnion<[zod.ZodObject<{
19006
19130
  featureId: zod.ZodOptional<zod.ZodString>;
19007
19131
  featureKey: zod.ZodOptional<zod.ZodString>;
19132
+ grants: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
19133
+ amount: zod.ZodNumber;
19134
+ annotations: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodAny>>;
19135
+ effectiveAt: zod.ZodDate;
19136
+ expiration: zod.ZodOptional<zod.ZodObject<{
19137
+ count: zod.ZodNumber;
19138
+ duration: zod.ZodEnum<["HOUR", "DAY", "WEEK", "MONTH", "YEAR"]>;
19139
+ }, "strip", zod.ZodTypeAny, {
19140
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
19141
+ count: number;
19142
+ }, {
19143
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
19144
+ count: number;
19145
+ }>>;
19146
+ maxRolloverAmount: zod.ZodOptional<zod.ZodNumber>;
19147
+ metadata: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodString>>;
19148
+ minRolloverAmount: zod.ZodOptional<zod.ZodNumber>;
19149
+ priority: zod.ZodOptional<zod.ZodNumber>;
19150
+ recurrence: zod.ZodOptional<zod.ZodObject<{
19151
+ anchor: zod.ZodOptional<zod.ZodDate>;
19152
+ interval: zod.ZodUnion<[zod.ZodString, zod.ZodEnum<["DAY", "WEEK", "MONTH", "YEAR"]>]>;
19153
+ }, "strip", zod.ZodTypeAny, {
19154
+ interval: string;
19155
+ anchor?: Date | undefined;
19156
+ }, {
19157
+ interval: string;
19158
+ anchor?: Date | undefined;
19159
+ }>>;
19160
+ }, "strip", zod.ZodTypeAny, {
19161
+ amount: number;
19162
+ effectiveAt: Date;
19163
+ metadata?: Record<string, string> | undefined;
19164
+ expiration?: {
19165
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
19166
+ count: number;
19167
+ } | undefined;
19168
+ maxRolloverAmount?: number | undefined;
19169
+ minRolloverAmount?: number | undefined;
19170
+ priority?: number | undefined;
19171
+ recurrence?: {
19172
+ interval: string;
19173
+ anchor?: Date | undefined;
19174
+ } | undefined;
19175
+ annotations?: Record<string, any> | undefined;
19176
+ }, {
19177
+ amount: number;
19178
+ effectiveAt: Date;
19179
+ metadata?: Record<string, string> | undefined;
19180
+ expiration?: {
19181
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
19182
+ count: number;
19183
+ } | undefined;
19184
+ maxRolloverAmount?: number | undefined;
19185
+ minRolloverAmount?: number | undefined;
19186
+ priority?: number | undefined;
19187
+ recurrence?: {
19188
+ interval: string;
19189
+ anchor?: Date | undefined;
19190
+ } | undefined;
19191
+ annotations?: Record<string, any> | undefined;
19192
+ }>, "many">>;
19008
19193
  isSoftLimit: zod.ZodOptional<zod.ZodBoolean>;
19194
+ issue: zod.ZodOptional<zod.ZodObject<{
19195
+ amount: zod.ZodNumber;
19196
+ priority: zod.ZodDefault<zod.ZodNumber>;
19197
+ }, "strip", zod.ZodTypeAny, {
19198
+ amount: number;
19199
+ priority: number;
19200
+ }, {
19201
+ amount: number;
19202
+ priority?: number | undefined;
19203
+ }>>;
19009
19204
  issueAfterReset: zod.ZodOptional<zod.ZodNumber>;
19010
19205
  issueAfterResetPriority: zod.ZodDefault<zod.ZodNumber>;
19011
- isUnlimited: zod.ZodOptional<zod.ZodBoolean>;
19012
19206
  measureUsageFrom: zod.ZodOptional<zod.ZodUnion<[zod.ZodEnum<["CURRENT_PERIOD_START", "NOW"]>, zod.ZodDate]>>;
19013
19207
  metadata: zod.ZodOptional<zod.ZodRecord<zod.ZodString, zod.ZodString>>;
19014
19208
  preserveOverageAtReset: zod.ZodOptional<zod.ZodBoolean>;
@@ -19036,8 +19230,28 @@ export declare const overrideCustomerEntitlementV2Body: zod.ZodUnion<[zod.ZodObj
19036
19230
  isSoftLimit?: boolean | undefined;
19037
19231
  issueAfterReset?: number | undefined;
19038
19232
  preserveOverageAtReset?: boolean | undefined;
19039
- isUnlimited?: boolean | undefined;
19040
19233
  measureUsageFrom?: Date | "CURRENT_PERIOD_START" | "NOW" | undefined;
19234
+ grants?: {
19235
+ amount: number;
19236
+ effectiveAt: Date;
19237
+ metadata?: Record<string, string> | undefined;
19238
+ expiration?: {
19239
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
19240
+ count: number;
19241
+ } | undefined;
19242
+ maxRolloverAmount?: number | undefined;
19243
+ minRolloverAmount?: number | undefined;
19244
+ priority?: number | undefined;
19245
+ recurrence?: {
19246
+ interval: string;
19247
+ anchor?: Date | undefined;
19248
+ } | undefined;
19249
+ annotations?: Record<string, any> | undefined;
19250
+ }[] | undefined;
19251
+ issue?: {
19252
+ amount: number;
19253
+ priority: number;
19254
+ } | undefined;
19041
19255
  }, {
19042
19256
  type: "metered";
19043
19257
  usagePeriod: {
@@ -19051,8 +19265,28 @@ export declare const overrideCustomerEntitlementV2Body: zod.ZodUnion<[zod.ZodObj
19051
19265
  issueAfterReset?: number | undefined;
19052
19266
  issueAfterResetPriority?: number | undefined;
19053
19267
  preserveOverageAtReset?: boolean | undefined;
19054
- isUnlimited?: boolean | undefined;
19055
19268
  measureUsageFrom?: Date | "CURRENT_PERIOD_START" | "NOW" | undefined;
19269
+ grants?: {
19270
+ amount: number;
19271
+ effectiveAt: Date;
19272
+ metadata?: Record<string, string> | undefined;
19273
+ expiration?: {
19274
+ duration: "HOUR" | "DAY" | "WEEK" | "MONTH" | "YEAR";
19275
+ count: number;
19276
+ } | undefined;
19277
+ maxRolloverAmount?: number | undefined;
19278
+ minRolloverAmount?: number | undefined;
19279
+ priority?: number | undefined;
19280
+ recurrence?: {
19281
+ interval: string;
19282
+ anchor?: Date | undefined;
19283
+ } | undefined;
19284
+ annotations?: Record<string, any> | undefined;
19285
+ }[] | undefined;
19286
+ issue?: {
19287
+ amount: number;
19288
+ priority?: number | undefined;
19289
+ } | undefined;
19056
19290
  }>, zod.ZodObject<{
19057
19291
  config: zod.ZodString;
19058
19292
  featureId: zod.ZodOptional<zod.ZodString>;