@gofynd/fdk-client-javascript 1.5.1 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +1 -1
- package/sdk/application/Cart/CartApplicationClient.js +293 -0
- package/sdk/application/Catalog/CatalogApplicationClient.js +408 -0
- package/sdk/application/Common/CommonApplicationClient.js +21 -0
- package/sdk/application/Communication/CommunicationApplicationClient.js +29 -0
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +147 -0
- package/sdk/application/Content/ContentApplicationClient.js +226 -0
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +43 -0
- package/sdk/application/Finance/FinanceApplicationClient.js +21 -0
- package/sdk/application/Lead/LeadApplicationClient.js +73 -0
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +1 -1
- package/sdk/application/Logistic/LogisticApplicationClient.js +192 -3
- package/sdk/application/Order/OrderApplicationClient.js +202 -0
- package/sdk/application/Payment/PaymentApplicationClient.js +454 -0
- package/sdk/application/Rewards/RewardsApplicationClient.js +68 -0
- package/sdk/application/Share/ShareApplicationClient.js +96 -0
- package/sdk/application/Theme/ThemeApplicationClient.js +64 -0
- package/sdk/application/User/UserApplicationClient.js +412 -0
- package/sdk/application/Webhook/WebhookApplicationClient.js +13 -0
- package/sdk/partner/FileStorage/FileStoragePartnerClient.d.ts +10 -0
- package/sdk/partner/FileStorage/FileStoragePartnerClient.js +75 -0
- package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +54 -1
- package/sdk/partner/FileStorage/FileStoragePartnerModel.js +43 -0
- package/sdk/partner/FileStorage/FileStoragePartnerValidator.d.ts +1 -0
- package/sdk/partner/FileStorage/FileStoragePartnerValidator.js +6 -0
- package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +16 -3
- package/sdk/partner/Webhook/WebhookPartnerModel.js +5 -3
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.d.ts +4 -1
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.js +1 -1
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +46 -23
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +12 -23
- package/sdk/platform/Cart/CartPlatformModel.d.ts +59 -1
- package/sdk/platform/Cart/CartPlatformModel.js +31 -0
- package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +0 -12
- package/sdk/platform/Content/ContentPlatformApplicationClient.js +0 -81
- package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +1 -10
- package/sdk/platform/Content/ContentPlatformApplicationValidator.js +0 -12
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +13 -0
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +82 -0
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +10 -1
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +12 -0
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +129 -1
- package/sdk/platform/Payment/PaymentPlatformModel.js +94 -0
- package/sdk/platform/User/UserPlatformModel.d.ts +2 -2
- package/sdk/platform/User/UserPlatformModel.js +2 -2
- package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +58 -14
- package/sdk/platform/Webhook/WebhookPlatformModel.js +15 -14
- package/sdk/public/Catalog/CatalogPublicClient.d.ts +22 -0
- package/sdk/public/Catalog/CatalogPublicClient.js +138 -0
- package/sdk/public/Catalog/CatalogPublicModel.d.ts +155 -0
- package/sdk/public/Catalog/CatalogPublicModel.js +116 -0
- package/sdk/public/Catalog/CatalogPublicValidator.d.ts +55 -0
- package/sdk/public/Catalog/CatalogPublicValidator.js +35 -0
- package/sdk/public/Configuration/ConfigurationPublicClient.js +16 -0
- package/sdk/public/Content/ContentPublicClient.js +116 -0
- package/sdk/public/Partner/PartnerPublicClient.js +15 -0
- package/sdk/public/PublicClient.d.ts +2 -0
- package/sdk/public/PublicClient.js +4 -0
- package/sdk/public/Webhook/WebhookPublicClient.js +40 -0
- package/sdk/public/Webhook/WebhookPublicModel.d.ts +194 -46
- package/sdk/public/Webhook/WebhookPublicModel.js +51 -46
- package/sdk/public/index.d.ts +1 -0
- package/sdk/public/index.js +2 -0
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
const {
|
|
2
|
+
FDKClientValidationError,
|
|
3
|
+
FDKResponseValidationError,
|
|
4
|
+
} = require("../../common/FDKError");
|
|
5
|
+
|
|
1
6
|
const ApplicationAPIClient = require("../ApplicationAPIClient");
|
|
2
7
|
const constructUrl = require("../constructUrl");
|
|
3
8
|
const Paginator = require("../../common/Paginator");
|
|
@@ -55,6 +60,14 @@ class Configuration {
|
|
|
55
60
|
{ requestHeaders } = { requestHeaders: {} },
|
|
56
61
|
{ responseHeaders } = { responseHeaders: false }
|
|
57
62
|
) {
|
|
63
|
+
let invalidInput = [];
|
|
64
|
+
if (invalidInput.length) {
|
|
65
|
+
const error = new Error();
|
|
66
|
+
error.message = "Missing required field";
|
|
67
|
+
error.details = invalidInput;
|
|
68
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
69
|
+
}
|
|
70
|
+
|
|
58
71
|
const query_params = {};
|
|
59
72
|
|
|
60
73
|
const xHeaders = {};
|
|
@@ -100,6 +113,14 @@ class Configuration {
|
|
|
100
113
|
} = { requestHeaders: {} },
|
|
101
114
|
{ responseHeaders } = { responseHeaders: false }
|
|
102
115
|
) {
|
|
116
|
+
let invalidInput = [];
|
|
117
|
+
if (invalidInput.length) {
|
|
118
|
+
const error = new Error();
|
|
119
|
+
error.message = "Missing required field";
|
|
120
|
+
error.details = invalidInput;
|
|
121
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
122
|
+
}
|
|
123
|
+
|
|
103
124
|
const query_params = {};
|
|
104
125
|
query_params["page_no"] = pageNo;
|
|
105
126
|
query_params["page_size"] = pageSize;
|
|
@@ -145,6 +166,14 @@ class Configuration {
|
|
|
145
166
|
},
|
|
146
167
|
{ responseHeaders } = { responseHeaders: false }
|
|
147
168
|
) {
|
|
169
|
+
let invalidInput = [];
|
|
170
|
+
if (invalidInput.length) {
|
|
171
|
+
const error = new Error();
|
|
172
|
+
error.message = "Missing required field";
|
|
173
|
+
error.details = invalidInput;
|
|
174
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
175
|
+
}
|
|
176
|
+
|
|
148
177
|
const query_params = {};
|
|
149
178
|
query_params["order_incent"] = orderIncent;
|
|
150
179
|
query_params["ordering_store"] = orderingStore;
|
|
@@ -185,6 +214,14 @@ class Configuration {
|
|
|
185
214
|
{ requestHeaders } = { requestHeaders: {} },
|
|
186
215
|
{ responseHeaders } = { responseHeaders: false }
|
|
187
216
|
) {
|
|
217
|
+
let invalidInput = [];
|
|
218
|
+
if (invalidInput.length) {
|
|
219
|
+
const error = new Error();
|
|
220
|
+
error.message = "Missing required field";
|
|
221
|
+
error.details = invalidInput;
|
|
222
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
223
|
+
}
|
|
224
|
+
|
|
188
225
|
const query_params = {};
|
|
189
226
|
|
|
190
227
|
const xHeaders = {};
|
|
@@ -222,6 +259,14 @@ class Configuration {
|
|
|
222
259
|
{ requestHeaders } = { requestHeaders: {} },
|
|
223
260
|
{ responseHeaders } = { responseHeaders: false }
|
|
224
261
|
) {
|
|
262
|
+
let invalidInput = [];
|
|
263
|
+
if (invalidInput.length) {
|
|
264
|
+
const error = new Error();
|
|
265
|
+
error.message = "Missing required field";
|
|
266
|
+
error.details = invalidInput;
|
|
267
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
268
|
+
}
|
|
269
|
+
|
|
225
270
|
const query_params = {};
|
|
226
271
|
|
|
227
272
|
const xHeaders = {};
|
|
@@ -259,6 +304,14 @@ class Configuration {
|
|
|
259
304
|
{ requestHeaders } = { requestHeaders: {} },
|
|
260
305
|
{ responseHeaders } = { responseHeaders: false }
|
|
261
306
|
) {
|
|
307
|
+
let invalidInput = [];
|
|
308
|
+
if (invalidInput.length) {
|
|
309
|
+
const error = new Error();
|
|
310
|
+
error.message = "Missing required field";
|
|
311
|
+
error.details = invalidInput;
|
|
312
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
313
|
+
}
|
|
314
|
+
|
|
262
315
|
const query_params = {};
|
|
263
316
|
|
|
264
317
|
const xHeaders = {};
|
|
@@ -296,6 +349,14 @@ class Configuration {
|
|
|
296
349
|
{ requestHeaders } = { requestHeaders: {} },
|
|
297
350
|
{ responseHeaders } = { responseHeaders: false }
|
|
298
351
|
) {
|
|
352
|
+
let invalidInput = [];
|
|
353
|
+
if (invalidInput.length) {
|
|
354
|
+
const error = new Error();
|
|
355
|
+
error.message = "Missing required field";
|
|
356
|
+
error.details = invalidInput;
|
|
357
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
358
|
+
}
|
|
359
|
+
|
|
299
360
|
const query_params = {};
|
|
300
361
|
|
|
301
362
|
const xHeaders = {};
|
|
@@ -333,6 +394,21 @@ class Configuration {
|
|
|
333
394
|
{ id, requestHeaders } = { requestHeaders: {} },
|
|
334
395
|
{ responseHeaders } = { responseHeaders: false }
|
|
335
396
|
) {
|
|
397
|
+
let invalidInput = [];
|
|
398
|
+
|
|
399
|
+
if (!id) {
|
|
400
|
+
invalidInput.push({
|
|
401
|
+
message: `The 'id' field is required.`,
|
|
402
|
+
path: ["id"],
|
|
403
|
+
});
|
|
404
|
+
}
|
|
405
|
+
if (invalidInput.length) {
|
|
406
|
+
const error = new Error();
|
|
407
|
+
error.message = "Missing required field";
|
|
408
|
+
error.details = invalidInput;
|
|
409
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
410
|
+
}
|
|
411
|
+
|
|
336
412
|
const query_params = {};
|
|
337
413
|
|
|
338
414
|
const xHeaders = {};
|
|
@@ -370,6 +446,14 @@ class Configuration {
|
|
|
370
446
|
{ requestHeaders } = { requestHeaders: {} },
|
|
371
447
|
{ responseHeaders } = { responseHeaders: false }
|
|
372
448
|
) {
|
|
449
|
+
let invalidInput = [];
|
|
450
|
+
if (invalidInput.length) {
|
|
451
|
+
const error = new Error();
|
|
452
|
+
error.message = "Missing required field";
|
|
453
|
+
error.details = invalidInput;
|
|
454
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
455
|
+
}
|
|
456
|
+
|
|
373
457
|
const query_params = {};
|
|
374
458
|
|
|
375
459
|
const xHeaders = {};
|
|
@@ -407,6 +491,14 @@ class Configuration {
|
|
|
407
491
|
{ requestHeaders } = { requestHeaders: {} },
|
|
408
492
|
{ responseHeaders } = { responseHeaders: false }
|
|
409
493
|
) {
|
|
494
|
+
let invalidInput = [];
|
|
495
|
+
if (invalidInput.length) {
|
|
496
|
+
const error = new Error();
|
|
497
|
+
error.message = "Missing required field";
|
|
498
|
+
error.details = invalidInput;
|
|
499
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
500
|
+
}
|
|
501
|
+
|
|
410
502
|
const query_params = {};
|
|
411
503
|
|
|
412
504
|
const xHeaders = {};
|
|
@@ -444,6 +536,14 @@ class Configuration {
|
|
|
444
536
|
{ requestHeaders } = { requestHeaders: {} },
|
|
445
537
|
{ responseHeaders } = { responseHeaders: false }
|
|
446
538
|
) {
|
|
539
|
+
let invalidInput = [];
|
|
540
|
+
if (invalidInput.length) {
|
|
541
|
+
const error = new Error();
|
|
542
|
+
error.message = "Missing required field";
|
|
543
|
+
error.details = invalidInput;
|
|
544
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
545
|
+
}
|
|
546
|
+
|
|
447
547
|
const query_params = {};
|
|
448
548
|
|
|
449
549
|
const xHeaders = {};
|
|
@@ -481,6 +581,14 @@ class Configuration {
|
|
|
481
581
|
{ body, requestHeaders } = { requestHeaders: {} },
|
|
482
582
|
{ responseHeaders } = { responseHeaders: false }
|
|
483
583
|
) {
|
|
584
|
+
let invalidInput = [];
|
|
585
|
+
if (invalidInput.length) {
|
|
586
|
+
const error = new Error();
|
|
587
|
+
error.message = "Missing required field";
|
|
588
|
+
error.details = invalidInput;
|
|
589
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
590
|
+
}
|
|
591
|
+
|
|
484
592
|
const query_params = {};
|
|
485
593
|
|
|
486
594
|
const xHeaders = {};
|
|
@@ -518,6 +626,14 @@ class Configuration {
|
|
|
518
626
|
{ pageNo, pageSize, q, requestHeaders } = { requestHeaders: {} },
|
|
519
627
|
{ responseHeaders } = { responseHeaders: false }
|
|
520
628
|
) {
|
|
629
|
+
let invalidInput = [];
|
|
630
|
+
if (invalidInput.length) {
|
|
631
|
+
const error = new Error();
|
|
632
|
+
error.message = "Missing required field";
|
|
633
|
+
error.details = invalidInput;
|
|
634
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
635
|
+
}
|
|
636
|
+
|
|
521
637
|
const query_params = {};
|
|
522
638
|
query_params["page_no"] = pageNo;
|
|
523
639
|
query_params["page_size"] = pageSize;
|
|
@@ -558,6 +674,14 @@ class Configuration {
|
|
|
558
674
|
{ requestHeaders } = { requestHeaders: {} },
|
|
559
675
|
{ responseHeaders } = { responseHeaders: false }
|
|
560
676
|
) {
|
|
677
|
+
let invalidInput = [];
|
|
678
|
+
if (invalidInput.length) {
|
|
679
|
+
const error = new Error();
|
|
680
|
+
error.message = "Missing required field";
|
|
681
|
+
error.details = invalidInput;
|
|
682
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
683
|
+
}
|
|
684
|
+
|
|
561
685
|
const query_params = {};
|
|
562
686
|
|
|
563
687
|
const xHeaders = {};
|
|
@@ -595,6 +719,21 @@ class Configuration {
|
|
|
595
719
|
{ storeId, requestHeaders } = { requestHeaders: {} },
|
|
596
720
|
{ responseHeaders } = { responseHeaders: false }
|
|
597
721
|
) {
|
|
722
|
+
let invalidInput = [];
|
|
723
|
+
|
|
724
|
+
if (!storeId) {
|
|
725
|
+
invalidInput.push({
|
|
726
|
+
message: `The 'storeId' field is required.`,
|
|
727
|
+
path: ["storeId"],
|
|
728
|
+
});
|
|
729
|
+
}
|
|
730
|
+
if (invalidInput.length) {
|
|
731
|
+
const error = new Error();
|
|
732
|
+
error.message = "Missing required field";
|
|
733
|
+
error.details = invalidInput;
|
|
734
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
735
|
+
}
|
|
736
|
+
|
|
598
737
|
const query_params = {};
|
|
599
738
|
|
|
600
739
|
const xHeaders = {};
|
|
@@ -632,6 +771,14 @@ class Configuration {
|
|
|
632
771
|
{ requestHeaders } = { requestHeaders: {} },
|
|
633
772
|
{ responseHeaders } = { responseHeaders: false }
|
|
634
773
|
) {
|
|
774
|
+
let invalidInput = [];
|
|
775
|
+
if (invalidInput.length) {
|
|
776
|
+
const error = new Error();
|
|
777
|
+
error.message = "Missing required field";
|
|
778
|
+
error.details = invalidInput;
|
|
779
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
780
|
+
}
|
|
781
|
+
|
|
635
782
|
const query_params = {};
|
|
636
783
|
|
|
637
784
|
const xHeaders = {};
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
const {
|
|
2
|
+
FDKClientValidationError,
|
|
3
|
+
FDKResponseValidationError,
|
|
4
|
+
} = require("../../common/FDKError");
|
|
5
|
+
|
|
1
6
|
const ApplicationAPIClient = require("../ApplicationAPIClient");
|
|
2
7
|
const constructUrl = require("../constructUrl");
|
|
3
8
|
const Paginator = require("../../common/Paginator");
|
|
@@ -59,6 +64,14 @@ class Content {
|
|
|
59
64
|
{ requestHeaders } = { requestHeaders: {} },
|
|
60
65
|
{ responseHeaders } = { responseHeaders: false }
|
|
61
66
|
) {
|
|
67
|
+
let invalidInput = [];
|
|
68
|
+
if (invalidInput.length) {
|
|
69
|
+
const error = new Error();
|
|
70
|
+
error.message = "Missing required field";
|
|
71
|
+
error.details = invalidInput;
|
|
72
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
73
|
+
}
|
|
74
|
+
|
|
62
75
|
const query_params = {};
|
|
63
76
|
|
|
64
77
|
const xHeaders = {};
|
|
@@ -96,6 +109,21 @@ class Content {
|
|
|
96
109
|
{ slug, rootId, preview, requestHeaders } = { requestHeaders: {} },
|
|
97
110
|
{ responseHeaders } = { responseHeaders: false }
|
|
98
111
|
) {
|
|
112
|
+
let invalidInput = [];
|
|
113
|
+
|
|
114
|
+
if (!slug) {
|
|
115
|
+
invalidInput.push({
|
|
116
|
+
message: `The 'slug' field is required.`,
|
|
117
|
+
path: ["slug"],
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
if (invalidInput.length) {
|
|
121
|
+
const error = new Error();
|
|
122
|
+
error.message = "Missing required field";
|
|
123
|
+
error.details = invalidInput;
|
|
124
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
125
|
+
}
|
|
126
|
+
|
|
99
127
|
const query_params = {};
|
|
100
128
|
query_params["root_id"] = rootId;
|
|
101
129
|
query_params["preview"] = preview;
|
|
@@ -135,6 +163,14 @@ class Content {
|
|
|
135
163
|
{ pageNo, pageSize, tags, search, requestHeaders } = { requestHeaders: {} },
|
|
136
164
|
{ responseHeaders } = { responseHeaders: false }
|
|
137
165
|
) {
|
|
166
|
+
let invalidInput = [];
|
|
167
|
+
if (invalidInput.length) {
|
|
168
|
+
const error = new Error();
|
|
169
|
+
error.message = "Missing required field";
|
|
170
|
+
error.details = invalidInput;
|
|
171
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
172
|
+
}
|
|
173
|
+
|
|
138
174
|
const query_params = {};
|
|
139
175
|
query_params["page_no"] = pageNo;
|
|
140
176
|
query_params["page_size"] = pageSize;
|
|
@@ -176,6 +212,27 @@ class Content {
|
|
|
176
212
|
{ resource, resourceSlug, requestHeaders } = { requestHeaders: {} },
|
|
177
213
|
{ responseHeaders } = { responseHeaders: false }
|
|
178
214
|
) {
|
|
215
|
+
let invalidInput = [];
|
|
216
|
+
|
|
217
|
+
if (!resource) {
|
|
218
|
+
invalidInput.push({
|
|
219
|
+
message: `The 'resource' field is required.`,
|
|
220
|
+
path: ["resource"],
|
|
221
|
+
});
|
|
222
|
+
}
|
|
223
|
+
if (!resourceSlug) {
|
|
224
|
+
invalidInput.push({
|
|
225
|
+
message: `The 'resourceSlug' field is required.`,
|
|
226
|
+
path: ["resourceSlug"],
|
|
227
|
+
});
|
|
228
|
+
}
|
|
229
|
+
if (invalidInput.length) {
|
|
230
|
+
const error = new Error();
|
|
231
|
+
error.message = "Missing required field";
|
|
232
|
+
error.details = invalidInput;
|
|
233
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
234
|
+
}
|
|
235
|
+
|
|
179
236
|
const query_params = {};
|
|
180
237
|
|
|
181
238
|
const xHeaders = {};
|
|
@@ -213,6 +270,27 @@ class Content {
|
|
|
213
270
|
{ definitionSlug, slug, requestHeaders } = { requestHeaders: {} },
|
|
214
271
|
{ responseHeaders } = { responseHeaders: false }
|
|
215
272
|
) {
|
|
273
|
+
let invalidInput = [];
|
|
274
|
+
|
|
275
|
+
if (!definitionSlug) {
|
|
276
|
+
invalidInput.push({
|
|
277
|
+
message: `The 'definitionSlug' field is required.`,
|
|
278
|
+
path: ["definitionSlug"],
|
|
279
|
+
});
|
|
280
|
+
}
|
|
281
|
+
if (!slug) {
|
|
282
|
+
invalidInput.push({
|
|
283
|
+
message: `The 'slug' field is required.`,
|
|
284
|
+
path: ["slug"],
|
|
285
|
+
});
|
|
286
|
+
}
|
|
287
|
+
if (invalidInput.length) {
|
|
288
|
+
const error = new Error();
|
|
289
|
+
error.message = "Missing required field";
|
|
290
|
+
error.details = invalidInput;
|
|
291
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
292
|
+
}
|
|
293
|
+
|
|
216
294
|
const query_params = {};
|
|
217
295
|
|
|
218
296
|
const xHeaders = {};
|
|
@@ -250,6 +328,14 @@ class Content {
|
|
|
250
328
|
{ requestHeaders } = { requestHeaders: {} },
|
|
251
329
|
{ responseHeaders } = { responseHeaders: false }
|
|
252
330
|
) {
|
|
331
|
+
let invalidInput = [];
|
|
332
|
+
if (invalidInput.length) {
|
|
333
|
+
const error = new Error();
|
|
334
|
+
error.message = "Missing required field";
|
|
335
|
+
error.details = invalidInput;
|
|
336
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
337
|
+
}
|
|
338
|
+
|
|
253
339
|
const query_params = {};
|
|
254
340
|
|
|
255
341
|
const xHeaders = {};
|
|
@@ -287,6 +373,21 @@ class Content {
|
|
|
287
373
|
{ slug, requestHeaders } = { requestHeaders: {} },
|
|
288
374
|
{ responseHeaders } = { responseHeaders: false }
|
|
289
375
|
) {
|
|
376
|
+
let invalidInput = [];
|
|
377
|
+
|
|
378
|
+
if (!slug) {
|
|
379
|
+
invalidInput.push({
|
|
380
|
+
message: `The 'slug' field is required.`,
|
|
381
|
+
path: ["slug"],
|
|
382
|
+
});
|
|
383
|
+
}
|
|
384
|
+
if (invalidInput.length) {
|
|
385
|
+
const error = new Error();
|
|
386
|
+
error.message = "Missing required field";
|
|
387
|
+
error.details = invalidInput;
|
|
388
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
389
|
+
}
|
|
390
|
+
|
|
290
391
|
const query_params = {};
|
|
291
392
|
|
|
292
393
|
const xHeaders = {};
|
|
@@ -324,6 +425,14 @@ class Content {
|
|
|
324
425
|
{ requestHeaders } = { requestHeaders: {} },
|
|
325
426
|
{ responseHeaders } = { responseHeaders: false }
|
|
326
427
|
) {
|
|
428
|
+
let invalidInput = [];
|
|
429
|
+
if (invalidInput.length) {
|
|
430
|
+
const error = new Error();
|
|
431
|
+
error.message = "Missing required field";
|
|
432
|
+
error.details = invalidInput;
|
|
433
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
434
|
+
}
|
|
435
|
+
|
|
327
436
|
const query_params = {};
|
|
328
437
|
|
|
329
438
|
const xHeaders = {};
|
|
@@ -361,6 +470,21 @@ class Content {
|
|
|
361
470
|
{ slug, requestHeaders } = { requestHeaders: {} },
|
|
362
471
|
{ responseHeaders } = { responseHeaders: false }
|
|
363
472
|
) {
|
|
473
|
+
let invalidInput = [];
|
|
474
|
+
|
|
475
|
+
if (!slug) {
|
|
476
|
+
invalidInput.push({
|
|
477
|
+
message: `The 'slug' field is required.`,
|
|
478
|
+
path: ["slug"],
|
|
479
|
+
});
|
|
480
|
+
}
|
|
481
|
+
if (invalidInput.length) {
|
|
482
|
+
const error = new Error();
|
|
483
|
+
error.message = "Missing required field";
|
|
484
|
+
error.details = invalidInput;
|
|
485
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
486
|
+
}
|
|
487
|
+
|
|
364
488
|
const query_params = {};
|
|
365
489
|
|
|
366
490
|
const xHeaders = {};
|
|
@@ -398,6 +522,14 @@ class Content {
|
|
|
398
522
|
{ requestHeaders } = { requestHeaders: {} },
|
|
399
523
|
{ responseHeaders } = { responseHeaders: false }
|
|
400
524
|
) {
|
|
525
|
+
let invalidInput = [];
|
|
526
|
+
if (invalidInput.length) {
|
|
527
|
+
const error = new Error();
|
|
528
|
+
error.message = "Missing required field";
|
|
529
|
+
error.details = invalidInput;
|
|
530
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
531
|
+
}
|
|
532
|
+
|
|
401
533
|
const query_params = {};
|
|
402
534
|
|
|
403
535
|
const xHeaders = {};
|
|
@@ -435,6 +567,21 @@ class Content {
|
|
|
435
567
|
{ slug, requestHeaders } = { requestHeaders: {} },
|
|
436
568
|
{ responseHeaders } = { responseHeaders: false }
|
|
437
569
|
) {
|
|
570
|
+
let invalidInput = [];
|
|
571
|
+
|
|
572
|
+
if (!slug) {
|
|
573
|
+
invalidInput.push({
|
|
574
|
+
message: `The 'slug' field is required.`,
|
|
575
|
+
path: ["slug"],
|
|
576
|
+
});
|
|
577
|
+
}
|
|
578
|
+
if (invalidInput.length) {
|
|
579
|
+
const error = new Error();
|
|
580
|
+
error.message = "Missing required field";
|
|
581
|
+
error.details = invalidInput;
|
|
582
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
583
|
+
}
|
|
584
|
+
|
|
438
585
|
const query_params = {};
|
|
439
586
|
|
|
440
587
|
const xHeaders = {};
|
|
@@ -472,6 +619,14 @@ class Content {
|
|
|
472
619
|
{ requestHeaders } = { requestHeaders: {} },
|
|
473
620
|
{ responseHeaders } = { responseHeaders: false }
|
|
474
621
|
) {
|
|
622
|
+
let invalidInput = [];
|
|
623
|
+
if (invalidInput.length) {
|
|
624
|
+
const error = new Error();
|
|
625
|
+
error.message = "Missing required field";
|
|
626
|
+
error.details = invalidInput;
|
|
627
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
628
|
+
}
|
|
629
|
+
|
|
475
630
|
const query_params = {};
|
|
476
631
|
|
|
477
632
|
const xHeaders = {};
|
|
@@ -509,6 +664,14 @@ class Content {
|
|
|
509
664
|
{ requestHeaders } = { requestHeaders: {} },
|
|
510
665
|
{ responseHeaders } = { responseHeaders: false }
|
|
511
666
|
) {
|
|
667
|
+
let invalidInput = [];
|
|
668
|
+
if (invalidInput.length) {
|
|
669
|
+
const error = new Error();
|
|
670
|
+
error.message = "Missing required field";
|
|
671
|
+
error.details = invalidInput;
|
|
672
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
673
|
+
}
|
|
674
|
+
|
|
512
675
|
const query_params = {};
|
|
513
676
|
|
|
514
677
|
const xHeaders = {};
|
|
@@ -546,6 +709,14 @@ class Content {
|
|
|
546
709
|
{ pageNo, pageSize, requestHeaders } = { requestHeaders: {} },
|
|
547
710
|
{ responseHeaders } = { responseHeaders: false }
|
|
548
711
|
) {
|
|
712
|
+
let invalidInput = [];
|
|
713
|
+
if (invalidInput.length) {
|
|
714
|
+
const error = new Error();
|
|
715
|
+
error.message = "Missing required field";
|
|
716
|
+
error.details = invalidInput;
|
|
717
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
718
|
+
}
|
|
719
|
+
|
|
549
720
|
const query_params = {};
|
|
550
721
|
query_params["page_no"] = pageNo;
|
|
551
722
|
query_params["page_size"] = pageSize;
|
|
@@ -585,6 +756,21 @@ class Content {
|
|
|
585
756
|
{ slug, rootId, requestHeaders } = { requestHeaders: {} },
|
|
586
757
|
{ responseHeaders } = { responseHeaders: false }
|
|
587
758
|
) {
|
|
759
|
+
let invalidInput = [];
|
|
760
|
+
|
|
761
|
+
if (!slug) {
|
|
762
|
+
invalidInput.push({
|
|
763
|
+
message: `The 'slug' field is required.`,
|
|
764
|
+
path: ["slug"],
|
|
765
|
+
});
|
|
766
|
+
}
|
|
767
|
+
if (invalidInput.length) {
|
|
768
|
+
const error = new Error();
|
|
769
|
+
error.message = "Missing required field";
|
|
770
|
+
error.details = invalidInput;
|
|
771
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
772
|
+
}
|
|
773
|
+
|
|
588
774
|
const query_params = {};
|
|
589
775
|
query_params["root_id"] = rootId;
|
|
590
776
|
|
|
@@ -623,6 +809,14 @@ class Content {
|
|
|
623
809
|
{ pageNo, pageSize, requestHeaders } = { requestHeaders: {} },
|
|
624
810
|
{ responseHeaders } = { responseHeaders: false }
|
|
625
811
|
) {
|
|
812
|
+
let invalidInput = [];
|
|
813
|
+
if (invalidInput.length) {
|
|
814
|
+
const error = new Error();
|
|
815
|
+
error.message = "Missing required field";
|
|
816
|
+
error.details = invalidInput;
|
|
817
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
818
|
+
}
|
|
819
|
+
|
|
626
820
|
const query_params = {};
|
|
627
821
|
query_params["page_no"] = pageNo;
|
|
628
822
|
query_params["page_size"] = pageSize;
|
|
@@ -662,6 +856,14 @@ class Content {
|
|
|
662
856
|
{ requestHeaders } = { requestHeaders: {} },
|
|
663
857
|
{ responseHeaders } = { responseHeaders: false }
|
|
664
858
|
) {
|
|
859
|
+
let invalidInput = [];
|
|
860
|
+
if (invalidInput.length) {
|
|
861
|
+
const error = new Error();
|
|
862
|
+
error.message = "Missing required field";
|
|
863
|
+
error.details = invalidInput;
|
|
864
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
865
|
+
}
|
|
866
|
+
|
|
665
867
|
const query_params = {};
|
|
666
868
|
|
|
667
869
|
const xHeaders = {};
|
|
@@ -699,6 +901,14 @@ class Content {
|
|
|
699
901
|
{ pageType, active, requestHeaders } = { requestHeaders: {} },
|
|
700
902
|
{ responseHeaders } = { responseHeaders: false }
|
|
701
903
|
) {
|
|
904
|
+
let invalidInput = [];
|
|
905
|
+
if (invalidInput.length) {
|
|
906
|
+
const error = new Error();
|
|
907
|
+
error.message = "Missing required field";
|
|
908
|
+
error.details = invalidInput;
|
|
909
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
910
|
+
}
|
|
911
|
+
|
|
702
912
|
const query_params = {};
|
|
703
913
|
query_params["page_type"] = pageType;
|
|
704
914
|
query_params["active"] = active;
|
|
@@ -738,6 +948,14 @@ class Content {
|
|
|
738
948
|
{ requestHeaders } = { requestHeaders: {} },
|
|
739
949
|
{ responseHeaders } = { responseHeaders: false }
|
|
740
950
|
) {
|
|
951
|
+
let invalidInput = [];
|
|
952
|
+
if (invalidInput.length) {
|
|
953
|
+
const error = new Error();
|
|
954
|
+
error.message = "Missing required field";
|
|
955
|
+
error.details = invalidInput;
|
|
956
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
957
|
+
}
|
|
958
|
+
|
|
741
959
|
const query_params = {};
|
|
742
960
|
|
|
743
961
|
const xHeaders = {};
|
|
@@ -775,6 +993,14 @@ class Content {
|
|
|
775
993
|
{ requestHeaders } = { requestHeaders: {} },
|
|
776
994
|
{ responseHeaders } = { responseHeaders: false }
|
|
777
995
|
) {
|
|
996
|
+
let invalidInput = [];
|
|
997
|
+
if (invalidInput.length) {
|
|
998
|
+
const error = new Error();
|
|
999
|
+
error.message = "Missing required field";
|
|
1000
|
+
error.details = invalidInput;
|
|
1001
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
1002
|
+
}
|
|
1003
|
+
|
|
778
1004
|
const query_params = {};
|
|
779
1005
|
|
|
780
1006
|
const xHeaders = {};
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
const {
|
|
2
|
+
FDKClientValidationError,
|
|
3
|
+
FDKResponseValidationError,
|
|
4
|
+
} = require("../../common/FDKError");
|
|
5
|
+
|
|
1
6
|
const ApplicationAPIClient = require("../ApplicationAPIClient");
|
|
2
7
|
const constructUrl = require("../constructUrl");
|
|
3
8
|
const Paginator = require("../../common/Paginator");
|
|
@@ -42,6 +47,21 @@ class FileStorage {
|
|
|
42
47
|
{ namespace, body, requestHeaders } = { requestHeaders: {} },
|
|
43
48
|
{ responseHeaders } = { responseHeaders: false }
|
|
44
49
|
) {
|
|
50
|
+
let invalidInput = [];
|
|
51
|
+
|
|
52
|
+
if (!namespace) {
|
|
53
|
+
invalidInput.push({
|
|
54
|
+
message: `The 'namespace' field is required.`,
|
|
55
|
+
path: ["namespace"],
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
if (invalidInput.length) {
|
|
59
|
+
const error = new Error();
|
|
60
|
+
error.message = "Missing required field";
|
|
61
|
+
error.details = invalidInput;
|
|
62
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
63
|
+
}
|
|
64
|
+
|
|
45
65
|
const query_params = {};
|
|
46
66
|
|
|
47
67
|
const xHeaders = {};
|
|
@@ -79,6 +99,14 @@ class FileStorage {
|
|
|
79
99
|
{ body, requestHeaders } = { requestHeaders: {} },
|
|
80
100
|
{ responseHeaders } = { responseHeaders: false }
|
|
81
101
|
) {
|
|
102
|
+
let invalidInput = [];
|
|
103
|
+
if (invalidInput.length) {
|
|
104
|
+
const error = new Error();
|
|
105
|
+
error.message = "Missing required field";
|
|
106
|
+
error.details = invalidInput;
|
|
107
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
108
|
+
}
|
|
109
|
+
|
|
82
110
|
const query_params = {};
|
|
83
111
|
|
|
84
112
|
const xHeaders = {};
|
|
@@ -116,6 +144,21 @@ class FileStorage {
|
|
|
116
144
|
{ namespace, body, requestHeaders } = { requestHeaders: {} },
|
|
117
145
|
{ responseHeaders } = { responseHeaders: false }
|
|
118
146
|
) {
|
|
147
|
+
let invalidInput = [];
|
|
148
|
+
|
|
149
|
+
if (!namespace) {
|
|
150
|
+
invalidInput.push({
|
|
151
|
+
message: `The 'namespace' field is required.`,
|
|
152
|
+
path: ["namespace"],
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
if (invalidInput.length) {
|
|
156
|
+
const error = new Error();
|
|
157
|
+
error.message = "Missing required field";
|
|
158
|
+
error.details = invalidInput;
|
|
159
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
160
|
+
}
|
|
161
|
+
|
|
119
162
|
const query_params = {};
|
|
120
163
|
|
|
121
164
|
const xHeaders = {};
|