@openmeter/client 1.0.0-beta.237 → 1.0.0-beta.238

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.
@@ -18,11 +18,13 @@ export const numeric = z
18
18
  .string()
19
19
  .regex(new RegExp('^\\-?[0-9]+(\\.[0-9]+)?$'))
20
20
  .describe('Numeric represents an arbitrary precision number.');
21
- export const cursorPaginationQueryPage = z
21
+ export const listEventsPage = z
22
22
  .object({
23
23
  size: z
24
24
  .number()
25
25
  .int()
26
+ .gte(1)
27
+ .lte(100)
26
28
  .optional()
27
29
  .describe('The number of items to include per page.'),
28
30
  after: z
@@ -34,7 +36,7 @@ export const cursorPaginationQueryPage = z
34
36
  .optional()
35
37
  .describe('Request the previous page of data, starting with the item before this parameter.'),
36
38
  })
37
- .describe('Determines which page of the collection to retrieve.');
39
+ .describe('Determines which page of the metering event list to retrieve. A page holds at most 100 events.');
38
40
  export const stringFieldFilter = z
39
41
  .union([
40
42
  z.string(),
@@ -493,6 +495,25 @@ export const validationIssueSeverity = z
493
495
  export const creditGrantVoidPaymentAdjustment = z
494
496
  .enum(['none'])
495
497
  .describe('Describes how voiding a credit grant adjusts related payment state. - `none`: Voiding does not adjust invoices, payment authorization, settlement, payment intents, or external collection state.');
498
+ export const cursorPaginationQueryPage = z
499
+ .object({
500
+ size: z
501
+ .number()
502
+ .int()
503
+ .gte(1)
504
+ .lte(1000)
505
+ .optional()
506
+ .describe('The number of items to include per page.'),
507
+ after: z
508
+ .string()
509
+ .optional()
510
+ .describe('Request the next page of data, starting with the item after this parameter.'),
511
+ before: z
512
+ .string()
513
+ .optional()
514
+ .describe('Request the previous page of data, starting with the item before this parameter.'),
515
+ })
516
+ .describe('Determines which page of the collection to retrieve.');
496
517
  export const creditTransactionType = z
497
518
  .enum(['funded', 'consumed', 'correction', 'expired', 'voided'])
498
519
  .describe('The type of the credit transaction. - `funded`: Credit granted and available for consumption. - `consumed`: Credit consumed by usage or fees. - `correction`: A balance adjustment reversing previously recorded usage. - `expired`: Credit removed because it expired before being used. - `voided`: Credit removed because the grant was voided before being used.');
@@ -506,7 +527,7 @@ export const chargesExpand = z
506
527
  'realization.totals',
507
528
  'realization.detailed_lines',
508
529
  ])
509
- .describe("Expands for customer charges. Values: - `real_time_usage`: The charge's real-time usage; it sets the `usage` and the `totals.realtime` fields, and fills the `outstanding` realization's `usage` with the not-yet-booked remainder of the live read. - `customer`: The complete customer entity of the charge. - `feature`: The complete feature entity of the charge. - `subscription`: The complete subscription of the charge, when present. - `realization.invoice`: The invoice header of each realization (the invoice entity without its `lines` and `customer` snapshot), in place of the ID reference. - `realization.totals`: The `totals` of each realization run, including credit allocations. - `realization.detailed_lines`: The `detailed_lines` of each realization run.");
530
+ .describe("Expands for customer charges. Values: - `real_time_usage`: Sets `usage` and `totals.realtime` for active usage-based charges and created usage-based charges whose effective service period contains the current time (inclusive start, exclusive end). Deleted charges are skipped. When present, the `outstanding` realization's `usage` shows the unbooked remainder of the live read. - `customer`: The complete customer entity of the charge. - `feature`: The complete feature entity of the charge. - `subscription`: The complete subscription of the charge, when present. - `realization.invoice`: The invoice header of each realization (the invoice entity without its `lines` and `customer` snapshot), in place of the ID reference. - `realization.totals`: The `totals` of each realization run, including credit allocations. - `realization.detailed_lines`: The `detailed_lines` of each realization run.");
510
531
  export const lifecycleController = z
511
532
  .enum(['system', 'manual'])
512
533
  .describe('Identifies whether a resource lifecycle is controlled by OpenMeter or manually overridden by the API user. Values: - `system`: The resource lifecycle is controlled by OpenMeter. - `manual`: The resource lifecycle was manually overridden by the API user.');
@@ -876,6 +897,25 @@ export const addonInstanceType = z
876
897
  export const addonStatus = z
877
898
  .enum(['draft', 'active', 'archived'])
878
899
  .describe('The status of the add-on defined by the `effective_from` and `effective_to` properties. - `draft`: The add-on has not yet been published and can be edited. - `active`: The add-on is published and available for use. - `archived`: The add-on is no longer available for use.');
900
+ export const entitlementAccessQueryPage = z
901
+ .object({
902
+ size: z
903
+ .number()
904
+ .int()
905
+ .gte(1)
906
+ .lte(100)
907
+ .optional()
908
+ .describe('The number of items to include per page.'),
909
+ after: z
910
+ .string()
911
+ .optional()
912
+ .describe('Request the next page of data, starting with the item after this parameter.'),
913
+ before: z
914
+ .string()
915
+ .optional()
916
+ .describe('Request the previous page of data, starting with the item before this parameter.'),
917
+ })
918
+ .describe('Determines which page of the entitlement access query to retrieve. A page holds at most 100 customers.');
879
919
  export const entitlementAccessQueryRequestCustomers = z
880
920
  .object({
881
921
  keys: z
@@ -1472,9 +1512,11 @@ export const pagePaginationQuery = z
1472
1512
  size: z
1473
1513
  .number()
1474
1514
  .int()
1515
+ .gte(1)
1516
+ .lte(1000)
1475
1517
  .optional()
1476
1518
  .describe('The number of items to include per page.'),
1477
- number: z.number().int().optional().describe('The page number.'),
1519
+ number: z.number().int().gte(1).optional().describe('The page number.'),
1478
1520
  })
1479
1521
  .optional()
1480
1522
  .describe('Determines which page of the collection to retrieve.'),
@@ -1926,11 +1968,11 @@ export const queryFilterNumeric = z
1926
1968
  },
1927
1969
  })
1928
1970
  .describe('A query filter for a numeric attribute. Operators are mutually exclusive, only one operator is allowed at a time.');
1929
- export const cursorPaginationQuery = z
1971
+ export const listEventsPagination = z
1930
1972
  .object({
1931
- page: cursorPaginationQueryPage.optional(),
1973
+ page: listEventsPage.optional(),
1932
1974
  })
1933
- .describe('Cursor page query.');
1975
+ .describe('Cursor pagination for the metering event list, with a smaller page size limit than the common one.');
1934
1976
  export const listMetersParamsFilter = z
1935
1977
  .object({
1936
1978
  key: stringFieldFilter.optional(),
@@ -2855,6 +2897,11 @@ export const voidCreditGrantRequest = z
2855
2897
  .default('none'),
2856
2898
  })
2857
2899
  .describe('Request body for voiding a credit grant.');
2900
+ export const cursorPaginationQuery = z
2901
+ .object({
2902
+ page: cursorPaginationQueryPage.optional(),
2903
+ })
2904
+ .describe('Cursor page query.');
2858
2905
  export const subscriptionProRatingConfig = z
2859
2906
  .object({
2860
2907
  enabled: z.boolean().describe('Whether pro-rating is enabled.'),
@@ -3090,6 +3137,11 @@ export const listCurrenciesParamsFilter = z
3090
3137
  code: stringFieldFilter.optional(),
3091
3138
  })
3092
3139
  .describe('Filter options for listing currencies.');
3140
+ export const entitlementAccessQueryPagination = z
3141
+ .object({
3142
+ page: entitlementAccessQueryPage.optional(),
3143
+ })
3144
+ .describe('Cursor pagination for the entitlement access query, with a smaller page size limit than the common one.');
3093
3145
  export const entitlementAccessQueryRequest = z
3094
3146
  .object({
3095
3147
  includeCredits: z
@@ -4174,6 +4226,7 @@ export const listChargesParamsFilter = z
4174
4226
  servicePeriodFrom: dateTimeFieldFilter.optional(),
4175
4227
  servicePeriodTo: dateTimeFieldFilter.optional(),
4176
4228
  customerId: ulidFieldFilter.optional(),
4229
+ subscriptionId: ulidFieldFilter.optional(),
4177
4230
  })
4178
4231
  .describe('Filter options for listing charges across customers.');
4179
4232
  export const listNotificationChannelsParamsFilter = z
@@ -4730,6 +4783,7 @@ export const subscriptionBase = z
4730
4783
  billingCadence: iso8601Duration,
4731
4784
  proRatingConfig: subscriptionProRatingConfig.optional(),
4732
4785
  billingAnchor: dateTime,
4786
+ billingStartsAt: dateTime.optional(),
4733
4787
  status: subscriptionStatus,
4734
4788
  settlementMode: settlementMode.optional(),
4735
4789
  })
@@ -7443,6 +7497,7 @@ export const subscription = z
7443
7497
  billingCadence: iso8601Duration,
7444
7498
  proRatingConfig: subscriptionProRatingConfig.optional(),
7445
7499
  billingAnchor: dateTime,
7500
+ billingStartsAt: dateTime.optional(),
7446
7501
  status: subscriptionStatus,
7447
7502
  settlementMode: settlementMode.optional(),
7448
7503
  currentPeriod: closedPeriod.optional(),
@@ -7453,6 +7508,7 @@ export const subscription = z
7453
7508
  .describe('Subscription.');
7454
7509
  export const subscriptionCreate = z.object({
7455
7510
  labels: labels.optional(),
7511
+ billingStartsAt: dateTime.optional(),
7456
7512
  settlementMode: settlementMode.optional(),
7457
7513
  customer: z
7458
7514
  .object({
@@ -8023,7 +8079,7 @@ export const notificationEventPagePaginatedResponse = z
8023
8079
  })
8024
8080
  .describe('Page paginated response.');
8025
8081
  export const listMeteringEventsQueryParams = z.object({
8026
- page: cursorPaginationQueryPage.optional(),
8082
+ page: listEventsPage.optional(),
8027
8083
  filter: listEventsParamsFilter.optional(),
8028
8084
  sort: sortQuery.optional(),
8029
8085
  });
@@ -8044,9 +8100,16 @@ export const listMetersQueryParams = z.object({
8044
8100
  size: z.coerce
8045
8101
  .number()
8046
8102
  .int()
8103
+ .gte(1)
8104
+ .lte(1000)
8047
8105
  .optional()
8048
8106
  .describe('The number of items to include per page.'),
8049
- number: z.coerce.number().int().optional().describe('The page number.'),
8107
+ number: z.coerce
8108
+ .number()
8109
+ .int()
8110
+ .gte(1)
8111
+ .optional()
8112
+ .describe('The page number.'),
8050
8113
  })
8051
8114
  .optional()
8052
8115
  .describe('Determines which page of the collection to retrieve.'),
@@ -8087,9 +8150,16 @@ export const listCustomersQueryParams = z.object({
8087
8150
  size: z.coerce
8088
8151
  .number()
8089
8152
  .int()
8153
+ .gte(1)
8154
+ .lte(1000)
8090
8155
  .optional()
8091
8156
  .describe('The number of items to include per page.'),
8092
- number: z.coerce.number().int().optional().describe('The page number.'),
8157
+ number: z.coerce
8158
+ .number()
8159
+ .int()
8160
+ .gte(1)
8161
+ .optional()
8162
+ .describe('The page number.'),
8093
8163
  })
8094
8164
  .optional()
8095
8165
  .describe('Determines which page of the collection to retrieve.'),
@@ -8198,9 +8268,16 @@ export const listCustomerEntitlementsQueryParams = z.object({
8198
8268
  size: z.coerce
8199
8269
  .number()
8200
8270
  .int()
8271
+ .gte(1)
8272
+ .lte(1000)
8201
8273
  .optional()
8202
8274
  .describe('The number of items to include per page.'),
8203
- number: z.coerce.number().int().optional().describe('The page number.'),
8275
+ number: z.coerce
8276
+ .number()
8277
+ .int()
8278
+ .gte(1)
8279
+ .optional()
8280
+ .describe('The page number.'),
8204
8281
  })
8205
8282
  .optional()
8206
8283
  .describe('Determines which page of the collection to retrieve.'),
@@ -8226,9 +8303,16 @@ export const listEntitlementsQueryParams = z.object({
8226
8303
  size: z.coerce
8227
8304
  .number()
8228
8305
  .int()
8306
+ .gte(1)
8307
+ .lte(1000)
8229
8308
  .optional()
8230
8309
  .describe('The number of items to include per page.'),
8231
- number: z.coerce.number().int().optional().describe('The page number.'),
8310
+ number: z.coerce
8311
+ .number()
8312
+ .int()
8313
+ .gte(1)
8314
+ .optional()
8315
+ .describe('The page number.'),
8232
8316
  })
8233
8317
  .optional()
8234
8318
  .describe('Determines which page of the collection to retrieve.'),
@@ -8259,9 +8343,16 @@ export const listCustomerEntitlementGrantsQueryParams = z.object({
8259
8343
  size: z.coerce
8260
8344
  .number()
8261
8345
  .int()
8346
+ .gte(1)
8347
+ .lte(1000)
8262
8348
  .optional()
8263
8349
  .describe('The number of items to include per page.'),
8264
- number: z.coerce.number().int().optional().describe('The page number.'),
8350
+ number: z.coerce
8351
+ .number()
8352
+ .int()
8353
+ .gte(1)
8354
+ .optional()
8355
+ .describe('The page number.'),
8265
8356
  })
8266
8357
  .optional()
8267
8358
  .describe('Determines which page of the collection to retrieve.'),
@@ -8293,9 +8384,16 @@ export const listGrantsQueryParams = z.object({
8293
8384
  size: z.coerce
8294
8385
  .number()
8295
8386
  .int()
8387
+ .gte(1)
8388
+ .lte(1000)
8296
8389
  .optional()
8297
8390
  .describe('The number of items to include per page.'),
8298
- number: z.coerce.number().int().optional().describe('The page number.'),
8391
+ number: z.coerce
8392
+ .number()
8393
+ .int()
8394
+ .gte(1)
8395
+ .optional()
8396
+ .describe('The page number.'),
8299
8397
  })
8300
8398
  .optional()
8301
8399
  .describe('Determines which page of the collection to retrieve.'),
@@ -8335,9 +8433,16 @@ export const listCreditGrantsQueryParams = z.object({
8335
8433
  size: z.coerce
8336
8434
  .number()
8337
8435
  .int()
8436
+ .gte(1)
8437
+ .lte(1000)
8338
8438
  .optional()
8339
8439
  .describe('The number of items to include per page.'),
8340
- number: z.coerce.number().int().optional().describe('The page number.'),
8440
+ number: z.coerce
8441
+ .number()
8442
+ .int()
8443
+ .gte(1)
8444
+ .optional()
8445
+ .describe('The page number.'),
8341
8446
  })
8342
8447
  .optional()
8343
8448
  .describe('Determines which page of the collection to retrieve.'),
@@ -8393,9 +8498,16 @@ export const listCustomerChargesQueryParams = z.object({
8393
8498
  size: z.coerce
8394
8499
  .number()
8395
8500
  .int()
8501
+ .gte(1)
8502
+ .lte(1000)
8396
8503
  .optional()
8397
8504
  .describe('The number of items to include per page.'),
8398
- number: z.coerce.number().int().optional().describe('The page number.'),
8505
+ number: z.coerce
8506
+ .number()
8507
+ .int()
8508
+ .gte(1)
8509
+ .optional()
8510
+ .describe('The page number.'),
8399
8511
  })
8400
8512
  .optional()
8401
8513
  .describe('Determines which page of the collection to retrieve.'),
@@ -8404,7 +8516,7 @@ export const listCustomerChargesQueryParams = z.object({
8404
8516
  expand: z
8405
8517
  .array(chargesExpand)
8406
8518
  .optional()
8407
- .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Expand the charge's real-time usage; it sets the `usage` and the `totals.realtime` fields. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
8519
+ .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Set `usage` and `totals.realtime` for active usage-based charges and created usage-based charges whose effective service period contains the current time (inclusive start, exclusive end). Deleted charges are skipped. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
8408
8520
  });
8409
8521
  export const listCustomerChargesResponse = z.object({
8410
8522
  data: z.array(charge),
@@ -8428,9 +8540,16 @@ export const listSubscriptionsQueryParams = z.object({
8428
8540
  size: z.coerce
8429
8541
  .number()
8430
8542
  .int()
8543
+ .gte(1)
8544
+ .lte(1000)
8431
8545
  .optional()
8432
8546
  .describe('The number of items to include per page.'),
8433
- number: z.coerce.number().int().optional().describe('The page number.'),
8547
+ number: z.coerce
8548
+ .number()
8549
+ .int()
8550
+ .gte(1)
8551
+ .optional()
8552
+ .describe('The page number.'),
8434
8553
  })
8435
8554
  .optional()
8436
8555
  .describe('Determines which page of the collection to retrieve.'),
@@ -8490,9 +8609,16 @@ export const listSubscriptionAddonsQueryParams = z.object({
8490
8609
  size: z.coerce
8491
8610
  .number()
8492
8611
  .int()
8612
+ .gte(1)
8613
+ .lte(1000)
8493
8614
  .optional()
8494
8615
  .describe('The number of items to include per page.'),
8495
- number: z.coerce.number().int().optional().describe('The page number.'),
8616
+ number: z.coerce
8617
+ .number()
8618
+ .int()
8619
+ .gte(1)
8620
+ .optional()
8621
+ .describe('The page number.'),
8496
8622
  })
8497
8623
  .optional()
8498
8624
  .describe('Determines which page of the collection to retrieve.'),
@@ -8519,9 +8645,16 @@ export const listAppsQueryParams = z.object({
8519
8645
  size: z.coerce
8520
8646
  .number()
8521
8647
  .int()
8648
+ .gte(1)
8649
+ .lte(1000)
8522
8650
  .optional()
8523
8651
  .describe('The number of items to include per page.'),
8524
- number: z.coerce.number().int().optional().describe('The page number.'),
8652
+ number: z.coerce
8653
+ .number()
8654
+ .int()
8655
+ .gte(1)
8656
+ .optional()
8657
+ .describe('The page number.'),
8525
8658
  })
8526
8659
  .optional()
8527
8660
  .describe('Determines which page of the collection to retrieve.'),
@@ -8555,9 +8688,16 @@ export const listAppCatalogQueryParams = z.object({
8555
8688
  size: z.coerce
8556
8689
  .number()
8557
8690
  .int()
8691
+ .gte(1)
8692
+ .lte(1000)
8558
8693
  .optional()
8559
8694
  .describe('The number of items to include per page.'),
8560
- number: z.coerce.number().int().optional().describe('The page number.'),
8695
+ number: z.coerce
8696
+ .number()
8697
+ .int()
8698
+ .gte(1)
8699
+ .optional()
8700
+ .describe('The page number.'),
8561
8701
  })
8562
8702
  .optional()
8563
8703
  .describe('Determines which page of the collection to retrieve.'),
@@ -8578,9 +8718,16 @@ export const listBillingProfilesQueryParams = z.object({
8578
8718
  size: z.coerce
8579
8719
  .number()
8580
8720
  .int()
8721
+ .gte(1)
8722
+ .lte(1000)
8581
8723
  .optional()
8582
8724
  .describe('The number of items to include per page.'),
8583
- number: z.coerce.number().int().optional().describe('The page number.'),
8725
+ number: z.coerce
8726
+ .number()
8727
+ .int()
8728
+ .gte(1)
8729
+ .optional()
8730
+ .describe('The page number.'),
8584
8731
  })
8585
8732
  .optional()
8586
8733
  .describe('Determines which page of the collection to retrieve.'),
@@ -8611,9 +8758,16 @@ export const listInvoicesQueryParams = z.object({
8611
8758
  size: z.coerce
8612
8759
  .number()
8613
8760
  .int()
8761
+ .gte(1)
8762
+ .lte(1000)
8614
8763
  .optional()
8615
8764
  .describe('The number of items to include per page.'),
8616
- number: z.coerce.number().int().optional().describe('The page number.'),
8765
+ number: z.coerce
8766
+ .number()
8767
+ .int()
8768
+ .gte(1)
8769
+ .optional()
8770
+ .describe('The page number.'),
8617
8771
  })
8618
8772
  .optional()
8619
8773
  .describe('Determines which page of the collection to retrieve.'),
@@ -8652,15 +8806,32 @@ export const snapshotQuantitiesInvoicePathParams = z.object({
8652
8806
  invoiceId: ulid,
8653
8807
  });
8654
8808
  export const snapshotQuantitiesInvoiceResponse = invoice;
8809
+ export const getChargePathParams = z.object({
8810
+ chargeId: ulid,
8811
+ });
8812
+ export const getChargeQueryParams = z.object({
8813
+ expand: z
8814
+ .array(chargesExpand)
8815
+ .optional()
8816
+ .describe('Expand related entities, realization details, or real-time usage.'),
8817
+ });
8818
+ export const getChargeResponse = charge;
8655
8819
  export const listChargesQueryParams = z.object({
8656
8820
  page: z
8657
8821
  .object({
8658
8822
  size: z.coerce
8659
8823
  .number()
8660
8824
  .int()
8825
+ .gte(1)
8826
+ .lte(1000)
8661
8827
  .optional()
8662
8828
  .describe('The number of items to include per page.'),
8663
- number: z.coerce.number().int().optional().describe('The page number.'),
8829
+ number: z.coerce
8830
+ .number()
8831
+ .int()
8832
+ .gte(1)
8833
+ .optional()
8834
+ .describe('The page number.'),
8664
8835
  })
8665
8836
  .optional()
8666
8837
  .describe('Determines which page of the collection to retrieve.'),
@@ -8669,7 +8840,7 @@ export const listChargesQueryParams = z.object({
8669
8840
  expand: z
8670
8841
  .array(chargesExpand)
8671
8842
  .optional()
8672
- .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Expand the charge's real-time usage; it sets the `usage` and the `totals.realtime` fields. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
8843
+ .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Set `usage` and `totals.realtime` for active usage-based charges and created usage-based charges whose effective service period contains the current time (inclusive start, exclusive end). Deleted charges are skipped. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
8673
8844
  });
8674
8845
  export const listChargesResponse = z.object({
8675
8846
  data: z.array(charge),
@@ -8687,9 +8858,16 @@ export const listTaxCodesQueryParams = z.object({
8687
8858
  size: z.coerce
8688
8859
  .number()
8689
8860
  .int()
8861
+ .gte(1)
8862
+ .lte(1000)
8690
8863
  .optional()
8691
8864
  .describe('The number of items to include per page.'),
8692
- number: z.coerce.number().int().optional().describe('The page number.'),
8865
+ number: z.coerce
8866
+ .number()
8867
+ .int()
8868
+ .gte(1)
8869
+ .optional()
8870
+ .describe('The page number.'),
8693
8871
  })
8694
8872
  .optional()
8695
8873
  .describe('Determines which page of the collection to retrieve.'),
@@ -8716,9 +8894,16 @@ export const listCurrenciesQueryParams = z.object({
8716
8894
  size: z.coerce
8717
8895
  .number()
8718
8896
  .int()
8897
+ .gte(1)
8898
+ .lte(1000)
8719
8899
  .optional()
8720
8900
  .describe('The number of items to include per page.'),
8721
- number: z.coerce.number().int().optional().describe('The page number.'),
8901
+ number: z.coerce
8902
+ .number()
8903
+ .int()
8904
+ .gte(1)
8905
+ .optional()
8906
+ .describe('The page number.'),
8722
8907
  })
8723
8908
  .optional()
8724
8909
  .describe('Determines which page of the collection to retrieve.'),
@@ -8749,9 +8934,16 @@ export const listCostBasesQueryParams = z.object({
8749
8934
  size: z.coerce
8750
8935
  .number()
8751
8936
  .int()
8937
+ .gte(1)
8938
+ .lte(1000)
8752
8939
  .optional()
8753
8940
  .describe('The number of items to include per page.'),
8754
- number: z.coerce.number().int().optional().describe('The page number.'),
8941
+ number: z.coerce
8942
+ .number()
8943
+ .int()
8944
+ .gte(1)
8945
+ .optional()
8946
+ .describe('The page number.'),
8755
8947
  })
8756
8948
  .optional()
8757
8949
  .describe('Determines which page of the collection to retrieve.'),
@@ -8771,9 +8963,16 @@ export const listFeaturesQueryParams = z.object({
8771
8963
  size: z.coerce
8772
8964
  .number()
8773
8965
  .int()
8966
+ .gte(1)
8967
+ .lte(1000)
8774
8968
  .optional()
8775
8969
  .describe('The number of items to include per page.'),
8776
- number: z.coerce.number().int().optional().describe('The page number.'),
8970
+ number: z.coerce
8971
+ .number()
8972
+ .int()
8973
+ .gte(1)
8974
+ .optional()
8975
+ .describe('The page number.'),
8777
8976
  })
8778
8977
  .optional()
8779
8978
  .describe('Determines which page of the collection to retrieve.'),
@@ -8811,9 +9010,16 @@ export const listLlmCostPricesQueryParams = z.object({
8811
9010
  size: z.coerce
8812
9011
  .number()
8813
9012
  .int()
9013
+ .gte(1)
9014
+ .lte(1000)
8814
9015
  .optional()
8815
9016
  .describe('The number of items to include per page.'),
8816
- number: z.coerce.number().int().optional().describe('The page number.'),
9017
+ number: z.coerce
9018
+ .number()
9019
+ .int()
9020
+ .gte(1)
9021
+ .optional()
9022
+ .describe('The page number.'),
8817
9023
  })
8818
9024
  .optional()
8819
9025
  .describe('Determines which page of the collection to retrieve.'),
@@ -8833,9 +9039,16 @@ export const listLlmCostOverridesQueryParams = z.object({
8833
9039
  size: z.coerce
8834
9040
  .number()
8835
9041
  .int()
9042
+ .gte(1)
9043
+ .lte(1000)
8836
9044
  .optional()
8837
9045
  .describe('The number of items to include per page.'),
8838
- number: z.coerce.number().int().optional().describe('The page number.'),
9046
+ number: z.coerce
9047
+ .number()
9048
+ .int()
9049
+ .gte(1)
9050
+ .optional()
9051
+ .describe('The page number.'),
8839
9052
  })
8840
9053
  .optional()
8841
9054
  .describe('Determines which page of the collection to retrieve.'),
@@ -8855,9 +9068,16 @@ export const listPlansQueryParams = z.object({
8855
9068
  size: z.coerce
8856
9069
  .number()
8857
9070
  .int()
9071
+ .gte(1)
9072
+ .lte(1000)
8858
9073
  .optional()
8859
9074
  .describe('The number of items to include per page.'),
8860
- number: z.coerce.number().int().optional().describe('The page number.'),
9075
+ number: z.coerce
9076
+ .number()
9077
+ .int()
9078
+ .gte(1)
9079
+ .optional()
9080
+ .describe('The page number.'),
8861
9081
  })
8862
9082
  .optional()
8863
9083
  .describe('Determines which page of the collection to retrieve.'),
@@ -8896,9 +9116,16 @@ export const listAddonsQueryParams = z.object({
8896
9116
  size: z.coerce
8897
9117
  .number()
8898
9118
  .int()
9119
+ .gte(1)
9120
+ .lte(1000)
8899
9121
  .optional()
8900
9122
  .describe('The number of items to include per page.'),
8901
- number: z.coerce.number().int().optional().describe('The page number.'),
9123
+ number: z.coerce
9124
+ .number()
9125
+ .int()
9126
+ .gte(1)
9127
+ .optional()
9128
+ .describe('The page number.'),
8902
9129
  })
8903
9130
  .optional()
8904
9131
  .describe('Determines which page of the collection to retrieve.'),
@@ -8940,9 +9167,16 @@ export const listPlanAddonsQueryParams = z.object({
8940
9167
  size: z.coerce
8941
9168
  .number()
8942
9169
  .int()
9170
+ .gte(1)
9171
+ .lte(1000)
8943
9172
  .optional()
8944
9173
  .describe('The number of items to include per page.'),
8945
- number: z.coerce.number().int().optional().describe('The page number.'),
9174
+ number: z.coerce
9175
+ .number()
9176
+ .int()
9177
+ .gte(1)
9178
+ .optional()
9179
+ .describe('The page number.'),
8946
9180
  })
8947
9181
  .optional()
8948
9182
  .describe('Determines which page of the collection to retrieve.'),
@@ -8977,7 +9211,7 @@ export const getOrganizationDefaultTaxCodesResponse = organizationDefaultTaxCode
8977
9211
  export const updateOrganizationDefaultTaxCodesBody = updateOrganizationDefaultTaxCodesRequest;
8978
9212
  export const updateOrganizationDefaultTaxCodesResponse = organizationDefaultTaxCodes;
8979
9213
  export const queryEntitlementAccessQueryParams = z.object({
8980
- page: cursorPaginationQueryPage.optional(),
9214
+ page: entitlementAccessQueryPage.optional(),
8981
9215
  });
8982
9216
  export const queryEntitlementAccessBody = entitlementAccessQueryRequest;
8983
9217
  export const queryEntitlementAccessResponse = entitlementAccessQueryResponse;
@@ -8987,9 +9221,16 @@ export const listBillingNotificationChannelsQueryParams = z.object({
8987
9221
  size: z.coerce
8988
9222
  .number()
8989
9223
  .int()
9224
+ .gte(1)
9225
+ .lte(1000)
8990
9226
  .optional()
8991
9227
  .describe('The number of items to include per page.'),
8992
- number: z.coerce.number().int().optional().describe('The page number.'),
9228
+ number: z.coerce
9229
+ .number()
9230
+ .int()
9231
+ .gte(1)
9232
+ .optional()
9233
+ .describe('The page number.'),
8993
9234
  })
8994
9235
  .optional()
8995
9236
  .describe('Determines which page of the collection to retrieve.'),
@@ -9020,9 +9261,16 @@ export const listBillingNotificationRulesQueryParams = z.object({
9020
9261
  size: z.coerce
9021
9262
  .number()
9022
9263
  .int()
9264
+ .gte(1)
9265
+ .lte(1000)
9023
9266
  .optional()
9024
9267
  .describe('The number of items to include per page.'),
9025
- number: z.coerce.number().int().optional().describe('The page number.'),
9268
+ number: z.coerce
9269
+ .number()
9270
+ .int()
9271
+ .gte(1)
9272
+ .optional()
9273
+ .describe('The page number.'),
9026
9274
  })
9027
9275
  .optional()
9028
9276
  .describe('Determines which page of the collection to retrieve.'),
@@ -9057,9 +9305,16 @@ export const listBillingNotificationEventsQueryParams = z.object({
9057
9305
  size: z.coerce
9058
9306
  .number()
9059
9307
  .int()
9308
+ .gte(1)
9309
+ .lte(1000)
9060
9310
  .optional()
9061
9311
  .describe('The number of items to include per page.'),
9062
- number: z.coerce.number().int().optional().describe('The page number.'),
9312
+ number: z.coerce
9313
+ .number()
9314
+ .int()
9315
+ .gte(1)
9316
+ .optional()
9317
+ .describe('The page number.'),
9063
9318
  })
9064
9319
  .optional()
9065
9320
  .describe('Determines which page of the collection to retrieve.'),
@@ -9096,11 +9351,13 @@ export const numericWire = z
9096
9351
  .string()
9097
9352
  .regex(new RegExp('^\\-?[0-9]+(\\.[0-9]+)?$'))
9098
9353
  .describe('Numeric represents an arbitrary precision number.');
9099
- export const cursorPaginationQueryPageWire = z
9354
+ export const listEventsPageWire = z
9100
9355
  .strictObject({
9101
9356
  size: z
9102
9357
  .number()
9103
9358
  .int()
9359
+ .gte(1)
9360
+ .lte(100)
9104
9361
  .optional()
9105
9362
  .describe('The number of items to include per page.'),
9106
9363
  after: z
@@ -9112,7 +9369,7 @@ export const cursorPaginationQueryPageWire = z
9112
9369
  .optional()
9113
9370
  .describe('Request the previous page of data, starting with the item before this parameter.'),
9114
9371
  })
9115
- .describe('Determines which page of the collection to retrieve.');
9372
+ .describe('Determines which page of the metering event list to retrieve. A page holds at most 100 events.');
9116
9373
  export const stringFieldFilterWire = z
9117
9374
  .union([
9118
9375
  z.string(),
@@ -9570,6 +9827,25 @@ export const validationIssueSeverityWire = z
9570
9827
  export const creditGrantVoidPaymentAdjustmentWire = z
9571
9828
  .enum(['none'])
9572
9829
  .describe('Describes how voiding a credit grant adjusts related payment state. - `none`: Voiding does not adjust invoices, payment authorization, settlement, payment intents, or external collection state.');
9830
+ export const cursorPaginationQueryPageWire = z
9831
+ .strictObject({
9832
+ size: z
9833
+ .number()
9834
+ .int()
9835
+ .gte(1)
9836
+ .lte(1000)
9837
+ .optional()
9838
+ .describe('The number of items to include per page.'),
9839
+ after: z
9840
+ .string()
9841
+ .optional()
9842
+ .describe('Request the next page of data, starting with the item after this parameter.'),
9843
+ before: z
9844
+ .string()
9845
+ .optional()
9846
+ .describe('Request the previous page of data, starting with the item before this parameter.'),
9847
+ })
9848
+ .describe('Determines which page of the collection to retrieve.');
9573
9849
  export const creditTransactionTypeWire = z
9574
9850
  .enum(['funded', 'consumed', 'correction', 'expired', 'voided'])
9575
9851
  .describe('The type of the credit transaction. - `funded`: Credit granted and available for consumption. - `consumed`: Credit consumed by usage or fees. - `correction`: A balance adjustment reversing previously recorded usage. - `expired`: Credit removed because it expired before being used. - `voided`: Credit removed because the grant was voided before being used.');
@@ -9583,7 +9859,7 @@ export const chargesExpandWire = z
9583
9859
  'realization.totals',
9584
9860
  'realization.detailed_lines',
9585
9861
  ])
9586
- .describe("Expands for customer charges. Values: - `real_time_usage`: The charge's real-time usage; it sets the `usage` and the `totals.realtime` fields, and fills the `outstanding` realization's `usage` with the not-yet-booked remainder of the live read. - `customer`: The complete customer entity of the charge. - `feature`: The complete feature entity of the charge. - `subscription`: The complete subscription of the charge, when present. - `realization.invoice`: The invoice header of each realization (the invoice entity without its `lines` and `customer` snapshot), in place of the ID reference. - `realization.totals`: The `totals` of each realization run, including credit allocations. - `realization.detailed_lines`: The `detailed_lines` of each realization run.");
9862
+ .describe("Expands for customer charges. Values: - `real_time_usage`: Sets `usage` and `totals.realtime` for active usage-based charges and created usage-based charges whose effective service period contains the current time (inclusive start, exclusive end). Deleted charges are skipped. When present, the `outstanding` realization's `usage` shows the unbooked remainder of the live read. - `customer`: The complete customer entity of the charge. - `feature`: The complete feature entity of the charge. - `subscription`: The complete subscription of the charge, when present. - `realization.invoice`: The invoice header of each realization (the invoice entity without its `lines` and `customer` snapshot), in place of the ID reference. - `realization.totals`: The `totals` of each realization run, including credit allocations. - `realization.detailed_lines`: The `detailed_lines` of each realization run.");
9587
9863
  export const lifecycleControllerWire = z
9588
9864
  .enum(['system', 'manual'])
9589
9865
  .describe('Identifies whether a resource lifecycle is controlled by OpenMeter or manually overridden by the API user. Values: - `system`: The resource lifecycle is controlled by OpenMeter. - `manual`: The resource lifecycle was manually overridden by the API user.');
@@ -9947,6 +10223,25 @@ export const addonInstanceTypeWire = z
9947
10223
  export const addonStatusWire = z
9948
10224
  .enum(['draft', 'active', 'archived'])
9949
10225
  .describe('The status of the add-on defined by the `effective_from` and `effective_to` properties. - `draft`: The add-on has not yet been published and can be edited. - `active`: The add-on is published and available for use. - `archived`: The add-on is no longer available for use.');
10226
+ export const entitlementAccessQueryPageWire = z
10227
+ .strictObject({
10228
+ size: z
10229
+ .number()
10230
+ .int()
10231
+ .gte(1)
10232
+ .lte(100)
10233
+ .optional()
10234
+ .describe('The number of items to include per page.'),
10235
+ after: z
10236
+ .string()
10237
+ .optional()
10238
+ .describe('Request the next page of data, starting with the item after this parameter.'),
10239
+ before: z
10240
+ .string()
10241
+ .optional()
10242
+ .describe('Request the previous page of data, starting with the item before this parameter.'),
10243
+ })
10244
+ .describe('Determines which page of the entitlement access query to retrieve. A page holds at most 100 customers.');
9950
10245
  export const entitlementAccessQueryRequestCustomersWire = z
9951
10246
  .strictObject({
9952
10247
  keys: z
@@ -10550,9 +10845,11 @@ export const pagePaginationQueryWire = z
10550
10845
  size: z
10551
10846
  .number()
10552
10847
  .int()
10848
+ .gte(1)
10849
+ .lte(1000)
10553
10850
  .optional()
10554
10851
  .describe('The number of items to include per page.'),
10555
- number: z.number().int().optional().describe('The page number.'),
10852
+ number: z.number().int().gte(1).optional().describe('The page number.'),
10556
10853
  })
10557
10854
  .optional()
10558
10855
  .describe('Determines which page of the collection to retrieve.'),
@@ -11003,11 +11300,11 @@ export const queryFilterNumericWire = z
11003
11300
  },
11004
11301
  })
11005
11302
  .describe('A query filter for a numeric attribute. Operators are mutually exclusive, only one operator is allowed at a time.');
11006
- export const cursorPaginationQueryWire = z
11303
+ export const listEventsPaginationWire = z
11007
11304
  .strictObject({
11008
- page: cursorPaginationQueryPageWire.optional(),
11305
+ page: listEventsPageWire.optional(),
11009
11306
  })
11010
- .describe('Cursor page query.');
11307
+ .describe('Cursor pagination for the metering event list, with a smaller page size limit than the common one.');
11011
11308
  export const listMetersParamsFilterWire = z
11012
11309
  .strictObject({
11013
11310
  key: stringFieldFilterWire.optional(),
@@ -11918,6 +12215,11 @@ export const voidCreditGrantRequestWire = z
11918
12215
  payment_adjustment: creditGrantVoidPaymentAdjustmentWire.optional(),
11919
12216
  })
11920
12217
  .describe('Request body for voiding a credit grant.');
12218
+ export const cursorPaginationQueryWire = z
12219
+ .strictObject({
12220
+ page: cursorPaginationQueryPageWire.optional(),
12221
+ })
12222
+ .describe('Cursor page query.');
11921
12223
  export const subscriptionProRatingConfigWire = z
11922
12224
  .strictObject({
11923
12225
  enabled: z.boolean().describe('Whether pro-rating is enabled.'),
@@ -12147,6 +12449,11 @@ export const listCurrenciesParamsFilterWire = z
12147
12449
  code: stringFieldFilterWire.optional(),
12148
12450
  })
12149
12451
  .describe('Filter options for listing currencies.');
12452
+ export const entitlementAccessQueryPaginationWire = z
12453
+ .strictObject({
12454
+ page: entitlementAccessQueryPageWire.optional(),
12455
+ })
12456
+ .describe('Cursor pagination for the entitlement access query, with a smaller page size limit than the common one.');
12150
12457
  export const entitlementAccessQueryRequestWire = z
12151
12458
  .strictObject({
12152
12459
  include_credits: z
@@ -13229,6 +13536,7 @@ export const listChargesParamsFilterWire = z
13229
13536
  service_period_from: dateTimeFieldFilterWire.optional(),
13230
13537
  service_period_to: dateTimeFieldFilterWire.optional(),
13231
13538
  customer_id: ulidFieldFilterWire.optional(),
13539
+ subscription_id: ulidFieldFilterWire.optional(),
13232
13540
  })
13233
13541
  .describe('Filter options for listing charges across customers.');
13234
13542
  export const listNotificationChannelsParamsFilterWire = z
@@ -13782,6 +14090,7 @@ export const subscriptionBaseWire = z
13782
14090
  billing_cadence: iso8601DurationWire,
13783
14091
  pro_rating_config: subscriptionProRatingConfigWire.optional(),
13784
14092
  billing_anchor: dateTimeWire,
14093
+ billing_starts_at: dateTimeWire.optional(),
13785
14094
  status: subscriptionStatusWire,
13786
14095
  settlement_mode: settlementModeWire.optional(),
13787
14096
  })
@@ -16568,6 +16877,7 @@ export const subscriptionWire = z
16568
16877
  billing_cadence: iso8601DurationWire,
16569
16878
  pro_rating_config: subscriptionProRatingConfigWire.optional(),
16570
16879
  billing_anchor: dateTimeWire,
16880
+ billing_starts_at: dateTimeWire.optional(),
16571
16881
  status: subscriptionStatusWire,
16572
16882
  settlement_mode: settlementModeWire.optional(),
16573
16883
  current_period: closedPeriodWire.optional(),
@@ -16578,6 +16888,7 @@ export const subscriptionWire = z
16578
16888
  .describe('Subscription.');
16579
16889
  export const subscriptionCreateWire = z.strictObject({
16580
16890
  labels: labelsWire.optional(),
16891
+ billing_starts_at: dateTimeWire.optional(),
16581
16892
  settlement_mode: settlementModeWire.optional(),
16582
16893
  customer: z
16583
16894
  .strictObject({
@@ -17184,7 +17495,7 @@ export const notificationEventPagePaginatedResponseWire = z
17184
17495
  })
17185
17496
  .describe('Page paginated response.');
17186
17497
  export const listMeteringEventsQueryParamsWire = z.object({
17187
- page: cursorPaginationQueryPageWire.optional(),
17498
+ page: listEventsPageWire.optional(),
17188
17499
  filter: listEventsParamsFilterWire.optional(),
17189
17500
  sort: z
17190
17501
  .string()
@@ -17211,9 +17522,16 @@ export const listMetersQueryParamsWire = z.object({
17211
17522
  size: z.coerce
17212
17523
  .number()
17213
17524
  .int()
17525
+ .gte(1)
17526
+ .lte(1000)
17214
17527
  .optional()
17215
17528
  .describe('The number of items to include per page.'),
17216
- number: z.coerce.number().int().optional().describe('The page number.'),
17529
+ number: z.coerce
17530
+ .number()
17531
+ .int()
17532
+ .gte(1)
17533
+ .optional()
17534
+ .describe('The page number.'),
17217
17535
  })
17218
17536
  .optional()
17219
17537
  .describe('Determines which page of the collection to retrieve.'),
@@ -17257,9 +17575,16 @@ export const listCustomersQueryParamsWire = z.object({
17257
17575
  size: z.coerce
17258
17576
  .number()
17259
17577
  .int()
17578
+ .gte(1)
17579
+ .lte(1000)
17260
17580
  .optional()
17261
17581
  .describe('The number of items to include per page.'),
17262
- number: z.coerce.number().int().optional().describe('The page number.'),
17582
+ number: z.coerce
17583
+ .number()
17584
+ .int()
17585
+ .gte(1)
17586
+ .optional()
17587
+ .describe('The page number.'),
17263
17588
  })
17264
17589
  .optional()
17265
17590
  .describe('Determines which page of the collection to retrieve.'),
@@ -17370,9 +17695,16 @@ export const listCustomerEntitlementsQueryParamsWire = z.object({
17370
17695
  size: z.coerce
17371
17696
  .number()
17372
17697
  .int()
17698
+ .gte(1)
17699
+ .lte(1000)
17373
17700
  .optional()
17374
17701
  .describe('The number of items to include per page.'),
17375
- number: z.coerce.number().int().optional().describe('The page number.'),
17702
+ number: z.coerce
17703
+ .number()
17704
+ .int()
17705
+ .gte(1)
17706
+ .optional()
17707
+ .describe('The page number.'),
17376
17708
  })
17377
17709
  .optional()
17378
17710
  .describe('Determines which page of the collection to retrieve.'),
@@ -17401,9 +17733,16 @@ export const listEntitlementsQueryParamsWire = z.object({
17401
17733
  size: z.coerce
17402
17734
  .number()
17403
17735
  .int()
17736
+ .gte(1)
17737
+ .lte(1000)
17404
17738
  .optional()
17405
17739
  .describe('The number of items to include per page.'),
17406
- number: z.coerce.number().int().optional().describe('The page number.'),
17740
+ number: z.coerce
17741
+ .number()
17742
+ .int()
17743
+ .gte(1)
17744
+ .optional()
17745
+ .describe('The page number.'),
17407
17746
  })
17408
17747
  .optional()
17409
17748
  .describe('Determines which page of the collection to retrieve.'),
@@ -17437,9 +17776,16 @@ export const listCustomerEntitlementGrantsQueryParamsWire = z.object({
17437
17776
  size: z.coerce
17438
17777
  .number()
17439
17778
  .int()
17779
+ .gte(1)
17780
+ .lte(1000)
17440
17781
  .optional()
17441
17782
  .describe('The number of items to include per page.'),
17442
- number: z.coerce.number().int().optional().describe('The page number.'),
17783
+ number: z.coerce
17784
+ .number()
17785
+ .int()
17786
+ .gte(1)
17787
+ .optional()
17788
+ .describe('The page number.'),
17443
17789
  })
17444
17790
  .optional()
17445
17791
  .describe('Determines which page of the collection to retrieve.'),
@@ -17474,9 +17820,16 @@ export const listGrantsQueryParamsWire = z.object({
17474
17820
  size: z.coerce
17475
17821
  .number()
17476
17822
  .int()
17823
+ .gte(1)
17824
+ .lte(1000)
17477
17825
  .optional()
17478
17826
  .describe('The number of items to include per page.'),
17479
- number: z.coerce.number().int().optional().describe('The page number.'),
17827
+ number: z.coerce
17828
+ .number()
17829
+ .int()
17830
+ .gte(1)
17831
+ .optional()
17832
+ .describe('The page number.'),
17480
17833
  })
17481
17834
  .optional()
17482
17835
  .describe('Determines which page of the collection to retrieve.'),
@@ -17519,9 +17872,16 @@ export const listCreditGrantsQueryParamsWire = z.object({
17519
17872
  size: z.coerce
17520
17873
  .number()
17521
17874
  .int()
17875
+ .gte(1)
17876
+ .lte(1000)
17522
17877
  .optional()
17523
17878
  .describe('The number of items to include per page.'),
17524
- number: z.coerce.number().int().optional().describe('The page number.'),
17879
+ number: z.coerce
17880
+ .number()
17881
+ .int()
17882
+ .gte(1)
17883
+ .optional()
17884
+ .describe('The page number.'),
17525
17885
  })
17526
17886
  .optional()
17527
17887
  .describe('Determines which page of the collection to retrieve.'),
@@ -17580,9 +17940,16 @@ export const listCustomerChargesQueryParamsWire = z.object({
17580
17940
  size: z.coerce
17581
17941
  .number()
17582
17942
  .int()
17943
+ .gte(1)
17944
+ .lte(1000)
17583
17945
  .optional()
17584
17946
  .describe('The number of items to include per page.'),
17585
- number: z.coerce.number().int().optional().describe('The page number.'),
17947
+ number: z.coerce
17948
+ .number()
17949
+ .int()
17950
+ .gte(1)
17951
+ .optional()
17952
+ .describe('The page number.'),
17586
17953
  })
17587
17954
  .optional()
17588
17955
  .describe('Determines which page of the collection to retrieve.'),
@@ -17594,7 +17961,7 @@ export const listCustomerChargesQueryParamsWire = z.object({
17594
17961
  expand: z
17595
17962
  .array(chargesExpandWire)
17596
17963
  .optional()
17597
- .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Expand the charge's real-time usage; it sets the `usage` and the `totals.realtime` fields. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
17964
+ .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Set `usage` and `totals.realtime` for active usage-based charges and created usage-based charges whose effective service period contains the current time (inclusive start, exclusive end). Deleted charges are skipped. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
17598
17965
  });
17599
17966
  export const listCustomerChargesResponseWire = z.strictObject({
17600
17967
  data: z.array(chargeWire),
@@ -17618,9 +17985,16 @@ export const listSubscriptionsQueryParamsWire = z.object({
17618
17985
  size: z.coerce
17619
17986
  .number()
17620
17987
  .int()
17988
+ .gte(1)
17989
+ .lte(1000)
17621
17990
  .optional()
17622
17991
  .describe('The number of items to include per page.'),
17623
- number: z.coerce.number().int().optional().describe('The page number.'),
17992
+ number: z.coerce
17993
+ .number()
17994
+ .int()
17995
+ .gte(1)
17996
+ .optional()
17997
+ .describe('The page number.'),
17624
17998
  })
17625
17999
  .optional()
17626
18000
  .describe('Determines which page of the collection to retrieve.'),
@@ -17683,9 +18057,16 @@ export const listSubscriptionAddonsQueryParamsWire = z.object({
17683
18057
  size: z.coerce
17684
18058
  .number()
17685
18059
  .int()
18060
+ .gte(1)
18061
+ .lte(1000)
17686
18062
  .optional()
17687
18063
  .describe('The number of items to include per page.'),
17688
- number: z.coerce.number().int().optional().describe('The page number.'),
18064
+ number: z.coerce
18065
+ .number()
18066
+ .int()
18067
+ .gte(1)
18068
+ .optional()
18069
+ .describe('The page number.'),
17689
18070
  })
17690
18071
  .optional()
17691
18072
  .describe('Determines which page of the collection to retrieve.'),
@@ -17715,9 +18096,16 @@ export const listAppsQueryParamsWire = z.object({
17715
18096
  size: z.coerce
17716
18097
  .number()
17717
18098
  .int()
18099
+ .gte(1)
18100
+ .lte(1000)
17718
18101
  .optional()
17719
18102
  .describe('The number of items to include per page.'),
17720
- number: z.coerce.number().int().optional().describe('The page number.'),
18103
+ number: z.coerce
18104
+ .number()
18105
+ .int()
18106
+ .gte(1)
18107
+ .optional()
18108
+ .describe('The page number.'),
17721
18109
  })
17722
18110
  .optional()
17723
18111
  .describe('Determines which page of the collection to retrieve.'),
@@ -17754,9 +18142,16 @@ export const listAppCatalogQueryParamsWire = z.object({
17754
18142
  size: z.coerce
17755
18143
  .number()
17756
18144
  .int()
18145
+ .gte(1)
18146
+ .lte(1000)
17757
18147
  .optional()
17758
18148
  .describe('The number of items to include per page.'),
17759
- number: z.coerce.number().int().optional().describe('The page number.'),
18149
+ number: z.coerce
18150
+ .number()
18151
+ .int()
18152
+ .gte(1)
18153
+ .optional()
18154
+ .describe('The page number.'),
17760
18155
  })
17761
18156
  .optional()
17762
18157
  .describe('Determines which page of the collection to retrieve.'),
@@ -17777,9 +18172,16 @@ export const listBillingProfilesQueryParamsWire = z.object({
17777
18172
  size: z.coerce
17778
18173
  .number()
17779
18174
  .int()
18175
+ .gte(1)
18176
+ .lte(1000)
17780
18177
  .optional()
17781
18178
  .describe('The number of items to include per page.'),
17782
- number: z.coerce.number().int().optional().describe('The page number.'),
18179
+ number: z.coerce
18180
+ .number()
18181
+ .int()
18182
+ .gte(1)
18183
+ .optional()
18184
+ .describe('The page number.'),
17783
18185
  })
17784
18186
  .optional()
17785
18187
  .describe('Determines which page of the collection to retrieve.'),
@@ -17813,9 +18215,16 @@ export const listInvoicesQueryParamsWire = z.object({
17813
18215
  size: z.coerce
17814
18216
  .number()
17815
18217
  .int()
18218
+ .gte(1)
18219
+ .lte(1000)
17816
18220
  .optional()
17817
18221
  .describe('The number of items to include per page.'),
17818
- number: z.coerce.number().int().optional().describe('The page number.'),
18222
+ number: z.coerce
18223
+ .number()
18224
+ .int()
18225
+ .gte(1)
18226
+ .optional()
18227
+ .describe('The page number.'),
17819
18228
  })
17820
18229
  .optional()
17821
18230
  .describe('Determines which page of the collection to retrieve.'),
@@ -17857,15 +18266,32 @@ export const snapshotQuantitiesInvoicePathParamsWire = z.object({
17857
18266
  invoiceId: ulidWire,
17858
18267
  });
17859
18268
  export const snapshotQuantitiesInvoiceResponseWire = invoiceWire;
18269
+ export const getChargePathParamsWire = z.object({
18270
+ chargeId: ulidWire,
18271
+ });
18272
+ export const getChargeQueryParamsWire = z.object({
18273
+ expand: z
18274
+ .array(chargesExpandWire)
18275
+ .optional()
18276
+ .describe('Expand related entities, realization details, or real-time usage.'),
18277
+ });
18278
+ export const getChargeResponseWire = chargeWire;
17860
18279
  export const listChargesQueryParamsWire = z.object({
17861
18280
  page: z
17862
18281
  .strictObject({
17863
18282
  size: z.coerce
17864
18283
  .number()
17865
18284
  .int()
18285
+ .gte(1)
18286
+ .lte(1000)
17866
18287
  .optional()
17867
18288
  .describe('The number of items to include per page.'),
17868
- number: z.coerce.number().int().optional().describe('The page number.'),
18289
+ number: z.coerce
18290
+ .number()
18291
+ .int()
18292
+ .gte(1)
18293
+ .optional()
18294
+ .describe('The page number.'),
17869
18295
  })
17870
18296
  .optional()
17871
18297
  .describe('Determines which page of the collection to retrieve.'),
@@ -17877,7 +18303,7 @@ export const listChargesQueryParamsWire = z.object({
17877
18303
  expand: z
17878
18304
  .array(chargesExpandWire)
17879
18305
  .optional()
17880
- .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Expand the charge's real-time usage; it sets the `usage` and the `totals.realtime` fields. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
18306
+ .describe("Expand full objects for referenced entities. Supported values are: - `real_time_usage`: Set `usage` and `totals.realtime` for active usage-based charges and created usage-based charges whose effective service period contains the current time (inclusive start, exclusive end). Deleted charges are skipped. - `customer`: Expand the charge's customer to the complete entity. - `feature`: Expand the charge's feature to the complete entity. - `subscription`: Expand the charge's subscription to the complete entity. - `realization.invoice`: Expand each realization's invoice to the complete entity. - `realization.totals`: Expand each realization run's `totals`. - `realization.detailed_lines`: Expand each realization run's `detailed_lines`."),
17881
18307
  });
17882
18308
  export const listChargesResponseWire = z.strictObject({
17883
18309
  data: z.array(chargeWire),
@@ -17895,9 +18321,16 @@ export const listTaxCodesQueryParamsWire = z.object({
17895
18321
  size: z.coerce
17896
18322
  .number()
17897
18323
  .int()
18324
+ .gte(1)
18325
+ .lte(1000)
17898
18326
  .optional()
17899
18327
  .describe('The number of items to include per page.'),
17900
- number: z.coerce.number().int().optional().describe('The page number.'),
18328
+ number: z.coerce
18329
+ .number()
18330
+ .int()
18331
+ .gte(1)
18332
+ .optional()
18333
+ .describe('The page number.'),
17901
18334
  })
17902
18335
  .optional()
17903
18336
  .describe('Determines which page of the collection to retrieve.'),
@@ -17924,9 +18357,16 @@ export const listCurrenciesQueryParamsWire = z.object({
17924
18357
  size: z.coerce
17925
18358
  .number()
17926
18359
  .int()
18360
+ .gte(1)
18361
+ .lte(1000)
17927
18362
  .optional()
17928
18363
  .describe('The number of items to include per page.'),
17929
- number: z.coerce.number().int().optional().describe('The page number.'),
18364
+ number: z.coerce
18365
+ .number()
18366
+ .int()
18367
+ .gte(1)
18368
+ .optional()
18369
+ .describe('The page number.'),
17930
18370
  })
17931
18371
  .optional()
17932
18372
  .describe('Determines which page of the collection to retrieve.'),
@@ -17960,9 +18400,16 @@ export const listCostBasesQueryParamsWire = z.object({
17960
18400
  size: z.coerce
17961
18401
  .number()
17962
18402
  .int()
18403
+ .gte(1)
18404
+ .lte(1000)
17963
18405
  .optional()
17964
18406
  .describe('The number of items to include per page.'),
17965
- number: z.coerce.number().int().optional().describe('The page number.'),
18407
+ number: z.coerce
18408
+ .number()
18409
+ .int()
18410
+ .gte(1)
18411
+ .optional()
18412
+ .describe('The page number.'),
17966
18413
  })
17967
18414
  .optional()
17968
18415
  .describe('Determines which page of the collection to retrieve.'),
@@ -17982,9 +18429,16 @@ export const listFeaturesQueryParamsWire = z.object({
17982
18429
  size: z.coerce
17983
18430
  .number()
17984
18431
  .int()
18432
+ .gte(1)
18433
+ .lte(1000)
17985
18434
  .optional()
17986
18435
  .describe('The number of items to include per page.'),
17987
- number: z.coerce.number().int().optional().describe('The page number.'),
18436
+ number: z.coerce
18437
+ .number()
18438
+ .int()
18439
+ .gte(1)
18440
+ .optional()
18441
+ .describe('The page number.'),
17988
18442
  })
17989
18443
  .optional()
17990
18444
  .describe('Determines which page of the collection to retrieve.'),
@@ -18028,9 +18482,16 @@ export const listLlmCostPricesQueryParamsWire = z.object({
18028
18482
  size: z.coerce
18029
18483
  .number()
18030
18484
  .int()
18485
+ .gte(1)
18486
+ .lte(1000)
18031
18487
  .optional()
18032
18488
  .describe('The number of items to include per page.'),
18033
- number: z.coerce.number().int().optional().describe('The page number.'),
18489
+ number: z.coerce
18490
+ .number()
18491
+ .int()
18492
+ .gte(1)
18493
+ .optional()
18494
+ .describe('The page number.'),
18034
18495
  })
18035
18496
  .optional()
18036
18497
  .describe('Determines which page of the collection to retrieve.'),
@@ -18050,9 +18511,16 @@ export const listLlmCostOverridesQueryParamsWire = z.object({
18050
18511
  size: z.coerce
18051
18512
  .number()
18052
18513
  .int()
18514
+ .gte(1)
18515
+ .lte(1000)
18053
18516
  .optional()
18054
18517
  .describe('The number of items to include per page.'),
18055
- number: z.coerce.number().int().optional().describe('The page number.'),
18518
+ number: z.coerce
18519
+ .number()
18520
+ .int()
18521
+ .gte(1)
18522
+ .optional()
18523
+ .describe('The page number.'),
18056
18524
  })
18057
18525
  .optional()
18058
18526
  .describe('Determines which page of the collection to retrieve.'),
@@ -18072,9 +18540,16 @@ export const listPlansQueryParamsWire = z.object({
18072
18540
  size: z.coerce
18073
18541
  .number()
18074
18542
  .int()
18543
+ .gte(1)
18544
+ .lte(1000)
18075
18545
  .optional()
18076
18546
  .describe('The number of items to include per page.'),
18077
- number: z.coerce.number().int().optional().describe('The page number.'),
18547
+ number: z.coerce
18548
+ .number()
18549
+ .int()
18550
+ .gte(1)
18551
+ .optional()
18552
+ .describe('The page number.'),
18078
18553
  })
18079
18554
  .optional()
18080
18555
  .describe('Determines which page of the collection to retrieve.'),
@@ -18116,9 +18591,16 @@ export const listAddonsQueryParamsWire = z.object({
18116
18591
  size: z.coerce
18117
18592
  .number()
18118
18593
  .int()
18594
+ .gte(1)
18595
+ .lte(1000)
18119
18596
  .optional()
18120
18597
  .describe('The number of items to include per page.'),
18121
- number: z.coerce.number().int().optional().describe('The page number.'),
18598
+ number: z.coerce
18599
+ .number()
18600
+ .int()
18601
+ .gte(1)
18602
+ .optional()
18603
+ .describe('The page number.'),
18122
18604
  })
18123
18605
  .optional()
18124
18606
  .describe('Determines which page of the collection to retrieve.'),
@@ -18163,9 +18645,16 @@ export const listPlanAddonsQueryParamsWire = z.object({
18163
18645
  size: z.coerce
18164
18646
  .number()
18165
18647
  .int()
18648
+ .gte(1)
18649
+ .lte(1000)
18166
18650
  .optional()
18167
18651
  .describe('The number of items to include per page.'),
18168
- number: z.coerce.number().int().optional().describe('The page number.'),
18652
+ number: z.coerce
18653
+ .number()
18654
+ .int()
18655
+ .gte(1)
18656
+ .optional()
18657
+ .describe('The page number.'),
18169
18658
  })
18170
18659
  .optional()
18171
18660
  .describe('Determines which page of the collection to retrieve.'),
@@ -18203,7 +18692,7 @@ export const getOrganizationDefaultTaxCodesResponseWire = organizationDefaultTax
18203
18692
  export const updateOrganizationDefaultTaxCodesBodyWire = updateOrganizationDefaultTaxCodesRequestWire;
18204
18693
  export const updateOrganizationDefaultTaxCodesResponseWire = organizationDefaultTaxCodesWire;
18205
18694
  export const queryEntitlementAccessQueryParamsWire = z.object({
18206
- page: cursorPaginationQueryPageWire.optional(),
18695
+ page: entitlementAccessQueryPageWire.optional(),
18207
18696
  });
18208
18697
  export const queryEntitlementAccessBodyWire = entitlementAccessQueryRequestWire;
18209
18698
  export const queryEntitlementAccessResponseWire = entitlementAccessQueryResponseWire;
@@ -18213,9 +18702,16 @@ export const listBillingNotificationChannelsQueryParamsWire = z.object({
18213
18702
  size: z.coerce
18214
18703
  .number()
18215
18704
  .int()
18705
+ .gte(1)
18706
+ .lte(1000)
18216
18707
  .optional()
18217
18708
  .describe('The number of items to include per page.'),
18218
- number: z.coerce.number().int().optional().describe('The page number.'),
18709
+ number: z.coerce
18710
+ .number()
18711
+ .int()
18712
+ .gte(1)
18713
+ .optional()
18714
+ .describe('The page number.'),
18219
18715
  })
18220
18716
  .optional()
18221
18717
  .describe('Determines which page of the collection to retrieve.'),
@@ -18249,9 +18745,16 @@ export const listBillingNotificationRulesQueryParamsWire = z.object({
18249
18745
  size: z.coerce
18250
18746
  .number()
18251
18747
  .int()
18748
+ .gte(1)
18749
+ .lte(1000)
18252
18750
  .optional()
18253
18751
  .describe('The number of items to include per page.'),
18254
- number: z.coerce.number().int().optional().describe('The page number.'),
18752
+ number: z.coerce
18753
+ .number()
18754
+ .int()
18755
+ .gte(1)
18756
+ .optional()
18757
+ .describe('The page number.'),
18255
18758
  })
18256
18759
  .optional()
18257
18760
  .describe('Determines which page of the collection to retrieve.'),
@@ -18289,9 +18792,16 @@ export const listBillingNotificationEventsQueryParamsWire = z.object({
18289
18792
  size: z.coerce
18290
18793
  .number()
18291
18794
  .int()
18795
+ .gte(1)
18796
+ .lte(1000)
18292
18797
  .optional()
18293
18798
  .describe('The number of items to include per page.'),
18294
- number: z.coerce.number().int().optional().describe('The page number.'),
18799
+ number: z.coerce
18800
+ .number()
18801
+ .int()
18802
+ .gte(1)
18803
+ .optional()
18804
+ .describe('The page number.'),
18295
18805
  })
18296
18806
  .optional()
18297
18807
  .describe('Determines which page of the collection to retrieve.'),