chargebee 3.29.0 → 3.30.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. package/CHANGELOG.md +58 -0
  2. package/cjs/environment.js +1 -1
  3. package/cjs/resources/api_endpoints.js +69 -0
  4. package/cjs/resources/webhook/eventType.js +4 -0
  5. package/cjs/schema/alert.schema.js +8 -3
  6. package/cjs/schema/coupon.schema.js +1 -1
  7. package/cjs/schema/credit_note.schema.js +8 -0
  8. package/cjs/schema/credit_unit.schema.js +38 -0
  9. package/cjs/schema/customer.schema.js +24 -0
  10. package/cjs/schema/entitlement.schema.js +4 -4
  11. package/cjs/schema/estimate.schema.js +9 -0
  12. package/cjs/schema/event.schema.js +16 -0
  13. package/cjs/schema/export.schema.js +21 -5
  14. package/cjs/schema/gift.schema.js +8 -0
  15. package/cjs/schema/grant_block.schema.js +4 -0
  16. package/cjs/schema/index.js +1 -0
  17. package/cjs/schema/invoice.schema.js +30 -2
  18. package/cjs/schema/item.schema.js +1 -1
  19. package/cjs/schema/item_family.schema.js +1 -1
  20. package/cjs/schema/item_price.schema.js +1 -1
  21. package/cjs/schema/ledger_operation.schema.js +14 -4
  22. package/cjs/schema/meter.schema.js +1 -1
  23. package/cjs/schema/payment_intent.schema.js +8 -0
  24. package/cjs/schema/payment_source.schema.js +28 -0
  25. package/cjs/schema/price_variant.schema.js +1 -1
  26. package/cjs/schema/purchase.schema.js +4 -0
  27. package/cjs/schema/ramp.schema.js +2 -2
  28. package/cjs/schema/subscription.schema.js +57 -0
  29. package/cjs/schema/transaction.schema.js +20 -0
  30. package/cjs/schema/webhook_endpoint.schema.js +8 -0
  31. package/esm/environment.js +1 -1
  32. package/esm/resources/api_endpoints.js +69 -0
  33. package/esm/resources/webhook/eventType.js +4 -0
  34. package/esm/schema/alert.schema.js +8 -3
  35. package/esm/schema/coupon.schema.js +1 -1
  36. package/esm/schema/credit_note.schema.js +8 -0
  37. package/esm/schema/credit_unit.schema.js +35 -0
  38. package/esm/schema/customer.schema.js +24 -0
  39. package/esm/schema/entitlement.schema.js +4 -4
  40. package/esm/schema/estimate.schema.js +9 -0
  41. package/esm/schema/event.schema.js +16 -0
  42. package/esm/schema/export.schema.js +21 -5
  43. package/esm/schema/gift.schema.js +8 -0
  44. package/esm/schema/grant_block.schema.js +4 -0
  45. package/esm/schema/index.js +1 -0
  46. package/esm/schema/invoice.schema.js +30 -2
  47. package/esm/schema/item.schema.js +1 -1
  48. package/esm/schema/item_family.schema.js +1 -1
  49. package/esm/schema/item_price.schema.js +1 -1
  50. package/esm/schema/ledger_operation.schema.js +13 -3
  51. package/esm/schema/meter.schema.js +1 -1
  52. package/esm/schema/payment_intent.schema.js +8 -0
  53. package/esm/schema/payment_source.schema.js +28 -0
  54. package/esm/schema/price_variant.schema.js +1 -1
  55. package/esm/schema/purchase.schema.js +4 -0
  56. package/esm/schema/ramp.schema.js +2 -2
  57. package/esm/schema/subscription.schema.js +57 -0
  58. package/esm/schema/transaction.schema.js +20 -0
  59. package/esm/schema/webhook_endpoint.schema.js +8 -0
  60. package/package.json +1 -1
  61. package/types/core.d.ts +27 -2
  62. package/types/index.d.ts +3 -0
  63. package/types/resources/Alert.d.ts +4 -2
  64. package/types/resources/AttachedItem.d.ts +2 -2
  65. package/types/resources/Content.d.ts +2 -0
  66. package/types/resources/CreditUnit.d.ts +90 -0
  67. package/types/resources/Customer.d.ts +10 -2
  68. package/types/resources/Estimate.d.ts +11 -2
  69. package/types/resources/Event.d.ts +4 -0
  70. package/types/resources/Gift.d.ts +10 -2
  71. package/types/resources/GrantBlock.d.ts +11 -5
  72. package/types/resources/Invoice.d.ts +10 -2
  73. package/types/resources/LedgerAccountBalance.d.ts +3 -1
  74. package/types/resources/LedgerEntry.d.ts +22 -0
  75. package/types/resources/LedgerOperation.d.ts +33 -6
  76. package/types/resources/PaymentIntent.d.ts +25 -5
  77. package/types/resources/PaymentSource.d.ts +5 -1
  78. package/types/resources/Purchase.d.ts +5 -1
  79. package/types/resources/Subscription.d.ts +36 -7
  80. package/types/resources/WebhookEvent.d.ts +26 -0
package/CHANGELOG.md CHANGED
@@ -1,3 +1,61 @@
1
+ ### v3.30.0 (2026-07-30)
2
+ * * *
3
+ ### New Resources:
4
+ - [`CreditUnit`](https://apidocs.chargebee.com/docs/api/credit_units) has been added.
5
+ - [`LedgerEntry`](https://apidocs.chargebee.com/docs/api/ledger_entries) has been added.
6
+
7
+
8
+ ### New Actions:
9
+ - [`allocate`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate) has been added to [`LedgerOperation`](https://apidocs.chargebee.com/docs/api/ledger_operations).
10
+
11
+
12
+ ### New Attributes:
13
+ - [`unit_id`](https://apidocs.chargebee.com/docs/api/alerts/alert-object#unit_id) has been added to [`Alert`](https://apidocs.chargebee.com/docs/api/alerts).
14
+ - [`subscription_id`](https://apidocs.chargebee.com/docs/api/grant_blocks/grant-block-object#subscription_id) has been added to [`GrantBlock`](https://apidocs.chargebee.com/docs/api/grant_blocks).
15
+ - [`modified_at`](https://apidocs.chargebee.com/docs/api/grant_blocks/grant-block-object#modified_at) has been added to [`GrantBlock`](https://apidocs.chargebee.com/docs/api/grant_blocks).
16
+ - [`resource_version`](https://apidocs.chargebee.com/docs/api/grant_blocks/grant-block-object#resource_version) has been added to [`GrantBlock`](https://apidocs.chargebee.com/docs/api/grant_blocks).
17
+ - [`created_at`](https://apidocs.chargebee.com/docs/api/ledger_account_balances/ledger-account-balance-object#created_at) has been added to [`LedgerAccountBalance`](https://apidocs.chargebee.com/docs/api/ledger_account_balances).
18
+ - [`resource_version`](https://apidocs.chargebee.com/docs/api/ledger_account_balances/ledger-account-balance-object#resource_version) has been added to [`LedgerAccountBalance`](https://apidocs.chargebee.com/docs/api/ledger_account_balances).
19
+
20
+
21
+ ### New Parameters:
22
+ - [`account_type`](https://apidocs.chargebee.com/docs/api/grant_blocks/list-grant-blocks#account_type) has been added as query parameter to [`list_grant_blocks`](https://apidocs.chargebee.com/docs/api/grant_blocks/list-grant-blocks) in [`GrantBlock`](https://apidocs.chargebee.com/docs/api/grant_blocks).
23
+ - [`unit_id`](https://apidocs.chargebee.com/docs/api/alerts/create-an-alert#unit_id) has been added as request body parameter to [`create_an_alert`](https://apidocs.chargebee.com/docs/api/alerts/create-an-alert) in [`Alert`](https://apidocs.chargebee.com/docs/api/alerts).
24
+ - [`include_cancellation_day_in_billing`](https://apidocs.chargebee.com/docs/api/estimates/cancel-subscription-for-items-estimate#include_cancellation_day_in_billing) has been added as request body parameter to [`cancel_subscription_for_items_estimate`](https://apidocs.chargebee.com/docs/api/estimates/cancel-subscription-for-items-estimate) in [`Estimate`](https://apidocs.chargebee.com/docs/api/estimates).
25
+ - [`subscription_id`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate#subscription_id) has been added as request body parameter to [`allocate`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate) in [`LedgerOperation`](https://apidocs.chargebee.com/docs/api/ledger_operations).
26
+ - [`unit_id`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate#unit_id) has been added as request body parameter to [`allocate`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate) in [`LedgerOperation`](https://apidocs.chargebee.com/docs/api/ledger_operations).
27
+ - [`amount`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate#amount) has been added as request body parameter to [`allocate`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate) in [`LedgerOperation`](https://apidocs.chargebee.com/docs/api/ledger_operations).
28
+ - [`expires_at`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate#expires_at) has been added as request body parameter to [`allocate`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate) in [`LedgerOperation`](https://apidocs.chargebee.com/docs/api/ledger_operations).
29
+ - [`metadata`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate#metadata) has been added as request body parameter to [`allocate`](https://apidocs.chargebee.com/docs/api/ledger_operations/allocate) in [`LedgerOperation`](https://apidocs.chargebee.com/docs/api/ledger_operations).
30
+ - [`include_cancellation_day_in_billing`](https://apidocs.chargebee.com/docs/api/subscriptions/cancel-subscription-for-items#include_cancellation_day_in_billing) has been added as request body parameter to [`cancel_subscription_for_items`](https://apidocs.chargebee.com/docs/api/subscriptions/cancel-subscription-for-items) in [`Subscription`](https://apidocs.chargebee.com/docs/api/subscriptions).
31
+
32
+
33
+ ### New Events:
34
+ - [`grant_blocks_created`](https://apidocs.chargebee.com/docs/api/events/webhook/grant_blocks_created) has been added.
35
+ - [`ledger_updated`](https://apidocs.chargebee.com/docs/api/events/webhook/ledger_updated) has been added.
36
+ - [`ledger_account_balance_updated`](https://apidocs.chargebee.com/docs/api/events/webhook/ledger_account_balance_updated) has been added.
37
+ - [`grant_blocks_updated`](https://apidocs.chargebee.com/docs/api/events/webhook/grant_blocks_updated) has been added.
38
+
39
+
40
+ ### New Enums:
41
+ - `ledger_account_balance_updated`, `grant_blocks_created`, `grant_blocks_updated`, and `ledger_updated` have been added as new values enum `EventType`.
42
+ - `dana`, `touch_n_go`, `tamara`, and `qpay` have been added as new values enum `PaymentMethod`.
43
+ - `dana`, `touch_n_go`, `tamara`, and `qpay` have been added as new values enum `PaymentMethodType`.
44
+ - `dana`, `touch_n_go`, `tamara`, `qpay`, `credit_balance_dropped`, `credit`, `debit`, `hold`, and `unhold` have been added as new values enum `Type`.
45
+ - `active` and `archived` have been added as new values to enum attribute [`status`](https://apidocs.chargebee.com/docs/api/credit_units/credit-unit-object#status) in [`CreditUnit`](https://apidocs.chargebee.com/docs/api/credit_units).
46
+ - `grant_renewal` and `subscription_renewed` have been added as new values to enum attribute [`grant_source`](https://apidocs.chargebee.com/docs/api/grant_blocks/grant-block-object#grant_source) in [`GrantBlock`](https://apidocs.chargebee.com/docs/api/grant_blocks).
47
+ - `provisioned` and `overdraft` have been added as new values to enum attribute [`account_type`](https://apidocs.chargebee.com/docs/api/ledger_entries/ledger-entry-object#account_type) in [`LedgerEntry`](https://apidocs.chargebee.com/docs/api/ledger_entries).
48
+ - `credit_unit` has been added as a new value to enum attribute [`unit_type`](https://apidocs.chargebee.com/docs/api/ledger_entries/ledger-entry-object#unit_type) in [`LedgerEntry`](https://apidocs.chargebee.com/docs/api/ledger_entries).
49
+ - `dana`, `touch_n_go`, `tamara`, and `qpay` have been added as new values to enum attribute [`payment_method_type`](https://apidocs.chargebee.com/docs/api/payment_intents/payment-intent-object#payment_method_type) in [`PaymentIntent`](https://apidocs.chargebee.com/docs/api/payment_intents).
50
+ - `dana`, `touch_n_go`, `tamara`, and `qpay` have been added as new values to enum attribute [`active_payment_attempt.payment_method_type`](https://apidocs.chargebee.com/docs/api/payment_intents/payment-intent-object#active_payment_attempt_payment_method_type) in [`PaymentIntent`](https://apidocs.chargebee.com/docs/api/payment_intents).
51
+ - `archived` and `active` have been added as new values to enum query parameter `status.in` in [`list_credit_units`](https://apidocs.chargebee.com/docs/api/credit_units/list-credit-units) of [`CreditUnit`](https://apidocs.chargebee.com/docs/api/credit_units).
52
+ - `archived` and `active` have been added as new values to enum query parameter `status.is` in [`list_credit_units`](https://apidocs.chargebee.com/docs/api/credit_units/list-credit-units) of [`CreditUnit`](https://apidocs.chargebee.com/docs/api/credit_units).
53
+ - `provisioned` and `overdraft` have been added as new values to enum query parameter `account_type.is` in [`list_grant_blocks`](https://apidocs.chargebee.com/docs/api/grant_blocks/list-grant-blocks) of [`GrantBlock`](https://apidocs.chargebee.com/docs/api/grant_blocks).
54
+ - `dana`, `touch_n_go`, `tamara`, and `qpay` have been added as new values to enum request body parameter `payment_method_type` in [`update_a_payment_intent`](https://apidocs.chargebee.com/docs/api/payment_intents/update-a-payment-intent) of [`PaymentIntent`](https://apidocs.chargebee.com/docs/api/payment_intents).
55
+ - `dana`, `touch_n_go`, `tamara`, and `qpay` have been added as new values to enum request body parameter `payment_method_type` in [`create_a_payment_intent`](https://apidocs.chargebee.com/docs/api/payment_intents/create-a-payment-intent) of [`PaymentIntent`](https://apidocs.chargebee.com/docs/api/payment_intents).
56
+
57
+
58
+
1
59
  ### v3.29.0 (2026-07-21)
2
60
  * * *
3
61
  ### New Resources:
@@ -11,7 +11,7 @@ exports.Environment = {
11
11
  hostSuffix: '.chargebee.com',
12
12
  apiPath: '/api/v2',
13
13
  timeout: DEFAULT_TIME_OUT,
14
- clientVersion: 'v3.29.0',
14
+ clientVersion: 'v3.30.0',
15
15
  port: DEFAULT_PORT,
16
16
  timemachineWaitInMillis: DEFAULT_TIME_MACHINE_WAIT,
17
17
  exportWaitInMillis: DEFAULT_EXPORT_WAIT,
@@ -4232,6 +4232,61 @@ exports.Endpoints = {
4232
4232
  impactedItem: [],
4233
4233
  impactedItemPrice: [],
4234
4234
  metadata: [],
4235
+ creditUnit: [
4236
+ ['list', 'GET', '/credit_units', null, false, null, false, {}, {}],
4237
+ [
4238
+ 'create',
4239
+ 'POST',
4240
+ '/credit_units',
4241
+ null,
4242
+ false,
4243
+ null,
4244
+ false,
4245
+ {},
4246
+ {
4247
+ isIdempotent: true,
4248
+ },
4249
+ ],
4250
+ [
4251
+ 'update',
4252
+ 'POST',
4253
+ '/credit_units',
4254
+ null,
4255
+ true,
4256
+ null,
4257
+ false,
4258
+ {},
4259
+ {
4260
+ isIdempotent: true,
4261
+ },
4262
+ ],
4263
+ [
4264
+ 'archive',
4265
+ 'POST',
4266
+ '/credit_units',
4267
+ '/archive_command',
4268
+ true,
4269
+ null,
4270
+ false,
4271
+ {},
4272
+ {
4273
+ isIdempotent: true,
4274
+ },
4275
+ ],
4276
+ [
4277
+ 'reactivate',
4278
+ 'POST',
4279
+ '/credit_units',
4280
+ '/reactivate_command',
4281
+ true,
4282
+ null,
4283
+ false,
4284
+ {},
4285
+ {
4286
+ isIdempotent: true,
4287
+ },
4288
+ ],
4289
+ ],
4235
4290
  subscriptionEntitlement: [
4236
4291
  [
4237
4292
  'subscriptionEntitlementsForSubscription',
@@ -5199,6 +5254,19 @@ exports.Endpoints = {
5199
5254
  },
5200
5255
  {},
5201
5256
  ],
5257
+ [
5258
+ 'allocate',
5259
+ 'POST',
5260
+ '/ledger_operations',
5261
+ '/allocate',
5262
+ false,
5263
+ null,
5264
+ true,
5265
+ {
5266
+ metadata: 0,
5267
+ },
5268
+ {},
5269
+ ],
5202
5270
  ],
5203
5271
  grantBlock: [
5204
5272
  [
@@ -5213,6 +5281,7 @@ exports.Endpoints = {
5213
5281
  {},
5214
5282
  ],
5215
5283
  ],
5284
+ ledgerEntry: [],
5216
5285
  promotionalGrant: [
5217
5286
  [
5218
5287
  'promotionalGrants',
@@ -69,6 +69,8 @@ var WebhookEventType;
69
69
  WebhookEventType["GiftScheduled"] = "gift_scheduled";
70
70
  WebhookEventType["GiftUnclaimed"] = "gift_unclaimed";
71
71
  WebhookEventType["GiftUpdated"] = "gift_updated";
72
+ WebhookEventType["GrantBlocksCreated"] = "grant_blocks_created";
73
+ WebhookEventType["GrantBlocksUpdated"] = "grant_blocks_updated";
72
74
  WebhookEventType["HierarchyCreated"] = "hierarchy_created";
73
75
  WebhookEventType["HierarchyDeleted"] = "hierarchy_deleted";
74
76
  WebhookEventType["InvoiceDeleted"] = "invoice_deleted";
@@ -88,6 +90,8 @@ var WebhookEventType;
88
90
  WebhookEventType["ItemPriceEntitlementsUpdated"] = "item_price_entitlements_updated";
89
91
  WebhookEventType["ItemPriceUpdated"] = "item_price_updated";
90
92
  WebhookEventType["ItemUpdated"] = "item_updated";
93
+ WebhookEventType["LedgerAccountBalanceUpdated"] = "ledger_account_balance_updated";
94
+ WebhookEventType["LedgerUpdated"] = "ledger_updated";
91
95
  WebhookEventType["MrrUpdated"] = "mrr_updated";
92
96
  WebhookEventType["NetdPaymentDueReminder"] = "netd_payment_due_reminder";
93
97
  WebhookEventType["OmnichannelOneTimeOrderCreated"] = "omnichannel_one_time_order_created";
@@ -16,11 +16,12 @@ const CreateAlertFilterConditionsSchema = zod_1.z.object({
16
16
  value: zod_1.z.array(zod_1.z.string().max(50).optional()).optional(),
17
17
  });
18
18
  const CreateAlertBodySchema = zod_1.z.looseObject({
19
- type: zod_1.z.enum(['usage_exceeded', 'spend_exceeded']),
19
+ type: zod_1.z.enum(['usage_exceeded', 'spend_exceeded', 'credit_balance_dropped']),
20
20
  name: zod_1.z.string().max(50),
21
21
  description: zod_1.z.string().max(65000).optional(),
22
22
  metered_feature_id: zod_1.z.string().max(50).optional(),
23
23
  currency_code: zod_1.z.string().max(3).optional(),
24
+ unit_id: zod_1.z.string().max(50).optional(),
24
25
  subscription_id: zod_1.z.string().max(50).optional(),
25
26
  meta: zod_1.z.string().max(65000).optional(),
26
27
  threshold: CreateAlertThresholdSchema.optional(),
@@ -32,7 +33,9 @@ const ListAlertIdSchema = zod_1.z.object({
32
33
  in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
33
34
  });
34
35
  const ListAlertTypeSchema = zod_1.z.object({
35
- is: zod_1.z.enum(['usage_exceeded', 'spend_exceeded']).optional(),
36
+ is: zod_1.z
37
+ .enum(['usage_exceeded', 'spend_exceeded', 'credit_balance_dropped'])
38
+ .optional(),
36
39
  });
37
40
  const ListAlertSubscriptionIdSchema = zod_1.z.object({
38
41
  is: zod_1.z.string().min(1).optional(),
@@ -64,7 +67,9 @@ const ApplicationAlertsforsubscriptionAlertStatusSchema = zod_1.z.object({
64
67
  is: zod_1.z.enum(['enabled', 'disabled']).optional(),
65
68
  });
66
69
  const ApplicationAlertsforsubscriptionAlertTypeSchema = zod_1.z.object({
67
- is: zod_1.z.enum(['usage_exceeded', 'spend_exceeded']).optional(),
70
+ is: zod_1.z
71
+ .enum(['usage_exceeded', 'spend_exceeded', 'credit_balance_dropped'])
72
+ .optional(),
68
73
  });
69
74
  const ApplicationAlertsforsubscriptionAlertBodySchema = zod_1.z.looseObject({
70
75
  limit: zod_1.z.number().int().min(1).max(100).optional(),
@@ -259,8 +259,8 @@ const ListCouponCurrencyCodeSchema = zod_1.z.object({
259
259
  not_in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
260
260
  });
261
261
  const ListCouponApplicableItemPriceIdsSchema = zod_1.z.object({
262
- is: zod_1.z.string().min(1).optional(),
263
262
  in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
263
+ is: zod_1.z.string().min(1).optional(),
264
264
  });
265
265
  const ListCouponBodySchema = zod_1.z.looseObject({
266
266
  limit: zod_1.z.number().int().min(1).max(100).optional(),
@@ -95,6 +95,10 @@ const RecordRefundCreditNoteTransactionSchema = zod_1.z.object({
95
95
  'app_store',
96
96
  'play_store',
97
97
  'custom',
98
+ 'dana',
99
+ 'touch_n_go',
100
+ 'tamara',
101
+ 'qpay',
98
102
  ]),
99
103
  reference_number: zod_1.z.string().max(100).optional(),
100
104
  custom_payment_method_id: zod_1.z.string().max(50).optional(),
@@ -475,6 +479,10 @@ const ImportCreditNoteCreditNoteLinkedRefundsSchema = zod_1.z.object({
475
479
  'app_store',
476
480
  'play_store',
477
481
  'custom',
482
+ 'dana',
483
+ 'touch_n_go',
484
+ 'tamara',
485
+ 'qpay',
478
486
  ])
479
487
  .optional()),
480
488
  date: zod_1.z.array(zod_1.z.number().int().optional()),
@@ -0,0 +1,38 @@
1
+ "use strict";
2
+ // Generated Zod schemas: CreditUnit
3
+ // Actions: list, create, update
4
+ // Do not edit manually – regenerate via sdk-generator
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.UpdateCreditUnitBodySchema = exports.CreateCreditUnitBodySchema = exports.ListCreditUnitBodySchema = void 0;
7
+ const zod_1 = require("zod");
8
+ //CreditUnit.list
9
+ const ListCreditUnitStatusSchema = zod_1.z.object({
10
+ in: zod_1.z.enum(['active', 'archived']).optional(),
11
+ is: zod_1.z.enum(['active', 'archived']).optional(),
12
+ });
13
+ const ListCreditUnitIdSchema = zod_1.z.object({
14
+ in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
15
+ is: zod_1.z.string().min(1).optional(),
16
+ });
17
+ const ListCreditUnitBodySchema = zod_1.z.looseObject({
18
+ limit: zod_1.z.number().int().min(1).max(100).optional(),
19
+ offset: zod_1.z.string().max(1000).optional(),
20
+ status: ListCreditUnitStatusSchema.optional(),
21
+ id: ListCreditUnitIdSchema.optional(),
22
+ });
23
+ exports.ListCreditUnitBodySchema = ListCreditUnitBodySchema;
24
+ //CreditUnit.create
25
+ const CreateCreditUnitBodySchema = zod_1.z.looseObject({
26
+ id: zod_1.z.string().max(50),
27
+ name: zod_1.z.string().max(50),
28
+ is_unlimited: zod_1.z.boolean(),
29
+ overdraft_amount: zod_1.z.string().max(50).optional(),
30
+ external_name: zod_1.z.string().max(50).optional(),
31
+ });
32
+ exports.CreateCreditUnitBodySchema = CreateCreditUnitBodySchema;
33
+ //CreditUnit.update
34
+ const UpdateCreditUnitBodySchema = zod_1.z.looseObject({
35
+ name: zod_1.z.string().max(50).optional(),
36
+ external_name: zod_1.z.string().max(50).optional(),
37
+ });
38
+ exports.UpdateCreditUnitBodySchema = UpdateCreditUnitBodySchema;
@@ -168,6 +168,10 @@ const CreateCustomerPaymentMethodSchema = zod_1.z.object({
168
168
  'paynow',
169
169
  'bizum',
170
170
  'promptpay',
171
+ 'dana',
172
+ 'touch_n_go',
173
+ 'tamara',
174
+ 'qpay',
171
175
  ])
172
176
  .optional(),
173
177
  gateway: zod_1.z
@@ -293,6 +297,10 @@ const CreateCustomerPaymentIntentSchema = zod_1.z.object({
293
297
  'paynow',
294
298
  'bizum',
295
299
  'promptpay',
300
+ 'dana',
301
+ 'touch_n_go',
302
+ 'tamara',
303
+ 'qpay',
296
304
  ])
297
305
  .optional(),
298
306
  reference_id: zod_1.z.string().max(65000).optional(),
@@ -715,6 +723,10 @@ const UpdatePaymentMethodCustomerPaymentMethodSchema = zod_1.z.object({
715
723
  'paynow',
716
724
  'bizum',
717
725
  'promptpay',
726
+ 'dana',
727
+ 'touch_n_go',
728
+ 'tamara',
729
+ 'qpay',
718
730
  ]),
719
731
  gateway: zod_1.z
720
732
  .enum([
@@ -935,6 +947,10 @@ const RecordExcessPaymentCustomerTransactionSchema = zod_1.z.object({
935
947
  'app_store',
936
948
  'play_store',
937
949
  'custom',
950
+ 'dana',
951
+ 'touch_n_go',
952
+ 'tamara',
953
+ 'qpay',
938
954
  ]),
939
955
  reference_number: zod_1.z.string().max(100).optional(),
940
956
  custom_payment_method_id: zod_1.z.string().max(50).optional(),
@@ -999,6 +1015,10 @@ const CollectPaymentCustomerPaymentMethodSchema = zod_1.z.object({
999
1015
  'paynow',
1000
1016
  'bizum',
1001
1017
  'promptpay',
1018
+ 'dana',
1019
+ 'touch_n_go',
1020
+ 'tamara',
1021
+ 'qpay',
1002
1022
  ])
1003
1023
  .optional(),
1004
1024
  gateway_account_id: zod_1.z.string().max(50).optional(),
@@ -1080,6 +1100,10 @@ const CollectPaymentCustomerPaymentIntentSchema = zod_1.z.object({
1080
1100
  'paynow',
1081
1101
  'bizum',
1082
1102
  'promptpay',
1103
+ 'dana',
1104
+ 'touch_n_go',
1105
+ 'tamara',
1106
+ 'qpay',
1083
1107
  ])
1084
1108
  .optional(),
1085
1109
  gw_payment_method_id: zod_1.z.string().max(65000).optional(),
@@ -7,20 +7,20 @@ exports.CreateEntitlementBodySchema = exports.ListEntitlementBodySchema = void 0
7
7
  const zod_1 = require("zod");
8
8
  //Entitlement.list
9
9
  const ListEntitlementFeatureIdSchema = zod_1.z.object({
10
- is: zod_1.z.string().min(1).optional(),
11
10
  in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
11
+ is: zod_1.z.string().min(1).optional(),
12
12
  });
13
13
  const ListEntitlementEntityTypeSchema = zod_1.z.object({
14
- is: zod_1.z
14
+ in: zod_1.z
15
15
  .enum(['plan', 'addon', 'charge', 'plan_price', 'addon_price'])
16
16
  .optional(),
17
- in: zod_1.z
17
+ is: zod_1.z
18
18
  .enum(['plan', 'addon', 'charge', 'plan_price', 'addon_price'])
19
19
  .optional(),
20
20
  });
21
21
  const ListEntitlementEntityIdSchema = zod_1.z.object({
22
- is: zod_1.z.string().min(1).optional(),
23
22
  in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
23
+ is: zod_1.z.string().min(1).optional(),
24
24
  });
25
25
  const ListEntitlementBodySchema = zod_1.z.looseObject({
26
26
  limit: zod_1.z.number().int().min(1).max(100).optional(),
@@ -1053,6 +1053,7 @@ const CancelSubscriptionForItemsEstimateBodySchema = zod_1.z.looseObject({
1053
1053
  ])
1054
1054
  .optional(),
1055
1055
  invoice_date: zod_1.z.number().int().optional(),
1056
+ include_cancellation_day_in_billing: zod_1.z.boolean().optional(),
1056
1057
  cancel_reason_code: zod_1.z.string().max(100).optional(),
1057
1058
  subscription_items: CancelSubscriptionForItemsEstimateSubscriptionItemsSchema.optional(),
1058
1059
  });
@@ -1157,6 +1158,10 @@ const GiftSubscriptionEstimatePaymentIntentSchema = zod_1.z.object({
1157
1158
  'paynow',
1158
1159
  'bizum',
1159
1160
  'promptpay',
1161
+ 'dana',
1162
+ 'touch_n_go',
1163
+ 'tamara',
1164
+ 'qpay',
1160
1165
  ])
1161
1166
  .optional(),
1162
1167
  reference_id: zod_1.z.string().max(65000).optional(),
@@ -1276,6 +1281,10 @@ const GiftSubscriptionForItemsEstimatePaymentIntentSchema = zod_1.z.object({
1276
1281
  'paynow',
1277
1282
  'bizum',
1278
1283
  'promptpay',
1284
+ 'dana',
1285
+ 'touch_n_go',
1286
+ 'tamara',
1287
+ 'qpay',
1279
1288
  ])
1280
1289
  .optional(),
1281
1290
  reference_id: zod_1.z.string().max(65000).optional(),
@@ -293,6 +293,10 @@ const ListEventEventTypeSchema = zod_1.z.object({
293
293
  'alert_status_changed',
294
294
  'omnichannel_subscription_item_updated',
295
295
  'omnichannel_subscription_item_recovered',
296
+ 'ledger_account_balance_updated',
297
+ 'grant_blocks_created',
298
+ 'grant_blocks_updated',
299
+ 'ledger_updated',
296
300
  ])
297
301
  .optional(),
298
302
  is_not: zod_1.z
@@ -520,6 +524,10 @@ const ListEventEventTypeSchema = zod_1.z.object({
520
524
  'alert_status_changed',
521
525
  'omnichannel_subscription_item_updated',
522
526
  'omnichannel_subscription_item_recovered',
527
+ 'ledger_account_balance_updated',
528
+ 'grant_blocks_created',
529
+ 'grant_blocks_updated',
530
+ 'ledger_updated',
523
531
  ])
524
532
  .optional(),
525
533
  in: zod_1.z
@@ -747,6 +755,10 @@ const ListEventEventTypeSchema = zod_1.z.object({
747
755
  'alert_status_changed',
748
756
  'omnichannel_subscription_item_updated',
749
757
  'omnichannel_subscription_item_recovered',
758
+ 'ledger_account_balance_updated',
759
+ 'grant_blocks_created',
760
+ 'grant_blocks_updated',
761
+ 'ledger_updated',
750
762
  ])
751
763
  .optional(),
752
764
  not_in: zod_1.z
@@ -974,6 +986,10 @@ const ListEventEventTypeSchema = zod_1.z.object({
974
986
  'alert_status_changed',
975
987
  'omnichannel_subscription_item_updated',
976
988
  'omnichannel_subscription_item_recovered',
989
+ 'ledger_account_balance_updated',
990
+ 'grant_blocks_created',
991
+ 'grant_blocks_updated',
992
+ 'ledger_updated',
977
993
  ])
978
994
  .optional(),
979
995
  });
@@ -1102,8 +1102,8 @@ const CouponsExportCurrencyCodeSchema = zod_1.z.object({
1102
1102
  not_in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
1103
1103
  });
1104
1104
  const CouponsExportApplicableItemPriceIdsSchema = zod_1.z.object({
1105
- is: zod_1.z.string().min(1).optional(),
1106
1105
  in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
1106
+ is: zod_1.z.string().min(1).optional(),
1107
1107
  });
1108
1108
  const CouponsExportIdSchema = zod_1.z.object({
1109
1109
  is: zod_1.z.string().min(1).optional(),
@@ -2135,6 +2135,10 @@ const TransactionsExportPaymentMethodSchema = zod_1.z.object({
2135
2135
  'paynow',
2136
2136
  'bizum',
2137
2137
  'promptpay',
2138
+ 'dana',
2139
+ 'touch_n_go',
2140
+ 'tamara',
2141
+ 'qpay',
2138
2142
  ])
2139
2143
  .optional(),
2140
2144
  is_not: zod_1.z
@@ -2199,6 +2203,10 @@ const TransactionsExportPaymentMethodSchema = zod_1.z.object({
2199
2203
  'paynow',
2200
2204
  'bizum',
2201
2205
  'promptpay',
2206
+ 'dana',
2207
+ 'touch_n_go',
2208
+ 'tamara',
2209
+ 'qpay',
2202
2210
  ])
2203
2211
  .optional(),
2204
2212
  in: zod_1.z
@@ -2263,6 +2271,10 @@ const TransactionsExportPaymentMethodSchema = zod_1.z.object({
2263
2271
  'paynow',
2264
2272
  'bizum',
2265
2273
  'promptpay',
2274
+ 'dana',
2275
+ 'touch_n_go',
2276
+ 'tamara',
2277
+ 'qpay',
2266
2278
  ])
2267
2279
  .optional(),
2268
2280
  not_in: zod_1.z
@@ -2327,6 +2339,10 @@ const TransactionsExportPaymentMethodSchema = zod_1.z.object({
2327
2339
  'paynow',
2328
2340
  'bizum',
2329
2341
  'promptpay',
2342
+ 'dana',
2343
+ 'touch_n_go',
2344
+ 'tamara',
2345
+ 'qpay',
2330
2346
  ])
2331
2347
  .optional(),
2332
2348
  });
@@ -2930,8 +2946,8 @@ const OrdersExportBodySchema = zod_1.z.looseObject({
2930
2946
  exports.OrdersExportBodySchema = OrdersExportBodySchema;
2931
2947
  //Export.itemFamilies
2932
2948
  const ItemFamiliesExportBusinessEntityIdSchema = zod_1.z.object({
2933
- is_present: zod_1.z.enum(['true', 'false']).optional(),
2934
2949
  is: zod_1.z.string().min(1).optional(),
2950
+ is_present: zod_1.z.enum(['true', 'false']).optional(),
2935
2951
  });
2936
2952
  const ItemFamiliesExportIncludeSiteLevelResourcesSchema = zod_1.z.object({
2937
2953
  is: zod_1.z.enum(['true', 'false']).optional(),
@@ -2969,8 +2985,8 @@ const ItemFamiliesExportBodySchema = zod_1.z.looseObject({
2969
2985
  exports.ItemFamiliesExportBodySchema = ItemFamiliesExportBodySchema;
2970
2986
  //Export.items
2971
2987
  const ItemsExportBusinessEntityIdSchema = zod_1.z.object({
2972
- is_present: zod_1.z.enum(['true', 'false']).optional(),
2973
2988
  is: zod_1.z.string().min(1).optional(),
2989
+ is_present: zod_1.z.enum(['true', 'false']).optional(),
2974
2990
  });
2975
2991
  const ItemsExportIncludeSiteLevelResourcesSchema = zod_1.z.object({
2976
2992
  is: zod_1.z.enum(['true', 'false']).optional(),
@@ -3085,8 +3101,8 @@ const ItemPricesExportCurrencyCodeSchema = zod_1.z.object({
3085
3101
  not_in: zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')).optional(),
3086
3102
  });
3087
3103
  const ItemPricesExportBusinessEntityIdSchema = zod_1.z.object({
3088
- is_present: zod_1.z.enum(['true', 'false']).optional(),
3089
3104
  is: zod_1.z.string().min(1).optional(),
3105
+ is_present: zod_1.z.enum(['true', 'false']).optional(),
3090
3106
  });
3091
3107
  const ItemPricesExportIncludeSiteLevelResourcesSchema = zod_1.z.object({
3092
3108
  is: zod_1.z.enum(['true', 'false']).optional(),
@@ -3346,8 +3362,8 @@ const DifferentialPricesExportBodySchema = zod_1.z.looseObject({
3346
3362
  exports.DifferentialPricesExportBodySchema = DifferentialPricesExportBodySchema;
3347
3363
  //Export.priceVariants
3348
3364
  const PriceVariantsExportBusinessEntityIdSchema = zod_1.z.object({
3349
- is_present: zod_1.z.enum(['true', 'false']).optional(),
3350
3365
  is: zod_1.z.string().min(1).optional(),
3366
+ is_present: zod_1.z.enum(['true', 'false']).optional(),
3351
3367
  });
3352
3368
  const PriceVariantsExportIncludeSiteLevelResourcesSchema = zod_1.z.object({
3353
3369
  is: zod_1.z.enum(['true', 'false']).optional(),
@@ -73,6 +73,10 @@ const CreateGiftPaymentIntentSchema = zod_1.z.object({
73
73
  'paynow',
74
74
  'bizum',
75
75
  'promptpay',
76
+ 'dana',
77
+ 'touch_n_go',
78
+ 'tamara',
79
+ 'qpay',
76
80
  ])
77
81
  .optional(),
78
82
  reference_id: zod_1.z.string().max(65000).optional(),
@@ -190,6 +194,10 @@ const CreateForItemsGiftPaymentIntentSchema = zod_1.z.object({
190
194
  'paynow',
191
195
  'bizum',
192
196
  'promptpay',
197
+ 'dana',
198
+ 'touch_n_go',
199
+ 'tamara',
200
+ 'qpay',
193
201
  ])
194
202
  .optional(),
195
203
  reference_id: zod_1.z.string().max(65000).optional(),
@@ -12,6 +12,9 @@ const ListGrantBlocksGrantBlockSubscriptionIdSchema = zod_1.z.object({
12
12
  const ListGrantBlocksGrantBlockUnitIdSchema = zod_1.z.object({
13
13
  is: zod_1.z.string().min(1).optional(),
14
14
  });
15
+ const ListGrantBlocksGrantBlockAccountTypeSchema = zod_1.z.object({
16
+ is: zod_1.z.enum(['provisioned', 'overdraft']).optional(),
17
+ });
15
18
  const ListGrantBlocksGrantBlockEffectiveFromSchema = zod_1.z.object({
16
19
  after: zod_1.z.string().regex(RegExp('^\\d{10}$')).optional(),
17
20
  before: zod_1.z.string().regex(RegExp('^\\d{10}$')).optional(),
@@ -39,6 +42,7 @@ const ListGrantBlocksGrantBlockBodySchema = zod_1.z.looseObject({
39
42
  offset: zod_1.z.string().max(1000).optional(),
40
43
  subscription_id: ListGrantBlocksGrantBlockSubscriptionIdSchema,
41
44
  unit_id: ListGrantBlocksGrantBlockUnitIdSchema.optional(),
45
+ account_type: ListGrantBlocksGrantBlockAccountTypeSchema.optional(),
42
46
  effective_from: ListGrantBlocksGrantBlockEffectiveFromSchema.optional(),
43
47
  expires_at: ListGrantBlocksGrantBlockExpiresAtSchema.optional(),
44
48
  created_at: ListGrantBlocksGrantBlockCreatedAtSchema.optional(),
@@ -27,6 +27,7 @@ __exportStar(require("./coupon.schema.js"), exports);
27
27
  __exportStar(require("./coupon_code.schema.js"), exports);
28
28
  __exportStar(require("./coupon_set.schema.js"), exports);
29
29
  __exportStar(require("./credit_note.schema.js"), exports);
30
+ __exportStar(require("./credit_unit.schema.js"), exports);
30
31
  __exportStar(require("./currency.schema.js"), exports);
31
32
  __exportStar(require("./customer.schema.js"), exports);
32
33
  __exportStar(require("./customer_entitlement.schema.js"), exports);