chargebee 3.35.0 → 3.36.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.
- package/CHANGELOG.md +65 -0
- package/cjs/environment.js +1 -1
- package/cjs/resources/api_endpoints.js +56 -0
- package/cjs/resources/webhook/eventType.js +2 -0
- package/cjs/schema/addon.schema.js +221 -40
- package/cjs/schema/alert.schema.js +17 -2
- package/cjs/schema/alert_status.schema.js +6 -1
- package/cjs/schema/attached_item.schema.js +101 -26
- package/cjs/schema/business_entity.schema.js +16 -5
- package/cjs/schema/business_rule.schema.js +2 -2
- package/cjs/schema/business_ruleset.schema.js +2 -2
- package/cjs/schema/comment.schema.js +15 -4
- package/cjs/schema/coupon.schema.js +218 -37
- package/cjs/schema/coupon_code.schema.js +36 -6
- package/cjs/schema/coupon_set.schema.js +108 -27
- package/cjs/schema/credit_note.schema.js +496 -105
- package/cjs/schema/credit_unit.schema.js +12 -2
- package/cjs/schema/customer.schema.js +212 -62
- package/cjs/schema/differential_price.schema.js +100 -12
- package/cjs/schema/dispute.schema.js +125 -33
- package/cjs/schema/einvoice.schema.js +27 -6
- package/cjs/schema/email_log.schema.js +15 -4
- package/cjs/schema/entitlement.schema.js +33 -4
- package/cjs/schema/entitlement_override.schema.js +17 -1
- package/cjs/schema/estimate.schema.js +581 -36
- package/cjs/schema/event.schema.js +1282 -633
- package/cjs/schema/export.schema.js +4459 -1412
- package/cjs/schema/feature.schema.js +73 -11
- package/cjs/schema/gateway_request_log.schema.js +309 -0
- package/cjs/schema/gateway_webhook_log.schema.js +257 -0
- package/cjs/schema/gift.schema.js +51 -5
- package/cjs/schema/grant_block.schema.js +45 -12
- package/cjs/schema/hosted_page.schema.js +562 -66
- package/cjs/schema/index.js +3 -0
- package/cjs/schema/invoice.schema.js +821 -121
- package/cjs/schema/item.schema.js +151 -28
- package/cjs/schema/item_entitlement.schema.js +23 -2
- package/cjs/schema/item_family.schema.js +29 -8
- package/cjs/schema/item_price.schema.js +263 -48
- package/cjs/schema/ledger_operation.schema.js +42 -15
- package/cjs/schema/metered_feature.schema.js +10 -1
- package/cjs/schema/omnichannel_one_time_order.schema.js +32 -2
- package/cjs/schema/omnichannel_subscription.schema.js +136 -30
- package/cjs/schema/order.schema.js +233 -61
- package/cjs/schema/organization_detail.schema.js +36 -0
- package/cjs/schema/payment_schedule.schema.js +39 -8
- package/cjs/schema/payment_schedule_scheme.schema.js +37 -7
- package/cjs/schema/payment_source.schema.js +360 -148
- package/cjs/schema/payment_voucher.schema.js +33 -5
- package/cjs/schema/plan.schema.js +345 -57
- package/cjs/schema/price_ramp.schema.js +79 -14
- package/cjs/schema/price_variant.schema.js +88 -18
- package/cjs/schema/pricing_page_session.schema.js +36 -2
- package/cjs/schema/promotional_credit.schema.js +27 -6
- package/cjs/schema/purchase.schema.js +204 -12
- package/cjs/schema/quote.schema.js +901 -81
- package/cjs/schema/quote_entitlement.schema.js +6 -2
- package/cjs/schema/ramp.schema.js +238 -24
- package/cjs/schema/site_migration_detail.schema.js +50 -16
- package/cjs/schema/subscription.schema.js +998 -169
- package/cjs/schema/subscription_entitlement.schema.js +9 -1
- package/cjs/schema/transaction.schema.js +780 -342
- package/cjs/schema/unbilled_charge.schema.js +141 -13
- package/cjs/schema/usage.schema.js +55 -12
- package/cjs/schema/usage_event.schema.js +13 -1
- package/cjs/schema/virtual_bank_account.schema.js +42 -10
- package/cjs/schema/webhook_endpoint.schema.js +4 -0
- package/esm/environment.js +1 -1
- package/esm/resources/api_endpoints.js +56 -0
- package/esm/resources/webhook/eventType.js +2 -0
- package/esm/schema/addon.schema.js +221 -40
- package/esm/schema/alert.schema.js +17 -2
- package/esm/schema/alert_status.schema.js +6 -1
- package/esm/schema/attached_item.schema.js +101 -26
- package/esm/schema/business_entity.schema.js +16 -5
- package/esm/schema/business_rule.schema.js +2 -2
- package/esm/schema/business_ruleset.schema.js +2 -2
- package/esm/schema/comment.schema.js +15 -4
- package/esm/schema/coupon.schema.js +218 -37
- package/esm/schema/coupon_code.schema.js +36 -6
- package/esm/schema/coupon_set.schema.js +108 -27
- package/esm/schema/credit_note.schema.js +496 -105
- package/esm/schema/credit_unit.schema.js +12 -2
- package/esm/schema/customer.schema.js +212 -62
- package/esm/schema/differential_price.schema.js +100 -12
- package/esm/schema/dispute.schema.js +125 -33
- package/esm/schema/einvoice.schema.js +27 -6
- package/esm/schema/email_log.schema.js +15 -4
- package/esm/schema/entitlement.schema.js +33 -4
- package/esm/schema/entitlement_override.schema.js +17 -1
- package/esm/schema/estimate.schema.js +581 -36
- package/esm/schema/event.schema.js +1282 -633
- package/esm/schema/export.schema.js +4459 -1412
- package/esm/schema/feature.schema.js +73 -11
- package/esm/schema/gateway_request_log.schema.js +306 -0
- package/esm/schema/gateway_webhook_log.schema.js +254 -0
- package/esm/schema/gift.schema.js +51 -5
- package/esm/schema/grant_block.schema.js +45 -12
- package/esm/schema/hosted_page.schema.js +562 -66
- package/esm/schema/index.js +3 -0
- package/esm/schema/invoice.schema.js +821 -121
- package/esm/schema/item.schema.js +151 -28
- package/esm/schema/item_entitlement.schema.js +23 -2
- package/esm/schema/item_family.schema.js +29 -8
- package/esm/schema/item_price.schema.js +263 -48
- package/esm/schema/ledger_operation.schema.js +42 -15
- package/esm/schema/metered_feature.schema.js +10 -1
- package/esm/schema/omnichannel_one_time_order.schema.js +32 -2
- package/esm/schema/omnichannel_subscription.schema.js +136 -30
- package/esm/schema/order.schema.js +233 -61
- package/esm/schema/organization_detail.schema.js +33 -0
- package/esm/schema/payment_schedule.schema.js +39 -8
- package/esm/schema/payment_schedule_scheme.schema.js +37 -7
- package/esm/schema/payment_source.schema.js +360 -148
- package/esm/schema/payment_voucher.schema.js +33 -5
- package/esm/schema/plan.schema.js +345 -57
- package/esm/schema/price_ramp.schema.js +79 -14
- package/esm/schema/price_variant.schema.js +88 -18
- package/esm/schema/pricing_page_session.schema.js +36 -2
- package/esm/schema/promotional_credit.schema.js +27 -6
- package/esm/schema/purchase.schema.js +204 -12
- package/esm/schema/quote.schema.js +901 -81
- package/esm/schema/quote_entitlement.schema.js +6 -2
- package/esm/schema/ramp.schema.js +238 -24
- package/esm/schema/site_migration_detail.schema.js +50 -16
- package/esm/schema/subscription.schema.js +998 -169
- package/esm/schema/subscription_entitlement.schema.js +9 -1
- package/esm/schema/transaction.schema.js +780 -342
- package/esm/schema/unbilled_charge.schema.js +141 -13
- package/esm/schema/usage.schema.js +55 -12
- package/esm/schema/usage_event.schema.js +13 -1
- package/esm/schema/virtual_bank_account.schema.js +42 -10
- package/esm/schema/webhook_endpoint.schema.js +4 -0
- package/package.json +1 -1
- package/types/core.d.ts +10 -6
- package/types/index.d.ts +8 -1
- package/types/resources/BillingLineItem.d.ts +10 -0
- package/types/resources/BillingMetadata.d.ts +9 -0
- package/types/resources/Content.d.ts +5 -0
- package/types/resources/Discount.d.ts +1 -0
- package/types/resources/DraftRequest.d.ts +1 -1
- package/types/resources/Estimate.d.ts +3 -0
- package/types/resources/Event.d.ts +2 -0
- package/types/resources/GatewayRequestLog.d.ts +82 -0
- package/types/resources/GatewayWebhookLog.d.ts +74 -0
- package/types/resources/GrantBlock.d.ts +5 -0
- package/types/resources/HostedPage.d.ts +18 -0
- package/types/resources/Invoice.d.ts +4 -0
- package/types/resources/OrganizationDetail.d.ts +84 -0
- package/types/resources/Subscription.d.ts +3 -0
- package/types/resources/Usage.d.ts +1 -0
- package/types/resources/WebhookEvent.d.ts +10 -0
|
@@ -6,6 +6,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.ListPaymentScheduleSchemeBodySchema = exports.CreatePaymentScheduleSchemeBodySchema = void 0;
|
|
7
7
|
const zod_1 = require("zod");
|
|
8
8
|
//PaymentScheduleScheme.create
|
|
9
|
+
const CreatePaymentScheduleSchemeFlexibleSchedulesItemSchema = zod_1.z.object({
|
|
10
|
+
period: zod_1.z.number().int().min(0).max(52).optional(),
|
|
11
|
+
amount_percentage: zod_1.z.number().min(1).max(100).optional(),
|
|
12
|
+
});
|
|
9
13
|
const CreatePaymentScheduleSchemeFlexibleSchedulesSchema = zod_1.z.object({
|
|
10
14
|
period: zod_1.z.array(zod_1.z.number().int().min(0).max(52).optional()).optional(),
|
|
11
15
|
amount_percentage: zod_1.z.array(zod_1.z.number().min(1).max(100).optional()).optional(),
|
|
@@ -15,7 +19,12 @@ const CreatePaymentScheduleSchemeBodySchema = zod_1.z.looseObject({
|
|
|
15
19
|
period_unit: zod_1.z.enum(['day', 'week', 'month']),
|
|
16
20
|
period: zod_1.z.number().int().min(1).max(30).optional(),
|
|
17
21
|
name: zod_1.z.string().max(100),
|
|
18
|
-
flexible_schedules:
|
|
22
|
+
flexible_schedules: zod_1.z
|
|
23
|
+
.union([
|
|
24
|
+
zod_1.z.array(CreatePaymentScheduleSchemeFlexibleSchedulesItemSchema.optional()),
|
|
25
|
+
CreatePaymentScheduleSchemeFlexibleSchedulesSchema,
|
|
26
|
+
])
|
|
27
|
+
.optional(),
|
|
19
28
|
});
|
|
20
29
|
exports.CreatePaymentScheduleSchemeBodySchema = CreatePaymentScheduleSchemeBodySchema;
|
|
21
30
|
//PaymentScheduleScheme.list
|
|
@@ -23,14 +32,35 @@ const ListPaymentScheduleSchemeIdSchema = zod_1.z.object({
|
|
|
23
32
|
is: zod_1.z.string().min(1).optional(),
|
|
24
33
|
is_not: zod_1.z.string().min(1).optional(),
|
|
25
34
|
starts_with: zod_1.z.string().min(1).optional(),
|
|
26
|
-
in: zod_1.z
|
|
27
|
-
|
|
35
|
+
in: zod_1.z
|
|
36
|
+
.union([
|
|
37
|
+
zod_1.z.array(zod_1.z.string().optional()),
|
|
38
|
+
zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')),
|
|
39
|
+
])
|
|
40
|
+
.optional(),
|
|
41
|
+
not_in: zod_1.z
|
|
42
|
+
.union([
|
|
43
|
+
zod_1.z.array(zod_1.z.string().optional()),
|
|
44
|
+
zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')),
|
|
45
|
+
])
|
|
46
|
+
.optional(),
|
|
28
47
|
});
|
|
29
48
|
const ListPaymentScheduleSchemeUpdatedAtSchema = zod_1.z.object({
|
|
30
|
-
after: zod_1.z
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
49
|
+
after: zod_1.z
|
|
50
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
51
|
+
.optional(),
|
|
52
|
+
before: zod_1.z
|
|
53
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
54
|
+
.optional(),
|
|
55
|
+
on: zod_1.z
|
|
56
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
57
|
+
.optional(),
|
|
58
|
+
between: zod_1.z
|
|
59
|
+
.union([
|
|
60
|
+
zod_1.z.array(zod_1.z.number().int().optional()).min(2).max(2),
|
|
61
|
+
zod_1.z.string().regex(RegExp('^\\[\\d{10},\\d{10}\\]$')),
|
|
62
|
+
])
|
|
63
|
+
.optional(),
|
|
34
64
|
});
|
|
35
65
|
const ListPaymentScheduleSchemeBodySchema = zod_1.z.looseObject({
|
|
36
66
|
limit: zod_1.z.number().int().min(1).max(100).optional(),
|
|
@@ -459,8 +459,18 @@ const ListPaymentSourceCustomerIdSchema = zod_1.z.object({
|
|
|
459
459
|
is: zod_1.z.string().min(1).optional(),
|
|
460
460
|
is_not: zod_1.z.string().min(1).optional(),
|
|
461
461
|
starts_with: zod_1.z.string().min(1).optional(),
|
|
462
|
-
in: zod_1.z
|
|
463
|
-
|
|
462
|
+
in: zod_1.z
|
|
463
|
+
.union([
|
|
464
|
+
zod_1.z.array(zod_1.z.string().optional()),
|
|
465
|
+
zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')),
|
|
466
|
+
])
|
|
467
|
+
.optional(),
|
|
468
|
+
not_in: zod_1.z
|
|
469
|
+
.union([
|
|
470
|
+
zod_1.z.array(zod_1.z.string().optional()),
|
|
471
|
+
zod_1.z.string().regex(RegExp('^\\[(.*)(,.*)*\\]$')),
|
|
472
|
+
])
|
|
473
|
+
.optional(),
|
|
464
474
|
});
|
|
465
475
|
const ListPaymentSourceTypeSchema = zod_1.z.object({
|
|
466
476
|
is: zod_1.z
|
|
@@ -606,145 +616,291 @@ const ListPaymentSourceTypeSchema = zod_1.z.object({
|
|
|
606
616
|
])
|
|
607
617
|
.optional(),
|
|
608
618
|
in: zod_1.z
|
|
609
|
-
.
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
619
|
+
.union([
|
|
620
|
+
zod_1.z.array(zod_1.z
|
|
621
|
+
.enum([
|
|
622
|
+
'card',
|
|
623
|
+
'paypal_express_checkout',
|
|
624
|
+
'amazon_payments',
|
|
625
|
+
'direct_debit',
|
|
626
|
+
'generic',
|
|
627
|
+
'alipay',
|
|
628
|
+
'unionpay',
|
|
629
|
+
'apple_pay',
|
|
630
|
+
'wechat_pay',
|
|
631
|
+
'ideal',
|
|
632
|
+
'google_pay',
|
|
633
|
+
'sofort',
|
|
634
|
+
'bancontact',
|
|
635
|
+
'giropay',
|
|
636
|
+
'dotpay',
|
|
637
|
+
'upi',
|
|
638
|
+
'netbanking_emandates',
|
|
639
|
+
'venmo',
|
|
640
|
+
'pay_to',
|
|
641
|
+
'faster_payments',
|
|
642
|
+
'sepa_instant_transfer',
|
|
643
|
+
'automated_bank_transfer',
|
|
644
|
+
'klarna_pay_now',
|
|
645
|
+
'online_banking_poland',
|
|
646
|
+
'payconiq_by_bancontact',
|
|
647
|
+
'electronic_payment_standard',
|
|
648
|
+
'kbc_payment_button',
|
|
649
|
+
'pay_by_bank',
|
|
650
|
+
'trustly',
|
|
651
|
+
'stablecoin',
|
|
652
|
+
'kakao_pay',
|
|
653
|
+
'naver_pay',
|
|
654
|
+
'revolut_pay',
|
|
655
|
+
'cash_app_pay',
|
|
656
|
+
'twint',
|
|
657
|
+
'go_pay',
|
|
658
|
+
'grab_pay',
|
|
659
|
+
'pay_co',
|
|
660
|
+
'after_pay',
|
|
661
|
+
'swish',
|
|
662
|
+
'payme',
|
|
663
|
+
'pix',
|
|
664
|
+
'klarna',
|
|
665
|
+
'alipay_hk',
|
|
666
|
+
'paypay',
|
|
667
|
+
'gcash',
|
|
668
|
+
'south_korean_cards',
|
|
669
|
+
'paynow',
|
|
670
|
+
'bizum',
|
|
671
|
+
'promptpay',
|
|
672
|
+
'dana',
|
|
673
|
+
'touch_n_go',
|
|
674
|
+
'tamara',
|
|
675
|
+
'qpay',
|
|
676
|
+
'ovo',
|
|
677
|
+
'momo',
|
|
678
|
+
'mercado_pago',
|
|
679
|
+
'nequi',
|
|
680
|
+
'nupay',
|
|
681
|
+
'picpay',
|
|
682
|
+
'thai_qr',
|
|
683
|
+
'blik',
|
|
684
|
+
'fpx',
|
|
685
|
+
'wero',
|
|
686
|
+
'p24',
|
|
687
|
+
'affirm_pay',
|
|
688
|
+
'rakuten_pay',
|
|
689
|
+
])
|
|
690
|
+
.optional()),
|
|
691
|
+
zod_1.z.enum([
|
|
692
|
+
'card',
|
|
693
|
+
'paypal_express_checkout',
|
|
694
|
+
'amazon_payments',
|
|
695
|
+
'direct_debit',
|
|
696
|
+
'generic',
|
|
697
|
+
'alipay',
|
|
698
|
+
'unionpay',
|
|
699
|
+
'apple_pay',
|
|
700
|
+
'wechat_pay',
|
|
701
|
+
'ideal',
|
|
702
|
+
'google_pay',
|
|
703
|
+
'sofort',
|
|
704
|
+
'bancontact',
|
|
705
|
+
'giropay',
|
|
706
|
+
'dotpay',
|
|
707
|
+
'upi',
|
|
708
|
+
'netbanking_emandates',
|
|
709
|
+
'venmo',
|
|
710
|
+
'pay_to',
|
|
711
|
+
'faster_payments',
|
|
712
|
+
'sepa_instant_transfer',
|
|
713
|
+
'automated_bank_transfer',
|
|
714
|
+
'klarna_pay_now',
|
|
715
|
+
'online_banking_poland',
|
|
716
|
+
'payconiq_by_bancontact',
|
|
717
|
+
'electronic_payment_standard',
|
|
718
|
+
'kbc_payment_button',
|
|
719
|
+
'pay_by_bank',
|
|
720
|
+
'trustly',
|
|
721
|
+
'stablecoin',
|
|
722
|
+
'kakao_pay',
|
|
723
|
+
'naver_pay',
|
|
724
|
+
'revolut_pay',
|
|
725
|
+
'cash_app_pay',
|
|
726
|
+
'twint',
|
|
727
|
+
'go_pay',
|
|
728
|
+
'grab_pay',
|
|
729
|
+
'pay_co',
|
|
730
|
+
'after_pay',
|
|
731
|
+
'swish',
|
|
732
|
+
'payme',
|
|
733
|
+
'pix',
|
|
734
|
+
'klarna',
|
|
735
|
+
'alipay_hk',
|
|
736
|
+
'paypay',
|
|
737
|
+
'gcash',
|
|
738
|
+
'south_korean_cards',
|
|
739
|
+
'paynow',
|
|
740
|
+
'bizum',
|
|
741
|
+
'promptpay',
|
|
742
|
+
'dana',
|
|
743
|
+
'touch_n_go',
|
|
744
|
+
'tamara',
|
|
745
|
+
'qpay',
|
|
746
|
+
'ovo',
|
|
747
|
+
'momo',
|
|
748
|
+
'mercado_pago',
|
|
749
|
+
'nequi',
|
|
750
|
+
'nupay',
|
|
751
|
+
'picpay',
|
|
752
|
+
'thai_qr',
|
|
753
|
+
'blik',
|
|
754
|
+
'fpx',
|
|
755
|
+
'wero',
|
|
756
|
+
'p24',
|
|
757
|
+
'affirm_pay',
|
|
758
|
+
'rakuten_pay',
|
|
759
|
+
]),
|
|
677
760
|
])
|
|
678
761
|
.optional(),
|
|
679
762
|
not_in: zod_1.z
|
|
680
|
-
.
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
763
|
+
.union([
|
|
764
|
+
zod_1.z.array(zod_1.z
|
|
765
|
+
.enum([
|
|
766
|
+
'card',
|
|
767
|
+
'paypal_express_checkout',
|
|
768
|
+
'amazon_payments',
|
|
769
|
+
'direct_debit',
|
|
770
|
+
'generic',
|
|
771
|
+
'alipay',
|
|
772
|
+
'unionpay',
|
|
773
|
+
'apple_pay',
|
|
774
|
+
'wechat_pay',
|
|
775
|
+
'ideal',
|
|
776
|
+
'google_pay',
|
|
777
|
+
'sofort',
|
|
778
|
+
'bancontact',
|
|
779
|
+
'giropay',
|
|
780
|
+
'dotpay',
|
|
781
|
+
'upi',
|
|
782
|
+
'netbanking_emandates',
|
|
783
|
+
'venmo',
|
|
784
|
+
'pay_to',
|
|
785
|
+
'faster_payments',
|
|
786
|
+
'sepa_instant_transfer',
|
|
787
|
+
'automated_bank_transfer',
|
|
788
|
+
'klarna_pay_now',
|
|
789
|
+
'online_banking_poland',
|
|
790
|
+
'payconiq_by_bancontact',
|
|
791
|
+
'electronic_payment_standard',
|
|
792
|
+
'kbc_payment_button',
|
|
793
|
+
'pay_by_bank',
|
|
794
|
+
'trustly',
|
|
795
|
+
'stablecoin',
|
|
796
|
+
'kakao_pay',
|
|
797
|
+
'naver_pay',
|
|
798
|
+
'revolut_pay',
|
|
799
|
+
'cash_app_pay',
|
|
800
|
+
'twint',
|
|
801
|
+
'go_pay',
|
|
802
|
+
'grab_pay',
|
|
803
|
+
'pay_co',
|
|
804
|
+
'after_pay',
|
|
805
|
+
'swish',
|
|
806
|
+
'payme',
|
|
807
|
+
'pix',
|
|
808
|
+
'klarna',
|
|
809
|
+
'alipay_hk',
|
|
810
|
+
'paypay',
|
|
811
|
+
'gcash',
|
|
812
|
+
'south_korean_cards',
|
|
813
|
+
'paynow',
|
|
814
|
+
'bizum',
|
|
815
|
+
'promptpay',
|
|
816
|
+
'dana',
|
|
817
|
+
'touch_n_go',
|
|
818
|
+
'tamara',
|
|
819
|
+
'qpay',
|
|
820
|
+
'ovo',
|
|
821
|
+
'momo',
|
|
822
|
+
'mercado_pago',
|
|
823
|
+
'nequi',
|
|
824
|
+
'nupay',
|
|
825
|
+
'picpay',
|
|
826
|
+
'thai_qr',
|
|
827
|
+
'blik',
|
|
828
|
+
'fpx',
|
|
829
|
+
'wero',
|
|
830
|
+
'p24',
|
|
831
|
+
'affirm_pay',
|
|
832
|
+
'rakuten_pay',
|
|
833
|
+
])
|
|
834
|
+
.optional()),
|
|
835
|
+
zod_1.z.enum([
|
|
836
|
+
'card',
|
|
837
|
+
'paypal_express_checkout',
|
|
838
|
+
'amazon_payments',
|
|
839
|
+
'direct_debit',
|
|
840
|
+
'generic',
|
|
841
|
+
'alipay',
|
|
842
|
+
'unionpay',
|
|
843
|
+
'apple_pay',
|
|
844
|
+
'wechat_pay',
|
|
845
|
+
'ideal',
|
|
846
|
+
'google_pay',
|
|
847
|
+
'sofort',
|
|
848
|
+
'bancontact',
|
|
849
|
+
'giropay',
|
|
850
|
+
'dotpay',
|
|
851
|
+
'upi',
|
|
852
|
+
'netbanking_emandates',
|
|
853
|
+
'venmo',
|
|
854
|
+
'pay_to',
|
|
855
|
+
'faster_payments',
|
|
856
|
+
'sepa_instant_transfer',
|
|
857
|
+
'automated_bank_transfer',
|
|
858
|
+
'klarna_pay_now',
|
|
859
|
+
'online_banking_poland',
|
|
860
|
+
'payconiq_by_bancontact',
|
|
861
|
+
'electronic_payment_standard',
|
|
862
|
+
'kbc_payment_button',
|
|
863
|
+
'pay_by_bank',
|
|
864
|
+
'trustly',
|
|
865
|
+
'stablecoin',
|
|
866
|
+
'kakao_pay',
|
|
867
|
+
'naver_pay',
|
|
868
|
+
'revolut_pay',
|
|
869
|
+
'cash_app_pay',
|
|
870
|
+
'twint',
|
|
871
|
+
'go_pay',
|
|
872
|
+
'grab_pay',
|
|
873
|
+
'pay_co',
|
|
874
|
+
'after_pay',
|
|
875
|
+
'swish',
|
|
876
|
+
'payme',
|
|
877
|
+
'pix',
|
|
878
|
+
'klarna',
|
|
879
|
+
'alipay_hk',
|
|
880
|
+
'paypay',
|
|
881
|
+
'gcash',
|
|
882
|
+
'south_korean_cards',
|
|
883
|
+
'paynow',
|
|
884
|
+
'bizum',
|
|
885
|
+
'promptpay',
|
|
886
|
+
'dana',
|
|
887
|
+
'touch_n_go',
|
|
888
|
+
'tamara',
|
|
889
|
+
'qpay',
|
|
890
|
+
'ovo',
|
|
891
|
+
'momo',
|
|
892
|
+
'mercado_pago',
|
|
893
|
+
'nequi',
|
|
894
|
+
'nupay',
|
|
895
|
+
'picpay',
|
|
896
|
+
'thai_qr',
|
|
897
|
+
'blik',
|
|
898
|
+
'fpx',
|
|
899
|
+
'wero',
|
|
900
|
+
'p24',
|
|
901
|
+
'affirm_pay',
|
|
902
|
+
'rakuten_pay',
|
|
903
|
+
]),
|
|
748
904
|
])
|
|
749
905
|
.optional(),
|
|
750
906
|
});
|
|
@@ -756,23 +912,79 @@ const ListPaymentSourceStatusSchema = zod_1.z.object({
|
|
|
756
912
|
.enum(['valid', 'expiring', 'expired', 'invalid', 'pending_verification'])
|
|
757
913
|
.optional(),
|
|
758
914
|
in: zod_1.z
|
|
759
|
-
.
|
|
915
|
+
.union([
|
|
916
|
+
zod_1.z.array(zod_1.z
|
|
917
|
+
.enum([
|
|
918
|
+
'valid',
|
|
919
|
+
'expiring',
|
|
920
|
+
'expired',
|
|
921
|
+
'invalid',
|
|
922
|
+
'pending_verification',
|
|
923
|
+
])
|
|
924
|
+
.optional()),
|
|
925
|
+
zod_1.z.enum([
|
|
926
|
+
'valid',
|
|
927
|
+
'expiring',
|
|
928
|
+
'expired',
|
|
929
|
+
'invalid',
|
|
930
|
+
'pending_verification',
|
|
931
|
+
]),
|
|
932
|
+
])
|
|
760
933
|
.optional(),
|
|
761
934
|
not_in: zod_1.z
|
|
762
|
-
.
|
|
935
|
+
.union([
|
|
936
|
+
zod_1.z.array(zod_1.z
|
|
937
|
+
.enum([
|
|
938
|
+
'valid',
|
|
939
|
+
'expiring',
|
|
940
|
+
'expired',
|
|
941
|
+
'invalid',
|
|
942
|
+
'pending_verification',
|
|
943
|
+
])
|
|
944
|
+
.optional()),
|
|
945
|
+
zod_1.z.enum([
|
|
946
|
+
'valid',
|
|
947
|
+
'expiring',
|
|
948
|
+
'expired',
|
|
949
|
+
'invalid',
|
|
950
|
+
'pending_verification',
|
|
951
|
+
]),
|
|
952
|
+
])
|
|
763
953
|
.optional(),
|
|
764
954
|
});
|
|
765
955
|
const ListPaymentSourceUpdatedAtSchema = zod_1.z.object({
|
|
766
|
-
after: zod_1.z
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
956
|
+
after: zod_1.z
|
|
957
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
958
|
+
.optional(),
|
|
959
|
+
before: zod_1.z
|
|
960
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
961
|
+
.optional(),
|
|
962
|
+
on: zod_1.z
|
|
963
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
964
|
+
.optional(),
|
|
965
|
+
between: zod_1.z
|
|
966
|
+
.union([
|
|
967
|
+
zod_1.z.array(zod_1.z.number().int().optional()).min(2).max(2),
|
|
968
|
+
zod_1.z.string().regex(RegExp('^\\[\\d{10},\\d{10}\\]$')),
|
|
969
|
+
])
|
|
970
|
+
.optional(),
|
|
770
971
|
});
|
|
771
972
|
const ListPaymentSourceCreatedAtSchema = zod_1.z.object({
|
|
772
|
-
after: zod_1.z
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
973
|
+
after: zod_1.z
|
|
974
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
975
|
+
.optional(),
|
|
976
|
+
before: zod_1.z
|
|
977
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
978
|
+
.optional(),
|
|
979
|
+
on: zod_1.z
|
|
980
|
+
.union([zod_1.z.number().int(), zod_1.z.string().regex(RegExp('^\\d{10}$'))])
|
|
981
|
+
.optional(),
|
|
982
|
+
between: zod_1.z
|
|
983
|
+
.union([
|
|
984
|
+
zod_1.z.array(zod_1.z.number().int().optional()).min(2).max(2),
|
|
985
|
+
zod_1.z.string().regex(RegExp('^\\[\\d{10},\\d{10}\\]$')),
|
|
986
|
+
])
|
|
987
|
+
.optional(),
|
|
776
988
|
});
|
|
777
989
|
const ListPaymentSourceSortBySchema = zod_1.z.looseObject({
|
|
778
990
|
asc: zod_1.z.enum(['created_at', 'updated_at']).optional(),
|
|
@@ -9,6 +9,9 @@ const zod_1 = require("zod");
|
|
|
9
9
|
const CreatePaymentVoucherVoucherPaymentSourceSchema = zod_1.z.object({
|
|
10
10
|
voucher_type: zod_1.z.enum(['boleto']),
|
|
11
11
|
});
|
|
12
|
+
const CreatePaymentVoucherInvoiceAllocationsItemSchema = zod_1.z.object({
|
|
13
|
+
invoice_id: zod_1.z.string().max(50),
|
|
14
|
+
});
|
|
12
15
|
const CreatePaymentVoucherInvoiceAllocationsSchema = zod_1.z.object({
|
|
13
16
|
invoice_id: zod_1.z.array(zod_1.z.string().max(50).optional()),
|
|
14
17
|
});
|
|
@@ -16,15 +19,30 @@ const CreatePaymentVoucherBodySchema = zod_1.z.looseObject({
|
|
|
16
19
|
customer_id: zod_1.z.string().max(50),
|
|
17
20
|
payment_source_id: zod_1.z.string().max(40).optional(),
|
|
18
21
|
voucher_payment_source: CreatePaymentVoucherVoucherPaymentSourceSchema.optional(),
|
|
19
|
-
invoice_allocations:
|
|
22
|
+
invoice_allocations: zod_1.z
|
|
23
|
+
.union([
|
|
24
|
+
zod_1.z.array(CreatePaymentVoucherInvoiceAllocationsItemSchema.optional()),
|
|
25
|
+
CreatePaymentVoucherInvoiceAllocationsSchema,
|
|
26
|
+
])
|
|
27
|
+
.optional(),
|
|
20
28
|
});
|
|
21
29
|
exports.CreatePaymentVoucherBodySchema = CreatePaymentVoucherBodySchema;
|
|
22
30
|
//PaymentVoucher.payment_vouchersForInvoice
|
|
23
31
|
const PaymentVouchersforinvoicePaymentVoucherStatusSchema = zod_1.z.object({
|
|
24
32
|
is: zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional(),
|
|
25
33
|
is_not: zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional(),
|
|
26
|
-
in: zod_1.z
|
|
27
|
-
|
|
34
|
+
in: zod_1.z
|
|
35
|
+
.union([
|
|
36
|
+
zod_1.z.array(zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional()),
|
|
37
|
+
zod_1.z.enum(['active', 'consumed', 'expired', 'failure']),
|
|
38
|
+
])
|
|
39
|
+
.optional(),
|
|
40
|
+
not_in: zod_1.z
|
|
41
|
+
.union([
|
|
42
|
+
zod_1.z.array(zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional()),
|
|
43
|
+
zod_1.z.enum(['active', 'consumed', 'expired', 'failure']),
|
|
44
|
+
])
|
|
45
|
+
.optional(),
|
|
28
46
|
});
|
|
29
47
|
const PaymentVouchersforinvoicePaymentVoucherSortBySchema = zod_1.z.looseObject({
|
|
30
48
|
asc: zod_1.z.enum(['date', 'updated_at']).optional(),
|
|
@@ -41,8 +59,18 @@ exports.PaymentVouchersforinvoicePaymentVoucherBodySchema = PaymentVouchersforin
|
|
|
41
59
|
const PaymentVouchersforcustomerPaymentVoucherStatusSchema = zod_1.z.object({
|
|
42
60
|
is: zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional(),
|
|
43
61
|
is_not: zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional(),
|
|
44
|
-
in: zod_1.z
|
|
45
|
-
|
|
62
|
+
in: zod_1.z
|
|
63
|
+
.union([
|
|
64
|
+
zod_1.z.array(zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional()),
|
|
65
|
+
zod_1.z.enum(['active', 'consumed', 'expired', 'failure']),
|
|
66
|
+
])
|
|
67
|
+
.optional(),
|
|
68
|
+
not_in: zod_1.z
|
|
69
|
+
.union([
|
|
70
|
+
zod_1.z.array(zod_1.z.enum(['active', 'consumed', 'expired', 'failure']).optional()),
|
|
71
|
+
zod_1.z.enum(['active', 'consumed', 'expired', 'failure']),
|
|
72
|
+
])
|
|
73
|
+
.optional(),
|
|
46
74
|
});
|
|
47
75
|
const PaymentVouchersforcustomerPaymentVoucherSortBySchema = zod_1.z.looseObject({
|
|
48
76
|
asc: zod_1.z.enum(['date', 'updated_at']).optional(),
|