globodai-fam-sdk 1.2.0 → 1.3.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/dist/index.d.cts +14 -2
- package/dist/index.d.ts +14 -2
- package/package.json +7 -7
package/dist/index.d.cts
CHANGED
|
@@ -1044,20 +1044,32 @@ interface CheckoutConfig {
|
|
|
1044
1044
|
productLabel: string;
|
|
1045
1045
|
/** Optional product description */
|
|
1046
1046
|
productDescription?: string | null;
|
|
1047
|
-
/** Amount in cents */
|
|
1047
|
+
/** Amount in cents (monthly price if frequency selector shown) */
|
|
1048
1048
|
amount: number;
|
|
1049
1049
|
/** Currency code (default: EUR) */
|
|
1050
1050
|
currency?: string;
|
|
1051
1051
|
/** Whether this is a recurring payment */
|
|
1052
1052
|
isRecurring: boolean;
|
|
1053
|
-
/** Payment frequency
|
|
1053
|
+
/** Payment frequency - if set, locks frequency (no selector shown in portal) */
|
|
1054
1054
|
frequency?: 'MONTHLY' | 'YEARLY';
|
|
1055
|
+
/** Amount in cents for yearly plan (only used when frequency selector is shown) */
|
|
1056
|
+
yearlyAmount?: number | null;
|
|
1057
|
+
/** Savings label for yearly plan (e.g., "2 mois offerts", "-17%") */
|
|
1058
|
+
yearlySavingsLabel?: string | null;
|
|
1055
1059
|
/** Whether a discount is applied */
|
|
1056
1060
|
hasDiscount?: boolean;
|
|
1057
1061
|
/** Display label for the discount */
|
|
1058
1062
|
discountLabel?: string | null;
|
|
1059
1063
|
/** Original amount before discount (in cents) */
|
|
1060
1064
|
originalAmount?: number | null;
|
|
1065
|
+
/** Required: Platform/merchant wallet ID to receive payment */
|
|
1066
|
+
creditedWalletId: string;
|
|
1067
|
+
/** Optional: Platform/merchant user ID (for fees) */
|
|
1068
|
+
creditedUserId?: string;
|
|
1069
|
+
/** Required: User ID in client app (e.g., Exaku user ID) */
|
|
1070
|
+
externalUserId: string;
|
|
1071
|
+
/** Optional: Subscription ID in client app */
|
|
1072
|
+
externalSubscriptionId?: string;
|
|
1061
1073
|
/** Client app specific metadata */
|
|
1062
1074
|
metadata?: Record<string, unknown>;
|
|
1063
1075
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1044,20 +1044,32 @@ interface CheckoutConfig {
|
|
|
1044
1044
|
productLabel: string;
|
|
1045
1045
|
/** Optional product description */
|
|
1046
1046
|
productDescription?: string | null;
|
|
1047
|
-
/** Amount in cents */
|
|
1047
|
+
/** Amount in cents (monthly price if frequency selector shown) */
|
|
1048
1048
|
amount: number;
|
|
1049
1049
|
/** Currency code (default: EUR) */
|
|
1050
1050
|
currency?: string;
|
|
1051
1051
|
/** Whether this is a recurring payment */
|
|
1052
1052
|
isRecurring: boolean;
|
|
1053
|
-
/** Payment frequency
|
|
1053
|
+
/** Payment frequency - if set, locks frequency (no selector shown in portal) */
|
|
1054
1054
|
frequency?: 'MONTHLY' | 'YEARLY';
|
|
1055
|
+
/** Amount in cents for yearly plan (only used when frequency selector is shown) */
|
|
1056
|
+
yearlyAmount?: number | null;
|
|
1057
|
+
/** Savings label for yearly plan (e.g., "2 mois offerts", "-17%") */
|
|
1058
|
+
yearlySavingsLabel?: string | null;
|
|
1055
1059
|
/** Whether a discount is applied */
|
|
1056
1060
|
hasDiscount?: boolean;
|
|
1057
1061
|
/** Display label for the discount */
|
|
1058
1062
|
discountLabel?: string | null;
|
|
1059
1063
|
/** Original amount before discount (in cents) */
|
|
1060
1064
|
originalAmount?: number | null;
|
|
1065
|
+
/** Required: Platform/merchant wallet ID to receive payment */
|
|
1066
|
+
creditedWalletId: string;
|
|
1067
|
+
/** Optional: Platform/merchant user ID (for fees) */
|
|
1068
|
+
creditedUserId?: string;
|
|
1069
|
+
/** Required: User ID in client app (e.g., Exaku user ID) */
|
|
1070
|
+
externalUserId: string;
|
|
1071
|
+
/** Optional: Subscription ID in client app */
|
|
1072
|
+
externalSubscriptionId?: string;
|
|
1061
1073
|
/** Client app specific metadata */
|
|
1062
1074
|
metadata?: Record<string, unknown>;
|
|
1063
1075
|
}
|
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "globodai-fam-sdk",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"description": "Official TypeScript SDK for the FAM API",
|
|
5
5
|
"type": "module",
|
|
6
|
-
"main": "./dist/index.
|
|
7
|
-
"module": "./dist/index.
|
|
6
|
+
"main": "./dist/index.cjs",
|
|
7
|
+
"module": "./dist/index.js",
|
|
8
8
|
"types": "./dist/index.d.ts",
|
|
9
9
|
"exports": {
|
|
10
10
|
".": {
|
|
11
11
|
"types": "./dist/index.d.ts",
|
|
12
|
-
"import": "./dist/index.
|
|
13
|
-
"require": "./dist/index.
|
|
12
|
+
"import": "./dist/index.js",
|
|
13
|
+
"require": "./dist/index.cjs"
|
|
14
14
|
},
|
|
15
15
|
"./webhooks": {
|
|
16
16
|
"types": "./dist/webhooks/index.d.ts",
|
|
17
|
-
"import": "./dist/webhooks/index.
|
|
18
|
-
"require": "./dist/webhooks/index.
|
|
17
|
+
"import": "./dist/webhooks/index.js",
|
|
18
|
+
"require": "./dist/webhooks/index.cjs"
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
21
|
"files": [
|