xendit-components-web 0.0.18 → 0.0.20
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 +16 -2
- package/README.md +2 -2
- package/package.json +16 -16
- package/sdk/dist/cjs/index.cjs +1 -1
- package/sdk/dist/cjs/index.cjs.map +1 -1
- package/sdk/dist/esm-bundled/index.mjs +2 -2
- package/sdk/dist/esm-bundled/index.mjs.map +1 -1
- package/sdk/dist/esm-external/index.mjs +1 -1
- package/sdk/dist/esm-external/index.mjs.map +1 -1
- package/sdk/dist/index.d.ts +44 -1
- package/sdk/dist/index.umd.js +2 -2
- package/sdk/dist/index.umd.js.map +1 -1
package/sdk/dist/index.d.ts
CHANGED
|
@@ -735,8 +735,9 @@ export declare interface XenditSession {
|
|
|
735
735
|
*
|
|
736
736
|
* PAY sessions create a payment request, calling /v3/payment_requests
|
|
737
737
|
* SAVE sessions create a saved payment token, calling /v3/payment_tokens
|
|
738
|
+
* SUBSCRIPTION sessions create a subscription, also calling /v3/payment_tokens
|
|
738
739
|
*/
|
|
739
|
-
sessionType: "PAY" | "SAVE";
|
|
740
|
+
sessionType: "PAY" | "SAVE" | "SUBSCRIPTION";
|
|
740
741
|
/**
|
|
741
742
|
* The kind of session, only COMPONENT sessions can be used with the components SDK.
|
|
742
743
|
*/
|
|
@@ -791,6 +792,48 @@ export declare interface XenditSession {
|
|
|
791
792
|
* Indicates whether the payment will be captured automatically or manually.
|
|
792
793
|
*/
|
|
793
794
|
captureMethod?: "AUTOMATIC" | "MANUAL";
|
|
795
|
+
/**
|
|
796
|
+
* For subscription sessions, the subscription details. This will be undefined for PAY and SAVE sessions.
|
|
797
|
+
*/
|
|
798
|
+
subscription?: {
|
|
799
|
+
/**
|
|
800
|
+
* Whether the first payment for the subscription should be made immediately upon session completion, or only after the anchor date.
|
|
801
|
+
*/
|
|
802
|
+
immediatePayment?: boolean;
|
|
803
|
+
/**
|
|
804
|
+
* The subscription schedule. This includes the anchor date, which determines when the subscription payments will be made, as well as the interval and count for both the regular payments and the retries.
|
|
805
|
+
*/
|
|
806
|
+
schedule: {
|
|
807
|
+
/**
|
|
808
|
+
* The anchor date for the subscription. This determines when the subscription payments will be made.
|
|
809
|
+
*/
|
|
810
|
+
anchorDate: Date;
|
|
811
|
+
/**
|
|
812
|
+
* The interval for the subscription payments.
|
|
813
|
+
*/
|
|
814
|
+
interval: "DAY" | "WEEK" | "MONTH";
|
|
815
|
+
/**
|
|
816
|
+
* The number of intervals for the subscription payments.
|
|
817
|
+
*/
|
|
818
|
+
intervalCount: number;
|
|
819
|
+
/**
|
|
820
|
+
* The interval for retrying failed subscription payments.
|
|
821
|
+
*/
|
|
822
|
+
retryInterval?: "DAY" | "WEEK" | "MONTH";
|
|
823
|
+
/**
|
|
824
|
+
* The number of intervals for retrying failed subscription payments.
|
|
825
|
+
*/
|
|
826
|
+
retryIntervalCount?: number;
|
|
827
|
+
/**
|
|
828
|
+
* The total number of subscription payments.
|
|
829
|
+
*/
|
|
830
|
+
totalRecurrence?: number;
|
|
831
|
+
/**
|
|
832
|
+
* The total number of retry attempts for failed subscription payments.
|
|
833
|
+
*/
|
|
834
|
+
totalRetry?: number;
|
|
835
|
+
};
|
|
836
|
+
};
|
|
794
837
|
/**
|
|
795
838
|
* Line items. The components SDK does not use this, but you may show it to your users.
|
|
796
839
|
*/
|