@gofynd/fdk-client-javascript 1.4.15-beta.3 → 1.4.15-beta.5
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 +48 -68
- package/sdk/application/Cart/CartApplicationClient.js +304 -114
- package/sdk/application/Catalog/CatalogApplicationClient.d.ts +58 -59
- package/sdk/application/Catalog/CatalogApplicationClient.js +437 -30
- package/sdk/application/Common/CommonApplicationClient.d.ts +2 -2
- package/sdk/application/Common/CommonApplicationClient.js +22 -1
- package/sdk/application/Communication/CommunicationApplicationClient.js +29 -0
- package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +20 -20
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +157 -10
- package/sdk/application/Content/ContentApplicationClient.d.ts +30 -19
- package/sdk/application/Content/ContentApplicationClient.js +297 -28
- package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +8 -8
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +50 -7
- package/sdk/application/Lead/LeadApplicationClient.d.ts +2 -2
- package/sdk/application/Lead/LeadApplicationClient.js +74 -1
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +15 -35
- package/sdk/application/Logistic/LogisticApplicationClient.js +159 -87
- package/sdk/application/Order/OrderApplicationClient.d.ts +12 -22
- package/sdk/application/Order/OrderApplicationClient.js +195 -47
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +87 -87
- package/sdk/application/Payment/PaymentApplicationClient.js +473 -46
- package/sdk/application/Rewards/RewardsApplicationClient.d.ts +13 -13
- package/sdk/application/Rewards/RewardsApplicationClient.js +75 -7
- package/sdk/application/Share/ShareApplicationClient.js +96 -0
- package/sdk/application/Theme/ThemeApplicationClient.d.ts +2 -2
- package/sdk/application/Theme/ThemeApplicationClient.js +66 -4
- package/sdk/application/User/UserApplicationClient.d.ts +10 -10
- package/sdk/application/User/UserApplicationClient.js +418 -6
- package/sdk/application/Webhook/WebhookApplicationClient.d.ts +4 -4
- package/sdk/application/Webhook/WebhookApplicationClient.js +16 -3
- 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 +167 -1200
- package/sdk/partner/Logistics/LogisticsPartnerModel.js +160 -571
- package/sdk/partner/Logistics/LogisticsPartnerValidator.d.ts +0 -10
- package/sdk/partner/Logistics/LogisticsPartnerValidator.js +7 -121
- 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 +115 -419
- package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +65 -118
- package/sdk/platform/Cart/CartPlatformApplicationValidator.js +44 -109
- package/sdk/platform/Cart/CartPlatformModel.d.ts +1298 -5037
- package/sdk/platform/Cart/CartPlatformModel.js +1217 -1976
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +183 -209
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +400 -457
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +142 -185
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +78 -96
- package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +117 -154
- package/sdk/platform/Catalog/CatalogPlatformClient.js +172 -292
- package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1647 -6385
- package/sdk/platform/Catalog/CatalogPlatformModel.js +1680 -3217
- package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +31 -72
- package/sdk/platform/Catalog/CatalogPlatformValidator.js +24 -50
- 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 +131 -283
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +97 -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 +6 -17
- package/sdk/platform/Order/OrderPlatformApplicationClient.js +7 -85
- package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +24 -95
- package/sdk/platform/Order/OrderPlatformApplicationValidator.js +19 -39
- package/sdk/platform/Order/OrderPlatformClient.d.ts +96 -153
- package/sdk/platform/Order/OrderPlatformClient.js +198 -416
- package/sdk/platform/Order/OrderPlatformModel.d.ts +1286 -7619
- package/sdk/platform/Order/OrderPlatformModel.js +1265 -3922
- package/sdk/platform/Order/OrderPlatformValidator.d.ts +109 -270
- package/sdk/platform/Order/OrderPlatformValidator.js +77 -135
- 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 +105 -93
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +141 -129
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +48 -48
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +48 -48
- package/sdk/platform/Payment/PaymentPlatformClient.d.ts +20 -20
- package/sdk/platform/Payment/PaymentPlatformClient.js +20 -20
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +319 -333
- package/sdk/platform/Payment/PaymentPlatformModel.js +278 -288
- package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +8 -8
- package/sdk/platform/Payment/PaymentPlatformValidator.js +8 -8
- 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 +36 -46
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationClient.js +41 -132
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.d.ts +17 -46
- package/sdk/platform/Serviceability/ServiceabilityPlatformApplicationValidator.js +14 -34
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.d.ts +46 -40
- package/sdk/platform/Serviceability/ServiceabilityPlatformClient.js +64 -58
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +612 -1845
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +554 -886
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.d.ts +46 -42
- package/sdk/platform/Serviceability/ServiceabilityPlatformValidator.js +28 -26
- 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 +21 -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 +20 -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/Partner/PartnerPublicClient.js +15 -0
- package/sdk/public/Webhook/WebhookPublicClient.d.ts +8 -8
- package/sdk/public/Webhook/WebhookPublicClient.js +48 -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 -29
- package/sdk/application/Finance/FinanceApplicationClient.js +0 -105
|
@@ -18,8 +18,7 @@ class Order {
|
|
|
18
18
|
* @param {OrderPlatformValidator.AddStateManagerConfigParam} arg - Arg object
|
|
19
19
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
20
20
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
21
|
-
* @returns {Promise<OrderPlatformModel.
|
|
22
|
-
* Success response
|
|
21
|
+
* @returns {Promise<OrderPlatformModel.ConfigUpdatedResponse>} - Success response
|
|
23
22
|
* @name addStateManagerConfig
|
|
24
23
|
* @summary: Allows esm config updation
|
|
25
24
|
* @description: Update ESM config - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/addStateManagerConfig/).
|
|
@@ -75,10 +74,10 @@ class Order {
|
|
|
75
74
|
|
|
76
75
|
const {
|
|
77
76
|
error: res_error,
|
|
78
|
-
} = OrderPlatformModel.
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
);
|
|
77
|
+
} = OrderPlatformModel.ConfigUpdatedResponse().validate(responseData, {
|
|
78
|
+
abortEarly: false,
|
|
79
|
+
allowUnknown: true,
|
|
80
|
+
});
|
|
82
81
|
|
|
83
82
|
if (res_error) {
|
|
84
83
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -98,8 +97,7 @@ class Order {
|
|
|
98
97
|
* @param {OrderPlatformValidator.AttachOrderUserParam} arg - Arg object
|
|
99
98
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
100
99
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
101
|
-
* @returns {Promise<OrderPlatformModel.
|
|
102
|
-
* Success response
|
|
100
|
+
* @returns {Promise<OrderPlatformModel.AttachOrderUserResponse>} - Success response
|
|
103
101
|
* @name attachOrderUser
|
|
104
102
|
* @summary: Attach order to a user
|
|
105
103
|
* @description: Attach an anonymous order to a customer based on OTP verification - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/attachOrderUser/).
|
|
@@ -155,10 +153,10 @@ class Order {
|
|
|
155
153
|
|
|
156
154
|
const {
|
|
157
155
|
error: res_error,
|
|
158
|
-
} = OrderPlatformModel.
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
);
|
|
156
|
+
} = OrderPlatformModel.AttachOrderUserResponse().validate(responseData, {
|
|
157
|
+
abortEarly: false,
|
|
158
|
+
allowUnknown: true,
|
|
159
|
+
});
|
|
162
160
|
|
|
163
161
|
if (res_error) {
|
|
164
162
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -178,7 +176,7 @@ class Order {
|
|
|
178
176
|
* @param {OrderPlatformValidator.BulkListingParam} arg - Arg object
|
|
179
177
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
180
178
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
181
|
-
* @returns {Promise<OrderPlatformModel.
|
|
179
|
+
* @returns {Promise<OrderPlatformModel.BulkListingResponse>} - Success response
|
|
182
180
|
* @name bulkListing
|
|
183
181
|
* @summary: Lists bulk operations
|
|
184
182
|
* @description: Get list of bulk operation that is initiated and completed as per the filters provided - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/bulkListing/).
|
|
@@ -260,7 +258,7 @@ class Order {
|
|
|
260
258
|
|
|
261
259
|
const {
|
|
262
260
|
error: res_error,
|
|
263
|
-
} = OrderPlatformModel.
|
|
261
|
+
} = OrderPlatformModel.BulkListingResponse().validate(responseData, {
|
|
264
262
|
abortEarly: false,
|
|
265
263
|
allowUnknown: true,
|
|
266
264
|
});
|
|
@@ -283,9 +281,8 @@ class Order {
|
|
|
283
281
|
* @param {OrderPlatformValidator.BulkStateTransistionParam} arg - Arg object
|
|
284
282
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
285
283
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
286
|
-
* @returns {Promise<OrderPlatformModel.
|
|
287
|
-
*
|
|
288
|
-
*
|
|
284
|
+
* @returns {Promise<OrderPlatformModel.BulkStateTransistionResponse>} -
|
|
285
|
+
* Success response
|
|
289
286
|
* @name bulkStateTransistion
|
|
290
287
|
* @summary: Upload bulk state transitions file
|
|
291
288
|
* @description: Performs state transisiton in bulk using the CSV or excel file for the given shipments. The bulk transition CSV or excel template can be downloaded using the seller template download method. Current supported format is excel and CSV. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/bulkStateTransistion/).
|
|
@@ -341,7 +338,7 @@ class Order {
|
|
|
341
338
|
|
|
342
339
|
const {
|
|
343
340
|
error: res_error,
|
|
344
|
-
} = OrderPlatformModel.
|
|
341
|
+
} = OrderPlatformModel.BulkStateTransistionResponse().validate(
|
|
345
342
|
responseData,
|
|
346
343
|
{ abortEarly: false, allowUnknown: true }
|
|
347
344
|
);
|
|
@@ -439,92 +436,11 @@ class Order {
|
|
|
439
436
|
return response;
|
|
440
437
|
}
|
|
441
438
|
|
|
442
|
-
/**
|
|
443
|
-
* @param {OrderPlatformValidator.CreateChannelConfigParam} arg - Arg object
|
|
444
|
-
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
445
|
-
* @param {import("../PlatformAPIClient").Options} - Options
|
|
446
|
-
* @returns {Promise<OrderPlatformModel.CreateChannelConfigResponseSchema>}
|
|
447
|
-
* - Success response
|
|
448
|
-
*
|
|
449
|
-
* @name createChannelConfig
|
|
450
|
-
* @summary: Create channel configuration
|
|
451
|
-
* @description: Set up configuration for a channel specific to orders which has implications over how the order fulfilment happens in a channel - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/createChannelConfig/).
|
|
452
|
-
*/
|
|
453
|
-
async createChannelConfig(
|
|
454
|
-
{ body, requestHeaders } = { requestHeaders: {} },
|
|
455
|
-
{ responseHeaders } = { responseHeaders: false }
|
|
456
|
-
) {
|
|
457
|
-
const { error } = OrderPlatformValidator.createChannelConfig().validate(
|
|
458
|
-
{
|
|
459
|
-
body,
|
|
460
|
-
},
|
|
461
|
-
{ abortEarly: false, allowUnknown: true }
|
|
462
|
-
);
|
|
463
|
-
if (error) {
|
|
464
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
465
|
-
}
|
|
466
|
-
|
|
467
|
-
// Showing warrnings if extra unknown parameters are found
|
|
468
|
-
const {
|
|
469
|
-
error: warrning,
|
|
470
|
-
} = OrderPlatformValidator.createChannelConfig().validate(
|
|
471
|
-
{
|
|
472
|
-
body,
|
|
473
|
-
},
|
|
474
|
-
{ abortEarly: false, allowUnknown: false }
|
|
475
|
-
);
|
|
476
|
-
if (warrning) {
|
|
477
|
-
Logger({
|
|
478
|
-
level: "WARN",
|
|
479
|
-
message: `Parameter Validation warrnings for platform > Order > createChannelConfig \n ${warrning}`,
|
|
480
|
-
});
|
|
481
|
-
}
|
|
482
|
-
|
|
483
|
-
const query_params = {};
|
|
484
|
-
|
|
485
|
-
const xHeaders = {};
|
|
486
|
-
|
|
487
|
-
const response = await PlatformAPIClient.execute(
|
|
488
|
-
this.config,
|
|
489
|
-
"post",
|
|
490
|
-
`/service/platform/order-manage/v1.0/company/${this.config.companyId}/order-config`,
|
|
491
|
-
query_params,
|
|
492
|
-
body,
|
|
493
|
-
{ ...xHeaders, ...requestHeaders },
|
|
494
|
-
{ responseHeaders }
|
|
495
|
-
);
|
|
496
|
-
|
|
497
|
-
let responseData = response;
|
|
498
|
-
if (responseHeaders) {
|
|
499
|
-
responseData = response[0];
|
|
500
|
-
}
|
|
501
|
-
|
|
502
|
-
const {
|
|
503
|
-
error: res_error,
|
|
504
|
-
} = OrderPlatformModel.CreateChannelConfigResponseSchema().validate(
|
|
505
|
-
responseData,
|
|
506
|
-
{ abortEarly: false, allowUnknown: true }
|
|
507
|
-
);
|
|
508
|
-
|
|
509
|
-
if (res_error) {
|
|
510
|
-
if (this.config.options.strictResponseCheck === true) {
|
|
511
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
512
|
-
} else {
|
|
513
|
-
Logger({
|
|
514
|
-
level: "WARN",
|
|
515
|
-
message: `Response Validation Warnings for platform > Order > createChannelConfig \n ${res_error}`,
|
|
516
|
-
});
|
|
517
|
-
}
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
return response;
|
|
521
|
-
}
|
|
522
|
-
|
|
523
439
|
/**
|
|
524
440
|
* @param {OrderPlatformValidator.CreateOrderParam} arg - Arg object
|
|
525
441
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
526
442
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
527
|
-
* @returns {Promise<OrderPlatformModel.
|
|
443
|
+
* @returns {Promise<OrderPlatformModel.CreateOrderResponse>} - Success response
|
|
528
444
|
* @name createOrder
|
|
529
445
|
* @summary: Create order
|
|
530
446
|
* @description: Creates an order - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/createOrder/).
|
|
@@ -578,7 +494,7 @@ class Order {
|
|
|
578
494
|
|
|
579
495
|
const {
|
|
580
496
|
error: res_error,
|
|
581
|
-
} = OrderPlatformModel.
|
|
497
|
+
} = OrderPlatformModel.CreateOrderResponse().validate(responseData, {
|
|
582
498
|
abortEarly: false,
|
|
583
499
|
allowUnknown: true,
|
|
584
500
|
});
|
|
@@ -601,7 +517,7 @@ class Order {
|
|
|
601
517
|
* @param {OrderPlatformValidator.DispatchManifestsParam} arg - Arg object
|
|
602
518
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
603
519
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
604
|
-
* @returns {Promise<OrderPlatformModel.
|
|
520
|
+
* @returns {Promise<OrderPlatformModel.SuccessResponse>} - Success response
|
|
605
521
|
* @name dispatchManifests
|
|
606
522
|
* @summary: Dispatch manifest
|
|
607
523
|
* @description: Updates the status of the manifest to processed and change the status of the shipments in the manifest to dispatch status - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/dispatchManifests/).
|
|
@@ -657,7 +573,7 @@ class Order {
|
|
|
657
573
|
|
|
658
574
|
const {
|
|
659
575
|
error: res_error,
|
|
660
|
-
} = OrderPlatformModel.
|
|
576
|
+
} = OrderPlatformModel.SuccessResponse().validate(responseData, {
|
|
661
577
|
abortEarly: false,
|
|
662
578
|
allowUnknown: true,
|
|
663
579
|
});
|
|
@@ -680,7 +596,7 @@ class Order {
|
|
|
680
596
|
* @param {OrderPlatformValidator.DownloadBulkActionTemplateParam} arg - Arg object
|
|
681
597
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
682
598
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
683
|
-
* @returns {Promise<OrderPlatformModel.
|
|
599
|
+
* @returns {Promise<OrderPlatformModel.FileResponse>} - Success response
|
|
684
600
|
* @name downloadBulkActionTemplate
|
|
685
601
|
* @summary: Download bulk template
|
|
686
602
|
* @description: Download bulk seller templates which can be used to perform operations in bulk - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/downloadBulkActionTemplate/).
|
|
@@ -739,7 +655,7 @@ class Order {
|
|
|
739
655
|
|
|
740
656
|
const {
|
|
741
657
|
error: res_error,
|
|
742
|
-
} = OrderPlatformModel.
|
|
658
|
+
} = OrderPlatformModel.FileResponse().validate(responseData, {
|
|
743
659
|
abortEarly: false,
|
|
744
660
|
allowUnknown: true,
|
|
745
661
|
});
|
|
@@ -762,9 +678,8 @@ class Order {
|
|
|
762
678
|
* @param {OrderPlatformValidator.DownloadLanesReportParam} arg - Arg object
|
|
763
679
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
764
680
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
765
|
-
* @returns {Promise<OrderPlatformModel.
|
|
766
|
-
*
|
|
767
|
-
*
|
|
681
|
+
* @returns {Promise<OrderPlatformModel.BulkReportsDownloadResponse>} -
|
|
682
|
+
* Success response
|
|
768
683
|
* @name downloadLanesReport
|
|
769
684
|
* @summary: Download Lane report
|
|
770
685
|
* @description: Downloads shipments/orders present in the provided lane - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/downloadLanesReport/).
|
|
@@ -820,7 +735,7 @@ class Order {
|
|
|
820
735
|
|
|
821
736
|
const {
|
|
822
737
|
error: res_error,
|
|
823
|
-
} = OrderPlatformModel.
|
|
738
|
+
} = OrderPlatformModel.BulkReportsDownloadResponse().validate(
|
|
824
739
|
responseData,
|
|
825
740
|
{ abortEarly: false, allowUnknown: true }
|
|
826
741
|
);
|
|
@@ -843,8 +758,7 @@ class Order {
|
|
|
843
758
|
* @param {OrderPlatformValidator.EInvoiceRetryParam} arg - Arg object
|
|
844
759
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
845
760
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
846
|
-
* @returns {Promise<OrderPlatformModel.
|
|
847
|
-
* Success response
|
|
761
|
+
* @returns {Promise<OrderPlatformModel.EInvoiceRetryResponse>} - Success response
|
|
848
762
|
* @name eInvoiceRetry
|
|
849
763
|
* @summary: Retry E-invoice
|
|
850
764
|
* @description: Reattempt the generation of an E-invoice - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/eInvoiceRetry/).
|
|
@@ -898,10 +812,10 @@ class Order {
|
|
|
898
812
|
|
|
899
813
|
const {
|
|
900
814
|
error: res_error,
|
|
901
|
-
} = OrderPlatformModel.
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
);
|
|
815
|
+
} = OrderPlatformModel.EInvoiceRetryResponse().validate(responseData, {
|
|
816
|
+
abortEarly: false,
|
|
817
|
+
allowUnknown: true,
|
|
818
|
+
});
|
|
905
819
|
|
|
906
820
|
if (res_error) {
|
|
907
821
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1080,8 +994,7 @@ class Order {
|
|
|
1080
994
|
* @param {OrderPlatformValidator.GenerateInvoiceIDParam} arg - Arg object
|
|
1081
995
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1082
996
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1083
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1084
|
-
* Success response
|
|
997
|
+
* @returns {Promise<OrderPlatformModel.GenerateInvoiceIDResponse>} - Success response
|
|
1085
998
|
* @name generateInvoiceID
|
|
1086
999
|
* @summary: Generate and attach invoice Id
|
|
1087
1000
|
* @description: Generate and attach Invoice Ids against shipments. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/generateInvoiceID/).
|
|
@@ -1139,10 +1052,10 @@ class Order {
|
|
|
1139
1052
|
|
|
1140
1053
|
const {
|
|
1141
1054
|
error: res_error,
|
|
1142
|
-
} = OrderPlatformModel.
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
);
|
|
1055
|
+
} = OrderPlatformModel.GenerateInvoiceIDResponse().validate(responseData, {
|
|
1056
|
+
abortEarly: false,
|
|
1057
|
+
allowUnknown: true,
|
|
1058
|
+
});
|
|
1146
1059
|
|
|
1147
1060
|
if (res_error) {
|
|
1148
1061
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1162,9 +1075,8 @@ class Order {
|
|
|
1162
1075
|
* @param {OrderPlatformValidator.GeneratePOSReceiptByOrderIdParam} arg - Arg object
|
|
1163
1076
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1164
1077
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1165
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1166
|
-
*
|
|
1167
|
-
*
|
|
1078
|
+
* @returns {Promise<OrderPlatformModel.GeneratePosOrderReceiptResponse>} -
|
|
1079
|
+
* Success response
|
|
1168
1080
|
* @name generatePOSReceiptByOrderId
|
|
1169
1081
|
* @summary: Generate POS receipt by order Id
|
|
1170
1082
|
* @description: Create a point-of-sale (POS) receipt for a specific order by order Id. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/generatePOSReceiptByOrderId/).
|
|
@@ -1230,7 +1142,7 @@ class Order {
|
|
|
1230
1142
|
|
|
1231
1143
|
const {
|
|
1232
1144
|
error: res_error,
|
|
1233
|
-
} = OrderPlatformModel.
|
|
1145
|
+
} = OrderPlatformModel.GeneratePosOrderReceiptResponse().validate(
|
|
1234
1146
|
responseData,
|
|
1235
1147
|
{ abortEarly: false, allowUnknown: true }
|
|
1236
1148
|
);
|
|
@@ -1253,7 +1165,7 @@ class Order {
|
|
|
1253
1165
|
* @param {OrderPlatformValidator.GenerateProcessManifestParam} arg - Arg object
|
|
1254
1166
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1255
1167
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1256
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1168
|
+
* @returns {Promise<OrderPlatformModel.ManifestResponse>} - Success response
|
|
1257
1169
|
* @name generateProcessManifest
|
|
1258
1170
|
* @summary: Process Order Manifest
|
|
1259
1171
|
* @description: Endpoint to save and process order manifests. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/generateProcessManifest/).
|
|
@@ -1309,7 +1221,7 @@ class Order {
|
|
|
1309
1221
|
|
|
1310
1222
|
const {
|
|
1311
1223
|
error: res_error,
|
|
1312
|
-
} = OrderPlatformModel.
|
|
1224
|
+
} = OrderPlatformModel.ManifestResponse().validate(responseData, {
|
|
1313
1225
|
abortEarly: false,
|
|
1314
1226
|
allowUnknown: true,
|
|
1315
1227
|
});
|
|
@@ -1418,8 +1330,7 @@ class Order {
|
|
|
1418
1330
|
* @param {OrderPlatformValidator.GetAllowedTemplatesForBulkParam} arg - Arg object
|
|
1419
1331
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1420
1332
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1421
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1422
|
-
* Success response
|
|
1333
|
+
* @returns {Promise<OrderPlatformModel.AllowedTemplatesResponse>} - Success response
|
|
1423
1334
|
* @name getAllowedTemplatesForBulk
|
|
1424
1335
|
* @summary: List bulk operation templates
|
|
1425
1336
|
* @description: Gets all the allowed templates to perform bulk operations. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getAllowedTemplatesForBulk/).
|
|
@@ -1473,10 +1384,10 @@ class Order {
|
|
|
1473
1384
|
|
|
1474
1385
|
const {
|
|
1475
1386
|
error: res_error,
|
|
1476
|
-
} = OrderPlatformModel.
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
);
|
|
1387
|
+
} = OrderPlatformModel.AllowedTemplatesResponse().validate(responseData, {
|
|
1388
|
+
abortEarly: false,
|
|
1389
|
+
allowUnknown: true,
|
|
1390
|
+
});
|
|
1480
1391
|
|
|
1481
1392
|
if (res_error) {
|
|
1482
1393
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1496,8 +1407,7 @@ class Order {
|
|
|
1496
1407
|
* @param {OrderPlatformValidator.GetAnnouncementsParam} arg - Arg object
|
|
1497
1408
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1498
1409
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1499
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1500
|
-
* Success response
|
|
1410
|
+
* @returns {Promise<OrderPlatformModel.AnnouncementsResponse>} - Success response
|
|
1501
1411
|
* @name getAnnouncements
|
|
1502
1412
|
* @summary: List announcements
|
|
1503
1413
|
* @description: Retrieve announcements related to orders fulfilment configured by platform or company admin - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getAnnouncements/).
|
|
@@ -1554,10 +1464,10 @@ class Order {
|
|
|
1554
1464
|
|
|
1555
1465
|
const {
|
|
1556
1466
|
error: res_error,
|
|
1557
|
-
} = OrderPlatformModel.
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
);
|
|
1467
|
+
} = OrderPlatformModel.AnnouncementsResponse().validate(responseData, {
|
|
1468
|
+
abortEarly: false,
|
|
1469
|
+
allowUnknown: true,
|
|
1470
|
+
});
|
|
1561
1471
|
|
|
1562
1472
|
if (res_error) {
|
|
1563
1473
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1577,9 +1487,8 @@ class Order {
|
|
|
1577
1487
|
* @param {OrderPlatformValidator.GetBagByIdParam} arg - Arg object
|
|
1578
1488
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1579
1489
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1580
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1581
|
-
*
|
|
1582
|
-
*
|
|
1490
|
+
* @returns {Promise<OrderPlatformModel.BagDetailsPlatformResponse>} -
|
|
1491
|
+
* Success response
|
|
1583
1492
|
* @name getBagById
|
|
1584
1493
|
* @summary: Get bag
|
|
1585
1494
|
* @description: Retrieve detailed information about a specific bag - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getBagById/).
|
|
@@ -1640,10 +1549,10 @@ class Order {
|
|
|
1640
1549
|
|
|
1641
1550
|
const {
|
|
1642
1551
|
error: res_error,
|
|
1643
|
-
} = OrderPlatformModel.
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
);
|
|
1552
|
+
} = OrderPlatformModel.BagDetailsPlatformResponse().validate(responseData, {
|
|
1553
|
+
abortEarly: false,
|
|
1554
|
+
allowUnknown: true,
|
|
1555
|
+
});
|
|
1647
1556
|
|
|
1648
1557
|
if (res_error) {
|
|
1649
1558
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1663,8 +1572,7 @@ class Order {
|
|
|
1663
1572
|
* @param {OrderPlatformValidator.GetBagsParam} arg - Arg object
|
|
1664
1573
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1665
1574
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1666
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1667
|
-
* Success response
|
|
1575
|
+
* @returns {Promise<OrderPlatformModel.GetBagsPlatformResponse>} - Success response
|
|
1668
1576
|
* @name getBags
|
|
1669
1577
|
* @summary: List bags
|
|
1670
1578
|
* @description: Get paginated list of bags based on provided filters - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getBags/).
|
|
@@ -1754,10 +1662,10 @@ class Order {
|
|
|
1754
1662
|
|
|
1755
1663
|
const {
|
|
1756
1664
|
error: res_error,
|
|
1757
|
-
} = OrderPlatformModel.
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
);
|
|
1665
|
+
} = OrderPlatformModel.GetBagsPlatformResponse().validate(responseData, {
|
|
1666
|
+
abortEarly: false,
|
|
1667
|
+
allowUnknown: true,
|
|
1668
|
+
});
|
|
1761
1669
|
|
|
1762
1670
|
if (res_error) {
|
|
1763
1671
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1777,9 +1685,8 @@ class Order {
|
|
|
1777
1685
|
* @param {OrderPlatformValidator.GetBulkActionTemplateParam} arg - Arg object
|
|
1778
1686
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1779
1687
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1780
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1781
|
-
*
|
|
1782
|
-
*
|
|
1688
|
+
* @returns {Promise<OrderPlatformModel.BulkActionTemplateResponse>} -
|
|
1689
|
+
* Success response
|
|
1783
1690
|
* @name getBulkActionTemplate
|
|
1784
1691
|
* @summary: List supported templates
|
|
1785
1692
|
* @description: Get list of templates so that users can download the required template - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getBulkActionTemplate/).
|
|
@@ -1831,10 +1738,10 @@ class Order {
|
|
|
1831
1738
|
|
|
1832
1739
|
const {
|
|
1833
1740
|
error: res_error,
|
|
1834
|
-
} = OrderPlatformModel.
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
);
|
|
1741
|
+
} = OrderPlatformModel.BulkActionTemplateResponse().validate(responseData, {
|
|
1742
|
+
abortEarly: false,
|
|
1743
|
+
allowUnknown: true,
|
|
1744
|
+
});
|
|
1838
1745
|
|
|
1839
1746
|
if (res_error) {
|
|
1840
1747
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -1854,7 +1761,7 @@ class Order {
|
|
|
1854
1761
|
* @param {OrderPlatformValidator.GetBulkShipmentExcelFileParam} arg - Arg object
|
|
1855
1762
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1856
1763
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1857
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1764
|
+
* @returns {Promise<OrderPlatformModel.FileResponse>} - Success response
|
|
1858
1765
|
* @name getBulkShipmentExcelFile
|
|
1859
1766
|
* @summary: Generate the report
|
|
1860
1767
|
* @description: Generates the report which can be filled and uploaded to perform the bulk operation based on the filters provided - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getBulkShipmentExcelFile/).
|
|
@@ -1960,7 +1867,7 @@ class Order {
|
|
|
1960
1867
|
|
|
1961
1868
|
const {
|
|
1962
1869
|
error: res_error,
|
|
1963
|
-
} = OrderPlatformModel.
|
|
1870
|
+
} = OrderPlatformModel.FileResponse().validate(responseData, {
|
|
1964
1871
|
abortEarly: false,
|
|
1965
1872
|
allowUnknown: true,
|
|
1966
1873
|
});
|
|
@@ -1979,86 +1886,11 @@ class Order {
|
|
|
1979
1886
|
return response;
|
|
1980
1887
|
}
|
|
1981
1888
|
|
|
1982
|
-
/**
|
|
1983
|
-
* @param {OrderPlatformValidator.GetChannelConfigParam} arg - Arg object
|
|
1984
|
-
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1985
|
-
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1986
|
-
* @returns {Promise<OrderPlatformModel.CreateChannelConfigData>} - Success response
|
|
1987
|
-
* @name getChannelConfig
|
|
1988
|
-
* @summary: Get channel configuration
|
|
1989
|
-
* @description: Retrieve configuration settings specific to orders for a channel - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getChannelConfig/).
|
|
1990
|
-
*/
|
|
1991
|
-
async getChannelConfig(
|
|
1992
|
-
{ requestHeaders } = { requestHeaders: {} },
|
|
1993
|
-
{ responseHeaders } = { responseHeaders: false }
|
|
1994
|
-
) {
|
|
1995
|
-
const { error } = OrderPlatformValidator.getChannelConfig().validate(
|
|
1996
|
-
{},
|
|
1997
|
-
{ abortEarly: false, allowUnknown: true }
|
|
1998
|
-
);
|
|
1999
|
-
if (error) {
|
|
2000
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
2001
|
-
}
|
|
2002
|
-
|
|
2003
|
-
// Showing warrnings if extra unknown parameters are found
|
|
2004
|
-
const {
|
|
2005
|
-
error: warrning,
|
|
2006
|
-
} = OrderPlatformValidator.getChannelConfig().validate(
|
|
2007
|
-
{},
|
|
2008
|
-
{ abortEarly: false, allowUnknown: false }
|
|
2009
|
-
);
|
|
2010
|
-
if (warrning) {
|
|
2011
|
-
Logger({
|
|
2012
|
-
level: "WARN",
|
|
2013
|
-
message: `Parameter Validation warrnings for platform > Order > getChannelConfig \n ${warrning}`,
|
|
2014
|
-
});
|
|
2015
|
-
}
|
|
2016
|
-
|
|
2017
|
-
const query_params = {};
|
|
2018
|
-
|
|
2019
|
-
const xHeaders = {};
|
|
2020
|
-
|
|
2021
|
-
const response = await PlatformAPIClient.execute(
|
|
2022
|
-
this.config,
|
|
2023
|
-
"get",
|
|
2024
|
-
`/service/platform/order-manage/v1.0/company/${this.config.companyId}/order-config`,
|
|
2025
|
-
query_params,
|
|
2026
|
-
undefined,
|
|
2027
|
-
{ ...xHeaders, ...requestHeaders },
|
|
2028
|
-
{ responseHeaders }
|
|
2029
|
-
);
|
|
2030
|
-
|
|
2031
|
-
let responseData = response;
|
|
2032
|
-
if (responseHeaders) {
|
|
2033
|
-
responseData = response[0];
|
|
2034
|
-
}
|
|
2035
|
-
|
|
2036
|
-
const {
|
|
2037
|
-
error: res_error,
|
|
2038
|
-
} = OrderPlatformModel.CreateChannelConfigData().validate(responseData, {
|
|
2039
|
-
abortEarly: false,
|
|
2040
|
-
allowUnknown: true,
|
|
2041
|
-
});
|
|
2042
|
-
|
|
2043
|
-
if (res_error) {
|
|
2044
|
-
if (this.config.options.strictResponseCheck === true) {
|
|
2045
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
2046
|
-
} else {
|
|
2047
|
-
Logger({
|
|
2048
|
-
level: "WARN",
|
|
2049
|
-
message: `Response Validation Warnings for platform > Order > getChannelConfig \n ${res_error}`,
|
|
2050
|
-
});
|
|
2051
|
-
}
|
|
2052
|
-
}
|
|
2053
|
-
|
|
2054
|
-
return response;
|
|
2055
|
-
}
|
|
2056
|
-
|
|
2057
1889
|
/**
|
|
2058
1890
|
* @param {OrderPlatformValidator.GetFileByStatusParam} arg - Arg object
|
|
2059
1891
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2060
1892
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2061
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1893
|
+
* @returns {Promise<OrderPlatformModel.JobFailedResponse>} - Success response
|
|
2062
1894
|
* @name getFileByStatus
|
|
2063
1895
|
* @summary: Download file used for Bulk operation
|
|
2064
1896
|
* @description: Get the file download URL used for performing bulk operation - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getFileByStatus/).
|
|
@@ -2125,7 +1957,7 @@ class Order {
|
|
|
2125
1957
|
|
|
2126
1958
|
const {
|
|
2127
1959
|
error: res_error,
|
|
2128
|
-
} = OrderPlatformModel.
|
|
1960
|
+
} = OrderPlatformModel.JobFailedResponse().validate(responseData, {
|
|
2129
1961
|
abortEarly: false,
|
|
2130
1962
|
allowUnknown: true,
|
|
2131
1963
|
});
|
|
@@ -2148,7 +1980,7 @@ class Order {
|
|
|
2148
1980
|
* @param {OrderPlatformValidator.GetLaneConfigParam} arg - Arg object
|
|
2149
1981
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2150
1982
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2151
|
-
* @returns {Promise<OrderPlatformModel.
|
|
1983
|
+
* @returns {Promise<OrderPlatformModel.LaneConfigResponse>} - Success response
|
|
2152
1984
|
* @name getLaneConfig
|
|
2153
1985
|
* @summary: Get lane configuration
|
|
2154
1986
|
* @description: Get configuration settings for lanes - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getLaneConfig/).
|
|
@@ -2278,7 +2110,7 @@ class Order {
|
|
|
2278
2110
|
|
|
2279
2111
|
const {
|
|
2280
2112
|
error: res_error,
|
|
2281
|
-
} = OrderPlatformModel.
|
|
2113
|
+
} = OrderPlatformModel.LaneConfigResponse().validate(responseData, {
|
|
2282
2114
|
abortEarly: false,
|
|
2283
2115
|
allowUnknown: true,
|
|
2284
2116
|
});
|
|
@@ -2523,8 +2355,7 @@ class Order {
|
|
|
2523
2355
|
* @param {OrderPlatformValidator.GetManifestfiltersParam} arg - Arg object
|
|
2524
2356
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2525
2357
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2526
|
-
* @returns {Promise<OrderPlatformModel.
|
|
2527
|
-
* Success response
|
|
2358
|
+
* @returns {Promise<OrderPlatformModel.ManifestFiltersResponse>} - Success response
|
|
2528
2359
|
* @name getManifestfilters
|
|
2529
2360
|
* @summary: List filters
|
|
2530
2361
|
* @description: Get supported filter for listing manifests - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getManifestfilters/).
|
|
@@ -2581,10 +2412,10 @@ class Order {
|
|
|
2581
2412
|
|
|
2582
2413
|
const {
|
|
2583
2414
|
error: res_error,
|
|
2584
|
-
} = OrderPlatformModel.
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
);
|
|
2415
|
+
} = OrderPlatformModel.ManifestFiltersResponse().validate(responseData, {
|
|
2416
|
+
abortEarly: false,
|
|
2417
|
+
allowUnknown: true,
|
|
2418
|
+
});
|
|
2588
2419
|
|
|
2589
2420
|
if (res_error) {
|
|
2590
2421
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -2717,8 +2548,7 @@ class Order {
|
|
|
2717
2548
|
* @param {OrderPlatformValidator.GetOrderByIdParam} arg - Arg object
|
|
2718
2549
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2719
2550
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2720
|
-
* @returns {Promise<OrderPlatformModel.
|
|
2721
|
-
* Success response
|
|
2551
|
+
* @returns {Promise<OrderPlatformModel.OrderDetailsResponse>} - Success response
|
|
2722
2552
|
* @name getOrderById
|
|
2723
2553
|
* @summary: Get order
|
|
2724
2554
|
* @description: Get detailed information about a specific order - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getOrderById/).
|
|
@@ -2781,7 +2611,7 @@ class Order {
|
|
|
2781
2611
|
|
|
2782
2612
|
const {
|
|
2783
2613
|
error: res_error,
|
|
2784
|
-
} = OrderPlatformModel.
|
|
2614
|
+
} = OrderPlatformModel.OrderDetailsResponse().validate(responseData, {
|
|
2785
2615
|
abortEarly: false,
|
|
2786
2616
|
allowUnknown: true,
|
|
2787
2617
|
});
|
|
@@ -2804,11 +2634,10 @@ class Order {
|
|
|
2804
2634
|
* @param {OrderPlatformValidator.GetOrdersParam} arg - Arg object
|
|
2805
2635
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2806
2636
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2807
|
-
* @returns {Promise<OrderPlatformModel.
|
|
2808
|
-
* Success response
|
|
2637
|
+
* @returns {Promise<OrderPlatformModel.OrderListingResponse>} - Success response
|
|
2809
2638
|
* @name getOrders
|
|
2810
2639
|
* @summary: List orders
|
|
2811
|
-
* @description: Get a list of orders based on the filters provided
|
|
2640
|
+
* @description: Get a list of orders based on the filters provided - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getOrders/).
|
|
2812
2641
|
*/
|
|
2813
2642
|
async getOrders(
|
|
2814
2643
|
{
|
|
@@ -2835,7 +2664,6 @@ class Order {
|
|
|
2835
2664
|
customerId,
|
|
2836
2665
|
orderType,
|
|
2837
2666
|
allowInactive,
|
|
2838
|
-
groupEntity,
|
|
2839
2667
|
enforceDateFilter,
|
|
2840
2668
|
requestHeaders,
|
|
2841
2669
|
} = { requestHeaders: {} },
|
|
@@ -2866,7 +2694,6 @@ class Order {
|
|
|
2866
2694
|
customerId,
|
|
2867
2695
|
orderType,
|
|
2868
2696
|
allowInactive,
|
|
2869
|
-
groupEntity,
|
|
2870
2697
|
enforceDateFilter,
|
|
2871
2698
|
},
|
|
2872
2699
|
{ abortEarly: false, allowUnknown: true }
|
|
@@ -2901,7 +2728,6 @@ class Order {
|
|
|
2901
2728
|
customerId,
|
|
2902
2729
|
orderType,
|
|
2903
2730
|
allowInactive,
|
|
2904
|
-
groupEntity,
|
|
2905
2731
|
enforceDateFilter,
|
|
2906
2732
|
},
|
|
2907
2733
|
{ abortEarly: false, allowUnknown: false }
|
|
@@ -2937,7 +2763,6 @@ class Order {
|
|
|
2937
2763
|
query_params["customer_id"] = customerId;
|
|
2938
2764
|
query_params["order_type"] = orderType;
|
|
2939
2765
|
query_params["allow_inactive"] = allowInactive;
|
|
2940
|
-
query_params["group_entity"] = groupEntity;
|
|
2941
2766
|
query_params["enforce_date_filter"] = enforceDateFilter;
|
|
2942
2767
|
|
|
2943
2768
|
const xHeaders = {};
|
|
@@ -2959,7 +2784,7 @@ class Order {
|
|
|
2959
2784
|
|
|
2960
2785
|
const {
|
|
2961
2786
|
error: res_error,
|
|
2962
|
-
} = OrderPlatformModel.
|
|
2787
|
+
} = OrderPlatformModel.OrderListingResponse().validate(responseData, {
|
|
2963
2788
|
abortEarly: false,
|
|
2964
2789
|
allowUnknown: true,
|
|
2965
2790
|
});
|
|
@@ -2982,7 +2807,7 @@ class Order {
|
|
|
2982
2807
|
* @param {OrderPlatformValidator.GetRoleBasedActionsParam} arg - Arg object
|
|
2983
2808
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
2984
2809
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
2985
|
-
* @returns {Promise<OrderPlatformModel.
|
|
2810
|
+
* @returns {Promise<OrderPlatformModel.GetActionsResponse>} - Success response
|
|
2986
2811
|
* @name getRoleBasedActions
|
|
2987
2812
|
* @summary: Get role-based actions
|
|
2988
2813
|
* @description: Retrieve permissible actions based on user roles such as company_admin, company_operation, customer_care, and read_only. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getRoleBasedActions/).
|
|
@@ -3034,7 +2859,7 @@ class Order {
|
|
|
3034
2859
|
|
|
3035
2860
|
const {
|
|
3036
2861
|
error: res_error,
|
|
3037
|
-
} = OrderPlatformModel.
|
|
2862
|
+
} = OrderPlatformModel.GetActionsResponse().validate(responseData, {
|
|
3038
2863
|
abortEarly: false,
|
|
3039
2864
|
allowUnknown: true,
|
|
3040
2865
|
});
|
|
@@ -3057,10 +2882,9 @@ class Order {
|
|
|
3057
2882
|
* @param {OrderPlatformValidator.GetShipmentByIdParam} arg - Arg object
|
|
3058
2883
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3059
2884
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3060
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3061
|
-
* Success response
|
|
2885
|
+
* @returns {Promise<OrderPlatformModel.ShipmentInfoResponse>} - Success response
|
|
3062
2886
|
* @name getShipmentById
|
|
3063
|
-
* @summary: Get shipment
|
|
2887
|
+
* @summary: Get shipment
|
|
3064
2888
|
* @description: Get detailed information about a specific shipment - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getShipmentById/).
|
|
3065
2889
|
*/
|
|
3066
2890
|
async getShipmentById(
|
|
@@ -3130,7 +2954,7 @@ class Order {
|
|
|
3130
2954
|
|
|
3131
2955
|
const {
|
|
3132
2956
|
error: res_error,
|
|
3133
|
-
} = OrderPlatformModel.
|
|
2957
|
+
} = OrderPlatformModel.ShipmentInfoResponse().validate(responseData, {
|
|
3134
2958
|
abortEarly: false,
|
|
3135
2959
|
allowUnknown: true,
|
|
3136
2960
|
});
|
|
@@ -3153,8 +2977,7 @@ class Order {
|
|
|
3153
2977
|
* @param {OrderPlatformValidator.GetShipmentHistoryParam} arg - Arg object
|
|
3154
2978
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3155
2979
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3156
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3157
|
-
* Success response
|
|
2980
|
+
* @returns {Promise<OrderPlatformModel.ShipmentHistoryResponse>} - Success response
|
|
3158
2981
|
* @name getShipmentHistory
|
|
3159
2982
|
* @summary: Get a shipment's history
|
|
3160
2983
|
* @description: Get the history of the shipment - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getShipmentHistory/).
|
|
@@ -3214,10 +3037,10 @@ class Order {
|
|
|
3214
3037
|
|
|
3215
3038
|
const {
|
|
3216
3039
|
error: res_error,
|
|
3217
|
-
} = OrderPlatformModel.
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
);
|
|
3040
|
+
} = OrderPlatformModel.ShipmentHistoryResponse().validate(responseData, {
|
|
3041
|
+
abortEarly: false,
|
|
3042
|
+
allowUnknown: true,
|
|
3043
|
+
});
|
|
3221
3044
|
|
|
3222
3045
|
if (res_error) {
|
|
3223
3046
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -3237,9 +3060,8 @@ class Order {
|
|
|
3237
3060
|
* @param {OrderPlatformValidator.GetShipmentReasonsParam} arg - Arg object
|
|
3238
3061
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3239
3062
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3240
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3241
|
-
*
|
|
3242
|
-
*
|
|
3063
|
+
* @returns {Promise<OrderPlatformModel.PlatformShipmentReasonsResponse>} -
|
|
3064
|
+
* Success response
|
|
3243
3065
|
* @name getShipmentReasons
|
|
3244
3066
|
* @summary: List bag cancellation reasons
|
|
3245
3067
|
* @description: Get reasons to perform full or partial cancellation of a bag - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getShipmentReasons/).
|
|
@@ -3299,7 +3121,7 @@ class Order {
|
|
|
3299
3121
|
|
|
3300
3122
|
const {
|
|
3301
3123
|
error: res_error,
|
|
3302
|
-
} = OrderPlatformModel.
|
|
3124
|
+
} = OrderPlatformModel.PlatformShipmentReasonsResponse().validate(
|
|
3303
3125
|
responseData,
|
|
3304
3126
|
{ abortEarly: false, allowUnknown: true }
|
|
3305
3127
|
);
|
|
@@ -3322,7 +3144,7 @@ class Order {
|
|
|
3322
3144
|
* @param {OrderPlatformValidator.GetShipmentsParam} arg - Arg object
|
|
3323
3145
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3324
3146
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3325
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3147
|
+
* @returns {Promise<OrderPlatformModel.ShipmentInternalPlatformViewResponse>}
|
|
3326
3148
|
* - Success response
|
|
3327
3149
|
*
|
|
3328
3150
|
* @name getShipments
|
|
@@ -3362,7 +3184,6 @@ class Order {
|
|
|
3362
3184
|
tags,
|
|
3363
3185
|
customerId,
|
|
3364
3186
|
orderType,
|
|
3365
|
-
groupEntity,
|
|
3366
3187
|
enforceDateFilter,
|
|
3367
3188
|
requestHeaders,
|
|
3368
3189
|
} = { requestHeaders: {} },
|
|
@@ -3401,7 +3222,6 @@ class Order {
|
|
|
3401
3222
|
tags,
|
|
3402
3223
|
customerId,
|
|
3403
3224
|
orderType,
|
|
3404
|
-
groupEntity,
|
|
3405
3225
|
enforceDateFilter,
|
|
3406
3226
|
},
|
|
3407
3227
|
{ abortEarly: false, allowUnknown: true }
|
|
@@ -3444,7 +3264,6 @@ class Order {
|
|
|
3444
3264
|
tags,
|
|
3445
3265
|
customerId,
|
|
3446
3266
|
orderType,
|
|
3447
|
-
groupEntity,
|
|
3448
3267
|
enforceDateFilter,
|
|
3449
3268
|
},
|
|
3450
3269
|
{ abortEarly: false, allowUnknown: false }
|
|
@@ -3488,7 +3307,6 @@ class Order {
|
|
|
3488
3307
|
query_params["tags"] = tags;
|
|
3489
3308
|
query_params["customer_id"] = customerId;
|
|
3490
3309
|
query_params["order_type"] = orderType;
|
|
3491
|
-
query_params["group_entity"] = groupEntity;
|
|
3492
3310
|
query_params["enforce_date_filter"] = enforceDateFilter;
|
|
3493
3311
|
|
|
3494
3312
|
const xHeaders = {};
|
|
@@ -3510,7 +3328,7 @@ class Order {
|
|
|
3510
3328
|
|
|
3511
3329
|
const {
|
|
3512
3330
|
error: res_error,
|
|
3513
|
-
} = OrderPlatformModel.
|
|
3331
|
+
} = OrderPlatformModel.ShipmentInternalPlatformViewResponse().validate(
|
|
3514
3332
|
responseData,
|
|
3515
3333
|
{ abortEarly: false, allowUnknown: true }
|
|
3516
3334
|
);
|
|
@@ -3694,8 +3512,7 @@ class Order {
|
|
|
3694
3512
|
* @param {OrderPlatformValidator.GetTemplateParam} arg - Arg object
|
|
3695
3513
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3696
3514
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3697
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3698
|
-
* Success response
|
|
3515
|
+
* @returns {Promise<OrderPlatformModel.TemplateDownloadResponse>} - Success response
|
|
3699
3516
|
* @name getTemplate
|
|
3700
3517
|
* @summary: Download bulk operation templates
|
|
3701
3518
|
* @description: Get the excel or CSV file URL for the template. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getTemplate/).
|
|
@@ -3749,10 +3566,10 @@ class Order {
|
|
|
3749
3566
|
|
|
3750
3567
|
const {
|
|
3751
3568
|
error: res_error,
|
|
3752
|
-
} = OrderPlatformModel.
|
|
3753
|
-
|
|
3754
|
-
|
|
3755
|
-
);
|
|
3569
|
+
} = OrderPlatformModel.TemplateDownloadResponse().validate(responseData, {
|
|
3570
|
+
abortEarly: false,
|
|
3571
|
+
allowUnknown: true,
|
|
3572
|
+
});
|
|
3756
3573
|
|
|
3757
3574
|
if (res_error) {
|
|
3758
3575
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -3772,7 +3589,7 @@ class Order {
|
|
|
3772
3589
|
* @param {OrderPlatformValidator.GetfiltersParam} arg - Arg object
|
|
3773
3590
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3774
3591
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3775
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3592
|
+
* @returns {Promise<OrderPlatformModel.FiltersResponse>} - Success response
|
|
3776
3593
|
* @name getfilters
|
|
3777
3594
|
* @summary: List filters
|
|
3778
3595
|
* @description: Get supported filters for various listing operations - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/getfilters/).
|
|
@@ -3830,7 +3647,7 @@ class Order {
|
|
|
3830
3647
|
|
|
3831
3648
|
const {
|
|
3832
3649
|
error: res_error,
|
|
3833
|
-
} = OrderPlatformModel.
|
|
3650
|
+
} = OrderPlatformModel.FiltersResponse().validate(responseData, {
|
|
3834
3651
|
abortEarly: false,
|
|
3835
3652
|
allowUnknown: true,
|
|
3836
3653
|
});
|
|
@@ -3853,9 +3670,8 @@ class Order {
|
|
|
3853
3670
|
* @param {OrderPlatformValidator.InvalidateShipmentCacheParam} arg - Arg object
|
|
3854
3671
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3855
3672
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3856
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3857
|
-
*
|
|
3858
|
-
*
|
|
3673
|
+
* @returns {Promise<OrderPlatformModel.InvalidateShipmentCacheResponse>} -
|
|
3674
|
+
* Success response
|
|
3859
3675
|
* @name invalidateShipmentCache
|
|
3860
3676
|
* @summary: Invalidate shipment cache
|
|
3861
3677
|
* @description: Clear the existing shipment cache data stored in Redis and serialize the updated data for subsequent use. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/invalidateShipmentCache/).
|
|
@@ -3911,7 +3727,7 @@ class Order {
|
|
|
3911
3727
|
|
|
3912
3728
|
const {
|
|
3913
3729
|
error: res_error,
|
|
3914
|
-
} = OrderPlatformModel.
|
|
3730
|
+
} = OrderPlatformModel.InvalidateShipmentCacheResponse().validate(
|
|
3915
3731
|
responseData,
|
|
3916
3732
|
{ abortEarly: false, allowUnknown: true }
|
|
3917
3733
|
);
|
|
@@ -3934,7 +3750,7 @@ class Order {
|
|
|
3934
3750
|
* @param {OrderPlatformValidator.JobDetailsParam} arg - Arg object
|
|
3935
3751
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
3936
3752
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
3937
|
-
* @returns {Promise<OrderPlatformModel.
|
|
3753
|
+
* @returns {Promise<OrderPlatformModel.JobDetailsResponse>} - Success response
|
|
3938
3754
|
* @name jobDetails
|
|
3939
3755
|
* @summary: Get bulk operation details
|
|
3940
3756
|
* @description: Fetches details of the job for the provided batch Id - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/jobDetails/).
|
|
@@ -3988,7 +3804,7 @@ class Order {
|
|
|
3988
3804
|
|
|
3989
3805
|
const {
|
|
3990
3806
|
error: res_error,
|
|
3991
|
-
} = OrderPlatformModel.
|
|
3807
|
+
} = OrderPlatformModel.JobDetailsResponse().validate(responseData, {
|
|
3992
3808
|
abortEarly: false,
|
|
3993
3809
|
allowUnknown: true,
|
|
3994
3810
|
});
|
|
@@ -4088,8 +3904,7 @@ class Order {
|
|
|
4088
3904
|
* @param {OrderPlatformValidator.PostShipmentHistoryParam} arg - Arg object
|
|
4089
3905
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4090
3906
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4091
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4092
|
-
* Success response
|
|
3907
|
+
* @returns {Promise<OrderPlatformModel.ShipmentHistoryResponse>} - Success response
|
|
4093
3908
|
* @name postShipmentHistory
|
|
4094
3909
|
* @summary: Create shipment history
|
|
4095
3910
|
* @description: Used to add logs in history for a bag for the provided Shipment ID - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/postShipmentHistory/).
|
|
@@ -4145,10 +3960,10 @@ class Order {
|
|
|
4145
3960
|
|
|
4146
3961
|
const {
|
|
4147
3962
|
error: res_error,
|
|
4148
|
-
} = OrderPlatformModel.
|
|
4149
|
-
|
|
4150
|
-
|
|
4151
|
-
);
|
|
3963
|
+
} = OrderPlatformModel.ShipmentHistoryResponse().validate(responseData, {
|
|
3964
|
+
abortEarly: false,
|
|
3965
|
+
allowUnknown: true,
|
|
3966
|
+
});
|
|
4152
3967
|
|
|
4153
3968
|
if (res_error) {
|
|
4154
3969
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -4168,8 +3983,7 @@ class Order {
|
|
|
4168
3983
|
* @param {OrderPlatformValidator.ReassignLocationParam} arg - Arg object
|
|
4169
3984
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4170
3985
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4171
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4172
|
-
* Success response
|
|
3986
|
+
* @returns {Promise<OrderPlatformModel.StoreReassignResponse>} - Success response
|
|
4173
3987
|
* @name reassignLocation
|
|
4174
3988
|
* @summary: Reassign location
|
|
4175
3989
|
* @description: Reassign the shipment to a another location and update its status to 'Store Reassigned.' - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/reassignLocation/).
|
|
@@ -4225,10 +4039,10 @@ class Order {
|
|
|
4225
4039
|
|
|
4226
4040
|
const {
|
|
4227
4041
|
error: res_error,
|
|
4228
|
-
} = OrderPlatformModel.
|
|
4229
|
-
|
|
4230
|
-
|
|
4231
|
-
);
|
|
4042
|
+
} = OrderPlatformModel.StoreReassignResponse().validate(responseData, {
|
|
4043
|
+
abortEarly: false,
|
|
4044
|
+
allowUnknown: true,
|
|
4045
|
+
});
|
|
4232
4046
|
|
|
4233
4047
|
if (res_error) {
|
|
4234
4048
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -4248,7 +4062,7 @@ class Order {
|
|
|
4248
4062
|
* @param {OrderPlatformValidator.SendSmsNinjaParam} arg - Arg object
|
|
4249
4063
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4250
4064
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4251
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4065
|
+
* @returns {Promise<OrderPlatformModel.BaseResponse>} - Success response
|
|
4252
4066
|
* @name sendSmsNinja
|
|
4253
4067
|
* @summary: Send SMS
|
|
4254
4068
|
* @description: Send SMS to customer based on the template that is selected - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/sendSmsNinja/).
|
|
@@ -4302,7 +4116,7 @@ class Order {
|
|
|
4302
4116
|
|
|
4303
4117
|
const {
|
|
4304
4118
|
error: res_error,
|
|
4305
|
-
} = OrderPlatformModel.
|
|
4119
|
+
} = OrderPlatformModel.BaseResponse().validate(responseData, {
|
|
4306
4120
|
abortEarly: false,
|
|
4307
4121
|
allowUnknown: true,
|
|
4308
4122
|
});
|
|
@@ -4325,8 +4139,7 @@ class Order {
|
|
|
4325
4139
|
* @param {OrderPlatformValidator.SendUserMobileOTPParam} arg - Arg object
|
|
4326
4140
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4327
4141
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4328
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4329
|
-
* Success response
|
|
4142
|
+
* @returns {Promise<OrderPlatformModel.SendUserMobileOtpResponse>} - Success response
|
|
4330
4143
|
* @name sendUserMobileOTP
|
|
4331
4144
|
* @summary: Send user mobile OTP
|
|
4332
4145
|
* @description: Send a one-time OTP to a customer mobile number - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/sendUserMobileOTP/).
|
|
@@ -4382,10 +4195,10 @@ class Order {
|
|
|
4382
4195
|
|
|
4383
4196
|
const {
|
|
4384
4197
|
error: res_error,
|
|
4385
|
-
} = OrderPlatformModel.
|
|
4386
|
-
|
|
4387
|
-
|
|
4388
|
-
);
|
|
4198
|
+
} = OrderPlatformModel.SendUserMobileOtpResponse().validate(responseData, {
|
|
4199
|
+
abortEarly: false,
|
|
4200
|
+
allowUnknown: true,
|
|
4201
|
+
});
|
|
4389
4202
|
|
|
4390
4203
|
if (res_error) {
|
|
4391
4204
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -4405,9 +4218,8 @@ class Order {
|
|
|
4405
4218
|
* @param {OrderPlatformValidator.TrackShipmentParam} arg - Arg object
|
|
4406
4219
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4407
4220
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4408
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4409
|
-
*
|
|
4410
|
-
*
|
|
4221
|
+
* @returns {Promise<OrderPlatformModel.CourierPartnerTrackingResponse>} -
|
|
4222
|
+
* Success response
|
|
4411
4223
|
* @name trackShipment
|
|
4412
4224
|
* @summary: Track shipment
|
|
4413
4225
|
* @description: Retrieve courier partner tracking details for a given shipment Id or AWB number - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/trackShipment/).
|
|
@@ -4473,7 +4285,7 @@ class Order {
|
|
|
4473
4285
|
|
|
4474
4286
|
const {
|
|
4475
4287
|
error: res_error,
|
|
4476
|
-
} = OrderPlatformModel.
|
|
4288
|
+
} = OrderPlatformModel.CourierPartnerTrackingResponse().validate(
|
|
4477
4289
|
responseData,
|
|
4478
4290
|
{ abortEarly: false, allowUnknown: true }
|
|
4479
4291
|
);
|
|
@@ -4496,19 +4308,44 @@ class Order {
|
|
|
4496
4308
|
* @param {OrderPlatformValidator.UpdateAddressParam} arg - Arg object
|
|
4497
4309
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4498
4310
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4499
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4311
|
+
* @returns {Promise<OrderPlatformModel.BaseResponse>} - Success response
|
|
4500
4312
|
* @name updateAddress
|
|
4501
4313
|
* @summary: Update shipment address
|
|
4502
|
-
* @description:
|
|
4314
|
+
* @description: Modify the address details of an existing shipment - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/updateAddress/).
|
|
4503
4315
|
*/
|
|
4504
4316
|
async updateAddress(
|
|
4505
|
-
{
|
|
4317
|
+
{
|
|
4318
|
+
shipmentId,
|
|
4319
|
+
addressCategory,
|
|
4320
|
+
name,
|
|
4321
|
+
address,
|
|
4322
|
+
addressType,
|
|
4323
|
+
pincode,
|
|
4324
|
+
phone,
|
|
4325
|
+
email,
|
|
4326
|
+
landmark,
|
|
4327
|
+
city,
|
|
4328
|
+
state,
|
|
4329
|
+
country,
|
|
4330
|
+
requestHeaders,
|
|
4331
|
+
} = { requestHeaders: {} },
|
|
4506
4332
|
{ responseHeaders } = { responseHeaders: false }
|
|
4507
4333
|
) {
|
|
4508
4334
|
const { error } = OrderPlatformValidator.updateAddress().validate(
|
|
4509
4335
|
{
|
|
4510
4336
|
shipmentId,
|
|
4511
|
-
|
|
4337
|
+
addressCategory,
|
|
4338
|
+
|
|
4339
|
+
name,
|
|
4340
|
+
address,
|
|
4341
|
+
addressType,
|
|
4342
|
+
pincode,
|
|
4343
|
+
phone,
|
|
4344
|
+
email,
|
|
4345
|
+
landmark,
|
|
4346
|
+
city,
|
|
4347
|
+
state,
|
|
4348
|
+
country,
|
|
4512
4349
|
},
|
|
4513
4350
|
{ abortEarly: false, allowUnknown: true }
|
|
4514
4351
|
);
|
|
@@ -4520,7 +4357,18 @@ class Order {
|
|
|
4520
4357
|
const { error: warrning } = OrderPlatformValidator.updateAddress().validate(
|
|
4521
4358
|
{
|
|
4522
4359
|
shipmentId,
|
|
4523
|
-
|
|
4360
|
+
addressCategory,
|
|
4361
|
+
|
|
4362
|
+
name,
|
|
4363
|
+
address,
|
|
4364
|
+
addressType,
|
|
4365
|
+
pincode,
|
|
4366
|
+
phone,
|
|
4367
|
+
email,
|
|
4368
|
+
landmark,
|
|
4369
|
+
city,
|
|
4370
|
+
state,
|
|
4371
|
+
country,
|
|
4524
4372
|
},
|
|
4525
4373
|
{ abortEarly: false, allowUnknown: false }
|
|
4526
4374
|
);
|
|
@@ -4532,15 +4380,27 @@ class Order {
|
|
|
4532
4380
|
}
|
|
4533
4381
|
|
|
4534
4382
|
const query_params = {};
|
|
4383
|
+
query_params["shipment_id"] = shipmentId;
|
|
4384
|
+
query_params["name"] = name;
|
|
4385
|
+
query_params["address"] = address;
|
|
4386
|
+
query_params["address_type"] = addressType;
|
|
4387
|
+
query_params["pincode"] = pincode;
|
|
4388
|
+
query_params["phone"] = phone;
|
|
4389
|
+
query_params["email"] = email;
|
|
4390
|
+
query_params["landmark"] = landmark;
|
|
4391
|
+
query_params["address_category"] = addressCategory;
|
|
4392
|
+
query_params["city"] = city;
|
|
4393
|
+
query_params["state"] = state;
|
|
4394
|
+
query_params["country"] = country;
|
|
4535
4395
|
|
|
4536
4396
|
const xHeaders = {};
|
|
4537
4397
|
|
|
4538
4398
|
const response = await PlatformAPIClient.execute(
|
|
4539
4399
|
this.config,
|
|
4540
|
-
"
|
|
4541
|
-
`/service/platform/order-manage/v1.0/company/${this.config.companyId}/
|
|
4400
|
+
"post",
|
|
4401
|
+
`/service/platform/order-manage/v1.0/company/${this.config.companyId}/delight/update-address`,
|
|
4542
4402
|
query_params,
|
|
4543
|
-
|
|
4403
|
+
undefined,
|
|
4544
4404
|
{ ...xHeaders, ...requestHeaders },
|
|
4545
4405
|
{ responseHeaders }
|
|
4546
4406
|
);
|
|
@@ -4552,7 +4412,7 @@ class Order {
|
|
|
4552
4412
|
|
|
4553
4413
|
const {
|
|
4554
4414
|
error: res_error,
|
|
4555
|
-
} = OrderPlatformModel.
|
|
4415
|
+
} = OrderPlatformModel.BaseResponse().validate(responseData, {
|
|
4556
4416
|
abortEarly: false,
|
|
4557
4417
|
allowUnknown: true,
|
|
4558
4418
|
});
|
|
@@ -4575,7 +4435,7 @@ class Order {
|
|
|
4575
4435
|
* @param {OrderPlatformValidator.UpdatePackagingDimensionsParam} arg - Arg object
|
|
4576
4436
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4577
4437
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4578
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4438
|
+
* @returns {Promise<OrderPlatformModel.UpdatePackagingDimensionsResponse>}
|
|
4579
4439
|
* - Success response
|
|
4580
4440
|
*
|
|
4581
4441
|
* @name updatePackagingDimensions
|
|
@@ -4635,7 +4495,7 @@ class Order {
|
|
|
4635
4495
|
|
|
4636
4496
|
const {
|
|
4637
4497
|
error: res_error,
|
|
4638
|
-
} = OrderPlatformModel.
|
|
4498
|
+
} = OrderPlatformModel.UpdatePackagingDimensionsResponse().validate(
|
|
4639
4499
|
responseData,
|
|
4640
4500
|
{ abortEarly: false, allowUnknown: true }
|
|
4641
4501
|
);
|
|
@@ -4654,90 +4514,12 @@ class Order {
|
|
|
4654
4514
|
return response;
|
|
4655
4515
|
}
|
|
4656
4516
|
|
|
4657
|
-
/**
|
|
4658
|
-
* @param {OrderPlatformValidator.UpdatePaymentInfoParam} arg - Arg object
|
|
4659
|
-
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4660
|
-
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4661
|
-
* @returns {Promise<Object>} - Success response
|
|
4662
|
-
* @name updatePaymentInfo
|
|
4663
|
-
* @summary: Update payment details for an order, its shipments and its bags.
|
|
4664
|
-
* @description: Updates the payment mode for an order, its shipments and its bags. This endpoint allows for modifying payment methods, and associated details but not amount. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/updatePaymentInfo/).
|
|
4665
|
-
*/
|
|
4666
|
-
async updatePaymentInfo(
|
|
4667
|
-
{ body, requestHeaders } = { requestHeaders: {} },
|
|
4668
|
-
{ responseHeaders } = { responseHeaders: false }
|
|
4669
|
-
) {
|
|
4670
|
-
const { error } = OrderPlatformValidator.updatePaymentInfo().validate(
|
|
4671
|
-
{
|
|
4672
|
-
body,
|
|
4673
|
-
},
|
|
4674
|
-
{ abortEarly: false, allowUnknown: true }
|
|
4675
|
-
);
|
|
4676
|
-
if (error) {
|
|
4677
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
4678
|
-
}
|
|
4679
|
-
|
|
4680
|
-
// Showing warrnings if extra unknown parameters are found
|
|
4681
|
-
const {
|
|
4682
|
-
error: warrning,
|
|
4683
|
-
} = OrderPlatformValidator.updatePaymentInfo().validate(
|
|
4684
|
-
{
|
|
4685
|
-
body,
|
|
4686
|
-
},
|
|
4687
|
-
{ abortEarly: false, allowUnknown: false }
|
|
4688
|
-
);
|
|
4689
|
-
if (warrning) {
|
|
4690
|
-
Logger({
|
|
4691
|
-
level: "WARN",
|
|
4692
|
-
message: `Parameter Validation warrnings for platform > Order > updatePaymentInfo \n ${warrning}`,
|
|
4693
|
-
});
|
|
4694
|
-
}
|
|
4695
|
-
|
|
4696
|
-
const query_params = {};
|
|
4697
|
-
|
|
4698
|
-
const xHeaders = {};
|
|
4699
|
-
|
|
4700
|
-
const response = await PlatformAPIClient.execute(
|
|
4701
|
-
this.config,
|
|
4702
|
-
"put",
|
|
4703
|
-
`/service/platform/order-manage/v1.0/company/${this.config.companyId}/payment/update`,
|
|
4704
|
-
query_params,
|
|
4705
|
-
body,
|
|
4706
|
-
{ ...xHeaders, ...requestHeaders },
|
|
4707
|
-
{ responseHeaders }
|
|
4708
|
-
);
|
|
4709
|
-
|
|
4710
|
-
let responseData = response;
|
|
4711
|
-
if (responseHeaders) {
|
|
4712
|
-
responseData = response[0];
|
|
4713
|
-
}
|
|
4714
|
-
|
|
4715
|
-
const { error: res_error } = Joi.any().validate(responseData, {
|
|
4716
|
-
abortEarly: false,
|
|
4717
|
-
allowUnknown: true,
|
|
4718
|
-
});
|
|
4719
|
-
|
|
4720
|
-
if (res_error) {
|
|
4721
|
-
if (this.config.options.strictResponseCheck === true) {
|
|
4722
|
-
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
4723
|
-
} else {
|
|
4724
|
-
Logger({
|
|
4725
|
-
level: "WARN",
|
|
4726
|
-
message: `Response Validation Warnings for platform > Order > updatePaymentInfo \n ${res_error}`,
|
|
4727
|
-
});
|
|
4728
|
-
}
|
|
4729
|
-
}
|
|
4730
|
-
|
|
4731
|
-
return response;
|
|
4732
|
-
}
|
|
4733
|
-
|
|
4734
4517
|
/**
|
|
4735
4518
|
* @param {OrderPlatformValidator.UpdateShipmentLockParam} arg - Arg object
|
|
4736
4519
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4737
4520
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4738
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4739
|
-
*
|
|
4740
|
-
*
|
|
4521
|
+
* @returns {Promise<OrderPlatformModel.UpdateShipmentLockResponse>} -
|
|
4522
|
+
* Success response
|
|
4741
4523
|
* @name updateShipmentLock
|
|
4742
4524
|
* @summary: Update a shipment lock
|
|
4743
4525
|
* @description: Modify shipment/bag lock status and update lock/unlock messages. - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/updateShipmentLock/).
|
|
@@ -4793,10 +4575,10 @@ class Order {
|
|
|
4793
4575
|
|
|
4794
4576
|
const {
|
|
4795
4577
|
error: res_error,
|
|
4796
|
-
} = OrderPlatformModel.
|
|
4797
|
-
|
|
4798
|
-
|
|
4799
|
-
);
|
|
4578
|
+
} = OrderPlatformModel.UpdateShipmentLockResponse().validate(responseData, {
|
|
4579
|
+
abortEarly: false,
|
|
4580
|
+
allowUnknown: true,
|
|
4581
|
+
});
|
|
4800
4582
|
|
|
4801
4583
|
if (res_error) {
|
|
4802
4584
|
if (this.config.options.strictResponseCheck === true) {
|
|
@@ -4977,7 +4759,7 @@ class Order {
|
|
|
4977
4759
|
* @param {OrderPlatformValidator.UploadConsentsParam} arg - Arg object
|
|
4978
4760
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
4979
4761
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
4980
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4762
|
+
* @returns {Promise<OrderPlatformModel.SuccessResponse>} - Success response
|
|
4981
4763
|
* @name uploadConsents
|
|
4982
4764
|
* @summary: Upload consent
|
|
4983
4765
|
* @description: Uploads the consent signed by courier partner and seller to keep records - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/uploadConsents/).
|
|
@@ -5033,7 +4815,7 @@ class Order {
|
|
|
5033
4815
|
|
|
5034
4816
|
const {
|
|
5035
4817
|
error: res_error,
|
|
5036
|
-
} = OrderPlatformModel.
|
|
4818
|
+
} = OrderPlatformModel.SuccessResponse().validate(responseData, {
|
|
5037
4819
|
abortEarly: false,
|
|
5038
4820
|
allowUnknown: true,
|
|
5039
4821
|
});
|
|
@@ -5056,7 +4838,7 @@ class Order {
|
|
|
5056
4838
|
* @param {OrderPlatformValidator.VerifyMobileOTPParam} arg - Arg object
|
|
5057
4839
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
5058
4840
|
* @param {import("../PlatformAPIClient").Options} - Options
|
|
5059
|
-
* @returns {Promise<OrderPlatformModel.
|
|
4841
|
+
* @returns {Promise<OrderPlatformModel.VerifyOtpResponse>} - Success response
|
|
5060
4842
|
* @name verifyMobileOTP
|
|
5061
4843
|
* @summary: Verify mobile OTP
|
|
5062
4844
|
* @description: Perform OTP verification to link a user to an anonymous order - Check out [method documentation](https://partners.fynd.com/help/docs/sdk/platform/order/verifyMobileOTP/).
|
|
@@ -5112,7 +4894,7 @@ class Order {
|
|
|
5112
4894
|
|
|
5113
4895
|
const {
|
|
5114
4896
|
error: res_error,
|
|
5115
|
-
} = OrderPlatformModel.
|
|
4897
|
+
} = OrderPlatformModel.VerifyOtpResponse().validate(responseData, {
|
|
5116
4898
|
abortEarly: false,
|
|
5117
4899
|
allowUnknown: true,
|
|
5118
4900
|
});
|