@gofynd/fdk-client-javascript 1.4.14 → 1.4.15-beta.2
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/README.md +1 -1
- package/package.json +1 -1
- package/sdk/application/ApplicationClient.d.ts +0 -2
- package/sdk/application/ApplicationClient.js +0 -2
- package/sdk/application/Cart/CartApplicationClient.d.ts +53 -60
- package/sdk/application/Cart/CartApplicationClient.js +53 -130
- package/sdk/application/Cart/CartApplicationModel.d.ts +143 -489
- package/sdk/application/Cart/CartApplicationModel.js +159 -380
- package/sdk/application/Cart/CartApplicationValidator.d.ts +19 -38
- package/sdk/application/Cart/CartApplicationValidator.js +18 -34
- package/sdk/application/Catalog/CatalogApplicationClient.d.ts +68 -88
- package/sdk/application/Catalog/CatalogApplicationClient.js +94 -114
- package/sdk/application/Catalog/CatalogApplicationModel.d.ts +142 -194
- package/sdk/application/Catalog/CatalogApplicationModel.js +133 -171
- package/sdk/application/Common/CommonApplicationClient.d.ts +2 -3
- package/sdk/application/Common/CommonApplicationClient.js +5 -6
- package/sdk/application/Common/CommonApplicationModel.d.ts +9 -9
- package/sdk/application/Common/CommonApplicationModel.js +6 -6
- package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +27 -34
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +27 -34
- package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +57 -45
- package/sdk/application/Configuration/ConfigurationApplicationModel.js +47 -35
- package/sdk/application/Configuration/ConfigurationApplicationValidator.d.ts +2 -2
- package/sdk/application/Configuration/ConfigurationApplicationValidator.js +2 -2
- package/sdk/application/Content/ContentApplicationClient.d.ts +33 -23
- package/sdk/application/Content/ContentApplicationClient.js +75 -54
- package/sdk/application/Content/ContentApplicationModel.d.ts +37 -93
- package/sdk/application/Content/ContentApplicationModel.js +32 -83
- package/sdk/application/Content/ContentApplicationValidator.d.ts +17 -23
- package/sdk/application/Content/ContentApplicationValidator.js +10 -15
- package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +8 -9
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +13 -14
- package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +25 -23
- package/sdk/application/FileStorage/FileStorageApplicationModel.js +18 -16
- package/sdk/application/FileStorage/FileStorageApplicationValidator.d.ts +6 -6
- package/sdk/application/FileStorage/FileStorageApplicationValidator.js +6 -6
- package/sdk/application/Lead/LeadApplicationClient.d.ts +3 -2
- package/sdk/application/Lead/LeadApplicationClient.js +3 -2
- package/sdk/application/Lead/LeadApplicationModel.d.ts +11 -11
- package/sdk/application/Lead/LeadApplicationModel.js +19 -19
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +16 -39
- package/sdk/application/Logistic/LogisticApplicationClient.js +21 -189
- package/sdk/application/Logistic/LogisticApplicationModel.d.ts +173 -532
- package/sdk/application/Logistic/LogisticApplicationModel.js +139 -409
- package/sdk/application/Logistic/LogisticApplicationValidator.d.ts +9 -54
- package/sdk/application/Logistic/LogisticApplicationValidator.js +8 -42
- package/sdk/application/Order/OrderApplicationClient.d.ts +10 -24
- package/sdk/application/Order/OrderApplicationClient.js +13 -96
- package/sdk/application/Order/OrderApplicationModel.d.ts +120 -436
- package/sdk/application/Order/OrderApplicationModel.js +81 -279
- package/sdk/application/Order/OrderApplicationValidator.d.ts +3 -17
- package/sdk/application/Order/OrderApplicationValidator.js +2 -15
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +99 -96
- package/sdk/application/Payment/PaymentApplicationClient.js +114 -111
- package/sdk/application/Payment/PaymentApplicationModel.d.ts +289 -293
- package/sdk/application/Payment/PaymentApplicationModel.js +241 -243
- package/sdk/application/Payment/PaymentApplicationValidator.d.ts +46 -46
- package/sdk/application/Payment/PaymentApplicationValidator.js +46 -46
- package/sdk/application/Rewards/RewardsApplicationClient.d.ts +16 -13
- package/sdk/application/Rewards/RewardsApplicationClient.js +22 -19
- package/sdk/application/Rewards/RewardsApplicationModel.d.ts +37 -37
- package/sdk/application/Rewards/RewardsApplicationModel.js +29 -29
- package/sdk/application/Rewards/RewardsApplicationValidator.d.ts +6 -6
- package/sdk/application/Rewards/RewardsApplicationValidator.js +6 -6
- package/sdk/application/Share/ShareApplicationModel.js +1 -1
- package/sdk/application/Theme/ThemeApplicationClient.d.ts +2 -2
- package/sdk/application/Theme/ThemeApplicationClient.js +6 -8
- package/sdk/application/Theme/ThemeApplicationModel.d.ts +17 -48
- package/sdk/application/Theme/ThemeApplicationModel.js +22 -42
- package/sdk/application/Theme/ThemeApplicationValidator.d.ts +3 -16
- package/sdk/application/Theme/ThemeApplicationValidator.js +2 -9
- package/sdk/application/User/UserApplicationClient.d.ts +10 -10
- package/sdk/application/User/UserApplicationClient.js +10 -10
- package/sdk/application/User/UserApplicationModel.d.ts +17 -17
- package/sdk/application/User/UserApplicationModel.js +16 -16
- package/sdk/application/User/UserApplicationValidator.d.ts +2 -2
- package/sdk/application/User/UserApplicationValidator.js +2 -2
- package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
- package/sdk/application/Webhook/WebhookApplicationClient.js +4 -4
- package/sdk/application/Webhook/WebhookApplicationModel.d.ts +9 -11
- package/sdk/application/Webhook/WebhookApplicationModel.js +6 -8
- package/sdk/application/Webhook/WebhookApplicationValidator.d.ts +2 -2
- package/sdk/application/Webhook/WebhookApplicationValidator.js +2 -2
- package/sdk/application/index.d.ts +0 -1
- package/sdk/application/index.js +0 -2
- package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +12 -86
- package/sdk/partner/FileStorage/FileStoragePartnerClient.js +24 -582
- package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +19 -116
- package/sdk/partner/FileStorage/FileStoragePartnerModel.js +14 -121
- package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +1 -8
- package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +4 -51
- package/sdk/partner/Lead/LeadPartnerClient.d.ts +2 -2
- package/sdk/partner/Lead/LeadPartnerClient.js +2 -2
- package/sdk/partner/Lead/LeadPartnerModel.d.ts +5 -5
- package/sdk/partner/Lead/LeadPartnerModel.js +15 -15
- package/sdk/partner/Logistics/LogisticsPartnerClient.d.ts +20 -126
- package/sdk/partner/Logistics/LogisticsPartnerClient.js +20 -970
- package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +85 -767
- package/sdk/partner/Logistics/LogisticsPartnerModel.js +76 -429
- package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +0 -10
- package/sdk/partner/Logistics/LogisticsPartnerValidator.js +6 -120
- package/sdk/partner/Theme/ThemePartnerClient.d.ts +10 -8
- package/sdk/partner/Theme/ThemePartnerClient.js +16 -14
- package/sdk/partner/Theme/ThemePartnerModel.d.ts +37 -96
- package/sdk/partner/Theme/ThemePartnerModel.js +36 -90
- package/sdk/partner/Theme/ThemePartnerValidator.js +4 -4
- package/sdk/partner/Webhook/WebhookPartnerClient.d.ts +18 -28
- package/sdk/partner/Webhook/WebhookPartnerClient.js +18 -103
- package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +179 -612
- package/sdk/partner/Webhook/WebhookPartnerModel.js +150 -253
- package/sdk/partner/Webhook/WebhookPartnerValidator.d.ts +0 -1
- package/sdk/partner/Webhook/WebhookPartnerValidator.js +3 -11
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +4 -5
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +8 -14
- package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +9 -59
- package/sdk/platform/Analytics/AnalyticsPlatformModel.js +4 -40
- package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +32 -2
- package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +243 -3
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +130 -11
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +152 -12
- package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +39 -1
- package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +35 -0
- package/sdk/platform/Billing/BillingPlatformClient.d.ts +12 -12
- package/sdk/platform/Billing/BillingPlatformClient.js +15 -15
- package/sdk/platform/Billing/BillingPlatformModel.d.ts +388 -443
- package/sdk/platform/Billing/BillingPlatformModel.js +263 -280
- package/sdk/platform/Billing/BillingPlatformValidator.d.ts +18 -16
- package/sdk/platform/Billing/BillingPlatformValidator.js +9 -8
- package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +103 -134
- package/sdk/platform/Cart/CartPlatformApplicationClient.js +112 -407
- package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +65 -111
- package/sdk/platform/Cart/CartPlatformApplicationValidator.js +44 -106
- package/sdk/platform/Cart/CartPlatformModel.d.ts +1321 -4975
- package/sdk/platform/Cart/CartPlatformModel.js +1226 -1922
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +183 -208
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +358 -383
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +126 -122
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +68 -66
- package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +118 -141
- package/sdk/platform/Catalog/CatalogPlatformClient.js +170 -193
- package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1751 -1501
- package/sdk/platform/Catalog/CatalogPlatformModel.js +1224 -1393
- package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +18 -18
- package/sdk/platform/Catalog/CatalogPlatformValidator.js +18 -18
- package/sdk/platform/Common/CommonPlatformClient.d.ts +2 -3
- package/sdk/platform/Common/CommonPlatformClient.js +2 -3
- package/sdk/platform/Common/CommonPlatformModel.d.ts +9 -9
- package/sdk/platform/Common/CommonPlatformModel.js +6 -6
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +17 -16
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +17 -16
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +8 -8
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +8 -8
- package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +33 -43
- package/sdk/platform/Communication/CommunicationPlatformModel.js +34 -38
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +42 -46
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +43 -47
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +223 -223
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +212 -210
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +12 -12
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +12 -12
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +33 -46
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +54 -67
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +18 -18
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +18 -18
- package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +24 -45
- package/sdk/platform/Configuration/ConfigurationPlatformClient.js +30 -134
- package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +124 -283
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +94 -219
- package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +9 -37
- package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +8 -27
- package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +141 -124
- package/sdk/platform/Content/ContentPlatformApplicationClient.js +422 -449
- package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +141 -179
- package/sdk/platform/Content/ContentPlatformApplicationValidator.js +130 -168
- package/sdk/platform/Content/ContentPlatformClient.d.ts +106 -142
- package/sdk/platform/Content/ContentPlatformClient.js +336 -523
- package/sdk/platform/Content/ContentPlatformModel.d.ts +395 -1241
- package/sdk/platform/Content/ContentPlatformModel.js +390 -521
- package/sdk/platform/Content/ContentPlatformValidator.d.ts +117 -168
- package/sdk/platform/Content/ContentPlatformValidator.js +108 -162
- package/sdk/platform/Discount/DiscountPlatformClient.d.ts +12 -14
- package/sdk/platform/Discount/DiscountPlatformClient.js +12 -14
- package/sdk/platform/Discount/DiscountPlatformModel.d.ts +13 -13
- package/sdk/platform/Discount/DiscountPlatformModel.js +12 -12
- package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +2 -2
- package/sdk/platform/Discount/DiscountPlatformValidator.js +2 -2
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +36 -94
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +60 -462
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +15 -62
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +13 -75
- package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +19 -19
- package/sdk/platform/FileStorage/FileStoragePlatformClient.js +21 -21
- package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +101 -370
- package/sdk/platform/FileStorage/FileStoragePlatformModel.js +84 -313
- package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +6 -6
- package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +6 -6
- package/sdk/platform/Finance/FinancePlatformClient.d.ts +320 -0
- package/sdk/platform/Finance/FinancePlatformClient.js +2333 -0
- package/sdk/platform/Finance/FinancePlatformModel.d.ts +2890 -0
- package/sdk/platform/Finance/FinancePlatformModel.js +2148 -0
- package/sdk/platform/Finance/FinancePlatformValidator.d.ts +284 -0
- package/sdk/platform/Finance/FinancePlatformValidator.js +354 -0
- package/sdk/platform/Lead/LeadPlatformClient.d.ts +2 -2
- package/sdk/platform/Lead/LeadPlatformClient.js +2 -2
- package/sdk/platform/Lead/LeadPlatformModel.d.ts +5 -5
- package/sdk/platform/Lead/LeadPlatformModel.js +16 -16
- package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +4 -15
- package/sdk/platform/Order/OrderPlatformApplicationClient.js +5 -83
- package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +4 -25
- package/sdk/platform/Order/OrderPlatformApplicationValidator.js +3 -16
- package/sdk/platform/Order/OrderPlatformClient.d.ts +97 -178
- package/sdk/platform/Order/OrderPlatformClient.js +245 -597
- package/sdk/platform/Order/OrderPlatformModel.d.ts +3071 -5449
- package/sdk/platform/Order/OrderPlatformModel.js +1656 -3501
- package/sdk/platform/Order/OrderPlatformValidator.d.ts +190 -237
- package/sdk/platform/Order/OrderPlatformValidator.js +105 -153
- package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +4 -6
- package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +7 -9
- package/sdk/platform/Partner/PartnerPlatformModel.d.ts +9 -9
- package/sdk/platform/Partner/PartnerPlatformModel.js +8 -8
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +106 -94
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +146 -131
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +93 -64
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +70 -62
- package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -20
- package/sdk/platform/Payment/PaymentPlatformClient.js +20 -20
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +507 -386
- package/sdk/platform/Payment/PaymentPlatformModel.js +376 -323
- package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +10 -10
- package/sdk/platform/Payment/PaymentPlatformValidator.js +10 -10
- package/sdk/platform/PlatformClient.d.ts +2 -0
- package/sdk/platform/PlatformClient.js +4 -0
- package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +2 -2
- package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +2 -2
- package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +2 -2
- package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +2 -2
- package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +9 -9
- package/sdk/platform/Rewards/RewardsPlatformModel.js +8 -8
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.d.ts +35 -45
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +38 -117
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +13 -22
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +12 -24
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +46 -40
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +64 -58
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +396 -620
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +326 -501
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +8 -8
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +8 -8
- package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +2 -2
- package/sdk/platform/Share/SharePlatformApplicationClient.js +2 -2
- package/sdk/platform/Share/SharePlatformModel.d.ts +5 -36
- package/sdk/platform/Share/SharePlatformModel.js +4 -27
- package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +3 -3
- package/sdk/platform/Theme/ThemePlatformApplicationClient.js +4 -8
- package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +0 -5
- package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +0 -2
- package/sdk/platform/Theme/ThemePlatformModel.d.ts +11 -37
- package/sdk/platform/Theme/ThemePlatformModel.js +15 -33
- package/sdk/platform/User/UserPlatformApplicationClient.d.ts +12 -12
- package/sdk/platform/User/UserPlatformApplicationClient.js +12 -12
- package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +2 -2
- package/sdk/platform/User/UserPlatformApplicationValidator.js +2 -2
- package/sdk/platform/User/UserPlatformModel.d.ts +21 -21
- package/sdk/platform/User/UserPlatformModel.js +23 -23
- package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +78 -25
- package/sdk/platform/Webhook/WebhookPlatformClient.js +470 -75
- package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +427 -720
- package/sdk/platform/Webhook/WebhookPlatformModel.js +386 -410
- package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +55 -10
- package/sdk/platform/Webhook/WebhookPlatformValidator.js +72 -12
- package/sdk/platform/index.d.ts +1 -0
- package/sdk/platform/index.js +2 -0
- package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +2 -3
- package/sdk/public/Configuration/ConfigurationPublicClient.js +5 -6
- package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +9 -9
- package/sdk/public/Configuration/ConfigurationPublicModel.js +6 -6
- package/sdk/public/Content/ContentPublicClient.d.ts +2 -112
- package/sdk/public/Content/ContentPublicClient.js +5 -791
- package/sdk/public/Content/ContentPublicModel.d.ts +3 -549
- package/sdk/public/Content/ContentPublicModel.js +3 -649
- package/sdk/public/Content/ContentPublicValidator.d.ts +3 -69
- package/sdk/public/Content/ContentPublicValidator.js +2 -88
- package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
- package/sdk/public/Webhook/WebhookPublicClient.js +8 -8
- package/sdk/public/Webhook/WebhookPublicModel.d.ts +21 -21
- package/sdk/public/Webhook/WebhookPublicModel.js +15 -15
- package/sdk/public/Webhook/WebhookPublicValidator.d.ts +4 -4
- package/sdk/public/Webhook/WebhookPublicValidator.js +4 -4
- package/sdk/application/Finance/FinanceApplicationClient.d.ts +0 -36
- package/sdk/application/Finance/FinanceApplicationClient.js +0 -202
- package/sdk/application/Finance/FinanceApplicationModel.d.ts +0 -289
- package/sdk/application/Finance/FinanceApplicationModel.js +0 -208
- package/sdk/application/Finance/FinanceApplicationValidator.d.ts +0 -25
- package/sdk/application/Finance/FinanceApplicationValidator.js +0 -31
|
@@ -19,7 +19,7 @@ class Cart {
|
|
|
19
19
|
* @param {CartPlatformApplicationValidator.AddAddressParam} arg - Arg object
|
|
20
20
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
21
21
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
22
|
-
* @returns {Promise<CartPlatformModel.
|
|
22
|
+
* @returns {Promise<CartPlatformModel.SaveAddressResponse>} - Success response
|
|
23
23
|
* @name addAddress
|
|
24
24
|
* @summary: Creates a new address for a customer
|
|
25
25
|
* @description: Customers can add a new address to their cart to save details such as name, email, contact information, and address. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/addAddress/).
|
|
@@ -73,7 +73,7 @@ class Cart {
|
|
|
73
73
|
|
|
74
74
|
const {
|
|
75
75
|
error: res_error,
|
|
76
|
-
} = CartPlatformModel.
|
|
76
|
+
} = CartPlatformModel.SaveAddressResponse().validate(responseData, {
|
|
77
77
|
abortEarly: false,
|
|
78
78
|
allowUnknown: true,
|
|
79
79
|
});
|
|
@@ -96,7 +96,7 @@ class Cart {
|
|
|
96
96
|
* @param {CartPlatformApplicationValidator.AddItemsParam} arg - Arg object
|
|
97
97
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
98
98
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
99
|
-
* @returns {Promise<CartPlatformModel.
|
|
99
|
+
* @returns {Promise<CartPlatformModel.AddCartDetailResponse>} - Success response
|
|
100
100
|
* @name addItems
|
|
101
101
|
* @summary: Add items to cart
|
|
102
102
|
* @description: Add product items to the customer's existing shopping cart. If there is no existing cart associated with the customer, it creates a new one and adds the items to it. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/addItems/).
|
|
@@ -155,7 +155,7 @@ class Cart {
|
|
|
155
155
|
|
|
156
156
|
const {
|
|
157
157
|
error: res_error,
|
|
158
|
-
} = CartPlatformModel.
|
|
158
|
+
} = CartPlatformModel.AddCartDetailResponse().validate(responseData, {
|
|
159
159
|
abortEarly: false,
|
|
160
160
|
allowUnknown: true,
|
|
161
161
|
});
|
|
@@ -178,7 +178,7 @@ class Cart {
|
|
|
178
178
|
* @param {CartPlatformApplicationValidator.AddPriceAdjustmentParam} arg - Arg object
|
|
179
179
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
180
180
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
181
|
-
* @returns {Promise<CartPlatformModel.
|
|
181
|
+
* @returns {Promise<CartPlatformModel.PriceAdjustmentResponse>} - Success response
|
|
182
182
|
* @name addPriceAdjustment
|
|
183
183
|
* @summary: Create price adjustments
|
|
184
184
|
* @description: Create custom price adjustments for items in the cart, facilitating the application of discounts or promotions. Price adjustments can be tailored based on specific sales channel contexts, enhancing flexibility in pricing strategies. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/addPriceAdjustment/).
|
|
@@ -234,7 +234,7 @@ class Cart {
|
|
|
234
234
|
|
|
235
235
|
const {
|
|
236
236
|
error: res_error,
|
|
237
|
-
} = CartPlatformModel.
|
|
237
|
+
} = CartPlatformModel.PriceAdjustmentResponse().validate(responseData, {
|
|
238
238
|
abortEarly: false,
|
|
239
239
|
allowUnknown: true,
|
|
240
240
|
});
|
|
@@ -257,7 +257,7 @@ class Cart {
|
|
|
257
257
|
* @param {CartPlatformApplicationValidator.ApplyCouponParam} arg - Arg object
|
|
258
258
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
259
259
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
260
|
-
* @returns {Promise<CartPlatformModel.
|
|
260
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
261
261
|
* @name applyCoupon
|
|
262
262
|
* @summary: Apply coupon
|
|
263
263
|
* @description: Apply a coupon code to the customer's cart to trigger discounts on eligible items - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/applyCoupon/).
|
|
@@ -326,7 +326,7 @@ class Cart {
|
|
|
326
326
|
|
|
327
327
|
const {
|
|
328
328
|
error: res_error,
|
|
329
|
-
} = CartPlatformModel.
|
|
329
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
330
330
|
abortEarly: false,
|
|
331
331
|
allowUnknown: true,
|
|
332
332
|
});
|
|
@@ -351,8 +351,9 @@ class Cart {
|
|
|
351
351
|
*
|
|
352
352
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
353
353
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
354
|
-
* @returns {Promise<CartPlatformModel.
|
|
355
|
-
* Success response
|
|
354
|
+
* @returns {Promise<CartPlatformModel.OpenApiCartServiceabilityResponse>}
|
|
355
|
+
* - Success response
|
|
356
|
+
*
|
|
356
357
|
* @name checkCartServiceability
|
|
357
358
|
* @summary: Check cart serviceability
|
|
358
359
|
* @description: Verify the serviceability of items in the cart at a specific pin code and ensure accurate delivery promises. System checks each item's availability and delivery feasibility, providing real-time information on serviceability and estimated delivery times. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/checkCartServiceability/).
|
|
@@ -408,7 +409,7 @@ class Cart {
|
|
|
408
409
|
|
|
409
410
|
const {
|
|
410
411
|
error: res_error,
|
|
411
|
-
} = CartPlatformModel.
|
|
412
|
+
} = CartPlatformModel.OpenApiCartServiceabilityResponse().validate(
|
|
412
413
|
responseData,
|
|
413
414
|
{ abortEarly: false, allowUnknown: true }
|
|
414
415
|
);
|
|
@@ -431,7 +432,7 @@ class Cart {
|
|
|
431
432
|
* @param {CartPlatformApplicationValidator.CheckoutCartParam} arg - Arg object
|
|
432
433
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
433
434
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
434
|
-
* @returns {Promise<CartPlatformModel.
|
|
435
|
+
* @returns {Promise<CartPlatformModel.OpenApiCheckoutResponse>} - Success response
|
|
435
436
|
* @name checkoutCart
|
|
436
437
|
* @summary: Checkout cart
|
|
437
438
|
* @description: The checkout cart initiates the order creation process based on the selected address and payment method. It revalidates the cart details to ensure safe and seamless order placement. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/checkoutCart/).
|
|
@@ -485,7 +486,7 @@ class Cart {
|
|
|
485
486
|
|
|
486
487
|
const {
|
|
487
488
|
error: res_error,
|
|
488
|
-
} = CartPlatformModel.
|
|
489
|
+
} = CartPlatformModel.OpenApiCheckoutResponse().validate(responseData, {
|
|
489
490
|
abortEarly: false,
|
|
490
491
|
allowUnknown: true,
|
|
491
492
|
});
|
|
@@ -589,7 +590,7 @@ class Cart {
|
|
|
589
590
|
* @param {CartPlatformApplicationValidator.CreateCouponParam} arg - Arg object
|
|
590
591
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
591
592
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
592
|
-
* @returns {Promise<CartPlatformModel.
|
|
593
|
+
* @returns {Promise<CartPlatformModel.SuccessMessage>} - Success response
|
|
593
594
|
* @name createCoupon
|
|
594
595
|
* @summary: Create a coupon
|
|
595
596
|
* @description: Creates a new coupon based on the selected coupon type. Sellers can choose from multiple supported coupon types, including percentage value, fixed amount value, bundled discount, buy X get Y items, and more, along with customizable coupon criteria to meet specific business requirements. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/createCoupon/).
|
|
@@ -643,7 +644,7 @@ class Cart {
|
|
|
643
644
|
|
|
644
645
|
const {
|
|
645
646
|
error: res_error,
|
|
646
|
-
} = CartPlatformModel.
|
|
647
|
+
} = CartPlatformModel.SuccessMessage().validate(responseData, {
|
|
647
648
|
abortEarly: false,
|
|
648
649
|
allowUnknown: true,
|
|
649
650
|
});
|
|
@@ -666,7 +667,7 @@ class Cart {
|
|
|
666
667
|
* @param {CartPlatformApplicationValidator.CreatePromotionParam} arg - Arg object
|
|
667
668
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
668
669
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
669
|
-
* @returns {Promise<CartPlatformModel.
|
|
670
|
+
* @returns {Promise<CartPlatformModel.PromotionAdd>} - Success response
|
|
670
671
|
* @name createPromotion
|
|
671
672
|
* @summary: Create a promotion
|
|
672
673
|
* @description: Creates a new promotion based on the selected promotion type. Sellers can choose from multiple supported promotion types, including percentage value, fixed amount value, bundled discount, buy X get Y items, and more, along with customizable promotion criteria to meet specific business requirements. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/createPromotion/).
|
|
@@ -722,7 +723,7 @@ class Cart {
|
|
|
722
723
|
|
|
723
724
|
const {
|
|
724
725
|
error: res_error,
|
|
725
|
-
} = CartPlatformModel.
|
|
726
|
+
} = CartPlatformModel.PromotionAdd().validate(responseData, {
|
|
726
727
|
abortEarly: false,
|
|
727
728
|
allowUnknown: true,
|
|
728
729
|
});
|
|
@@ -745,7 +746,7 @@ class Cart {
|
|
|
745
746
|
* @param {CartPlatformApplicationValidator.DeleteCartParam} arg - Arg object
|
|
746
747
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
747
748
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
748
|
-
* @returns {Promise<CartPlatformModel.
|
|
749
|
+
* @returns {Promise<CartPlatformModel.DeleteCartDetailResponse>} - Success response
|
|
749
750
|
* @name deleteCart
|
|
750
751
|
* @summary: Delete a cart
|
|
751
752
|
* @description: Delete all items from the user's cart and resets it to its initial state, providing a clean slate for new selections. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/deleteCart/).
|
|
@@ -802,7 +803,7 @@ class Cart {
|
|
|
802
803
|
|
|
803
804
|
const {
|
|
804
805
|
error: res_error,
|
|
805
|
-
} = CartPlatformModel.
|
|
806
|
+
} = CartPlatformModel.DeleteCartDetailResponse().validate(responseData, {
|
|
806
807
|
abortEarly: false,
|
|
807
808
|
allowUnknown: true,
|
|
808
809
|
});
|
|
@@ -821,169 +822,13 @@ class Cart {
|
|
|
821
822
|
return response;
|
|
822
823
|
}
|
|
823
824
|
|
|
824
|
-
/**
|
|
825
|
-
* @param {CartPlatformApplicationValidator.DeleteCouponParam} arg - Arg object
|
|
826
|
-
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
827
|
-
* @param {import("../PlatformAPIClient").Options} - Options
|
|
828
|
-
* @returns {Promise<CartPlatformModel.SuccessMessage>} - Success response
|
|
829
|
-
* @name deleteCoupon
|
|
830
|
-
* @summary: Delete a coupon which is in draft state
|
|
831
|
-
* @description: Delete details of a draft coupon by providing its unique identifier to delete information such as coupon type, rules, validity period and other related information. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/deleteCoupon/).
|
|
832
|
-
*/
|
|
833
|
-
async deleteCoupon(
|
|
834
|
-
{ id, requestHeaders } = { requestHeaders: {} },
|
|
835
|
-
{ responseHeaders } = { responseHeaders: false }
|
|
836
|
-
) {
|
|
837
|
-
const { error } = CartPlatformApplicationValidator.deleteCoupon().validate(
|
|
838
|
-
{
|
|
839
|
-
id,
|
|
840
|
-
},
|
|
841
|
-
{ abortEarly: false, allowUnknown: true }
|
|
842
|
-
);
|
|
843
|
-
if (error) {
|
|
844
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
845
|
-
}
|
|
846
|
-
|
|
847
|
-
// Showing warrnings if extra unknown parameters are found
|
|
848
|
-
const {
|
|
849
|
-
error: warrning,
|
|
850
|
-
} = CartPlatformApplicationValidator.deleteCoupon().validate(
|
|
851
|
-
{
|
|
852
|
-
id,
|
|
853
|
-
},
|
|
854
|
-
{ abortEarly: false, allowUnknown: false }
|
|
855
|
-
);
|
|
856
|
-
if (warrning) {
|
|
857
|
-
Logger({
|
|
858
|
-
level: "WARN",
|
|
859
|
-
message: `Parameter Validation warrnings for platform > Cart > deleteCoupon \n ${warrning}`,
|
|
860
|
-
});
|
|
861
|
-
}
|
|
862
|
-
|
|
863
|
-
const query_params = {};
|
|
864
|
-
|
|
865
|
-
const response = await PlatformAPIClient.execute(
|
|
866
|
-
this.config,
|
|
867
|
-
"delete",
|
|
868
|
-
`/service/platform/cart/v1.0/company/${this.config.companyId}/application/${this.applicationId}/coupon/${id}`,
|
|
869
|
-
query_params,
|
|
870
|
-
undefined,
|
|
871
|
-
requestHeaders,
|
|
872
|
-
{ responseHeaders }
|
|
873
|
-
);
|
|
874
|
-
|
|
875
|
-
let responseData = response;
|
|
876
|
-
if (responseHeaders) {
|
|
877
|
-
responseData = response[0];
|
|
878
|
-
}
|
|
879
|
-
|
|
880
|
-
const {
|
|
881
|
-
error: res_error,
|
|
882
|
-
} = CartPlatformModel.SuccessMessage().validate(responseData, {
|
|
883
|
-
abortEarly: false,
|
|
884
|
-
allowUnknown: true,
|
|
885
|
-
});
|
|
886
|
-
|
|
887
|
-
if (res_error) {
|
|
888
|
-
if (this.config.options.strictResponseCheck === true) {
|
|
889
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
890
|
-
} else {
|
|
891
|
-
Logger({
|
|
892
|
-
level: "WARN",
|
|
893
|
-
message: `Response Validation Warnings for platform > Cart > deleteCoupon \n ${res_error}`,
|
|
894
|
-
});
|
|
895
|
-
}
|
|
896
|
-
}
|
|
897
|
-
|
|
898
|
-
return response;
|
|
899
|
-
}
|
|
900
|
-
|
|
901
|
-
/**
|
|
902
|
-
* @param {CartPlatformApplicationValidator.DeletePromotionParam} arg - Arg object
|
|
903
|
-
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
904
|
-
* @param {import("../PlatformAPIClient").Options} - Options
|
|
905
|
-
* @returns {Promise<CartPlatformModel.SuccessMessage>} - Success response
|
|
906
|
-
* @name deletePromotion
|
|
907
|
-
* @summary: Delete a promotion which is in draft state
|
|
908
|
-
* @description: Delete details of a draft promotion by providing its unique identifier to delete information such as promotion type, rules, validity period and other related information. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/deletePromotion/).
|
|
909
|
-
*/
|
|
910
|
-
async deletePromotion(
|
|
911
|
-
{ id, requestHeaders } = { requestHeaders: {} },
|
|
912
|
-
{ responseHeaders } = { responseHeaders: false }
|
|
913
|
-
) {
|
|
914
|
-
const {
|
|
915
|
-
error,
|
|
916
|
-
} = CartPlatformApplicationValidator.deletePromotion().validate(
|
|
917
|
-
{
|
|
918
|
-
id,
|
|
919
|
-
},
|
|
920
|
-
{ abortEarly: false, allowUnknown: true }
|
|
921
|
-
);
|
|
922
|
-
if (error) {
|
|
923
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
924
|
-
}
|
|
925
|
-
|
|
926
|
-
// Showing warrnings if extra unknown parameters are found
|
|
927
|
-
const {
|
|
928
|
-
error: warrning,
|
|
929
|
-
} = CartPlatformApplicationValidator.deletePromotion().validate(
|
|
930
|
-
{
|
|
931
|
-
id,
|
|
932
|
-
},
|
|
933
|
-
{ abortEarly: false, allowUnknown: false }
|
|
934
|
-
);
|
|
935
|
-
if (warrning) {
|
|
936
|
-
Logger({
|
|
937
|
-
level: "WARN",
|
|
938
|
-
message: `Parameter Validation warrnings for platform > Cart > deletePromotion \n ${warrning}`,
|
|
939
|
-
});
|
|
940
|
-
}
|
|
941
|
-
|
|
942
|
-
const query_params = {};
|
|
943
|
-
|
|
944
|
-
const response = await PlatformAPIClient.execute(
|
|
945
|
-
this.config,
|
|
946
|
-
"delete",
|
|
947
|
-
`/service/platform/cart/v1.0/company/${this.config.companyId}/application/${this.applicationId}/promotion/${id}`,
|
|
948
|
-
query_params,
|
|
949
|
-
undefined,
|
|
950
|
-
requestHeaders,
|
|
951
|
-
{ responseHeaders }
|
|
952
|
-
);
|
|
953
|
-
|
|
954
|
-
let responseData = response;
|
|
955
|
-
if (responseHeaders) {
|
|
956
|
-
responseData = response[0];
|
|
957
|
-
}
|
|
958
|
-
|
|
959
|
-
const {
|
|
960
|
-
error: res_error,
|
|
961
|
-
} = CartPlatformModel.SuccessMessage().validate(responseData, {
|
|
962
|
-
abortEarly: false,
|
|
963
|
-
allowUnknown: true,
|
|
964
|
-
});
|
|
965
|
-
|
|
966
|
-
if (res_error) {
|
|
967
|
-
if (this.config.options.strictResponseCheck === true) {
|
|
968
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
969
|
-
} else {
|
|
970
|
-
Logger({
|
|
971
|
-
level: "WARN",
|
|
972
|
-
message: `Response Validation Warnings for platform > Cart > deletePromotion \n ${res_error}`,
|
|
973
|
-
});
|
|
974
|
-
}
|
|
975
|
-
}
|
|
976
|
-
|
|
977
|
-
return response;
|
|
978
|
-
}
|
|
979
|
-
|
|
980
825
|
/**
|
|
981
826
|
* @param {CartPlatformApplicationValidator.FetchAndvalidateCartItemsParam} arg
|
|
982
827
|
* - Arg object
|
|
983
828
|
*
|
|
984
829
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
985
830
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
986
|
-
* @returns {Promise<CartPlatformModel.
|
|
831
|
+
* @returns {Promise<CartPlatformModel.OpenapiCartDetailsResponse>} - Success response
|
|
987
832
|
* @name fetchAndvalidateCartItems
|
|
988
833
|
* @summary: Get and validate cart items
|
|
989
834
|
* @description: Retrieve cart details for a provided list of cart items and validate its contents. This ensures accuracy and completeness in cart information, including item quantities, prices, discounts, and applicable taxes. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/fetchAndvalidateCartItems/).
|
|
@@ -1039,7 +884,7 @@ class Cart {
|
|
|
1039
884
|
|
|
1040
885
|
const {
|
|
1041
886
|
error: res_error,
|
|
1042
|
-
} = CartPlatformModel.
|
|
887
|
+
} = CartPlatformModel.OpenapiCartDetailsResponse().validate(responseData, {
|
|
1043
888
|
abortEarly: false,
|
|
1044
889
|
allowUnknown: true,
|
|
1045
890
|
});
|
|
@@ -1137,7 +982,7 @@ class Cart {
|
|
|
1137
982
|
* @param {CartPlatformApplicationValidator.GetAbandonedCartParam} arg - Arg object
|
|
1138
983
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1139
984
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1140
|
-
* @returns {Promise<CartPlatformModel.
|
|
985
|
+
* @returns {Promise<CartPlatformModel.AbandonedCartResponse>} - Success response
|
|
1141
986
|
* @name getAbandonedCart
|
|
1142
987
|
* @summary: Get abandoned carts
|
|
1143
988
|
* @description: Retrieve the list of abandoned carts that have been active for the specified period of time and have not yet been archived for the specific sales channel. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getAbandonedCart/).
|
|
@@ -1221,7 +1066,7 @@ class Cart {
|
|
|
1221
1066
|
|
|
1222
1067
|
const {
|
|
1223
1068
|
error: res_error,
|
|
1224
|
-
} = CartPlatformModel.
|
|
1069
|
+
} = CartPlatformModel.AbandonedCartResponse().validate(responseData, {
|
|
1225
1070
|
abortEarly: false,
|
|
1226
1071
|
allowUnknown: true,
|
|
1227
1072
|
});
|
|
@@ -1246,7 +1091,7 @@ class Cart {
|
|
|
1246
1091
|
*
|
|
1247
1092
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1248
1093
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1249
|
-
* @returns {Promise<CartPlatformModel.
|
|
1094
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
1250
1095
|
* @name getAbandonedCartDetails
|
|
1251
1096
|
* @summary: Get abandoned cart details
|
|
1252
1097
|
* @description: Retrieves abandoned cart details linked to a specific customer using a unique cart ID. It offers an overview of the items, quantities, prices, and other relevant information associated with the cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getAbandonedCartDetails/).
|
|
@@ -1312,7 +1157,7 @@ class Cart {
|
|
|
1312
1157
|
|
|
1313
1158
|
const {
|
|
1314
1159
|
error: res_error,
|
|
1315
|
-
} = CartPlatformModel.
|
|
1160
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
1316
1161
|
abortEarly: false,
|
|
1317
1162
|
allowUnknown: true,
|
|
1318
1163
|
});
|
|
@@ -1445,7 +1290,7 @@ class Cart {
|
|
|
1445
1290
|
* @param {CartPlatformApplicationValidator.GetAddressesParam} arg - Arg object
|
|
1446
1291
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1447
1292
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1448
|
-
* @returns {Promise<CartPlatformModel.
|
|
1293
|
+
* @returns {Promise<CartPlatformModel.PlatformGetAddressesResponse>} -
|
|
1449
1294
|
* Success response
|
|
1450
1295
|
* @name getAddresses
|
|
1451
1296
|
* @summary: Get a list of addresses for a customer
|
|
@@ -1528,10 +1373,10 @@ class Cart {
|
|
|
1528
1373
|
|
|
1529
1374
|
const {
|
|
1530
1375
|
error: res_error,
|
|
1531
|
-
} = CartPlatformModel.
|
|
1532
|
-
|
|
1533
|
-
allowUnknown: true
|
|
1534
|
-
|
|
1376
|
+
} = CartPlatformModel.PlatformGetAddressesResponse().validate(
|
|
1377
|
+
responseData,
|
|
1378
|
+
{ abortEarly: false, allowUnknown: true }
|
|
1379
|
+
);
|
|
1535
1380
|
|
|
1536
1381
|
if (res_error) {
|
|
1537
1382
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1551,9 +1396,9 @@ class Cart {
|
|
|
1551
1396
|
* @param {CartPlatformApplicationValidator.GetAppCouponsParam} arg - Arg object
|
|
1552
1397
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1553
1398
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1554
|
-
* @returns {Promise<CartPlatformModel.
|
|
1399
|
+
* @returns {Promise<CartPlatformModel.GetCouponResponse>} - Success response
|
|
1555
1400
|
* @name getAppCoupons
|
|
1556
|
-
* @summary: List
|
|
1401
|
+
* @summary: List coupons
|
|
1557
1402
|
* @description: Retrieve a list of all available coupons that customer can apply to their carts. It provides details about each coupon, including its code, discount amount, and applicable conditions. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getAppCoupons/).
|
|
1558
1403
|
*/
|
|
1559
1404
|
async getAppCoupons(
|
|
@@ -1615,7 +1460,7 @@ class Cart {
|
|
|
1615
1460
|
|
|
1616
1461
|
const {
|
|
1617
1462
|
error: res_error,
|
|
1618
|
-
} = CartPlatformModel.
|
|
1463
|
+
} = CartPlatformModel.GetCouponResponse().validate(responseData, {
|
|
1619
1464
|
abortEarly: false,
|
|
1620
1465
|
allowUnknown: true,
|
|
1621
1466
|
});
|
|
@@ -1640,7 +1485,7 @@ class Cart {
|
|
|
1640
1485
|
*
|
|
1641
1486
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1642
1487
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1643
|
-
* @returns {Promise<CartPlatformModel.
|
|
1488
|
+
* @returns {Promise<CartPlatformModel.CartDeliveryModesResponse>} - Success response
|
|
1644
1489
|
* @name getAvailableDeliveryModes
|
|
1645
1490
|
* @summary: Get delivery modes
|
|
1646
1491
|
* @description: Retrieve a list of delivery modes (home delivery/store pickup) along with a list of available pickup stores for a given cart at a specified PIN Code. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getAvailableDeliveryModes/).
|
|
@@ -1700,7 +1545,7 @@ class Cart {
|
|
|
1700
1545
|
|
|
1701
1546
|
const {
|
|
1702
1547
|
error: res_error,
|
|
1703
|
-
} = CartPlatformModel.
|
|
1548
|
+
} = CartPlatformModel.CartDeliveryModesResponse().validate(responseData, {
|
|
1704
1549
|
abortEarly: false,
|
|
1705
1550
|
allowUnknown: true,
|
|
1706
1551
|
});
|
|
@@ -1723,7 +1568,7 @@ class Cart {
|
|
|
1723
1568
|
* @param {CartPlatformApplicationValidator.GetCartParam} arg - Arg object
|
|
1724
1569
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1725
1570
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1726
|
-
* @returns {Promise<CartPlatformModel.
|
|
1571
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
1727
1572
|
* @name getCart
|
|
1728
1573
|
* @summary: Get a cart
|
|
1729
1574
|
* @description: Retrieve details of a cart linked to a specific customer using either the customer's ID or a unique cart ID. It offers an overview of the items, quantities, prices, and other relevant information associated with the cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getCart/).
|
|
@@ -1798,7 +1643,7 @@ class Cart {
|
|
|
1798
1643
|
|
|
1799
1644
|
const {
|
|
1800
1645
|
error: res_error,
|
|
1801
|
-
} = CartPlatformModel.
|
|
1646
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
1802
1647
|
abortEarly: false,
|
|
1803
1648
|
allowUnknown: true,
|
|
1804
1649
|
});
|
|
@@ -1821,10 +1666,10 @@ class Cart {
|
|
|
1821
1666
|
* @param {CartPlatformApplicationValidator.GetCartListParam} arg - Arg object
|
|
1822
1667
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1823
1668
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1824
|
-
* @returns {Promise<CartPlatformModel.
|
|
1669
|
+
* @returns {Promise<CartPlatformModel.MultiCartResponse>} - Success response
|
|
1825
1670
|
* @name getCartList
|
|
1826
|
-
* @summary: List
|
|
1827
|
-
* @description: Retrieve the list of active carts associated with a specific customer.
|
|
1671
|
+
* @summary: List carts
|
|
1672
|
+
* @description: Retrieve the list of active carts associated with a specific customer. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getCartList/).
|
|
1828
1673
|
*/
|
|
1829
1674
|
async getCartList(
|
|
1830
1675
|
{ fromDate, toDate, filterOn, requestHeaders } = { requestHeaders: {} },
|
|
@@ -1882,7 +1727,7 @@ class Cart {
|
|
|
1882
1727
|
|
|
1883
1728
|
const {
|
|
1884
1729
|
error: res_error,
|
|
1885
|
-
} = CartPlatformModel.
|
|
1730
|
+
} = CartPlatformModel.MultiCartResponse().validate(responseData, {
|
|
1886
1731
|
abortEarly: false,
|
|
1887
1732
|
allowUnknown: true,
|
|
1888
1733
|
});
|
|
@@ -1905,7 +1750,7 @@ class Cart {
|
|
|
1905
1750
|
* @param {CartPlatformApplicationValidator.GetCartShareLinkParam} arg - Arg object
|
|
1906
1751
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1907
1752
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1908
|
-
* @returns {Promise<CartPlatformModel.
|
|
1753
|
+
* @returns {Promise<CartPlatformModel.GetShareCartLinkResponse>} - Success response
|
|
1909
1754
|
* @name getCartShareLink
|
|
1910
1755
|
* @summary: Share cart link
|
|
1911
1756
|
* @description: Generate a unique shareable link for the customer's cart for a specific sales channel. This link enables easy sharing of the cart contents with other users, facilitating collaborative shopping experiences. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getCartShareLink/).
|
|
@@ -1961,7 +1806,7 @@ class Cart {
|
|
|
1961
1806
|
|
|
1962
1807
|
const {
|
|
1963
1808
|
error: res_error,
|
|
1964
|
-
} = CartPlatformModel.
|
|
1809
|
+
} = CartPlatformModel.GetShareCartLinkResponse().validate(responseData, {
|
|
1965
1810
|
abortEarly: false,
|
|
1966
1811
|
allowUnknown: true,
|
|
1967
1812
|
});
|
|
@@ -1984,7 +1829,7 @@ class Cart {
|
|
|
1984
1829
|
* @param {CartPlatformApplicationValidator.GetCartSharedItemsParam} arg - Arg object
|
|
1985
1830
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1986
1831
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1987
|
-
* @returns {Promise<CartPlatformModel.
|
|
1832
|
+
* @returns {Promise<CartPlatformModel.SharedCartResponse>} - Success response
|
|
1988
1833
|
* @name getCartSharedItems
|
|
1989
1834
|
* @summary: List shared cart items
|
|
1990
1835
|
* @description: Retrieve the cart items from the shared cart link based on unique token. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getCartSharedItems/).
|
|
@@ -2040,7 +1885,7 @@ class Cart {
|
|
|
2040
1885
|
|
|
2041
1886
|
const {
|
|
2042
1887
|
error: res_error,
|
|
2043
|
-
} = CartPlatformModel.
|
|
1888
|
+
} = CartPlatformModel.SharedCartResponse().validate(responseData, {
|
|
2044
1889
|
abortEarly: false,
|
|
2045
1890
|
allowUnknown: true,
|
|
2046
1891
|
});
|
|
@@ -2293,9 +2138,9 @@ class Cart {
|
|
|
2293
2138
|
* @param {CartPlatformApplicationValidator.GetCouponsParam} arg - Arg object
|
|
2294
2139
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2295
2140
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2296
|
-
* @returns {Promise<CartPlatformModel.
|
|
2141
|
+
* @returns {Promise<CartPlatformModel.CouponsResponse>} - Success response
|
|
2297
2142
|
* @name getCoupons
|
|
2298
|
-
* @summary: List
|
|
2143
|
+
* @summary: List coupons
|
|
2299
2144
|
* @description: Retrieve a list of all created coupons for specific sales channel. It also supports searching based on text search, pagination and other flags to filter coupons. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getCoupons/).
|
|
2300
2145
|
*/
|
|
2301
2146
|
async getCoupons(
|
|
@@ -2308,13 +2153,6 @@ class Cart {
|
|
|
2308
2153
|
isDisplay,
|
|
2309
2154
|
typeSlug,
|
|
2310
2155
|
code,
|
|
2311
|
-
createdBy,
|
|
2312
|
-
reviewedBy,
|
|
2313
|
-
approvedStartTime,
|
|
2314
|
-
approvedEndTime,
|
|
2315
|
-
reviewStartTime,
|
|
2316
|
-
reviewEndTime,
|
|
2317
|
-
status,
|
|
2318
2156
|
requestHeaders,
|
|
2319
2157
|
} = { requestHeaders: {} },
|
|
2320
2158
|
{ responseHeaders } = { responseHeaders: false }
|
|
@@ -2329,13 +2167,6 @@ class Cart {
|
|
|
2329
2167
|
isDisplay,
|
|
2330
2168
|
typeSlug,
|
|
2331
2169
|
code,
|
|
2332
|
-
createdBy,
|
|
2333
|
-
reviewedBy,
|
|
2334
|
-
approvedStartTime,
|
|
2335
|
-
approvedEndTime,
|
|
2336
|
-
reviewStartTime,
|
|
2337
|
-
reviewEndTime,
|
|
2338
|
-
status,
|
|
2339
2170
|
},
|
|
2340
2171
|
{ abortEarly: false, allowUnknown: true }
|
|
2341
2172
|
);
|
|
@@ -2356,13 +2187,6 @@ class Cart {
|
|
|
2356
2187
|
isDisplay,
|
|
2357
2188
|
typeSlug,
|
|
2358
2189
|
code,
|
|
2359
|
-
createdBy,
|
|
2360
|
-
reviewedBy,
|
|
2361
|
-
approvedStartTime,
|
|
2362
|
-
approvedEndTime,
|
|
2363
|
-
reviewStartTime,
|
|
2364
|
-
reviewEndTime,
|
|
2365
|
-
status,
|
|
2366
2190
|
},
|
|
2367
2191
|
{ abortEarly: false, allowUnknown: false }
|
|
2368
2192
|
);
|
|
@@ -2382,13 +2206,6 @@ class Cart {
|
|
|
2382
2206
|
query_params["is_display"] = isDisplay;
|
|
2383
2207
|
query_params["type_slug"] = typeSlug;
|
|
2384
2208
|
query_params["code"] = code;
|
|
2385
|
-
query_params["created_by"] = createdBy;
|
|
2386
|
-
query_params["reviewed_by"] = reviewedBy;
|
|
2387
|
-
query_params["approved_start_time"] = approvedStartTime;
|
|
2388
|
-
query_params["approved_end_time"] = approvedEndTime;
|
|
2389
|
-
query_params["review_start_time"] = reviewStartTime;
|
|
2390
|
-
query_params["review_end_time"] = reviewEndTime;
|
|
2391
|
-
query_params["status"] = status;
|
|
2392
2209
|
|
|
2393
2210
|
const response = await PlatformAPIClient.execute(
|
|
2394
2211
|
this.config,
|
|
@@ -2407,7 +2224,7 @@ class Cart {
|
|
|
2407
2224
|
|
|
2408
2225
|
const {
|
|
2409
2226
|
error: res_error,
|
|
2410
|
-
} = CartPlatformModel.
|
|
2227
|
+
} = CartPlatformModel.CouponsResponse().validate(responseData, {
|
|
2411
2228
|
abortEarly: false,
|
|
2412
2229
|
allowUnknown: true,
|
|
2413
2230
|
});
|
|
@@ -2430,7 +2247,7 @@ class Cart {
|
|
|
2430
2247
|
* @param {CartPlatformApplicationValidator.GetItemCountParam} arg - Arg object
|
|
2431
2248
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2432
2249
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2433
|
-
* @returns {Promise<CartPlatformModel.
|
|
2250
|
+
* @returns {Promise<CartPlatformModel.CartItemCountResponse>} - Success response
|
|
2434
2251
|
* @name getItemCount
|
|
2435
2252
|
* @summary: Get a cart items count
|
|
2436
2253
|
* @description: Retrieve the total count of items currently present in the customer's cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getItemCount/).
|
|
@@ -2488,7 +2305,7 @@ class Cart {
|
|
|
2488
2305
|
|
|
2489
2306
|
const {
|
|
2490
2307
|
error: res_error,
|
|
2491
|
-
} = CartPlatformModel.
|
|
2308
|
+
} = CartPlatformModel.CartItemCountResponse().validate(responseData, {
|
|
2492
2309
|
abortEarly: false,
|
|
2493
2310
|
allowUnknown: true,
|
|
2494
2311
|
});
|
|
@@ -2511,7 +2328,7 @@ class Cart {
|
|
|
2511
2328
|
* @param {CartPlatformApplicationValidator.GetPriceAdjustmentsParam} arg - Arg object
|
|
2512
2329
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2513
2330
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2514
|
-
* @returns {Promise<CartPlatformModel.
|
|
2331
|
+
* @returns {Promise<CartPlatformModel.GetPriceAdjustmentResponse>} - Success response
|
|
2515
2332
|
* @name getPriceAdjustments
|
|
2516
2333
|
* @summary: Get a list of all price adjustments associated with a cart
|
|
2517
2334
|
* @description: This API helps to get price adjustments data associated to a particular cart - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getPriceAdjustments/).
|
|
@@ -2568,7 +2385,7 @@ class Cart {
|
|
|
2568
2385
|
|
|
2569
2386
|
const {
|
|
2570
2387
|
error: res_error,
|
|
2571
|
-
} = CartPlatformModel.
|
|
2388
|
+
} = CartPlatformModel.GetPriceAdjustmentResponse().validate(responseData, {
|
|
2572
2389
|
abortEarly: false,
|
|
2573
2390
|
allowUnknown: true,
|
|
2574
2391
|
});
|
|
@@ -2593,7 +2410,7 @@ class Cart {
|
|
|
2593
2410
|
*
|
|
2594
2411
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2595
2412
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2596
|
-
* @returns {Promise<CartPlatformModel.
|
|
2413
|
+
* @returns {Promise<CartPlatformModel.ActivePromosResponse>} - Success response
|
|
2597
2414
|
* @name getPromosCouponConfig
|
|
2598
2415
|
* @summary: Get promotion and coupon type
|
|
2599
2416
|
* @description: Retrieve the configuration settings related to promotions and coupons for a specific seller. It provides details of the supported types of coupons and promotions along with their descriptions, examples, and related attributes. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getPromosCouponConfig/).
|
|
@@ -2653,7 +2470,7 @@ class Cart {
|
|
|
2653
2470
|
|
|
2654
2471
|
const {
|
|
2655
2472
|
error: res_error,
|
|
2656
|
-
} = CartPlatformModel.
|
|
2473
|
+
} = CartPlatformModel.ActivePromosResponse().validate(responseData, {
|
|
2657
2474
|
abortEarly: false,
|
|
2658
2475
|
allowUnknown: true,
|
|
2659
2476
|
});
|
|
@@ -2676,9 +2493,9 @@ class Cart {
|
|
|
2676
2493
|
* @param {CartPlatformApplicationValidator.GetPromotionByIdParam} arg - Arg object
|
|
2677
2494
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2678
2495
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2679
|
-
* @returns {Promise<CartPlatformModel.
|
|
2496
|
+
* @returns {Promise<CartPlatformModel.PromotionUpdate>} - Success response
|
|
2680
2497
|
* @name getPromotionById
|
|
2681
|
-
* @summary: Get a
|
|
2498
|
+
* @summary: Get a promotion
|
|
2682
2499
|
* @description: Retrieve details of a specific promotion by providing its unique identifier to obtain information such as promotion type, rules, validity period and other related information. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getPromotionById/).
|
|
2683
2500
|
*/
|
|
2684
2501
|
async getPromotionById(
|
|
@@ -2732,7 +2549,7 @@ class Cart {
|
|
|
2732
2549
|
|
|
2733
2550
|
const {
|
|
2734
2551
|
error: res_error,
|
|
2735
|
-
} = CartPlatformModel.
|
|
2552
|
+
} = CartPlatformModel.PromotionUpdate().validate(responseData, {
|
|
2736
2553
|
abortEarly: false,
|
|
2737
2554
|
allowUnknown: true,
|
|
2738
2555
|
});
|
|
@@ -2835,9 +2652,9 @@ class Cart {
|
|
|
2835
2652
|
* @param {CartPlatformApplicationValidator.GetPromotionOffersParam} arg - Arg object
|
|
2836
2653
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2837
2654
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2838
|
-
* @returns {Promise<CartPlatformModel.
|
|
2655
|
+
* @returns {Promise<CartPlatformModel.PromotionOffersResponse>} - Success response
|
|
2839
2656
|
* @name getPromotionOffers
|
|
2840
|
-
* @summary: List
|
|
2657
|
+
* @summary: List available promotion offers
|
|
2841
2658
|
* @description: Retrieve a list of all promotional offers available for the items in the cart, including details such as offer text, unique promotion ID, and validity period. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getPromotionOffers/).
|
|
2842
2659
|
*/
|
|
2843
2660
|
async getPromotionOffers(
|
|
@@ -2906,7 +2723,7 @@ class Cart {
|
|
|
2906
2723
|
|
|
2907
2724
|
const {
|
|
2908
2725
|
error: res_error,
|
|
2909
|
-
} = CartPlatformModel.
|
|
2726
|
+
} = CartPlatformModel.PromotionOffersResponse().validate(responseData, {
|
|
2910
2727
|
abortEarly: false,
|
|
2911
2728
|
allowUnknown: true,
|
|
2912
2729
|
});
|
|
@@ -2931,7 +2748,7 @@ class Cart {
|
|
|
2931
2748
|
*
|
|
2932
2749
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2933
2750
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2934
|
-
* @returns {Promise<CartPlatformModel.
|
|
2751
|
+
* @returns {Promise<CartPlatformModel.PromotionPaymentOffersResponse>} -
|
|
2935
2752
|
* Success response
|
|
2936
2753
|
* @name getPromotionPaymentOffers
|
|
2937
2754
|
* @summary: Fetch available promotions payment offers
|
|
@@ -2992,7 +2809,7 @@ class Cart {
|
|
|
2992
2809
|
|
|
2993
2810
|
const {
|
|
2994
2811
|
error: res_error,
|
|
2995
|
-
} = CartPlatformModel.
|
|
2812
|
+
} = CartPlatformModel.PromotionPaymentOffersResponse().validate(
|
|
2996
2813
|
responseData,
|
|
2997
2814
|
{ abortEarly: false, allowUnknown: true }
|
|
2998
2815
|
);
|
|
@@ -3015,9 +2832,9 @@ class Cart {
|
|
|
3015
2832
|
* @param {CartPlatformApplicationValidator.GetPromotionsParam} arg - Arg object
|
|
3016
2833
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3017
2834
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3018
|
-
* @returns {Promise<CartPlatformModel.
|
|
2835
|
+
* @returns {Promise<CartPlatformModel.PromotionsResponse>} - Success response
|
|
3019
2836
|
* @name getPromotions
|
|
3020
|
-
* @summary: List
|
|
2837
|
+
* @summary: List promotions
|
|
3021
2838
|
* @description: Retrieve a list of all created promotions for specific sales channel. It also supports efficient text search and pagination functionalities, ensuring optimized promotion listing for streamlined navigation and management. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getPromotions/).
|
|
3022
2839
|
*/
|
|
3023
2840
|
async getPromotions(
|
|
@@ -3030,13 +2847,6 @@ class Cart {
|
|
|
3030
2847
|
promotionType,
|
|
3031
2848
|
fpPanel,
|
|
3032
2849
|
promotionId,
|
|
3033
|
-
createdBy,
|
|
3034
|
-
reviewedBy,
|
|
3035
|
-
approvedStartTime,
|
|
3036
|
-
approvedEndTime,
|
|
3037
|
-
reviewStartTime,
|
|
3038
|
-
reviewEndTime,
|
|
3039
|
-
status,
|
|
3040
2850
|
requestHeaders,
|
|
3041
2851
|
} = { requestHeaders: {} },
|
|
3042
2852
|
{ responseHeaders } = { responseHeaders: false }
|
|
@@ -3051,13 +2861,6 @@ class Cart {
|
|
|
3051
2861
|
promotionType,
|
|
3052
2862
|
fpPanel,
|
|
3053
2863
|
promotionId,
|
|
3054
|
-
createdBy,
|
|
3055
|
-
reviewedBy,
|
|
3056
|
-
approvedStartTime,
|
|
3057
|
-
approvedEndTime,
|
|
3058
|
-
reviewStartTime,
|
|
3059
|
-
reviewEndTime,
|
|
3060
|
-
status,
|
|
3061
2864
|
},
|
|
3062
2865
|
{ abortEarly: false, allowUnknown: true }
|
|
3063
2866
|
);
|
|
@@ -3078,13 +2881,6 @@ class Cart {
|
|
|
3078
2881
|
promotionType,
|
|
3079
2882
|
fpPanel,
|
|
3080
2883
|
promotionId,
|
|
3081
|
-
createdBy,
|
|
3082
|
-
reviewedBy,
|
|
3083
|
-
approvedStartTime,
|
|
3084
|
-
approvedEndTime,
|
|
3085
|
-
reviewStartTime,
|
|
3086
|
-
reviewEndTime,
|
|
3087
|
-
status,
|
|
3088
2884
|
},
|
|
3089
2885
|
{ abortEarly: false, allowUnknown: false }
|
|
3090
2886
|
);
|
|
@@ -3104,13 +2900,6 @@ class Cart {
|
|
|
3104
2900
|
query_params["promotion_type"] = promotionType;
|
|
3105
2901
|
query_params["fp_panel"] = fpPanel;
|
|
3106
2902
|
query_params["promotion_id"] = promotionId;
|
|
3107
|
-
query_params["created_by"] = createdBy;
|
|
3108
|
-
query_params["reviewed_by"] = reviewedBy;
|
|
3109
|
-
query_params["approved_start_time"] = approvedStartTime;
|
|
3110
|
-
query_params["approved_end_time"] = approvedEndTime;
|
|
3111
|
-
query_params["review_start_time"] = reviewStartTime;
|
|
3112
|
-
query_params["review_end_time"] = reviewEndTime;
|
|
3113
|
-
query_params["status"] = status;
|
|
3114
2903
|
|
|
3115
2904
|
const response = await PlatformAPIClient.execute(
|
|
3116
2905
|
this.config,
|
|
@@ -3129,7 +2918,7 @@ class Cart {
|
|
|
3129
2918
|
|
|
3130
2919
|
const {
|
|
3131
2920
|
error: res_error,
|
|
3132
|
-
} = CartPlatformModel.
|
|
2921
|
+
} = CartPlatformModel.PromotionsResponse().validate(responseData, {
|
|
3133
2922
|
abortEarly: false,
|
|
3134
2923
|
allowUnknown: true,
|
|
3135
2924
|
});
|
|
@@ -3152,7 +2941,7 @@ class Cart {
|
|
|
3152
2941
|
* @param {CartPlatformApplicationValidator.GetShipmentsParam} arg - Arg object
|
|
3153
2942
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3154
2943
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3155
|
-
* @returns {Promise<CartPlatformModel.
|
|
2944
|
+
* @returns {Promise<CartPlatformModel.PlatformCartShipmentsResponse>} -
|
|
3156
2945
|
* Success response
|
|
3157
2946
|
* @name getShipments
|
|
3158
2947
|
* @summary: Get shipments details
|
|
@@ -3239,10 +3028,10 @@ class Cart {
|
|
|
3239
3028
|
|
|
3240
3029
|
const {
|
|
3241
3030
|
error: res_error,
|
|
3242
|
-
} = CartPlatformModel.
|
|
3243
|
-
|
|
3244
|
-
allowUnknown: true
|
|
3245
|
-
|
|
3031
|
+
} = CartPlatformModel.PlatformCartShipmentsResponse().validate(
|
|
3032
|
+
responseData,
|
|
3033
|
+
{ abortEarly: false, allowUnknown: true }
|
|
3034
|
+
);
|
|
3246
3035
|
|
|
3247
3036
|
if (res_error) {
|
|
3248
3037
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -3264,7 +3053,7 @@ class Cart {
|
|
|
3264
3053
|
*
|
|
3265
3054
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3266
3055
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3267
|
-
* @returns {Promise<CartPlatformModel.
|
|
3056
|
+
* @returns {Promise<CartPlatformModel.StoreDetailsResponse>} - Success response
|
|
3268
3057
|
* @name getStoreAddressByUid
|
|
3269
3058
|
* @summary: Get Store Address
|
|
3270
3059
|
* @description: Retrieve store details by entering the unique identifier of the pickup stores. Store details include the seller's name, contact information such as email address or phone number and business address. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/getStoreAddressByUid/).
|
|
@@ -3321,7 +3110,7 @@ class Cart {
|
|
|
3321
3110
|
|
|
3322
3111
|
const {
|
|
3323
3112
|
error: res_error,
|
|
3324
|
-
} = CartPlatformModel.
|
|
3113
|
+
} = CartPlatformModel.StoreDetailsResponse().validate(responseData, {
|
|
3325
3114
|
abortEarly: false,
|
|
3326
3115
|
allowUnknown: true,
|
|
3327
3116
|
});
|
|
@@ -3344,7 +3133,7 @@ class Cart {
|
|
|
3344
3133
|
* @param {CartPlatformApplicationValidator.OverrideCartParam} arg - Arg object
|
|
3345
3134
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3346
3135
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3347
|
-
* @returns {Promise<CartPlatformModel.
|
|
3136
|
+
* @returns {Promise<CartPlatformModel.OverrideCheckoutResponse>} - Success response
|
|
3348
3137
|
* @name overrideCart
|
|
3349
3138
|
* @summary: Update cart checkout
|
|
3350
3139
|
* @description: Overrides the cart's checkout process with a new provided cart items. It provides flexibility in customizing checkout flows to meet specific business requirements, enhancing the user experience and optimizing order processing workflows. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/overrideCart/).
|
|
@@ -3398,7 +3187,7 @@ class Cart {
|
|
|
3398
3187
|
|
|
3399
3188
|
const {
|
|
3400
3189
|
error: res_error,
|
|
3401
|
-
} = CartPlatformModel.
|
|
3190
|
+
} = CartPlatformModel.OverrideCheckoutResponse().validate(responseData, {
|
|
3402
3191
|
abortEarly: false,
|
|
3403
3192
|
allowUnknown: true,
|
|
3404
3193
|
});
|
|
@@ -3421,7 +3210,7 @@ class Cart {
|
|
|
3421
3210
|
* @param {CartPlatformApplicationValidator.PlatformAddItemsParam} arg - Arg object
|
|
3422
3211
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3423
3212
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3424
|
-
* @returns {Promise<CartPlatformModel.
|
|
3213
|
+
* @returns {Promise<CartPlatformModel.AddCartDetailResponse>} - Success response
|
|
3425
3214
|
* @name platformAddItems
|
|
3426
3215
|
* @summary: Add items to cart
|
|
3427
3216
|
* @description: Add product items to the customer's existing shopping cart. If there is no existing cart associated with the customer, it creates a new one and adds the items to it. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/platformAddItems/).
|
|
@@ -3494,7 +3283,7 @@ class Cart {
|
|
|
3494
3283
|
|
|
3495
3284
|
const {
|
|
3496
3285
|
error: res_error,
|
|
3497
|
-
} = CartPlatformModel.
|
|
3286
|
+
} = CartPlatformModel.AddCartDetailResponse().validate(responseData, {
|
|
3498
3287
|
abortEarly: false,
|
|
3499
3288
|
allowUnknown: true,
|
|
3500
3289
|
});
|
|
@@ -3513,97 +3302,13 @@ class Cart {
|
|
|
3513
3302
|
return response;
|
|
3514
3303
|
}
|
|
3515
3304
|
|
|
3516
|
-
/**
|
|
3517
|
-
* @param {CartPlatformApplicationValidator.PlatformCheckoutCartParam} arg
|
|
3518
|
-
* - Arg object
|
|
3519
|
-
*
|
|
3520
|
-
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3521
|
-
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3522
|
-
* @returns {Promise<CartPlatformModel.CartCheckoutResult>} - Success response
|
|
3523
|
-
* @name platformCheckoutCart
|
|
3524
|
-
* @summary: Checkout cart
|
|
3525
|
-
* @description: The checkout cart initiates the order creation process based on the selected address and payment method. It revalidates the cart details to ensure safe and seamless order placement. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/platformCheckoutCart/).
|
|
3526
|
-
*/
|
|
3527
|
-
async platformCheckoutCart(
|
|
3528
|
-
{ body, id, requestHeaders } = { requestHeaders: {} },
|
|
3529
|
-
{ responseHeaders } = { responseHeaders: false }
|
|
3530
|
-
) {
|
|
3531
|
-
const {
|
|
3532
|
-
error,
|
|
3533
|
-
} = CartPlatformApplicationValidator.platformCheckoutCart().validate(
|
|
3534
|
-
{
|
|
3535
|
-
body,
|
|
3536
|
-
id,
|
|
3537
|
-
},
|
|
3538
|
-
{ abortEarly: false, allowUnknown: true }
|
|
3539
|
-
);
|
|
3540
|
-
if (error) {
|
|
3541
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
3542
|
-
}
|
|
3543
|
-
|
|
3544
|
-
// Showing warrnings if extra unknown parameters are found
|
|
3545
|
-
const {
|
|
3546
|
-
error: warrning,
|
|
3547
|
-
} = CartPlatformApplicationValidator.platformCheckoutCart().validate(
|
|
3548
|
-
{
|
|
3549
|
-
body,
|
|
3550
|
-
id,
|
|
3551
|
-
},
|
|
3552
|
-
{ abortEarly: false, allowUnknown: false }
|
|
3553
|
-
);
|
|
3554
|
-
if (warrning) {
|
|
3555
|
-
Logger({
|
|
3556
|
-
level: "WARN",
|
|
3557
|
-
message: `Parameter Validation warrnings for platform > Cart > platformCheckoutCart \n ${warrning}`,
|
|
3558
|
-
});
|
|
3559
|
-
}
|
|
3560
|
-
|
|
3561
|
-
const query_params = {};
|
|
3562
|
-
query_params["id"] = id;
|
|
3563
|
-
|
|
3564
|
-
const response = await PlatformAPIClient.execute(
|
|
3565
|
-
this.config,
|
|
3566
|
-
"post",
|
|
3567
|
-
`/service/platform/cart/v1.0/company/${this.config.companyId}/application/${this.applicationId}/checkout`,
|
|
3568
|
-
query_params,
|
|
3569
|
-
body,
|
|
3570
|
-
requestHeaders,
|
|
3571
|
-
{ responseHeaders }
|
|
3572
|
-
);
|
|
3573
|
-
|
|
3574
|
-
let responseData = response;
|
|
3575
|
-
if (responseHeaders) {
|
|
3576
|
-
responseData = response[0];
|
|
3577
|
-
}
|
|
3578
|
-
|
|
3579
|
-
const {
|
|
3580
|
-
error: res_error,
|
|
3581
|
-
} = CartPlatformModel.CartCheckoutResult().validate(responseData, {
|
|
3582
|
-
abortEarly: false,
|
|
3583
|
-
allowUnknown: true,
|
|
3584
|
-
});
|
|
3585
|
-
|
|
3586
|
-
if (res_error) {
|
|
3587
|
-
if (this.config.options.strictResponseCheck === true) {
|
|
3588
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
3589
|
-
} else {
|
|
3590
|
-
Logger({
|
|
3591
|
-
level: "WARN",
|
|
3592
|
-
message: `Response Validation Warnings for platform > Cart > platformCheckoutCart \n ${res_error}`,
|
|
3593
|
-
});
|
|
3594
|
-
}
|
|
3595
|
-
}
|
|
3596
|
-
|
|
3597
|
-
return response;
|
|
3598
|
-
}
|
|
3599
|
-
|
|
3600
3305
|
/**
|
|
3601
3306
|
* @param {CartPlatformApplicationValidator.PlatformCheckoutCartV2Param} arg
|
|
3602
3307
|
* - Arg object
|
|
3603
3308
|
*
|
|
3604
3309
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3605
3310
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3606
|
-
* @returns {Promise<CartPlatformModel.
|
|
3311
|
+
* @returns {Promise<CartPlatformModel.CartCheckoutResponse>} - Success response
|
|
3607
3312
|
* @name platformCheckoutCartV2
|
|
3608
3313
|
* @summary: Checkout cart
|
|
3609
3314
|
* @description: The checkout cart initiates the order creation process based on the items in the user’s cart, their selected address, and chosen payment methods. It also supports multiple payment method options and revalidates the cart details to ensure a secure and seamless order placement. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/platformCheckoutCartV2/).
|
|
@@ -3662,7 +3367,7 @@ class Cart {
|
|
|
3662
3367
|
|
|
3663
3368
|
const {
|
|
3664
3369
|
error: res_error,
|
|
3665
|
-
} = CartPlatformModel.
|
|
3370
|
+
} = CartPlatformModel.CartCheckoutResponse().validate(responseData, {
|
|
3666
3371
|
abortEarly: false,
|
|
3667
3372
|
allowUnknown: true,
|
|
3668
3373
|
});
|
|
@@ -3685,7 +3390,7 @@ class Cart {
|
|
|
3685
3390
|
* @param {CartPlatformApplicationValidator.PlatformUpdateCartParam} arg - Arg object
|
|
3686
3391
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3687
3392
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3688
|
-
* @returns {Promise<CartPlatformModel.
|
|
3393
|
+
* @returns {Promise<CartPlatformModel.UpdateCartDetailResponse>} - Success response
|
|
3689
3394
|
* @name platformUpdateCart
|
|
3690
3395
|
* @summary: Update cart items
|
|
3691
3396
|
* @description: Customers can modify added product attributes such as quantity and size, as well as remove items from the cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/platformUpdateCart/).
|
|
@@ -3758,7 +3463,7 @@ class Cart {
|
|
|
3758
3463
|
|
|
3759
3464
|
const {
|
|
3760
3465
|
error: res_error,
|
|
3761
|
-
} = CartPlatformModel.
|
|
3466
|
+
} = CartPlatformModel.UpdateCartDetailResponse().validate(responseData, {
|
|
3762
3467
|
abortEarly: false,
|
|
3763
3468
|
allowUnknown: true,
|
|
3764
3469
|
});
|
|
@@ -3781,7 +3486,7 @@ class Cart {
|
|
|
3781
3486
|
* @param {CartPlatformApplicationValidator.RemoveAddressParam} arg - Arg object
|
|
3782
3487
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3783
3488
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3784
|
-
* @returns {Promise<CartPlatformModel.
|
|
3489
|
+
* @returns {Promise<CartPlatformModel.DeleteAddressResponse>} - Success response
|
|
3785
3490
|
* @name removeAddress
|
|
3786
3491
|
* @summary: Removes an address from a customer's address list
|
|
3787
3492
|
* @description: Remove an existing customer address from the system. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/removeAddress/).
|
|
@@ -3838,7 +3543,7 @@ class Cart {
|
|
|
3838
3543
|
|
|
3839
3544
|
const {
|
|
3840
3545
|
error: res_error,
|
|
3841
|
-
} = CartPlatformModel.
|
|
3546
|
+
} = CartPlatformModel.DeleteAddressResponse().validate(responseData, {
|
|
3842
3547
|
abortEarly: false,
|
|
3843
3548
|
allowUnknown: true,
|
|
3844
3549
|
});
|
|
@@ -3861,7 +3566,7 @@ class Cart {
|
|
|
3861
3566
|
* @param {CartPlatformApplicationValidator.RemoveCouponParam} arg - Arg object
|
|
3862
3567
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3863
3568
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3864
|
-
* @returns {Promise<CartPlatformModel.
|
|
3569
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
3865
3570
|
* @name removeCoupon
|
|
3866
3571
|
* @summary: Remove coupon
|
|
3867
3572
|
* @description: Remove an applied coupon from the customer's cart, thereby removing the associated discount from the cart total. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/removeCoupon/).
|
|
@@ -3919,7 +3624,7 @@ class Cart {
|
|
|
3919
3624
|
|
|
3920
3625
|
const {
|
|
3921
3626
|
error: res_error,
|
|
3922
|
-
} = CartPlatformModel.
|
|
3627
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
3923
3628
|
abortEarly: false,
|
|
3924
3629
|
allowUnknown: true,
|
|
3925
3630
|
});
|
|
@@ -4023,7 +3728,7 @@ class Cart {
|
|
|
4023
3728
|
* @param {CartPlatformApplicationValidator.SelectAddressParam} arg - Arg object
|
|
4024
3729
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4025
3730
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4026
|
-
* @returns {Promise<CartPlatformModel.
|
|
3731
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
4027
3732
|
* @name selectAddress
|
|
4028
3733
|
* @summary: Select customer address for order processing
|
|
4029
3734
|
* @description: Select an address from the saved customer addresses and validates the availability of items in the cart. Additionally, it verifies and updates the delivery promise based on the selected address. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/selectAddress/).
|
|
@@ -4089,7 +3794,7 @@ class Cart {
|
|
|
4089
3794
|
|
|
4090
3795
|
const {
|
|
4091
3796
|
error: res_error,
|
|
4092
|
-
} = CartPlatformModel.
|
|
3797
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
4093
3798
|
abortEarly: false,
|
|
4094
3799
|
allowUnknown: true,
|
|
4095
3800
|
});
|
|
@@ -4112,7 +3817,7 @@ class Cart {
|
|
|
4112
3817
|
* @param {CartPlatformApplicationValidator.SelectPaymentModeParam} arg - Arg object
|
|
4113
3818
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4114
3819
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4115
|
-
* @returns {Promise<CartPlatformModel.
|
|
3820
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
4116
3821
|
* @name selectPaymentMode
|
|
4117
3822
|
* @summary: Select payment mode
|
|
4118
3823
|
* @description: Customers can select a preferred payment mode from available options during the cart checkout process to securely and efficiently complete their transaction. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/selectPaymentMode/).
|
|
@@ -4177,7 +3882,7 @@ class Cart {
|
|
|
4177
3882
|
|
|
4178
3883
|
const {
|
|
4179
3884
|
error: res_error,
|
|
4180
|
-
} = CartPlatformModel.
|
|
3885
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
4181
3886
|
abortEarly: false,
|
|
4182
3887
|
allowUnknown: true,
|
|
4183
3888
|
});
|
|
@@ -4200,7 +3905,7 @@ class Cart {
|
|
|
4200
3905
|
* @param {CartPlatformApplicationValidator.SelectPaymentModeV2Param} arg - Arg object
|
|
4201
3906
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4202
3907
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4203
|
-
* @returns {Promise<CartPlatformModel.
|
|
3908
|
+
* @returns {Promise<CartPlatformModel.CartDetailResponse>} - Success response
|
|
4204
3909
|
* @name selectPaymentModeV2
|
|
4205
3910
|
* @summary: Select payment mode (latest)
|
|
4206
3911
|
* @description: Selection of payment mode that supports multiple MOP(mode of payment). - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/selectPaymentModeV2/).
|
|
@@ -4265,7 +3970,7 @@ class Cart {
|
|
|
4265
3970
|
|
|
4266
3971
|
const {
|
|
4267
3972
|
error: res_error,
|
|
4268
|
-
} = CartPlatformModel.
|
|
3973
|
+
} = CartPlatformModel.CartDetailResponse().validate(responseData, {
|
|
4269
3974
|
abortEarly: false,
|
|
4270
3975
|
allowUnknown: true,
|
|
4271
3976
|
});
|
|
@@ -4288,7 +3993,7 @@ class Cart {
|
|
|
4288
3993
|
* @param {CartPlatformApplicationValidator.UpdateAddressParam} arg - Arg object
|
|
4289
3994
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4290
3995
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4291
|
-
* @returns {Promise<CartPlatformModel.
|
|
3996
|
+
* @returns {Promise<CartPlatformModel.UpdateAddressResponse>} - Success response
|
|
4292
3997
|
* @name updateAddress
|
|
4293
3998
|
* @summary: Updates an existing customer address
|
|
4294
3999
|
* @description: Update the user address - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updateAddress/).
|
|
@@ -4344,7 +4049,7 @@ class Cart {
|
|
|
4344
4049
|
|
|
4345
4050
|
const {
|
|
4346
4051
|
error: res_error,
|
|
4347
|
-
} = CartPlatformModel.
|
|
4052
|
+
} = CartPlatformModel.UpdateAddressResponse().validate(responseData, {
|
|
4348
4053
|
abortEarly: false,
|
|
4349
4054
|
allowUnknown: true,
|
|
4350
4055
|
});
|
|
@@ -4367,7 +4072,7 @@ class Cart {
|
|
|
4367
4072
|
* @param {CartPlatformApplicationValidator.UpdateCartParam} arg - Arg object
|
|
4368
4073
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4369
4074
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4370
|
-
* @returns {Promise<CartPlatformModel.
|
|
4075
|
+
* @returns {Promise<CartPlatformModel.UpdateCartDetailResponse>} - Success response
|
|
4371
4076
|
* @name updateCart
|
|
4372
4077
|
* @summary: Update cart items
|
|
4373
4078
|
* @description: Customers can modify added product attributes such as quantity and size, as well as remove items from the cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updateCart/).
|
|
@@ -4426,7 +4131,7 @@ class Cart {
|
|
|
4426
4131
|
|
|
4427
4132
|
const {
|
|
4428
4133
|
error: res_error,
|
|
4429
|
-
} = CartPlatformModel.
|
|
4134
|
+
} = CartPlatformModel.UpdateCartDetailResponse().validate(responseData, {
|
|
4430
4135
|
abortEarly: false,
|
|
4431
4136
|
allowUnknown: true,
|
|
4432
4137
|
});
|
|
@@ -4449,7 +4154,7 @@ class Cart {
|
|
|
4449
4154
|
* @param {CartPlatformApplicationValidator.UpdateCartMetaParam} arg - Arg object
|
|
4450
4155
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4451
4156
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4452
|
-
* @returns {Promise<CartPlatformModel.
|
|
4157
|
+
* @returns {Promise<CartPlatformModel.CartMetaResponse>} - Success response
|
|
4453
4158
|
* @name updateCartMeta
|
|
4454
4159
|
* @summary: Update cart metadata
|
|
4455
4160
|
* @description: Add or modify metadata associated with a cart, which includes customer preferences, delivery instructions, or any special requirements related to the cart items. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updateCartMeta/).
|
|
@@ -4511,7 +4216,7 @@ class Cart {
|
|
|
4511
4216
|
|
|
4512
4217
|
const {
|
|
4513
4218
|
error: res_error,
|
|
4514
|
-
} = CartPlatformModel.
|
|
4219
|
+
} = CartPlatformModel.CartMetaResponse().validate(responseData, {
|
|
4515
4220
|
abortEarly: false,
|
|
4516
4221
|
allowUnknown: true,
|
|
4517
4222
|
});
|
|
@@ -4617,7 +4322,7 @@ class Cart {
|
|
|
4617
4322
|
* @param {CartPlatformApplicationValidator.UpdateCartUserParam} arg - Arg object
|
|
4618
4323
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4619
4324
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4620
|
-
* @returns {Promise<CartPlatformModel.
|
|
4325
|
+
* @returns {Promise<CartPlatformModel.UserCartMappingResponse>} - Success response
|
|
4621
4326
|
* @name updateCartUser
|
|
4622
4327
|
* @summary: Update user of a cart
|
|
4623
4328
|
* @description: Modify the cart user to a new valid customer for the provided customer ID. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updateCartUser/).
|
|
@@ -4676,7 +4381,7 @@ class Cart {
|
|
|
4676
4381
|
|
|
4677
4382
|
const {
|
|
4678
4383
|
error: res_error,
|
|
4679
|
-
} = CartPlatformModel.
|
|
4384
|
+
} = CartPlatformModel.UserCartMappingResponse().validate(responseData, {
|
|
4680
4385
|
abortEarly: false,
|
|
4681
4386
|
allowUnknown: true,
|
|
4682
4387
|
});
|
|
@@ -4701,7 +4406,7 @@ class Cart {
|
|
|
4701
4406
|
*
|
|
4702
4407
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4703
4408
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4704
|
-
* @returns {Promise<CartPlatformModel.
|
|
4409
|
+
* @returns {Promise<CartPlatformModel.SharedCartResponse>} - Success response
|
|
4705
4410
|
* @name updateCartWithSharedItems
|
|
4706
4411
|
* @summary: Update shared cart items
|
|
4707
4412
|
* @description: Customer can either merge or replace shared cart items with existing cart. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updateCartWithSharedItems/).
|
|
@@ -4762,7 +4467,7 @@ class Cart {
|
|
|
4762
4467
|
|
|
4763
4468
|
const {
|
|
4764
4469
|
error: res_error,
|
|
4765
|
-
} = CartPlatformModel.
|
|
4470
|
+
} = CartPlatformModel.SharedCartResponse().validate(responseData, {
|
|
4766
4471
|
abortEarly: false,
|
|
4767
4472
|
allowUnknown: true,
|
|
4768
4473
|
});
|
|
@@ -4785,7 +4490,7 @@ class Cart {
|
|
|
4785
4490
|
* @param {CartPlatformApplicationValidator.UpdateCouponParam} arg - Arg object
|
|
4786
4491
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4787
4492
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4788
|
-
* @returns {Promise<CartPlatformModel.
|
|
4493
|
+
* @returns {Promise<CartPlatformModel.SuccessMessage>} - Success response
|
|
4789
4494
|
* @name updateCoupon
|
|
4790
4495
|
* @summary: Update a coupon
|
|
4791
4496
|
* @description: Update the details of an existing coupon by specifying its unique identifier. This includes modifying coupon attributes such as discount percentage, validity period, and associated conditions. Leveraging this functionality allows businesses to quickly adapt their promotional strategies to changing market dynamics. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updateCoupon/).
|
|
@@ -4841,7 +4546,7 @@ class Cart {
|
|
|
4841
4546
|
|
|
4842
4547
|
const {
|
|
4843
4548
|
error: res_error,
|
|
4844
|
-
} = CartPlatformModel.
|
|
4549
|
+
} = CartPlatformModel.SuccessMessage().validate(responseData, {
|
|
4845
4550
|
abortEarly: false,
|
|
4846
4551
|
allowUnknown: true,
|
|
4847
4552
|
});
|
|
@@ -4949,7 +4654,7 @@ class Cart {
|
|
|
4949
4654
|
*
|
|
4950
4655
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4951
4656
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4952
|
-
* @returns {Promise<CartPlatformModel.
|
|
4657
|
+
* @returns {Promise<CartPlatformModel.PriceAdjustmentResponse>} - Success response
|
|
4953
4658
|
* @name updatePriceAdjustment
|
|
4954
4659
|
* @summary: Update price adjustments
|
|
4955
4660
|
* @description: Modify price adjustments for specific items in the cart. By providing the seller ID, sales channel ID, and price adjustment ID, seller can apply discounts or other adjustments to the prices of cart items, facilitating dynamic pricing strategies. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updatePriceAdjustment/).
|
|
@@ -5007,7 +4712,7 @@ class Cart {
|
|
|
5007
4712
|
|
|
5008
4713
|
const {
|
|
5009
4714
|
error: res_error,
|
|
5010
|
-
} = CartPlatformModel.
|
|
4715
|
+
} = CartPlatformModel.PriceAdjustmentResponse().validate(responseData, {
|
|
5011
4716
|
abortEarly: false,
|
|
5012
4717
|
allowUnknown: true,
|
|
5013
4718
|
});
|
|
@@ -5030,7 +4735,7 @@ class Cart {
|
|
|
5030
4735
|
* @param {CartPlatformApplicationValidator.UpdatePromotionParam} arg - Arg object
|
|
5031
4736
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
5032
4737
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
5033
|
-
* @returns {Promise<CartPlatformModel.
|
|
4738
|
+
* @returns {Promise<CartPlatformModel.PromotionUpdate>} - Success response
|
|
5034
4739
|
* @name updatePromotion
|
|
5035
4740
|
* @summary: Update a promotion
|
|
5036
4741
|
* @description: Update the details of an existing promotion by specifying its unique identifier. This includes modifying promotion attributes such as discount percentage, validity period, and associated conditions. Leveraging this functionality allows businesses to quickly adapt their promotional strategies to changing market dynamics. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/cart/updatePromotion/).
|
|
@@ -5088,7 +4793,7 @@ class Cart {
|
|
|
5088
4793
|
|
|
5089
4794
|
const {
|
|
5090
4795
|
error: res_error,
|
|
5091
|
-
} = CartPlatformModel.
|
|
4796
|
+
} = CartPlatformModel.PromotionUpdate().validate(responseData, {
|
|
5092
4797
|
abortEarly: false,
|
|
5093
4798
|
allowUnknown: true,
|
|
5094
4799
|
});
|
|
@@ -5194,7 +4899,7 @@ class Cart {
|
|
|
5194
4899
|
* @param {CartPlatformApplicationValidator.UpdateShipmentsParam} arg - Arg object
|
|
5195
4900
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
5196
4901
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
5197
|
-
* @returns {Promise<CartPlatformModel.
|
|
4902
|
+
* @returns {Promise<CartPlatformModel.PlatformCartShipmentsResponse>} -
|
|
5198
4903
|
* Success response
|
|
5199
4904
|
* @name updateShipments
|
|
5200
4905
|
* @summary: Update shipments
|
|
@@ -5271,10 +4976,10 @@ class Cart {
|
|
|
5271
4976
|
|
|
5272
4977
|
const {
|
|
5273
4978
|
error: res_error,
|
|
5274
|
-
} = CartPlatformModel.
|
|
5275
|
-
|
|
5276
|
-
allowUnknown: true
|
|
5277
|
-
|
|
4979
|
+
} = CartPlatformModel.PlatformCartShipmentsResponse().validate(
|
|
4980
|
+
responseData,
|
|
4981
|
+
{ abortEarly: false, allowUnknown: true }
|
|
4982
|
+
);
|
|
5278
4983
|
|
|
5279
4984
|
if (res_error) {
|
|
5280
4985
|
if (this.config.options.strictResponseCheck === true) {
|