@wix/auto_sdk_subscription_subscriptions 1.0.41 → 1.0.43

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 (37) hide show
  1. package/build/cjs/index.d.ts +2 -2
  2. package/build/cjs/index.js +795 -91
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +690 -51
  5. package/build/cjs/index.typings.js +648 -0
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +666 -51
  8. package/build/cjs/meta.js +506 -0
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/es/index.d.mts +2 -2
  11. package/build/es/index.mjs +785 -91
  12. package/build/es/index.mjs.map +1 -1
  13. package/build/es/index.typings.d.mts +690 -51
  14. package/build/es/index.typings.mjs +638 -0
  15. package/build/es/index.typings.mjs.map +1 -1
  16. package/build/es/meta.d.mts +666 -51
  17. package/build/es/meta.mjs +496 -0
  18. package/build/es/meta.mjs.map +1 -1
  19. package/build/internal/cjs/index.d.ts +90 -4
  20. package/build/internal/cjs/index.js +795 -91
  21. package/build/internal/cjs/index.js.map +1 -1
  22. package/build/internal/cjs/index.typings.d.ts +766 -51
  23. package/build/internal/cjs/index.typings.js +648 -0
  24. package/build/internal/cjs/index.typings.js.map +1 -1
  25. package/build/internal/cjs/meta.d.ts +666 -51
  26. package/build/internal/cjs/meta.js +506 -0
  27. package/build/internal/cjs/meta.js.map +1 -1
  28. package/build/internal/es/index.d.mts +90 -4
  29. package/build/internal/es/index.mjs +785 -91
  30. package/build/internal/es/index.mjs.map +1 -1
  31. package/build/internal/es/index.typings.d.mts +766 -51
  32. package/build/internal/es/index.typings.mjs +638 -0
  33. package/build/internal/es/index.typings.mjs.map +1 -1
  34. package/build/internal/es/meta.d.mts +666 -51
  35. package/build/internal/es/meta.mjs +496 -0
  36. package/build/internal/es/meta.mjs.map +1 -1
  37. package/package.json +2 -2
@@ -24,6 +24,7 @@ __export(index_exports, {
24
24
  ActionType: () => ActionType,
25
25
  AdditionalFeeTrigger: () => AdditionalFeeTrigger,
26
26
  CancellationInitiator: () => CancellationInitiator,
27
+ ChangeEffectiveTime: () => ChangeEffectiveTime,
27
28
  CollectionMethod: () => CollectionMethod,
28
29
  CollectionMethodEnumCollectionMethod: () => CollectionMethodEnumCollectionMethod,
29
30
  CreationMode: () => CreationMode,
@@ -43,6 +44,9 @@ __export(index_exports, {
43
44
  PaymentStatus: () => PaymentStatus,
44
45
  PaymentStatusEnumPaymentStatus: () => PaymentStatusEnumPaymentStatus,
45
46
  PaymentTestMode: () => PaymentTestMode,
47
+ PriceAdjustmentReason: () => PriceAdjustmentReason,
48
+ ProrationAction: () => ProrationAction,
49
+ ProrationBehavior: () => ProrationBehavior,
46
50
  RefundReason: () => RefundReason,
47
51
  RequestedFields: () => RequestedFields,
48
52
  ResumeAt: () => ResumeAt,
@@ -61,14 +65,20 @@ __export(index_exports, {
61
65
  cancelSubscription: () => cancelSubscription4,
62
66
  countSubscriptions: () => countSubscriptions4,
63
67
  customerAllowedActions: () => customerAllowedActions4,
68
+ customerCancelScheduledPause: () => customerCancelScheduledPause4,
69
+ customerCancelScheduledSkip: () => customerCancelScheduledSkip4,
64
70
  customerCancelSubscription: () => customerCancelSubscription4,
65
71
  customerExtendSubscription: () => customerExtendSubscription4,
66
72
  customerGetSubscription: () => customerGetSubscription4,
67
73
  customerInitiatePaymentMethodSetup: () => customerInitiatePaymentMethodSetup4,
68
74
  customerListUpcomingCharges: () => customerListUpcomingCharges4,
75
+ customerPauseSubscription: () => customerPauseSubscription4,
69
76
  customerQuerySubscriptions: () => customerQuerySubscriptions4,
77
+ customerResumeSubscription: () => customerResumeSubscription4,
78
+ customerSkipCycle: () => customerSkipCycle4,
70
79
  customerTurnOffSubscriptionAutoRenewal: () => customerTurnOffSubscriptionAutoRenewal4,
71
80
  customerTurnOnSubscriptionAutoRenewal: () => customerTurnOnSubscriptionAutoRenewal4,
81
+ customerUpdateBillingDate: () => customerUpdateBillingDate4,
72
82
  customerUpdateSubscriptionPaymentMethod: () => customerUpdateSubscriptionPaymentMethod4,
73
83
  extendSubscription: () => extendSubscription4,
74
84
  getSubscription: () => getSubscription4,
@@ -695,6 +705,348 @@ function customerInitiatePaymentMethodSetup(payload) {
695
705
  }
696
706
  return __customerInitiatePaymentMethodSetup;
697
707
  }
708
+ function customerSkipCycle(payload) {
709
+ function __customerSkipCycle({ host }) {
710
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
711
+ {
712
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
713
+ paths: [
714
+ { path: "pauseAtSchedule.specificDate" },
715
+ { path: "autoResumeAtSchedule.specificDate" }
716
+ ]
717
+ }
718
+ ]);
719
+ const metadata = {
720
+ entityFqdn: "wix.billing.v1.subscription",
721
+ method: "POST",
722
+ methodFqn: "com.wixpress.billing.subscriptions.api.v1.CustomerSubscriptionsService.CustomerSkipCycle",
723
+ packageName: PACKAGE_NAME,
724
+ migrationOptions: {
725
+ optInTransformResponse: true
726
+ },
727
+ url: resolveComWixpressBillingSubscriptionsApiV1CustomerSubscriptionsServiceUrl(
728
+ {
729
+ protoPath: "/v1/customer_subscriptions/{id}/skip_cycle",
730
+ data: serializedData,
731
+ host
732
+ }
733
+ ),
734
+ data: serializedData,
735
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
736
+ {
737
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
738
+ paths: [
739
+ { path: "subscription.createdDate" },
740
+ { path: "subscription.updatedDate" },
741
+ { path: "subscription.startDate" },
742
+ { path: "subscription.endDate" },
743
+ { path: "subscription.billingStatus.nextBillingDate" },
744
+ { path: "subscription.billingStatus.previousBillingDate" },
745
+ {
746
+ path: "subscription.billingStatus.latestPaymentData.initialFailedPaymentDate"
747
+ },
748
+ { path: "subscription.billingStatus.freeTrialData.startDate" },
749
+ { path: "subscription.billingStatus.freeTrialData.endDate" },
750
+ {
751
+ path: "subscription.billingStatus.updateBillingDateData.paidUntil"
752
+ },
753
+ { path: "subscription.billingStatus.gracePeriodData.startDate" },
754
+ { path: "subscription.billingStatus.gracePeriodData.endDate" },
755
+ { path: "subscription.pauseInfo.startDate" },
756
+ { path: "subscription.pauseInfo.resumeDate" },
757
+ { path: "subscription.cancellationInfo.cancellationDate" },
758
+ {
759
+ path: "subscription.specificDatePendingUpdateData.executionDate"
760
+ }
761
+ ]
762
+ }
763
+ ])
764
+ };
765
+ return metadata;
766
+ }
767
+ return __customerSkipCycle;
768
+ }
769
+ function customerCancelScheduledSkip(payload) {
770
+ function __customerCancelScheduledSkip({ host }) {
771
+ const metadata = {
772
+ entityFqdn: "wix.billing.v1.subscription",
773
+ method: "POST",
774
+ methodFqn: "com.wixpress.billing.subscriptions.api.v1.CustomerSubscriptionsService.CustomerCancelScheduledSkip",
775
+ packageName: PACKAGE_NAME,
776
+ migrationOptions: {
777
+ optInTransformResponse: true
778
+ },
779
+ url: resolveComWixpressBillingSubscriptionsApiV1CustomerSubscriptionsServiceUrl(
780
+ {
781
+ protoPath: "/v1/customer_subscriptions/{id}/cancel_scheduled_skip",
782
+ data: payload,
783
+ host
784
+ }
785
+ ),
786
+ data: payload,
787
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
788
+ {
789
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
790
+ paths: [
791
+ { path: "subscription.createdDate" },
792
+ { path: "subscription.updatedDate" },
793
+ { path: "subscription.startDate" },
794
+ { path: "subscription.endDate" },
795
+ { path: "subscription.billingStatus.nextBillingDate" },
796
+ { path: "subscription.billingStatus.previousBillingDate" },
797
+ {
798
+ path: "subscription.billingStatus.latestPaymentData.initialFailedPaymentDate"
799
+ },
800
+ { path: "subscription.billingStatus.freeTrialData.startDate" },
801
+ { path: "subscription.billingStatus.freeTrialData.endDate" },
802
+ {
803
+ path: "subscription.billingStatus.updateBillingDateData.paidUntil"
804
+ },
805
+ { path: "subscription.billingStatus.gracePeriodData.startDate" },
806
+ { path: "subscription.billingStatus.gracePeriodData.endDate" },
807
+ { path: "subscription.pauseInfo.startDate" },
808
+ { path: "subscription.pauseInfo.resumeDate" },
809
+ { path: "subscription.cancellationInfo.cancellationDate" },
810
+ {
811
+ path: "subscription.specificDatePendingUpdateData.executionDate"
812
+ }
813
+ ]
814
+ }
815
+ ])
816
+ };
817
+ return metadata;
818
+ }
819
+ return __customerCancelScheduledSkip;
820
+ }
821
+ function customerPauseSubscription(payload) {
822
+ function __customerPauseSubscription({ host }) {
823
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
824
+ {
825
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
826
+ paths: [
827
+ { path: "pauseAtSchedule.specificDate" },
828
+ { path: "autoResumeAtSchedule.specificDate" }
829
+ ]
830
+ }
831
+ ]);
832
+ const metadata = {
833
+ entityFqdn: "wix.billing.v1.subscription",
834
+ method: "POST",
835
+ methodFqn: "com.wixpress.billing.subscriptions.api.v1.CustomerSubscriptionsService.CustomerPauseSubscription",
836
+ packageName: PACKAGE_NAME,
837
+ migrationOptions: {
838
+ optInTransformResponse: true
839
+ },
840
+ url: resolveComWixpressBillingSubscriptionsApiV1CustomerSubscriptionsServiceUrl(
841
+ {
842
+ protoPath: "/v1/customer_subscriptions/{id}/pause",
843
+ data: serializedData,
844
+ host
845
+ }
846
+ ),
847
+ data: serializedData,
848
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
849
+ {
850
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
851
+ paths: [
852
+ { path: "subscription.createdDate" },
853
+ { path: "subscription.updatedDate" },
854
+ { path: "subscription.startDate" },
855
+ { path: "subscription.endDate" },
856
+ { path: "subscription.billingStatus.nextBillingDate" },
857
+ { path: "subscription.billingStatus.previousBillingDate" },
858
+ {
859
+ path: "subscription.billingStatus.latestPaymentData.initialFailedPaymentDate"
860
+ },
861
+ { path: "subscription.billingStatus.freeTrialData.startDate" },
862
+ { path: "subscription.billingStatus.freeTrialData.endDate" },
863
+ {
864
+ path: "subscription.billingStatus.updateBillingDateData.paidUntil"
865
+ },
866
+ { path: "subscription.billingStatus.gracePeriodData.startDate" },
867
+ { path: "subscription.billingStatus.gracePeriodData.endDate" },
868
+ { path: "subscription.pauseInfo.startDate" },
869
+ { path: "subscription.pauseInfo.resumeDate" },
870
+ { path: "subscription.cancellationInfo.cancellationDate" },
871
+ {
872
+ path: "subscription.specificDatePendingUpdateData.executionDate"
873
+ }
874
+ ]
875
+ }
876
+ ])
877
+ };
878
+ return metadata;
879
+ }
880
+ return __customerPauseSubscription;
881
+ }
882
+ function customerResumeSubscription(payload) {
883
+ function __customerResumeSubscription({ host }) {
884
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
885
+ {
886
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
887
+ paths: [{ path: "resumeAtSchedule.specificDate" }]
888
+ }
889
+ ]);
890
+ const metadata = {
891
+ entityFqdn: "wix.billing.v1.subscription",
892
+ method: "POST",
893
+ methodFqn: "com.wixpress.billing.subscriptions.api.v1.CustomerSubscriptionsService.CustomerResumeSubscription",
894
+ packageName: PACKAGE_NAME,
895
+ migrationOptions: {
896
+ optInTransformResponse: true
897
+ },
898
+ url: resolveComWixpressBillingSubscriptionsApiV1CustomerSubscriptionsServiceUrl(
899
+ {
900
+ protoPath: "/v1/customer_subscriptions/{id}/resume",
901
+ data: serializedData,
902
+ host
903
+ }
904
+ ),
905
+ data: serializedData,
906
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
907
+ {
908
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
909
+ paths: [
910
+ { path: "subscription.createdDate" },
911
+ { path: "subscription.updatedDate" },
912
+ { path: "subscription.startDate" },
913
+ { path: "subscription.endDate" },
914
+ { path: "subscription.billingStatus.nextBillingDate" },
915
+ { path: "subscription.billingStatus.previousBillingDate" },
916
+ {
917
+ path: "subscription.billingStatus.latestPaymentData.initialFailedPaymentDate"
918
+ },
919
+ { path: "subscription.billingStatus.freeTrialData.startDate" },
920
+ { path: "subscription.billingStatus.freeTrialData.endDate" },
921
+ {
922
+ path: "subscription.billingStatus.updateBillingDateData.paidUntil"
923
+ },
924
+ { path: "subscription.billingStatus.gracePeriodData.startDate" },
925
+ { path: "subscription.billingStatus.gracePeriodData.endDate" },
926
+ { path: "subscription.pauseInfo.startDate" },
927
+ { path: "subscription.pauseInfo.resumeDate" },
928
+ { path: "subscription.cancellationInfo.cancellationDate" },
929
+ {
930
+ path: "subscription.specificDatePendingUpdateData.executionDate"
931
+ }
932
+ ]
933
+ }
934
+ ])
935
+ };
936
+ return metadata;
937
+ }
938
+ return __customerResumeSubscription;
939
+ }
940
+ function customerCancelScheduledPause(payload) {
941
+ function __customerCancelScheduledPause({ host }) {
942
+ const metadata = {
943
+ entityFqdn: "wix.billing.v1.subscription",
944
+ method: "POST",
945
+ methodFqn: "com.wixpress.billing.subscriptions.api.v1.CustomerSubscriptionsService.CustomerCancelScheduledPause",
946
+ packageName: PACKAGE_NAME,
947
+ migrationOptions: {
948
+ optInTransformResponse: true
949
+ },
950
+ url: resolveComWixpressBillingSubscriptionsApiV1CustomerSubscriptionsServiceUrl(
951
+ {
952
+ protoPath: "/v1/customer_subscriptions/{id}/cancel_scheduled_pause",
953
+ data: payload,
954
+ host
955
+ }
956
+ ),
957
+ data: payload,
958
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
959
+ {
960
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
961
+ paths: [
962
+ { path: "subscription.createdDate" },
963
+ { path: "subscription.updatedDate" },
964
+ { path: "subscription.startDate" },
965
+ { path: "subscription.endDate" },
966
+ { path: "subscription.billingStatus.nextBillingDate" },
967
+ { path: "subscription.billingStatus.previousBillingDate" },
968
+ {
969
+ path: "subscription.billingStatus.latestPaymentData.initialFailedPaymentDate"
970
+ },
971
+ { path: "subscription.billingStatus.freeTrialData.startDate" },
972
+ { path: "subscription.billingStatus.freeTrialData.endDate" },
973
+ {
974
+ path: "subscription.billingStatus.updateBillingDateData.paidUntil"
975
+ },
976
+ { path: "subscription.billingStatus.gracePeriodData.startDate" },
977
+ { path: "subscription.billingStatus.gracePeriodData.endDate" },
978
+ { path: "subscription.pauseInfo.startDate" },
979
+ { path: "subscription.pauseInfo.resumeDate" },
980
+ { path: "subscription.cancellationInfo.cancellationDate" },
981
+ {
982
+ path: "subscription.specificDatePendingUpdateData.executionDate"
983
+ }
984
+ ]
985
+ }
986
+ ])
987
+ };
988
+ return metadata;
989
+ }
990
+ return __customerCancelScheduledPause;
991
+ }
992
+ function customerUpdateBillingDate(payload) {
993
+ function __customerUpdateBillingDate({ host }) {
994
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
995
+ {
996
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
997
+ paths: [{ path: "billingDate" }]
998
+ }
999
+ ]);
1000
+ const metadata = {
1001
+ entityFqdn: "wix.billing.v1.subscription",
1002
+ method: "POST",
1003
+ methodFqn: "com.wixpress.billing.subscriptions.api.v1.CustomerSubscriptionsService.CustomerUpdateBillingDate",
1004
+ packageName: PACKAGE_NAME,
1005
+ migrationOptions: {
1006
+ optInTransformResponse: true
1007
+ },
1008
+ url: resolveComWixpressBillingSubscriptionsApiV1CustomerSubscriptionsServiceUrl(
1009
+ {
1010
+ protoPath: "/v1/customer_subscriptions/{id}/update_billing_date",
1011
+ data: serializedData,
1012
+ host
1013
+ }
1014
+ ),
1015
+ data: serializedData,
1016
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
1017
+ {
1018
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
1019
+ paths: [
1020
+ { path: "subscription.createdDate" },
1021
+ { path: "subscription.updatedDate" },
1022
+ { path: "subscription.startDate" },
1023
+ { path: "subscription.endDate" },
1024
+ { path: "subscription.billingStatus.nextBillingDate" },
1025
+ { path: "subscription.billingStatus.previousBillingDate" },
1026
+ {
1027
+ path: "subscription.billingStatus.latestPaymentData.initialFailedPaymentDate"
1028
+ },
1029
+ { path: "subscription.billingStatus.freeTrialData.startDate" },
1030
+ { path: "subscription.billingStatus.freeTrialData.endDate" },
1031
+ {
1032
+ path: "subscription.billingStatus.updateBillingDateData.paidUntil"
1033
+ },
1034
+ { path: "subscription.billingStatus.gracePeriodData.startDate" },
1035
+ { path: "subscription.billingStatus.gracePeriodData.endDate" },
1036
+ { path: "subscription.pauseInfo.startDate" },
1037
+ { path: "subscription.pauseInfo.resumeDate" },
1038
+ { path: "subscription.cancellationInfo.cancellationDate" },
1039
+ {
1040
+ path: "subscription.specificDatePendingUpdateData.executionDate"
1041
+ }
1042
+ ]
1043
+ }
1044
+ ])
1045
+ };
1046
+ return metadata;
1047
+ }
1048
+ return __customerUpdateBillingDate;
1049
+ }
698
1050
  function payCycle(payload) {
699
1051
  function __payCycle({ host }) {
700
1052
  const metadata = {
@@ -3362,6 +3714,8 @@ var ActionType = /* @__PURE__ */ ((ActionType2) => {
3362
3714
  ActionType2["UPM"] = "UPM";
3363
3715
  ActionType2["UPDATE_BILLING_DATE"] = "UPDATE_BILLING_DATE";
3364
3716
  ActionType2["UPDATE_COLLECTION_METHOD"] = "UPDATE_COLLECTION_METHOD";
3717
+ ActionType2["SKIP_CYCLE"] = "SKIP_CYCLE";
3718
+ ActionType2["CUSTOMER_UPDATE_BILLING_DATE"] = "CUSTOMER_UPDATE_BILLING_DATE";
3365
3719
  return ActionType2;
3366
3720
  })(ActionType || {});
3367
3721
  var ExtendPolicyType = /* @__PURE__ */ ((ExtendPolicyType2) => {
@@ -3429,6 +3783,7 @@ var InvoiceStatus = /* @__PURE__ */ ((InvoiceStatus2) => {
3429
3783
  InvoiceStatus2["ATTEMPT_FAILED"] = "ATTEMPT_FAILED";
3430
3784
  InvoiceStatus2["CANCELED"] = "CANCELED";
3431
3785
  InvoiceStatus2["REFUNDED"] = "REFUNDED";
3786
+ InvoiceStatus2["CHARGEBACKED"] = "CHARGEBACKED";
3432
3787
  return InvoiceStatus2;
3433
3788
  })(InvoiceStatus || {});
3434
3789
  var CollectionMethod = /* @__PURE__ */ ((CollectionMethod2) => {
@@ -3453,8 +3808,19 @@ var PaymentAttemptStatus = /* @__PURE__ */ ((PaymentAttemptStatus2) => {
3453
3808
  PaymentAttemptStatus2["TECHNICAL_FAILURE"] = "TECHNICAL_FAILURE";
3454
3809
  PaymentAttemptStatus2["CANCELED"] = "CANCELED";
3455
3810
  PaymentAttemptStatus2["PENDING"] = "PENDING";
3811
+ PaymentAttemptStatus2["REFUNDED"] = "REFUNDED";
3812
+ PaymentAttemptStatus2["CHARGEBACKED"] = "CHARGEBACKED";
3456
3813
  return PaymentAttemptStatus2;
3457
3814
  })(PaymentAttemptStatus || {});
3815
+ var PriceAdjustmentReason = /* @__PURE__ */ ((PriceAdjustmentReason2) => {
3816
+ PriceAdjustmentReason2["PRICE_ADJUSTMENT_REASON_UNSPECIFIED"] = "PRICE_ADJUSTMENT_REASON_UNSPECIFIED";
3817
+ PriceAdjustmentReason2["BILLING_DATE_CHANGE"] = "BILLING_DATE_CHANGE";
3818
+ PriceAdjustmentReason2["PLAN_CHANGE_PRORATION"] = "PLAN_CHANGE_PRORATION";
3819
+ PriceAdjustmentReason2["CYCLE_CHANGE_PRORATION"] = "CYCLE_CHANGE_PRORATION";
3820
+ PriceAdjustmentReason2["QUANTITY_CHANGE_PRORATION"] = "QUANTITY_CHANGE_PRORATION";
3821
+ PriceAdjustmentReason2["CUSTOM_PRICE_ADJUSTMENT"] = "CUSTOM_PRICE_ADJUSTMENT";
3822
+ return PriceAdjustmentReason2;
3823
+ })(PriceAdjustmentReason || {});
3458
3824
  var RefundReason = /* @__PURE__ */ ((RefundReason2) => {
3459
3825
  RefundReason2["UNKNOWN_REFUND_REASON"] = "UNKNOWN_REFUND_REASON";
3460
3826
  RefundReason2["DUPLICATE_CHARGE"] = "DUPLICATE_CHARGE";
@@ -3464,6 +3830,28 @@ var RefundReason = /* @__PURE__ */ ((RefundReason2) => {
3464
3830
  RefundReason2["OTHER"] = "OTHER";
3465
3831
  return RefundReason2;
3466
3832
  })(RefundReason || {});
3833
+ var ChangeEffectiveTime = /* @__PURE__ */ ((ChangeEffectiveTime2) => {
3834
+ ChangeEffectiveTime2["UNKNOWN"] = "UNKNOWN";
3835
+ ChangeEffectiveTime2["IMMEDIATELY"] = "IMMEDIATELY";
3836
+ ChangeEffectiveTime2["AT_NEXT_RENEWAL"] = "AT_NEXT_RENEWAL";
3837
+ return ChangeEffectiveTime2;
3838
+ })(ChangeEffectiveTime || {});
3839
+ var ProrationBehavior = /* @__PURE__ */ ((ProrationBehavior2) => {
3840
+ ProrationBehavior2["UNKNOWN"] = "UNKNOWN";
3841
+ ProrationBehavior2["PRORATE_AND_CHARGE"] = "PRORATE_AND_CHARGE";
3842
+ ProrationBehavior2["PRORATE_AND_REFUND"] = "PRORATE_AND_REFUND";
3843
+ ProrationBehavior2["PRORATE_AND_EXTEND"] = "PRORATE_AND_EXTEND";
3844
+ ProrationBehavior2["NO_PRORATION"] = "NO_PRORATION";
3845
+ return ProrationBehavior2;
3846
+ })(ProrationBehavior || {});
3847
+ var ProrationAction = /* @__PURE__ */ ((ProrationAction2) => {
3848
+ ProrationAction2["UNKNOWN"] = "UNKNOWN";
3849
+ ProrationAction2["CHARGE"] = "CHARGE";
3850
+ ProrationAction2["REFUND"] = "REFUND";
3851
+ ProrationAction2["EXTEND_PERIOD"] = "EXTEND_PERIOD";
3852
+ ProrationAction2["NO_CHANGE"] = "NO_CHANGE";
3853
+ return ProrationAction2;
3854
+ })(ProrationAction || {});
3467
3855
  var IdentityType = /* @__PURE__ */ ((IdentityType2) => {
3468
3856
  IdentityType2["UNDEFINED"] = "UNDEFINED";
3469
3857
  IdentityType2["MEMBER"] = "MEMBER";
@@ -3555,22 +3943,212 @@ async function customerGetSubscription2(_id) {
3555
3943
  err,
3556
3944
  {
3557
3945
  spreadPathsToArguments: {},
3558
- explicitPathsToArguments: { id: "$[0]" },
3946
+ explicitPathsToArguments: { id: "$[0]" },
3947
+ singleArgumentUnchanged: false
3948
+ },
3949
+ ["_id"]
3950
+ );
3951
+ sideEffects?.onError?.(err);
3952
+ throw transformedError;
3953
+ }
3954
+ }
3955
+ async function customerCancelSubscription2(_id, options) {
3956
+ const { httpClient, sideEffects } = arguments[2];
3957
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3958
+ id: _id,
3959
+ reason: options?.reason
3960
+ });
3961
+ const reqOpts = customerCancelSubscription(payload);
3962
+ sideEffects?.onSiteCall?.();
3963
+ try {
3964
+ const result = await httpClient.request(reqOpts);
3965
+ sideEffects?.onSuccess?.(result);
3966
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
3967
+ (0, import_transform_paths2.transformPaths)(result.data, [
3968
+ {
3969
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
3970
+ paths: [
3971
+ { path: "subscription.billingSettings.billingAddress.address" },
3972
+ { path: "subscription.shippingAddress.address" }
3973
+ ]
3974
+ }
3975
+ ])
3976
+ );
3977
+ } catch (err) {
3978
+ const transformedError = (0, import_transform_error.transformError)(
3979
+ err,
3980
+ {
3981
+ spreadPathsToArguments: {},
3982
+ explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
3983
+ singleArgumentUnchanged: false
3984
+ },
3985
+ ["_id", "options"]
3986
+ );
3987
+ sideEffects?.onError?.(err);
3988
+ throw transformedError;
3989
+ }
3990
+ }
3991
+ async function customerTurnOnSubscriptionAutoRenewal2(_id, options) {
3992
+ const { httpClient, sideEffects } = arguments[2];
3993
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3994
+ id: _id,
3995
+ reason: options?.reason
3996
+ });
3997
+ const reqOpts = customerTurnOnSubscriptionAutoRenewal(
3998
+ payload
3999
+ );
4000
+ sideEffects?.onSiteCall?.();
4001
+ try {
4002
+ const result = await httpClient.request(reqOpts);
4003
+ sideEffects?.onSuccess?.(result);
4004
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4005
+ (0, import_transform_paths2.transformPaths)(result.data, [
4006
+ {
4007
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4008
+ paths: [
4009
+ { path: "subscription.billingSettings.billingAddress.address" },
4010
+ { path: "subscription.shippingAddress.address" }
4011
+ ]
4012
+ }
4013
+ ])
4014
+ );
4015
+ } catch (err) {
4016
+ const transformedError = (0, import_transform_error.transformError)(
4017
+ err,
4018
+ {
4019
+ spreadPathsToArguments: {},
4020
+ explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
4021
+ singleArgumentUnchanged: false
4022
+ },
4023
+ ["_id", "options"]
4024
+ );
4025
+ sideEffects?.onError?.(err);
4026
+ throw transformedError;
4027
+ }
4028
+ }
4029
+ async function customerTurnOffSubscriptionAutoRenewal2(_id, options) {
4030
+ const { httpClient, sideEffects } = arguments[2];
4031
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
4032
+ id: _id,
4033
+ reason: options?.reason
4034
+ });
4035
+ const reqOpts = customerTurnOffSubscriptionAutoRenewal(
4036
+ payload
4037
+ );
4038
+ sideEffects?.onSiteCall?.();
4039
+ try {
4040
+ const result = await httpClient.request(reqOpts);
4041
+ sideEffects?.onSuccess?.(result);
4042
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4043
+ (0, import_transform_paths2.transformPaths)(result.data, [
4044
+ {
4045
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4046
+ paths: [
4047
+ { path: "subscription.billingSettings.billingAddress.address" },
4048
+ { path: "subscription.shippingAddress.address" }
4049
+ ]
4050
+ }
4051
+ ])
4052
+ );
4053
+ } catch (err) {
4054
+ const transformedError = (0, import_transform_error.transformError)(
4055
+ err,
4056
+ {
4057
+ spreadPathsToArguments: {},
4058
+ explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
4059
+ singleArgumentUnchanged: false
4060
+ },
4061
+ ["_id", "options"]
4062
+ );
4063
+ sideEffects?.onError?.(err);
4064
+ throw transformedError;
4065
+ }
4066
+ }
4067
+ async function customerExtendSubscription2(_id, options) {
4068
+ const { httpClient, sideEffects } = arguments[2];
4069
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
4070
+ id: _id,
4071
+ reason: options?.reason,
4072
+ billingCyclesToAdd: options?.billingCyclesToAdd
4073
+ });
4074
+ const reqOpts = customerExtendSubscription(payload);
4075
+ sideEffects?.onSiteCall?.();
4076
+ try {
4077
+ const result = await httpClient.request(reqOpts);
4078
+ sideEffects?.onSuccess?.(result);
4079
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4080
+ (0, import_transform_paths2.transformPaths)(result.data, [
4081
+ {
4082
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4083
+ paths: [
4084
+ { path: "subscription.billingSettings.billingAddress.address" },
4085
+ { path: "subscription.shippingAddress.address" }
4086
+ ]
4087
+ }
4088
+ ])
4089
+ );
4090
+ } catch (err) {
4091
+ const transformedError = (0, import_transform_error.transformError)(
4092
+ err,
4093
+ {
4094
+ spreadPathsToArguments: {},
4095
+ explicitPathsToArguments: {
4096
+ id: "$[0]",
4097
+ reason: "$[1].reason",
4098
+ billingCyclesToAdd: "$[1].billingCyclesToAdd"
4099
+ },
4100
+ singleArgumentUnchanged: false
4101
+ },
4102
+ ["_id", "options"]
4103
+ );
4104
+ sideEffects?.onError?.(err);
4105
+ throw transformedError;
4106
+ }
4107
+ }
4108
+ async function customerQuerySubscriptions2(options) {
4109
+ const { httpClient, sideEffects } = arguments[1];
4110
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
4111
+ query: options?.query
4112
+ });
4113
+ const reqOpts = customerQuerySubscriptions(payload);
4114
+ sideEffects?.onSiteCall?.();
4115
+ try {
4116
+ const result = await httpClient.request(reqOpts);
4117
+ sideEffects?.onSuccess?.(result);
4118
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4119
+ (0, import_transform_paths2.transformPaths)(result.data, [
4120
+ {
4121
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4122
+ paths: [
4123
+ { path: "subscriptions.billingSettings.billingAddress.address" },
4124
+ { path: "subscriptions.shippingAddress.address" }
4125
+ ]
4126
+ }
4127
+ ])
4128
+ );
4129
+ } catch (err) {
4130
+ const transformedError = (0, import_transform_error.transformError)(
4131
+ err,
4132
+ {
4133
+ spreadPathsToArguments: {},
4134
+ explicitPathsToArguments: { query: "$[0].query" },
3559
4135
  singleArgumentUnchanged: false
3560
4136
  },
3561
- ["_id"]
4137
+ ["options"]
3562
4138
  );
3563
4139
  sideEffects?.onError?.(err);
3564
4140
  throw transformedError;
3565
4141
  }
3566
4142
  }
3567
- async function customerCancelSubscription2(_id, options) {
4143
+ async function customerUpdateSubscriptionPaymentMethod2(_id, paymentMethodId) {
3568
4144
  const { httpClient, sideEffects } = arguments[2];
3569
4145
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3570
4146
  id: _id,
3571
- reason: options?.reason
4147
+ paymentMethodId
3572
4148
  });
3573
- const reqOpts = customerCancelSubscription(payload);
4149
+ const reqOpts = customerUpdateSubscriptionPaymentMethod(
4150
+ payload
4151
+ );
3574
4152
  sideEffects?.onSiteCall?.();
3575
4153
  try {
3576
4154
  const result = await httpClient.request(reqOpts);
@@ -3591,83 +4169,86 @@ async function customerCancelSubscription2(_id, options) {
3591
4169
  err,
3592
4170
  {
3593
4171
  spreadPathsToArguments: {},
3594
- explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
4172
+ explicitPathsToArguments: { id: "$[0]", paymentMethodId: "$[1]" },
3595
4173
  singleArgumentUnchanged: false
3596
4174
  },
3597
- ["_id", "options"]
4175
+ ["_id", "paymentMethodId"]
3598
4176
  );
3599
4177
  sideEffects?.onError?.(err);
3600
4178
  throw transformedError;
3601
4179
  }
3602
4180
  }
3603
- async function customerTurnOnSubscriptionAutoRenewal2(_id, options) {
3604
- const { httpClient, sideEffects } = arguments[2];
3605
- const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3606
- id: _id,
3607
- reason: options?.reason
3608
- });
3609
- const reqOpts = customerTurnOnSubscriptionAutoRenewal(
3610
- payload
3611
- );
4181
+ async function customerAllowedActions2(_id) {
4182
+ const { httpClient, sideEffects } = arguments[1];
4183
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ id: _id });
4184
+ const reqOpts = customerAllowedActions(payload);
3612
4185
  sideEffects?.onSiteCall?.();
3613
4186
  try {
3614
4187
  const result = await httpClient.request(reqOpts);
3615
4188
  sideEffects?.onSuccess?.(result);
3616
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
3617
- (0, import_transform_paths2.transformPaths)(result.data, [
3618
- {
3619
- transformFn: import_address2.transformRESTAddressToSDKAddress,
3620
- paths: [
3621
- { path: "subscription.billingSettings.billingAddress.address" },
3622
- { path: "subscription.shippingAddress.address" }
3623
- ]
3624
- }
3625
- ])
4189
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
4190
+ } catch (err) {
4191
+ const transformedError = (0, import_transform_error.transformError)(
4192
+ err,
4193
+ {
4194
+ spreadPathsToArguments: {},
4195
+ explicitPathsToArguments: { id: "$[0]" },
4196
+ singleArgumentUnchanged: false
4197
+ },
4198
+ ["_id"]
3626
4199
  );
4200
+ sideEffects?.onError?.(err);
4201
+ throw transformedError;
4202
+ }
4203
+ }
4204
+ async function customerListUpcomingCharges2(_id) {
4205
+ const { httpClient, sideEffects } = arguments[1];
4206
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ id: _id });
4207
+ const reqOpts = customerListUpcomingCharges(payload);
4208
+ sideEffects?.onSiteCall?.();
4209
+ try {
4210
+ const result = await httpClient.request(reqOpts);
4211
+ sideEffects?.onSuccess?.(result);
4212
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
3627
4213
  } catch (err) {
3628
4214
  const transformedError = (0, import_transform_error.transformError)(
3629
4215
  err,
3630
4216
  {
3631
4217
  spreadPathsToArguments: {},
3632
- explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
4218
+ explicitPathsToArguments: { id: "$[0]" },
3633
4219
  singleArgumentUnchanged: false
3634
4220
  },
3635
- ["_id", "options"]
4221
+ ["_id"]
3636
4222
  );
3637
4223
  sideEffects?.onError?.(err);
3638
4224
  throw transformedError;
3639
4225
  }
3640
4226
  }
3641
- async function customerTurnOffSubscriptionAutoRenewal2(_id, options) {
4227
+ async function customerInitiatePaymentMethodSetup2(_id, options) {
3642
4228
  const { httpClient, sideEffects } = arguments[2];
3643
4229
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3644
4230
  id: _id,
3645
- reason: options?.reason
4231
+ paymentMode: options?.paymentMode,
4232
+ paymentSettings: options?.paymentSettings
3646
4233
  });
3647
- const reqOpts = customerTurnOffSubscriptionAutoRenewal(
4234
+ const reqOpts = customerInitiatePaymentMethodSetup(
3648
4235
  payload
3649
4236
  );
3650
4237
  sideEffects?.onSiteCall?.();
3651
4238
  try {
3652
4239
  const result = await httpClient.request(reqOpts);
3653
4240
  sideEffects?.onSuccess?.(result);
3654
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
3655
- (0, import_transform_paths2.transformPaths)(result.data, [
3656
- {
3657
- transformFn: import_address2.transformRESTAddressToSDKAddress,
3658
- paths: [
3659
- { path: "subscription.billingSettings.billingAddress.address" },
3660
- { path: "subscription.shippingAddress.address" }
3661
- ]
3662
- }
3663
- ])
3664
- );
4241
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
3665
4242
  } catch (err) {
3666
4243
  const transformedError = (0, import_transform_error.transformError)(
3667
4244
  err,
3668
4245
  {
3669
4246
  spreadPathsToArguments: {},
3670
- explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
4247
+ explicitPathsToArguments: {
4248
+ id: "$[0]",
4249
+ paymentMode: "$[1].paymentMode",
4250
+ paymentSettings: "$[1].paymentSettings"
4251
+ },
3671
4252
  singleArgumentUnchanged: false
3672
4253
  },
3673
4254
  ["_id", "options"]
@@ -3676,14 +4257,16 @@ async function customerTurnOffSubscriptionAutoRenewal2(_id, options) {
3676
4257
  throw transformedError;
3677
4258
  }
3678
4259
  }
3679
- async function customerExtendSubscription2(_id, options) {
3680
- const { httpClient, sideEffects } = arguments[2];
4260
+ async function customerSkipCycle2(_id, cyclesToSkip, options) {
4261
+ const { httpClient, sideEffects } = arguments[3];
3681
4262
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3682
4263
  id: _id,
3683
- reason: options?.reason,
3684
- billingCyclesToAdd: options?.billingCyclesToAdd
4264
+ cyclesToSkip,
4265
+ pauseAtSchedule: options?.pauseAtSchedule,
4266
+ autoResumeAtSchedule: options?.autoResumeAtSchedule,
4267
+ reason: options?.reason
3685
4268
  });
3686
- const reqOpts = customerExtendSubscription(payload);
4269
+ const reqOpts = customerSkipCycle(payload);
3687
4270
  sideEffects?.onSiteCall?.();
3688
4271
  try {
3689
4272
  const result = await httpClient.request(reqOpts);
@@ -3706,23 +4289,26 @@ async function customerExtendSubscription2(_id, options) {
3706
4289
  spreadPathsToArguments: {},
3707
4290
  explicitPathsToArguments: {
3708
4291
  id: "$[0]",
3709
- reason: "$[1].reason",
3710
- billingCyclesToAdd: "$[1].billingCyclesToAdd"
4292
+ cyclesToSkip: "$[1]",
4293
+ pauseAtSchedule: "$[2].pauseAtSchedule",
4294
+ autoResumeAtSchedule: "$[2].autoResumeAtSchedule",
4295
+ reason: "$[2].reason"
3711
4296
  },
3712
4297
  singleArgumentUnchanged: false
3713
4298
  },
3714
- ["_id", "options"]
4299
+ ["_id", "cyclesToSkip", "options"]
3715
4300
  );
3716
4301
  sideEffects?.onError?.(err);
3717
4302
  throw transformedError;
3718
4303
  }
3719
4304
  }
3720
- async function customerQuerySubscriptions2(options) {
3721
- const { httpClient, sideEffects } = arguments[1];
4305
+ async function customerCancelScheduledSkip2(_id, options) {
4306
+ const { httpClient, sideEffects } = arguments[2];
3722
4307
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3723
- query: options?.query
4308
+ id: _id,
4309
+ reason: options?.reason
3724
4310
  });
3725
- const reqOpts = customerQuerySubscriptions(payload);
4311
+ const reqOpts = customerCancelScheduledSkip(payload);
3726
4312
  sideEffects?.onSiteCall?.();
3727
4313
  try {
3728
4314
  const result = await httpClient.request(reqOpts);
@@ -3732,8 +4318,8 @@ async function customerQuerySubscriptions2(options) {
3732
4318
  {
3733
4319
  transformFn: import_address2.transformRESTAddressToSDKAddress,
3734
4320
  paths: [
3735
- { path: "subscriptions.billingSettings.billingAddress.address" },
3736
- { path: "subscriptions.shippingAddress.address" }
4321
+ { path: "subscription.billingSettings.billingAddress.address" },
4322
+ { path: "subscription.shippingAddress.address" }
3737
4323
  ]
3738
4324
  }
3739
4325
  ])
@@ -3743,24 +4329,26 @@ async function customerQuerySubscriptions2(options) {
3743
4329
  err,
3744
4330
  {
3745
4331
  spreadPathsToArguments: {},
3746
- explicitPathsToArguments: { query: "$[0].query" },
4332
+ explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
3747
4333
  singleArgumentUnchanged: false
3748
4334
  },
3749
- ["options"]
4335
+ ["_id", "options"]
3750
4336
  );
3751
4337
  sideEffects?.onError?.(err);
3752
4338
  throw transformedError;
3753
4339
  }
3754
4340
  }
3755
- async function customerUpdateSubscriptionPaymentMethod2(_id, paymentMethodId) {
4341
+ async function customerPauseSubscription2(_id, options) {
3756
4342
  const { httpClient, sideEffects } = arguments[2];
3757
4343
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3758
4344
  id: _id,
3759
- paymentMethodId
4345
+ pausePolicy: options?.pausePolicy,
4346
+ reason: options?.reason,
4347
+ pauseAt: options?.pauseAt,
4348
+ pauseAtSchedule: options?.pauseAtSchedule,
4349
+ autoResumeAtSchedule: options?.autoResumeAtSchedule
3760
4350
  });
3761
- const reqOpts = customerUpdateSubscriptionPaymentMethod(
3762
- payload
3763
- );
4351
+ const reqOpts = customerPauseSubscription(payload);
3764
4352
  sideEffects?.onSiteCall?.();
3765
4353
  try {
3766
4354
  const result = await httpClient.request(reqOpts);
@@ -3781,76 +4369,125 @@ async function customerUpdateSubscriptionPaymentMethod2(_id, paymentMethodId) {
3781
4369
  err,
3782
4370
  {
3783
4371
  spreadPathsToArguments: {},
3784
- explicitPathsToArguments: { id: "$[0]", paymentMethodId: "$[1]" },
4372
+ explicitPathsToArguments: {
4373
+ id: "$[0]",
4374
+ pausePolicy: "$[1].pausePolicy",
4375
+ reason: "$[1].reason",
4376
+ pauseAt: "$[1].pauseAt",
4377
+ pauseAtSchedule: "$[1].pauseAtSchedule",
4378
+ autoResumeAtSchedule: "$[1].autoResumeAtSchedule"
4379
+ },
3785
4380
  singleArgumentUnchanged: false
3786
4381
  },
3787
- ["_id", "paymentMethodId"]
4382
+ ["_id", "options"]
3788
4383
  );
3789
4384
  sideEffects?.onError?.(err);
3790
4385
  throw transformedError;
3791
4386
  }
3792
4387
  }
3793
- async function customerAllowedActions2(_id) {
3794
- const { httpClient, sideEffects } = arguments[1];
3795
- const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ id: _id });
3796
- const reqOpts = customerAllowedActions(payload);
4388
+ async function customerResumeSubscription2(_id, options) {
4389
+ const { httpClient, sideEffects } = arguments[2];
4390
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
4391
+ id: _id,
4392
+ reason: options?.reason,
4393
+ resumeAt: options?.resumeAt,
4394
+ resumeAtSchedule: options?.resumeAtSchedule
4395
+ });
4396
+ const reqOpts = customerResumeSubscription(payload);
3797
4397
  sideEffects?.onSiteCall?.();
3798
4398
  try {
3799
4399
  const result = await httpClient.request(reqOpts);
3800
4400
  sideEffects?.onSuccess?.(result);
3801
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
4401
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4402
+ (0, import_transform_paths2.transformPaths)(result.data, [
4403
+ {
4404
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4405
+ paths: [
4406
+ { path: "subscription.billingSettings.billingAddress.address" },
4407
+ { path: "subscription.shippingAddress.address" }
4408
+ ]
4409
+ }
4410
+ ])
4411
+ );
3802
4412
  } catch (err) {
3803
4413
  const transformedError = (0, import_transform_error.transformError)(
3804
4414
  err,
3805
4415
  {
3806
4416
  spreadPathsToArguments: {},
3807
- explicitPathsToArguments: { id: "$[0]" },
4417
+ explicitPathsToArguments: {
4418
+ id: "$[0]",
4419
+ reason: "$[1].reason",
4420
+ resumeAt: "$[1].resumeAt",
4421
+ resumeAtSchedule: "$[1].resumeAtSchedule"
4422
+ },
3808
4423
  singleArgumentUnchanged: false
3809
4424
  },
3810
- ["_id"]
4425
+ ["_id", "options"]
3811
4426
  );
3812
4427
  sideEffects?.onError?.(err);
3813
4428
  throw transformedError;
3814
4429
  }
3815
4430
  }
3816
- async function customerListUpcomingCharges2(_id) {
3817
- const { httpClient, sideEffects } = arguments[1];
3818
- const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ id: _id });
3819
- const reqOpts = customerListUpcomingCharges(payload);
4431
+ async function customerCancelScheduledPause2(_id, options) {
4432
+ const { httpClient, sideEffects } = arguments[2];
4433
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
4434
+ id: _id,
4435
+ reason: options?.reason
4436
+ });
4437
+ const reqOpts = customerCancelScheduledPause(payload);
3820
4438
  sideEffects?.onSiteCall?.();
3821
4439
  try {
3822
4440
  const result = await httpClient.request(reqOpts);
3823
4441
  sideEffects?.onSuccess?.(result);
3824
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
4442
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4443
+ (0, import_transform_paths2.transformPaths)(result.data, [
4444
+ {
4445
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4446
+ paths: [
4447
+ { path: "subscription.billingSettings.billingAddress.address" },
4448
+ { path: "subscription.shippingAddress.address" }
4449
+ ]
4450
+ }
4451
+ ])
4452
+ );
3825
4453
  } catch (err) {
3826
4454
  const transformedError = (0, import_transform_error.transformError)(
3827
4455
  err,
3828
4456
  {
3829
4457
  spreadPathsToArguments: {},
3830
- explicitPathsToArguments: { id: "$[0]" },
4458
+ explicitPathsToArguments: { id: "$[0]", reason: "$[1].reason" },
3831
4459
  singleArgumentUnchanged: false
3832
4460
  },
3833
- ["_id"]
4461
+ ["_id", "options"]
3834
4462
  );
3835
4463
  sideEffects?.onError?.(err);
3836
4464
  throw transformedError;
3837
4465
  }
3838
4466
  }
3839
- async function customerInitiatePaymentMethodSetup2(_id, options) {
3840
- const { httpClient, sideEffects } = arguments[2];
4467
+ async function customerUpdateBillingDate2(_id, billingDate, options) {
4468
+ const { httpClient, sideEffects } = arguments[3];
3841
4469
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
3842
4470
  id: _id,
3843
- paymentMode: options?.paymentMode,
3844
- paymentSettings: options?.paymentSettings
4471
+ billingDate,
4472
+ proration: options?.proration,
4473
+ reason: options?.reason
3845
4474
  });
3846
- const reqOpts = customerInitiatePaymentMethodSetup(
3847
- payload
3848
- );
4475
+ const reqOpts = customerUpdateBillingDate(payload);
3849
4476
  sideEffects?.onSiteCall?.();
3850
4477
  try {
3851
4478
  const result = await httpClient.request(reqOpts);
3852
4479
  sideEffects?.onSuccess?.(result);
3853
- return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
4480
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
4481
+ (0, import_transform_paths2.transformPaths)(result.data, [
4482
+ {
4483
+ transformFn: import_address2.transformRESTAddressToSDKAddress,
4484
+ paths: [
4485
+ { path: "subscription.billingSettings.billingAddress.address" },
4486
+ { path: "subscription.shippingAddress.address" }
4487
+ ]
4488
+ }
4489
+ ])
4490
+ );
3854
4491
  } catch (err) {
3855
4492
  const transformedError = (0, import_transform_error.transformError)(
3856
4493
  err,
@@ -3858,12 +4495,13 @@ async function customerInitiatePaymentMethodSetup2(_id, options) {
3858
4495
  spreadPathsToArguments: {},
3859
4496
  explicitPathsToArguments: {
3860
4497
  id: "$[0]",
3861
- paymentMode: "$[1].paymentMode",
3862
- paymentSettings: "$[1].paymentSettings"
4498
+ billingDate: "$[1]",
4499
+ proration: "$[2].proration",
4500
+ reason: "$[2].reason"
3863
4501
  },
3864
4502
  singleArgumentUnchanged: false
3865
4503
  },
3866
- ["_id", "options"]
4504
+ ["_id", "billingDate", "options"]
3867
4505
  );
3868
4506
  sideEffects?.onError?.(err);
3869
4507
  throw transformedError;
@@ -4981,6 +5619,56 @@ function customerInitiatePaymentMethodSetup3(httpClient) {
4981
5619
  { httpClient }
4982
5620
  );
4983
5621
  }
5622
+ function customerSkipCycle3(httpClient) {
5623
+ return (_id, cyclesToSkip, options) => customerSkipCycle2(
5624
+ _id,
5625
+ cyclesToSkip,
5626
+ options,
5627
+ // @ts-ignore
5628
+ { httpClient }
5629
+ );
5630
+ }
5631
+ function customerCancelScheduledSkip3(httpClient) {
5632
+ return (_id, options) => customerCancelScheduledSkip2(
5633
+ _id,
5634
+ options,
5635
+ // @ts-ignore
5636
+ { httpClient }
5637
+ );
5638
+ }
5639
+ function customerPauseSubscription3(httpClient) {
5640
+ return (_id, options) => customerPauseSubscription2(
5641
+ _id,
5642
+ options,
5643
+ // @ts-ignore
5644
+ { httpClient }
5645
+ );
5646
+ }
5647
+ function customerResumeSubscription3(httpClient) {
5648
+ return (_id, options) => customerResumeSubscription2(
5649
+ _id,
5650
+ options,
5651
+ // @ts-ignore
5652
+ { httpClient }
5653
+ );
5654
+ }
5655
+ function customerCancelScheduledPause3(httpClient) {
5656
+ return (_id, options) => customerCancelScheduledPause2(
5657
+ _id,
5658
+ options,
5659
+ // @ts-ignore
5660
+ { httpClient }
5661
+ );
5662
+ }
5663
+ function customerUpdateBillingDate3(httpClient) {
5664
+ return (_id, billingDate, options) => customerUpdateBillingDate2(
5665
+ _id,
5666
+ billingDate,
5667
+ options,
5668
+ // @ts-ignore
5669
+ { httpClient }
5670
+ );
5671
+ }
4984
5672
  function payCycle3(httpClient) {
4985
5673
  return (subscriptionId, options) => payCycle2(
4986
5674
  subscriptionId,
@@ -5782,6 +6470,12 @@ var customerUpdateSubscriptionPaymentMethod4 = /* @__PURE__ */ (0, import_rest_m
5782
6470
  var customerAllowedActions4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerAllowedActions3);
5783
6471
  var customerListUpcomingCharges4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerListUpcomingCharges3);
5784
6472
  var customerInitiatePaymentMethodSetup4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerInitiatePaymentMethodSetup3);
6473
+ var customerSkipCycle4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerSkipCycle3);
6474
+ var customerCancelScheduledSkip4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerCancelScheduledSkip3);
6475
+ var customerPauseSubscription4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerPauseSubscription3);
6476
+ var customerResumeSubscription4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerResumeSubscription3);
6477
+ var customerCancelScheduledPause4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerCancelScheduledPause3);
6478
+ var customerUpdateBillingDate4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customerUpdateBillingDate3);
5785
6479
  var payCycle4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(payCycle3);
5786
6480
  var getSubscription4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getSubscription3);
5787
6481
  var updateSubscriptionPaymentMethod4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateSubscriptionPaymentMethod3);
@@ -5850,6 +6544,7 @@ var onSubscriptionResumed2 = (0, import_event_definition_modules.createEventModu
5850
6544
  ActionType,
5851
6545
  AdditionalFeeTrigger,
5852
6546
  CancellationInitiator,
6547
+ ChangeEffectiveTime,
5853
6548
  CollectionMethod,
5854
6549
  CollectionMethodEnumCollectionMethod,
5855
6550
  CreationMode,
@@ -5869,6 +6564,9 @@ var onSubscriptionResumed2 = (0, import_event_definition_modules.createEventModu
5869
6564
  PaymentStatus,
5870
6565
  PaymentStatusEnumPaymentStatus,
5871
6566
  PaymentTestMode,
6567
+ PriceAdjustmentReason,
6568
+ ProrationAction,
6569
+ ProrationBehavior,
5872
6570
  RefundReason,
5873
6571
  RequestedFields,
5874
6572
  ResumeAt,
@@ -5887,14 +6585,20 @@ var onSubscriptionResumed2 = (0, import_event_definition_modules.createEventModu
5887
6585
  cancelSubscription,
5888
6586
  countSubscriptions,
5889
6587
  customerAllowedActions,
6588
+ customerCancelScheduledPause,
6589
+ customerCancelScheduledSkip,
5890
6590
  customerCancelSubscription,
5891
6591
  customerExtendSubscription,
5892
6592
  customerGetSubscription,
5893
6593
  customerInitiatePaymentMethodSetup,
5894
6594
  customerListUpcomingCharges,
6595
+ customerPauseSubscription,
5895
6596
  customerQuerySubscriptions,
6597
+ customerResumeSubscription,
6598
+ customerSkipCycle,
5896
6599
  customerTurnOffSubscriptionAutoRenewal,
5897
6600
  customerTurnOnSubscriptionAutoRenewal,
6601
+ customerUpdateBillingDate,
5898
6602
  customerUpdateSubscriptionPaymentMethod,
5899
6603
  extendSubscription,
5900
6604
  getSubscription,