@gofynd/fdk-client-javascript 1.4.14 → 1.4.15-beta.10
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 +2 -2
- package/application.d.ts +1 -2
- package/application.js +2 -3
- package/index.d.ts +1 -2
- package/index.js +7 -1
- package/package.json +2 -3
- package/sdk/application/ApplicationClient.d.ts +0 -2
- package/sdk/application/ApplicationClient.js +0 -20
- package/sdk/application/Cart/CartApplicationClient.d.ts +55 -97
- package/sdk/application/Cart/CartApplicationClient.js +60 -1262
- package/sdk/application/Catalog/CatalogApplicationClient.d.ts +80 -162
- package/sdk/application/Catalog/CatalogApplicationClient.js +148 -1313
- package/sdk/application/Common/CommonApplicationClient.d.ts +4 -9
- package/sdk/application/Common/CommonApplicationClient.js +5 -90
- package/sdk/application/Communication/CommunicationApplicationClient.d.ts +6 -19
- package/sdk/application/Communication/CommunicationApplicationClient.js +6 -145
- package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +32 -80
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +31 -725
- package/sdk/application/Content/ContentApplicationClient.d.ts +63 -85
- package/sdk/application/Content/ContentApplicationClient.js +126 -942
- package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +11 -15
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +26 -130
- package/sdk/application/Lead/LeadApplicationClient.d.ts +10 -17
- package/sdk/application/Lead/LeadApplicationClient.js +32 -201
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +22 -62
- package/sdk/application/Logistic/LogisticApplicationClient.js +51 -647
- package/sdk/application/Order/OrderApplicationClient.d.ts +22 -56
- package/sdk/application/Order/OrderApplicationClient.js +86 -555
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +92 -209
- package/sdk/application/Payment/PaymentApplicationClient.js +57 -2099
- package/sdk/application/Rewards/RewardsApplicationClient.d.ts +15 -26
- package/sdk/application/Rewards/RewardsApplicationClient.js +17 -303
- package/sdk/application/Share/ShareApplicationClient.d.ts +14 -24
- package/sdk/application/Share/ShareApplicationClient.js +34 -294
- package/sdk/application/Theme/ThemeApplicationClient.d.ts +8 -14
- package/sdk/application/Theme/ThemeApplicationClient.js +30 -166
- package/sdk/application/User/UserApplicationClient.d.ts +87 -138
- package/sdk/application/User/UserApplicationClient.js +47 -1817
- package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -7
- package/sdk/application/Webhook/WebhookApplicationClient.js +6 -49
- package/sdk/application/index.d.ts +0 -19
- package/sdk/application/index.js +0 -35
- package/sdk/common/Utility.d.ts +1 -1
- package/sdk/common/Utility.js +10 -7
- package/sdk/common/Validator.d.ts +1 -0
- package/sdk/common/Validator.js +20 -0
- package/sdk/common/utils.d.ts +0 -1
- package/sdk/common/utils.js +0 -14
- package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +12 -86
- package/sdk/partner/FileStorage/FileStoragePartnerClient.js +24 -582
- package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +21 -116
- package/sdk/partner/FileStorage/FileStoragePartnerModel.js +16 -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/OAuthClient.js +1 -0
- package/sdk/partner/Theme/ThemePartnerClient.d.ts +10 -8
- package/sdk/partner/Theme/ThemePartnerClient.js +16 -14
- package/sdk/partner/Theme/ThemePartnerModel.d.ts +39 -135
- package/sdk/partner/Theme/ThemePartnerModel.js +38 -114
- 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 +1328 -4975
- package/sdk/platform/Cart/CartPlatformModel.js +1229 -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 +1744 -1501
- package/sdk/platform/Catalog/CatalogPlatformModel.js +1211 -1383
- 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 +138 -283
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +100 -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 +39 -95
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +63 -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 +22 -20
- package/sdk/platform/FileStorage/FileStoragePlatformClient.js +24 -21
- package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +116 -370
- package/sdk/platform/FileStorage/FileStoragePlatformModel.js +104 -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 -25
- package/sdk/platform/Order/OrderPlatformApplicationClient.js +5 -175
- package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +4 -52
- package/sdk/platform/Order/OrderPlatformApplicationValidator.js +3 -34
- package/sdk/platform/Order/OrderPlatformClient.d.ts +103 -174
- package/sdk/platform/Order/OrderPlatformClient.js +275 -528
- package/sdk/platform/Order/OrderPlatformModel.d.ts +3078 -5449
- package/sdk/platform/Order/OrderPlatformModel.js +1659 -3501
- package/sdk/platform/Order/OrderPlatformValidator.d.ts +219 -234
- package/sdk/platform/Order/OrderPlatformValidator.js +118 -146
- 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 +68 -62
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +396 -620
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +326 -501
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +11 -11
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +10 -10
- 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 +13 -76
- package/sdk/platform/Theme/ThemePlatformModel.js +17 -57
- 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 +10 -8
- 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 +19 -793
- 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/Partner/PartnerPublicClient.d.ts +1 -1
- package/sdk/public/Partner/PartnerPublicClient.js +14 -2
- package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
- package/sdk/public/Webhook/WebhookPublicClient.js +13 -10
- 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/Cart/CartApplicationModel.d.ts +0 -4340
- package/sdk/application/Cart/CartApplicationModel.js +0 -2718
- package/sdk/application/Cart/CartApplicationValidator.d.ts +0 -788
- package/sdk/application/Cart/CartApplicationValidator.js +0 -546
- package/sdk/application/Catalog/CatalogApplicationModel.d.ts +0 -3909
- package/sdk/application/Catalog/CatalogApplicationModel.js +0 -2667
- package/sdk/application/Catalog/CatalogApplicationValidator.d.ts +0 -791
- package/sdk/application/Catalog/CatalogApplicationValidator.js +0 -551
- package/sdk/application/Common/CommonApplicationModel.d.ts +0 -449
- package/sdk/application/Common/CommonApplicationModel.js +0 -308
- package/sdk/application/Common/CommonApplicationValidator.d.ts +0 -46
- package/sdk/application/Common/CommonApplicationValidator.js +0 -38
- package/sdk/application/Communication/CommunicationApplicationModel.d.ts +0 -293
- package/sdk/application/Communication/CommunicationApplicationModel.js +0 -201
- package/sdk/application/Communication/CommunicationApplicationValidator.d.ts +0 -29
- package/sdk/application/Communication/CommunicationApplicationValidator.js +0 -38
- package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +0 -2544
- package/sdk/application/Configuration/ConfigurationApplicationModel.js +0 -1875
- package/sdk/application/Configuration/ConfigurationApplicationValidator.d.ts +0 -179
- package/sdk/application/Configuration/ConfigurationApplicationValidator.js +0 -176
- package/sdk/application/Content/ContentApplicationModel.d.ts +0 -2189
- package/sdk/application/Content/ContentApplicationModel.js +0 -1640
- package/sdk/application/Content/ContentApplicationValidator.d.ts +0 -290
- package/sdk/application/Content/ContentApplicationValidator.js +0 -269
- package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +0 -270
- package/sdk/application/FileStorage/FileStorageApplicationModel.js +0 -188
- package/sdk/application/FileStorage/FileStorageApplicationValidator.d.ts +0 -56
- package/sdk/application/FileStorage/FileStorageApplicationValidator.js +0 -53
- 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
- package/sdk/application/Lead/LeadApplicationModel.d.ts +0 -590
- package/sdk/application/Lead/LeadApplicationModel.js +0 -480
- package/sdk/application/Lead/LeadApplicationValidator.d.ts +0 -68
- package/sdk/application/Lead/LeadApplicationValidator.js +0 -71
- package/sdk/application/Logistic/LogisticApplicationModel.d.ts +0 -2034
- package/sdk/application/Logistic/LogisticApplicationModel.js +0 -1391
- package/sdk/application/Logistic/LogisticApplicationValidator.d.ts +0 -299
- package/sdk/application/Logistic/LogisticApplicationValidator.js +0 -224
- package/sdk/application/Order/OrderApplicationModel.d.ts +0 -2612
- package/sdk/application/Order/OrderApplicationModel.js +0 -1669
- package/sdk/application/Order/OrderApplicationValidator.d.ts +0 -279
- package/sdk/application/Order/OrderApplicationValidator.js +0 -210
- package/sdk/application/Payment/PaymentApplicationModel.d.ts +0 -4062
- package/sdk/application/Payment/PaymentApplicationModel.js +0 -2632
- package/sdk/application/Payment/PaymentApplicationValidator.d.ts +0 -576
- package/sdk/application/Payment/PaymentApplicationValidator.js +0 -594
- package/sdk/application/Rewards/RewardsApplicationModel.d.ts +0 -365
- package/sdk/application/Rewards/RewardsApplicationModel.js +0 -396
- package/sdk/application/Rewards/RewardsApplicationValidator.d.ts +0 -73
- package/sdk/application/Rewards/RewardsApplicationValidator.js +0 -84
- package/sdk/application/Share/ShareApplicationModel.d.ts +0 -339
- package/sdk/application/Share/ShareApplicationModel.js +0 -234
- package/sdk/application/Share/ShareApplicationValidator.d.ts +0 -90
- package/sdk/application/Share/ShareApplicationValidator.js +0 -91
- package/sdk/application/Theme/ThemeApplicationModel.d.ts +0 -1744
- package/sdk/application/Theme/ThemeApplicationModel.js +0 -1446
- package/sdk/application/Theme/ThemeApplicationValidator.d.ts +0 -79
- package/sdk/application/Theme/ThemeApplicationValidator.js +0 -65
- package/sdk/application/User/UserApplicationModel.d.ts +0 -1943
- package/sdk/application/User/UserApplicationModel.js +0 -1382
- package/sdk/application/User/UserApplicationValidator.d.ts +0 -560
- package/sdk/application/User/UserApplicationValidator.js +0 -573
- package/sdk/application/Webhook/WebhookApplicationModel.d.ts +0 -54
- package/sdk/application/Webhook/WebhookApplicationModel.js +0 -48
- package/sdk/application/Webhook/WebhookApplicationValidator.d.ts +0 -16
- package/sdk/application/Webhook/WebhookApplicationValidator.js +0 -19
- package/sdk/common/Clickstream.d.ts +0 -1
- package/sdk/common/Clickstream.js +0 -464
|
@@ -14,77 +14,66 @@ declare class Rewards {
|
|
|
14
14
|
_urls: {};
|
|
15
15
|
updateUrls(urls: any): void;
|
|
16
16
|
/**
|
|
17
|
-
* @param {RewardsApplicationValidator.CatalogueOrderParam} arg - Arg object.
|
|
18
17
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
19
18
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
20
|
-
* @returns {Promise<
|
|
21
|
-
* Success response
|
|
19
|
+
* @returns {Promise<CatalogueOrderResponse>} - Success response
|
|
22
20
|
* @name catalogueOrder
|
|
23
21
|
* @summary: Order from catalogue
|
|
24
|
-
* @description: Place
|
|
22
|
+
* @description: Place an reward on order items available in the catalogue. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/catalogueOrder/).
|
|
25
23
|
*/
|
|
26
|
-
catalogueOrder({ body, requestHeaders }?:
|
|
24
|
+
catalogueOrder({ body, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<CatalogueOrderResponse>;
|
|
27
25
|
/**
|
|
28
|
-
* @param {RewardsApplicationValidator.GetOfferByNameParam} arg - Arg object.
|
|
29
26
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
30
27
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
31
|
-
* @returns {Promise<
|
|
28
|
+
* @returns {Promise<Offer>} - Success response
|
|
32
29
|
* @name getOfferByName
|
|
33
30
|
* @summary: Get specific offer
|
|
34
31
|
* @description: Retrieves detailed information about an offer by its name. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getOfferByName/).
|
|
35
32
|
*/
|
|
36
|
-
getOfferByName({ name, requestHeaders }?:
|
|
33
|
+
getOfferByName({ name, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options, ...args: any[]): Promise<Offer>;
|
|
37
34
|
/**
|
|
38
|
-
* @param {RewardsApplicationValidator.GetOrderDiscountParam} arg - Arg object.
|
|
39
35
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
40
36
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
41
|
-
* @returns {Promise<
|
|
37
|
+
* @returns {Promise<OrderDiscountResponse>} - Success response
|
|
42
38
|
* @name getOrderDiscount
|
|
43
39
|
* @summary: Order discount
|
|
44
40
|
* @description: Retrieve the discount applied to a specific order. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getOrderDiscount/).
|
|
45
41
|
*/
|
|
46
|
-
getOrderDiscount({ body, requestHeaders }?:
|
|
42
|
+
getOrderDiscount({ body, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<OrderDiscountResponse>;
|
|
47
43
|
/**
|
|
48
|
-
* @param {RewardsApplicationValidator.GetUserPointsParam} arg - Arg object.
|
|
49
44
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
50
45
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
51
|
-
* @returns {Promise<
|
|
46
|
+
* @returns {Promise<PointsResponse>} - Success response
|
|
52
47
|
* @name getUserPoints
|
|
53
48
|
* @summary: Current points
|
|
54
49
|
* @description: Retrieves the current reward points balance for the user. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getUserPoints/).
|
|
55
50
|
*/
|
|
56
|
-
getUserPoints({ requestHeaders }?:
|
|
51
|
+
getUserPoints({ requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<PointsResponse>;
|
|
57
52
|
/**
|
|
58
|
-
* @param {RewardsApplicationValidator.GetUserPointsHistoryParam} arg - Arg object.
|
|
59
53
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
60
54
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
61
|
-
* @returns {Promise<
|
|
55
|
+
* @returns {Promise<PointsHistoryResponse>} - Success response
|
|
62
56
|
* @name getUserPointsHistory
|
|
63
57
|
* @summary: Points history
|
|
64
58
|
* @description: Gets the historical data of points earned or spent by the user. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getUserPointsHistory/).
|
|
65
59
|
*/
|
|
66
|
-
getUserPointsHistory({ pageId, pageSize, requestHeaders }?:
|
|
60
|
+
getUserPointsHistory({ pageId, pageSize, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<PointsHistoryResponse>;
|
|
67
61
|
/**
|
|
68
|
-
* @param {RewardsApplicationValidator.GetUserReferralDetailsParam} arg - Arg object.
|
|
69
62
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
70
63
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
71
|
-
* @returns {Promise<
|
|
64
|
+
* @returns {Promise<ReferralDetailsResponse>} - Success response
|
|
72
65
|
* @name getUserReferralDetails
|
|
73
66
|
* @summary: Referral details
|
|
74
67
|
* @description: Gets the details of the user’s referral status and codes. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getUserReferralDetails/).
|
|
75
68
|
*/
|
|
76
|
-
getUserReferralDetails({ requestHeaders }?:
|
|
69
|
+
getUserReferralDetails({ requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<ReferralDetailsResponse>;
|
|
77
70
|
/**
|
|
78
|
-
* @param {RewardsApplicationValidator.RedeemReferralCodeParam} arg - Arg object.
|
|
79
71
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
80
72
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
81
|
-
* @returns {Promise<
|
|
82
|
-
* Success response
|
|
73
|
+
* @returns {Promise<RedeemReferralCodeResponse>} - Success response
|
|
83
74
|
* @name redeemReferralCode
|
|
84
75
|
* @summary: Redeem code
|
|
85
76
|
* @description: Applies a referral code to earn or redeem rewards. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/redeemReferralCode/).
|
|
86
77
|
*/
|
|
87
|
-
redeemReferralCode({ body, requestHeaders }?:
|
|
78
|
+
redeemReferralCode({ body, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<RedeemReferralCodeResponse>;
|
|
88
79
|
}
|
|
89
|
-
import RewardsApplicationValidator = require("./RewardsApplicationValidator");
|
|
90
|
-
import RewardsApplicationModel = require("./RewardsApplicationModel");
|
|
@@ -1,14 +1,12 @@
|
|
|
1
|
-
const ApplicationAPIClient = require("../ApplicationAPIClient");
|
|
2
1
|
const {
|
|
3
2
|
FDKClientValidationError,
|
|
4
3
|
FDKResponseValidationError,
|
|
5
4
|
} = require("../../common/FDKError");
|
|
5
|
+
|
|
6
|
+
const ApplicationAPIClient = require("../ApplicationAPIClient");
|
|
6
7
|
const constructUrl = require("../constructUrl");
|
|
7
8
|
const Paginator = require("../../common/Paginator");
|
|
8
|
-
const
|
|
9
|
-
const RewardsApplicationModel = require("./RewardsApplicationModel");
|
|
10
|
-
const { Logger } = require("./../../common/Logger");
|
|
11
|
-
const Joi = require("joi");
|
|
9
|
+
const { validateRequiredParams } = require("../../common/Validator");
|
|
12
10
|
|
|
13
11
|
class Rewards {
|
|
14
12
|
constructor(_conf) {
|
|
@@ -44,41 +42,17 @@ class Rewards {
|
|
|
44
42
|
}
|
|
45
43
|
|
|
46
44
|
/**
|
|
47
|
-
* @param {RewardsApplicationValidator.CatalogueOrderParam} arg - Arg object.
|
|
48
45
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
49
46
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
50
|
-
* @returns {Promise<
|
|
51
|
-
* Success response
|
|
47
|
+
* @returns {Promise<CatalogueOrderResponse>} - Success response
|
|
52
48
|
* @name catalogueOrder
|
|
53
49
|
* @summary: Order from catalogue
|
|
54
|
-
* @description: Place
|
|
50
|
+
* @description: Place an reward on order items available in the catalogue. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/catalogueOrder/).
|
|
55
51
|
*/
|
|
56
52
|
async catalogueOrder(
|
|
57
53
|
{ body, requestHeaders } = { requestHeaders: {} },
|
|
58
54
|
{ responseHeaders } = { responseHeaders: false }
|
|
59
55
|
) {
|
|
60
|
-
const { error } = RewardsApplicationValidator.catalogueOrder().validate(
|
|
61
|
-
{ body },
|
|
62
|
-
{ abortEarly: false, allowUnknown: true }
|
|
63
|
-
);
|
|
64
|
-
if (error) {
|
|
65
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
// Showing warrnings if extra unknown parameters are found
|
|
69
|
-
const {
|
|
70
|
-
error: warrning,
|
|
71
|
-
} = RewardsApplicationValidator.catalogueOrder().validate(
|
|
72
|
-
{ body },
|
|
73
|
-
{ abortEarly: false, allowUnknown: false }
|
|
74
|
-
);
|
|
75
|
-
if (warrning) {
|
|
76
|
-
Logger({
|
|
77
|
-
level: "WARN",
|
|
78
|
-
message: `Parameter Validation warrnings for application > Rewards > catalogueOrder \n ${warrning}`,
|
|
79
|
-
});
|
|
80
|
-
}
|
|
81
|
-
|
|
82
56
|
const query_params = {};
|
|
83
57
|
|
|
84
58
|
const xHeaders = {};
|
|
@@ -101,32 +75,13 @@ class Rewards {
|
|
|
101
75
|
responseData = response[0];
|
|
102
76
|
}
|
|
103
77
|
|
|
104
|
-
const {
|
|
105
|
-
error: res_error,
|
|
106
|
-
} = RewardsApplicationModel.CatalogueOrderDetails().validate(responseData, {
|
|
107
|
-
abortEarly: false,
|
|
108
|
-
allowUnknown: true,
|
|
109
|
-
});
|
|
110
|
-
|
|
111
|
-
if (res_error) {
|
|
112
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
113
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
114
|
-
} else {
|
|
115
|
-
Logger({
|
|
116
|
-
level: "WARN",
|
|
117
|
-
message: `Response Validation Warnings for application > Rewards > catalogueOrder \n ${res_error}`,
|
|
118
|
-
});
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
|
|
122
78
|
return response;
|
|
123
79
|
}
|
|
124
80
|
|
|
125
81
|
/**
|
|
126
|
-
* @param {RewardsApplicationValidator.GetOfferByNameParam} arg - Arg object.
|
|
127
82
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
128
83
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
129
|
-
* @returns {Promise<
|
|
84
|
+
* @returns {Promise<Offer>} - Success response
|
|
130
85
|
* @name getOfferByName
|
|
131
86
|
* @summary: Get specific offer
|
|
132
87
|
* @description: Retrieves detailed information about an offer by its name. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getOfferByName/).
|
|
@@ -135,26 +90,13 @@ class Rewards {
|
|
|
135
90
|
{ name, requestHeaders } = { requestHeaders: {} },
|
|
136
91
|
{ responseHeaders } = { responseHeaders: false }
|
|
137
92
|
) {
|
|
138
|
-
const
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
// Showing warrnings if extra unknown parameters are found
|
|
147
|
-
const {
|
|
148
|
-
error: warrning,
|
|
149
|
-
} = RewardsApplicationValidator.getOfferByName().validate(
|
|
150
|
-
{ name },
|
|
151
|
-
{ abortEarly: false, allowUnknown: false }
|
|
152
|
-
);
|
|
153
|
-
if (warrning) {
|
|
154
|
-
Logger({
|
|
155
|
-
level: "WARN",
|
|
156
|
-
message: `Parameter Validation warrnings for application > Rewards > getOfferByName \n ${warrning}`,
|
|
93
|
+
const errors = validateRequiredParams(arguments[0], ["name"]);
|
|
94
|
+
if (errors.length > 0) {
|
|
95
|
+
const error = new FDKClientValidationError({
|
|
96
|
+
message: "Missing required field",
|
|
97
|
+
details: errors,
|
|
157
98
|
});
|
|
99
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
158
100
|
}
|
|
159
101
|
|
|
160
102
|
const query_params = {};
|
|
@@ -179,32 +121,13 @@ class Rewards {
|
|
|
179
121
|
responseData = response[0];
|
|
180
122
|
}
|
|
181
123
|
|
|
182
|
-
const {
|
|
183
|
-
error: res_error,
|
|
184
|
-
} = RewardsApplicationModel.Offer().validate(responseData, {
|
|
185
|
-
abortEarly: false,
|
|
186
|
-
allowUnknown: true,
|
|
187
|
-
});
|
|
188
|
-
|
|
189
|
-
if (res_error) {
|
|
190
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
191
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
192
|
-
} else {
|
|
193
|
-
Logger({
|
|
194
|
-
level: "WARN",
|
|
195
|
-
message: `Response Validation Warnings for application > Rewards > getOfferByName \n ${res_error}`,
|
|
196
|
-
});
|
|
197
|
-
}
|
|
198
|
-
}
|
|
199
|
-
|
|
200
124
|
return response;
|
|
201
125
|
}
|
|
202
126
|
|
|
203
127
|
/**
|
|
204
|
-
* @param {RewardsApplicationValidator.GetOrderDiscountParam} arg - Arg object.
|
|
205
128
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
206
129
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
207
|
-
* @returns {Promise<
|
|
130
|
+
* @returns {Promise<OrderDiscountResponse>} - Success response
|
|
208
131
|
* @name getOrderDiscount
|
|
209
132
|
* @summary: Order discount
|
|
210
133
|
* @description: Retrieve the discount applied to a specific order. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getOrderDiscount/).
|
|
@@ -213,28 +136,6 @@ class Rewards {
|
|
|
213
136
|
{ body, requestHeaders } = { requestHeaders: {} },
|
|
214
137
|
{ responseHeaders } = { responseHeaders: false }
|
|
215
138
|
) {
|
|
216
|
-
const { error } = RewardsApplicationValidator.getOrderDiscount().validate(
|
|
217
|
-
{ body },
|
|
218
|
-
{ abortEarly: false, allowUnknown: true }
|
|
219
|
-
);
|
|
220
|
-
if (error) {
|
|
221
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
// Showing warrnings if extra unknown parameters are found
|
|
225
|
-
const {
|
|
226
|
-
error: warrning,
|
|
227
|
-
} = RewardsApplicationValidator.getOrderDiscount().validate(
|
|
228
|
-
{ body },
|
|
229
|
-
{ abortEarly: false, allowUnknown: false }
|
|
230
|
-
);
|
|
231
|
-
if (warrning) {
|
|
232
|
-
Logger({
|
|
233
|
-
level: "WARN",
|
|
234
|
-
message: `Parameter Validation warrnings for application > Rewards > getOrderDiscount \n ${warrning}`,
|
|
235
|
-
});
|
|
236
|
-
}
|
|
237
|
-
|
|
238
139
|
const query_params = {};
|
|
239
140
|
|
|
240
141
|
const xHeaders = {};
|
|
@@ -257,32 +158,13 @@ class Rewards {
|
|
|
257
158
|
responseData = response[0];
|
|
258
159
|
}
|
|
259
160
|
|
|
260
|
-
const {
|
|
261
|
-
error: res_error,
|
|
262
|
-
} = RewardsApplicationModel.OrderDiscountDetails().validate(responseData, {
|
|
263
|
-
abortEarly: false,
|
|
264
|
-
allowUnknown: true,
|
|
265
|
-
});
|
|
266
|
-
|
|
267
|
-
if (res_error) {
|
|
268
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
269
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
270
|
-
} else {
|
|
271
|
-
Logger({
|
|
272
|
-
level: "WARN",
|
|
273
|
-
message: `Response Validation Warnings for application > Rewards > getOrderDiscount \n ${res_error}`,
|
|
274
|
-
});
|
|
275
|
-
}
|
|
276
|
-
}
|
|
277
|
-
|
|
278
161
|
return response;
|
|
279
162
|
}
|
|
280
163
|
|
|
281
164
|
/**
|
|
282
|
-
* @param {RewardsApplicationValidator.GetUserPointsParam} arg - Arg object.
|
|
283
165
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
284
166
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
285
|
-
* @returns {Promise<
|
|
167
|
+
* @returns {Promise<PointsResponse>} - Success response
|
|
286
168
|
* @name getUserPoints
|
|
287
169
|
* @summary: Current points
|
|
288
170
|
* @description: Retrieves the current reward points balance for the user. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getUserPoints/).
|
|
@@ -291,28 +173,6 @@ class Rewards {
|
|
|
291
173
|
{ requestHeaders } = { requestHeaders: {} },
|
|
292
174
|
{ responseHeaders } = { responseHeaders: false }
|
|
293
175
|
) {
|
|
294
|
-
const { error } = RewardsApplicationValidator.getUserPoints().validate(
|
|
295
|
-
{},
|
|
296
|
-
{ abortEarly: false, allowUnknown: true }
|
|
297
|
-
);
|
|
298
|
-
if (error) {
|
|
299
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
// Showing warrnings if extra unknown parameters are found
|
|
303
|
-
const {
|
|
304
|
-
error: warrning,
|
|
305
|
-
} = RewardsApplicationValidator.getUserPoints().validate(
|
|
306
|
-
{},
|
|
307
|
-
{ abortEarly: false, allowUnknown: false }
|
|
308
|
-
);
|
|
309
|
-
if (warrning) {
|
|
310
|
-
Logger({
|
|
311
|
-
level: "WARN",
|
|
312
|
-
message: `Parameter Validation warrnings for application > Rewards > getUserPoints \n ${warrning}`,
|
|
313
|
-
});
|
|
314
|
-
}
|
|
315
|
-
|
|
316
176
|
const query_params = {};
|
|
317
177
|
|
|
318
178
|
const xHeaders = {};
|
|
@@ -335,32 +195,13 @@ class Rewards {
|
|
|
335
195
|
responseData = response[0];
|
|
336
196
|
}
|
|
337
197
|
|
|
338
|
-
const {
|
|
339
|
-
error: res_error,
|
|
340
|
-
} = RewardsApplicationModel.PointsDetails().validate(responseData, {
|
|
341
|
-
abortEarly: false,
|
|
342
|
-
allowUnknown: true,
|
|
343
|
-
});
|
|
344
|
-
|
|
345
|
-
if (res_error) {
|
|
346
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
347
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
348
|
-
} else {
|
|
349
|
-
Logger({
|
|
350
|
-
level: "WARN",
|
|
351
|
-
message: `Response Validation Warnings for application > Rewards > getUserPoints \n ${res_error}`,
|
|
352
|
-
});
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
|
|
356
198
|
return response;
|
|
357
199
|
}
|
|
358
200
|
|
|
359
201
|
/**
|
|
360
|
-
* @param {RewardsApplicationValidator.GetUserPointsHistoryParam} arg - Arg object.
|
|
361
202
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
362
203
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
363
|
-
* @returns {Promise<
|
|
204
|
+
* @returns {Promise<PointsHistoryResponse>} - Success response
|
|
364
205
|
* @name getUserPointsHistory
|
|
365
206
|
* @summary: Points history
|
|
366
207
|
* @description: Gets the historical data of points earned or spent by the user. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getUserPointsHistory/).
|
|
@@ -369,30 +210,6 @@ class Rewards {
|
|
|
369
210
|
{ pageId, pageSize, requestHeaders } = { requestHeaders: {} },
|
|
370
211
|
{ responseHeaders } = { responseHeaders: false }
|
|
371
212
|
) {
|
|
372
|
-
const {
|
|
373
|
-
error,
|
|
374
|
-
} = RewardsApplicationValidator.getUserPointsHistory().validate(
|
|
375
|
-
{ pageId, pageSize },
|
|
376
|
-
{ abortEarly: false, allowUnknown: true }
|
|
377
|
-
);
|
|
378
|
-
if (error) {
|
|
379
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
380
|
-
}
|
|
381
|
-
|
|
382
|
-
// Showing warrnings if extra unknown parameters are found
|
|
383
|
-
const {
|
|
384
|
-
error: warrning,
|
|
385
|
-
} = RewardsApplicationValidator.getUserPointsHistory().validate(
|
|
386
|
-
{ pageId, pageSize },
|
|
387
|
-
{ abortEarly: false, allowUnknown: false }
|
|
388
|
-
);
|
|
389
|
-
if (warrning) {
|
|
390
|
-
Logger({
|
|
391
|
-
level: "WARN",
|
|
392
|
-
message: `Parameter Validation warrnings for application > Rewards > getUserPointsHistory \n ${warrning}`,
|
|
393
|
-
});
|
|
394
|
-
}
|
|
395
|
-
|
|
396
213
|
const query_params = {};
|
|
397
214
|
query_params["page_id"] = pageId;
|
|
398
215
|
query_params["page_size"] = pageSize;
|
|
@@ -417,32 +234,13 @@ class Rewards {
|
|
|
417
234
|
responseData = response[0];
|
|
418
235
|
}
|
|
419
236
|
|
|
420
|
-
const {
|
|
421
|
-
error: res_error,
|
|
422
|
-
} = RewardsApplicationModel.PointsHistoryDetails().validate(responseData, {
|
|
423
|
-
abortEarly: false,
|
|
424
|
-
allowUnknown: true,
|
|
425
|
-
});
|
|
426
|
-
|
|
427
|
-
if (res_error) {
|
|
428
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
429
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
430
|
-
} else {
|
|
431
|
-
Logger({
|
|
432
|
-
level: "WARN",
|
|
433
|
-
message: `Response Validation Warnings for application > Rewards > getUserPointsHistory \n ${res_error}`,
|
|
434
|
-
});
|
|
435
|
-
}
|
|
436
|
-
}
|
|
437
|
-
|
|
438
237
|
return response;
|
|
439
238
|
}
|
|
440
239
|
|
|
441
240
|
/**
|
|
442
|
-
* @param {RewardsApplicationValidator.GetUserReferralDetailsParam} arg - Arg object.
|
|
443
241
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
444
242
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
445
|
-
* @returns {Promise<
|
|
243
|
+
* @returns {Promise<ReferralDetailsResponse>} - Success response
|
|
446
244
|
* @name getUserReferralDetails
|
|
447
245
|
* @summary: Referral details
|
|
448
246
|
* @description: Gets the details of the user’s referral status and codes. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/getUserReferralDetails/).
|
|
@@ -451,30 +249,6 @@ class Rewards {
|
|
|
451
249
|
{ requestHeaders } = { requestHeaders: {} },
|
|
452
250
|
{ responseHeaders } = { responseHeaders: false }
|
|
453
251
|
) {
|
|
454
|
-
const {
|
|
455
|
-
error,
|
|
456
|
-
} = RewardsApplicationValidator.getUserReferralDetails().validate(
|
|
457
|
-
{},
|
|
458
|
-
{ abortEarly: false, allowUnknown: true }
|
|
459
|
-
);
|
|
460
|
-
if (error) {
|
|
461
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
// Showing warrnings if extra unknown parameters are found
|
|
465
|
-
const {
|
|
466
|
-
error: warrning,
|
|
467
|
-
} = RewardsApplicationValidator.getUserReferralDetails().validate(
|
|
468
|
-
{},
|
|
469
|
-
{ abortEarly: false, allowUnknown: false }
|
|
470
|
-
);
|
|
471
|
-
if (warrning) {
|
|
472
|
-
Logger({
|
|
473
|
-
level: "WARN",
|
|
474
|
-
message: `Parameter Validation warrnings for application > Rewards > getUserReferralDetails \n ${warrning}`,
|
|
475
|
-
});
|
|
476
|
-
}
|
|
477
|
-
|
|
478
252
|
const query_params = {};
|
|
479
253
|
|
|
480
254
|
const xHeaders = {};
|
|
@@ -497,33 +271,13 @@ class Rewards {
|
|
|
497
271
|
responseData = response[0];
|
|
498
272
|
}
|
|
499
273
|
|
|
500
|
-
const {
|
|
501
|
-
error: res_error,
|
|
502
|
-
} = RewardsApplicationModel.ReferralDetails().validate(responseData, {
|
|
503
|
-
abortEarly: false,
|
|
504
|
-
allowUnknown: true,
|
|
505
|
-
});
|
|
506
|
-
|
|
507
|
-
if (res_error) {
|
|
508
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
509
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
510
|
-
} else {
|
|
511
|
-
Logger({
|
|
512
|
-
level: "WARN",
|
|
513
|
-
message: `Response Validation Warnings for application > Rewards > getUserReferralDetails \n ${res_error}`,
|
|
514
|
-
});
|
|
515
|
-
}
|
|
516
|
-
}
|
|
517
|
-
|
|
518
274
|
return response;
|
|
519
275
|
}
|
|
520
276
|
|
|
521
277
|
/**
|
|
522
|
-
* @param {RewardsApplicationValidator.RedeemReferralCodeParam} arg - Arg object.
|
|
523
278
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
524
279
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
525
|
-
* @returns {Promise<
|
|
526
|
-
* Success response
|
|
280
|
+
* @returns {Promise<RedeemReferralCodeResponse>} - Success response
|
|
527
281
|
* @name redeemReferralCode
|
|
528
282
|
* @summary: Redeem code
|
|
529
283
|
* @description: Applies a referral code to earn or redeem rewards. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/rewards/redeemReferralCode/).
|
|
@@ -532,28 +286,6 @@ class Rewards {
|
|
|
532
286
|
{ body, requestHeaders } = { requestHeaders: {} },
|
|
533
287
|
{ responseHeaders } = { responseHeaders: false }
|
|
534
288
|
) {
|
|
535
|
-
const { error } = RewardsApplicationValidator.redeemReferralCode().validate(
|
|
536
|
-
{ body },
|
|
537
|
-
{ abortEarly: false, allowUnknown: true }
|
|
538
|
-
);
|
|
539
|
-
if (error) {
|
|
540
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
541
|
-
}
|
|
542
|
-
|
|
543
|
-
// Showing warrnings if extra unknown parameters are found
|
|
544
|
-
const {
|
|
545
|
-
error: warrning,
|
|
546
|
-
} = RewardsApplicationValidator.redeemReferralCode().validate(
|
|
547
|
-
{ body },
|
|
548
|
-
{ abortEarly: false, allowUnknown: false }
|
|
549
|
-
);
|
|
550
|
-
if (warrning) {
|
|
551
|
-
Logger({
|
|
552
|
-
level: "WARN",
|
|
553
|
-
message: `Parameter Validation warrnings for application > Rewards > redeemReferralCode \n ${warrning}`,
|
|
554
|
-
});
|
|
555
|
-
}
|
|
556
|
-
|
|
557
289
|
const query_params = {};
|
|
558
290
|
|
|
559
291
|
const xHeaders = {};
|
|
@@ -576,24 +308,6 @@ class Rewards {
|
|
|
576
308
|
responseData = response[0];
|
|
577
309
|
}
|
|
578
310
|
|
|
579
|
-
const {
|
|
580
|
-
error: res_error,
|
|
581
|
-
} = RewardsApplicationModel.RedeemReferralCodeDetails().validate(
|
|
582
|
-
responseData,
|
|
583
|
-
{ abortEarly: false, allowUnknown: true }
|
|
584
|
-
);
|
|
585
|
-
|
|
586
|
-
if (res_error) {
|
|
587
|
-
if (this._conf.options.strictResponseCheck === true) {
|
|
588
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
589
|
-
} else {
|
|
590
|
-
Logger({
|
|
591
|
-
level: "WARN",
|
|
592
|
-
message: `Response Validation Warnings for application > Rewards > redeemReferralCode \n ${res_error}`,
|
|
593
|
-
});
|
|
594
|
-
}
|
|
595
|
-
}
|
|
596
|
-
|
|
597
311
|
return response;
|
|
598
312
|
}
|
|
599
313
|
}
|
|
@@ -14,76 +14,66 @@ declare class Share {
|
|
|
14
14
|
_urls: {};
|
|
15
15
|
updateUrls(urls: any): void;
|
|
16
16
|
/**
|
|
17
|
-
* @param {ShareApplicationValidator.CreateShortLinkParam} arg - Arg object.
|
|
18
17
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
19
18
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
20
|
-
* @returns {Promise<
|
|
19
|
+
* @returns {Promise<ShortLinkRes>} - Success response
|
|
21
20
|
* @name createShortLink
|
|
22
21
|
* @summary: Shorten URL
|
|
23
22
|
* @description: Creates a shortened version of a given URL for easier sharing. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/createShortLink/).
|
|
24
23
|
*/
|
|
25
|
-
createShortLink({ body, requestHeaders }?:
|
|
24
|
+
createShortLink({ body, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<ShortLinkRes>;
|
|
26
25
|
/**
|
|
27
|
-
* @param {ShareApplicationValidator.GetApplicationQRCodeParam} arg - Arg object.
|
|
28
26
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
29
27
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
30
|
-
* @returns {Promise<
|
|
28
|
+
* @returns {Promise<QRCodeResp>} - Success response
|
|
31
29
|
* @name getApplicationQRCode
|
|
32
30
|
* @summary: App QR code
|
|
33
31
|
* @description: Generates a QR code for the application for easy sharing. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/getApplicationQRCode/).
|
|
34
32
|
*/
|
|
35
|
-
getApplicationQRCode({ requestHeaders }?:
|
|
33
|
+
getApplicationQRCode({ requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<QRCodeResp>;
|
|
36
34
|
/**
|
|
37
|
-
* @param {ShareApplicationValidator.GetCollectionQRCodeBySlugParam} arg - Arg object.
|
|
38
35
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
39
36
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
40
|
-
* @returns {Promise<
|
|
37
|
+
* @returns {Promise<QRCodeResp>} - Success response
|
|
41
38
|
* @name getCollectionQRCodeBySlug
|
|
42
39
|
* @summary: Collection QR code
|
|
43
40
|
* @description: Generates a QR code for a specific product collection using its slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/getCollectionQRCodeBySlug/).
|
|
44
41
|
*/
|
|
45
|
-
getCollectionQRCodeBySlug({ slug, requestHeaders }?:
|
|
42
|
+
getCollectionQRCodeBySlug({ slug, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options, ...args: any[]): Promise<QRCodeResp>;
|
|
46
43
|
/**
|
|
47
|
-
* @param {ShareApplicationValidator.GetOriginalShortLinkByHashParam} arg -
|
|
48
|
-
* Arg object.
|
|
49
44
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
50
45
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
51
|
-
* @returns {Promise<
|
|
46
|
+
* @returns {Promise<ShortLinkRes>} - Success response
|
|
52
47
|
* @name getOriginalShortLinkByHash
|
|
53
48
|
* @summary: Original URL
|
|
54
49
|
* @description: Retrieve the original link from a short-link by using a hash value. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/getOriginalShortLinkByHash/).
|
|
55
50
|
*/
|
|
56
|
-
getOriginalShortLinkByHash({ hash, requestHeaders }?:
|
|
51
|
+
getOriginalShortLinkByHash({ hash, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options, ...args: any[]): Promise<ShortLinkRes>;
|
|
57
52
|
/**
|
|
58
|
-
* @param {ShareApplicationValidator.GetProductQRCodeBySlugParam} arg - Arg object.
|
|
59
53
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
60
54
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
61
|
-
* @returns {Promise<
|
|
55
|
+
* @returns {Promise<QRCodeResp>} - Success response
|
|
62
56
|
* @name getProductQRCodeBySlug
|
|
63
57
|
* @summary: Product QR code
|
|
64
58
|
* @description: Creates a QR code for a specific product identified by its slug. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/getProductQRCodeBySlug/).
|
|
65
59
|
*/
|
|
66
|
-
getProductQRCodeBySlug({ slug, requestHeaders }?:
|
|
60
|
+
getProductQRCodeBySlug({ slug, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options, ...args: any[]): Promise<QRCodeResp>;
|
|
67
61
|
/**
|
|
68
|
-
* @param {ShareApplicationValidator.GetShortLinkByHashParam} arg - Arg object.
|
|
69
62
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
70
63
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
71
|
-
* @returns {Promise<
|
|
64
|
+
* @returns {Promise<ShortLinkRes>} - Success response
|
|
72
65
|
* @name getShortLinkByHash
|
|
73
66
|
* @summary: Get short link
|
|
74
67
|
* @description: Retrieves a previously created short link using its hash identifier. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/getShortLinkByHash/).
|
|
75
68
|
*/
|
|
76
|
-
getShortLinkByHash({ hash, requestHeaders }?:
|
|
69
|
+
getShortLinkByHash({ hash, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options, ...args: any[]): Promise<ShortLinkRes>;
|
|
77
70
|
/**
|
|
78
|
-
* @param {ShareApplicationValidator.GetUrlQRCodeParam} arg - Arg object.
|
|
79
71
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
80
72
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
81
|
-
* @returns {Promise<
|
|
73
|
+
* @returns {Promise<QRCodeResp>} - Success response
|
|
82
74
|
* @name getUrlQRCode
|
|
83
75
|
* @summary: URL to QR code
|
|
84
76
|
* @description: Converts a given URL into a scannable QR code. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/application/share/getUrlQRCode/).
|
|
85
77
|
*/
|
|
86
|
-
getUrlQRCode({ url, requestHeaders }?:
|
|
78
|
+
getUrlQRCode({ url, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<QRCodeResp>;
|
|
87
79
|
}
|
|
88
|
-
import ShareApplicationValidator = require("./ShareApplicationValidator");
|
|
89
|
-
import ShareApplicationModel = require("./ShareApplicationModel");
|