@gofynd/fdk-client-javascript 1.0.1 → 1.0.3
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/documentation/application/CART.md +5934 -4502
- package/documentation/application/CATALOG.md +6338 -7245
- package/documentation/application/COMMON.md +95 -222
- package/documentation/application/COMMUNICATION.md +106 -186
- package/documentation/application/CONFIGURATION.md +903 -1597
- package/documentation/application/CONTENT.md +562 -1270
- package/documentation/application/FILESTORAGE.md +84 -220
- package/documentation/application/LEAD.md +314 -660
- package/documentation/application/LOGISTIC.md +229 -305
- package/documentation/application/ORDER.md +642 -1137
- package/documentation/application/PAYMENT.md +2285 -3031
- package/documentation/application/POSCART.md +6079 -4642
- package/documentation/application/REWARDS.md +94 -248
- package/documentation/application/SHARE.md +152 -250
- package/documentation/application/THEME.md +952 -1235
- package/documentation/application/USER.md +1228 -1765
- package/documentation/platform/ANALYTICS.md +207 -349
- package/documentation/platform/AUDITTRAIL.md +121 -204
- package/documentation/platform/BILLING.md +865 -1376
- package/documentation/platform/CART.md +2814 -3662
- package/documentation/platform/CATALOG.md +15266 -17619
- package/documentation/platform/COMMON.md +95 -222
- package/documentation/platform/COMMUNICATION.md +1632 -2380
- package/documentation/platform/COMPANYPROFILE.md +572 -957
- package/documentation/platform/CONFIGURATION.md +3050 -4073
- package/documentation/platform/CONTENT.md +3509 -4121
- package/documentation/platform/DISCOUNT.md +140 -236
- package/documentation/platform/FILESTORAGE.md +187 -323
- package/documentation/platform/INVENTORY.md +268 -911
- package/documentation/platform/LEAD.md +2195 -2541
- package/documentation/platform/ORDER.md +3750 -5636
- package/documentation/platform/PARTNER.md +9 -36
- package/documentation/platform/PAYMENT.md +903 -1213
- package/documentation/platform/REWARDS.md +183 -347
- package/documentation/platform/SHARE.md +120 -213
- package/documentation/platform/THEME.md +12956 -13239
- package/documentation/platform/USER.md +975 -1120
- package/documentation/platform/WEBHOOK.md +78 -184
- package/documentation/public/CONFIGURATION.md +95 -222
- package/documentation/public/INVENTORY.md +100 -282
- package/documentation/public/WEBHOOK.md +27 -133
- package/package.json +1 -1
- package/sdk/application/ApplicationConfig.js +1 -1
- package/sdk/application/Cart/CartApplicationClient.d.ts +243 -243
- package/sdk/application/Cart/CartApplicationClient.js +1058 -547
- package/sdk/application/Cart/CartApplicationModel.d.ts +64 -63
- package/sdk/application/Cart/CartApplicationModel.js +489 -886
- package/sdk/application/Cart/CartApplicationValidator.d.ts +17 -17
- package/sdk/application/Cart/CartApplicationValidator.js +98 -98
- package/sdk/application/Catalog/CatalogApplicationClient.d.ts +358 -358
- package/sdk/application/Catalog/CatalogApplicationClient.js +1545 -949
- package/sdk/application/Catalog/CatalogApplicationModel.d.ts +90 -90
- package/sdk/application/Catalog/CatalogApplicationModel.js +692 -1258
- package/sdk/application/Catalog/CatalogApplicationValidator.d.ts +19 -19
- package/sdk/application/Catalog/CatalogApplicationValidator.js +110 -110
- package/sdk/application/Common/CommonApplicationClient.d.ts +13 -13
- package/sdk/application/Common/CommonApplicationClient.js +76 -36
- package/sdk/application/Common/CommonApplicationModel.d.ts +12 -12
- package/sdk/application/Common/CommonApplicationModel.js +83 -160
- package/sdk/application/Common/CommonApplicationValidator.d.ts +1 -1
- package/sdk/application/Common/CommonApplicationValidator.js +6 -6
- package/sdk/application/Communication/CommunicationApplicationClient.d.ts +11 -11
- package/sdk/application/Communication/CommunicationApplicationClient.js +92 -31
- package/sdk/application/Communication/CommunicationApplicationModel.d.ts +6 -6
- package/sdk/application/Communication/CommunicationApplicationModel.js +38 -83
- package/sdk/application/Communication/CommunicationApplicationValidator.d.ts +1 -1
- package/sdk/application/Communication/CommunicationApplicationValidator.js +4 -4
- package/sdk/application/Configuration/ConfigurationApplicationClient.d.ts +116 -116
- package/sdk/application/Configuration/ConfigurationApplicationClient.js +638 -312
- package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +85 -85
- package/sdk/application/Configuration/ConfigurationApplicationModel.js +480 -851
- package/sdk/application/Configuration/ConfigurationApplicationValidator.d.ts +8 -8
- package/sdk/application/Configuration/ConfigurationApplicationValidator.js +33 -33
- package/sdk/application/Content/ContentApplicationClient.d.ts +67 -67
- package/sdk/application/Content/ContentApplicationClient.js +581 -213
- package/sdk/application/Content/ContentApplicationModel.d.ts +76 -75
- package/sdk/application/Content/ContentApplicationModel.js +468 -875
- package/sdk/application/Content/ContentApplicationValidator.d.ts +5 -5
- package/sdk/application/Content/ContentApplicationValidator.js +24 -24
- package/sdk/application/FileStorage/FileStorageApplicationClient.d.ts +25 -25
- package/sdk/application/FileStorage/FileStorageApplicationClient.js +121 -59
- package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +13 -13
- package/sdk/application/FileStorage/FileStorageApplicationModel.js +86 -169
- package/sdk/application/FileStorage/FileStorageApplicationValidator.d.ts +1 -1
- package/sdk/application/FileStorage/FileStorageApplicationValidator.js +7 -7
- package/sdk/application/Lead/LeadApplicationClient.d.ts +24 -24
- package/sdk/application/Lead/LeadApplicationClient.js +230 -96
- package/sdk/application/Lead/LeadApplicationModel.d.ts +35 -35
- package/sdk/application/Lead/LeadApplicationModel.js +267 -474
- package/sdk/application/Lead/LeadApplicationValidator.d.ts +2 -2
- package/sdk/application/Lead/LeadApplicationValidator.js +11 -11
- package/sdk/application/Logistic/LogisticApplicationClient.d.ts +30 -19
- package/sdk/application/Logistic/LogisticApplicationClient.js +196 -47
- package/sdk/application/Logistic/LogisticApplicationModel.d.ts +17 -14
- package/sdk/application/Logistic/LogisticApplicationModel.js +133 -201
- package/sdk/application/Logistic/LogisticApplicationValidator.d.ts +3 -2
- package/sdk/application/Logistic/LogisticApplicationValidator.js +14 -8
- package/sdk/application/Order/OrderApplicationClient.d.ts +86 -86
- package/sdk/application/Order/OrderApplicationClient.js +448 -215
- package/sdk/application/Order/OrderApplicationModel.d.ts +50 -50
- package/sdk/application/Order/OrderApplicationModel.js +357 -661
- package/sdk/application/Order/OrderApplicationValidator.d.ts +7 -7
- package/sdk/application/Order/OrderApplicationValidator.js +28 -28
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +318 -318
- package/sdk/application/Payment/PaymentApplicationClient.js +1525 -750
- package/sdk/application/Payment/PaymentApplicationModel.d.ts +72 -72
- package/sdk/application/Payment/PaymentApplicationModel.js +565 -1033
- package/sdk/application/Payment/PaymentApplicationValidator.d.ts +28 -28
- package/sdk/application/Payment/PaymentApplicationValidator.js +107 -107
- package/sdk/application/PosCart/PosCartApplicationClient.d.ts +254 -254
- package/sdk/application/PosCart/PosCartApplicationClient.js +1137 -606
- package/sdk/application/PosCart/PosCartApplicationModel.d.ts +61 -60
- package/sdk/application/PosCart/PosCartApplicationModel.js +477 -873
- package/sdk/application/PosCart/PosCartApplicationValidator.d.ts +18 -18
- package/sdk/application/PosCart/PosCartApplicationValidator.js +103 -103
- package/sdk/application/Rewards/RewardsApplicationClient.d.ts +27 -27
- package/sdk/application/Rewards/RewardsApplicationClient.js +253 -113
- package/sdk/application/Rewards/RewardsApplicationModel.d.ts +14 -14
- package/sdk/application/Rewards/RewardsApplicationModel.js +96 -191
- package/sdk/application/Rewards/RewardsApplicationValidator.d.ts +3 -3
- package/sdk/application/Rewards/RewardsApplicationValidator.js +12 -12
- package/sdk/application/Share/ShareApplicationClient.d.ts +37 -37
- package/sdk/application/Share/ShareApplicationClient.js +221 -96
- package/sdk/application/Share/ShareApplicationModel.d.ts +8 -8
- package/sdk/application/Share/ShareApplicationModel.js +63 -123
- package/sdk/application/Share/ShareApplicationValidator.d.ts +4 -4
- package/sdk/application/Share/ShareApplicationValidator.js +12 -12
- package/sdk/application/Theme/ThemeApplicationClient.d.ts +8 -8
- package/sdk/application/Theme/ThemeApplicationClient.js +115 -37
- package/sdk/application/Theme/ThemeApplicationModel.d.ts +34 -34
- package/sdk/application/Theme/ThemeApplicationModel.js +190 -336
- package/sdk/application/Theme/ThemeApplicationValidator.d.ts +1 -1
- package/sdk/application/Theme/ThemeApplicationValidator.js +4 -4
- package/sdk/application/User/UserApplicationClient.d.ts +280 -280
- package/sdk/application/User/UserApplicationClient.js +1201 -543
- package/sdk/application/User/UserApplicationModel.d.ts +79 -72
- package/sdk/application/User/UserApplicationModel.js +440 -689
- package/sdk/application/User/UserApplicationValidator.d.ts +24 -24
- package/sdk/application/User/UserApplicationValidator.js +89 -89
- package/sdk/common/AxiosHelper.js +1 -1
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.d.ts +55 -47
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationClient.js +308 -151
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.d.ts +6 -6
- package/sdk/platform/Analytics/AnalyticsPlatformApplicationValidator.js +20 -20
- package/sdk/platform/Analytics/AnalyticsPlatformClient.d.ts +8 -4
- package/sdk/platform/Analytics/AnalyticsPlatformClient.js +103 -16
- package/sdk/platform/Analytics/AnalyticsPlatformModel.d.ts +11 -11
- package/sdk/platform/Analytics/AnalyticsPlatformModel.js +95 -178
- package/sdk/platform/AuditTrail/AuditTrailPlatformClient.d.ts +16 -12
- package/sdk/platform/AuditTrail/AuditTrailPlatformClient.js +131 -44
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +10 -10
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +50 -89
- package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.d.ts +1 -1
- package/sdk/platform/AuditTrail/AuditTrailPlatformValidator.js +6 -6
- package/sdk/platform/Billing/BillingPlatformClient.d.ts +68 -56
- package/sdk/platform/Billing/BillingPlatformClient.js +416 -171
- package/sdk/platform/Billing/BillingPlatformModel.d.ts +40 -40
- package/sdk/platform/Billing/BillingPlatformModel.js +342 -668
- package/sdk/platform/Billing/BillingPlatformValidator.d.ts +8 -8
- package/sdk/platform/Billing/BillingPlatformValidator.js +25 -25
- package/sdk/platform/Cart/CartPlatformApplicationClient.d.ts +176 -159
- package/sdk/platform/Cart/CartPlatformApplicationClient.js +837 -500
- package/sdk/platform/Cart/CartPlatformApplicationValidator.d.ts +11 -11
- package/sdk/platform/Cart/CartPlatformApplicationValidator.js +63 -63
- package/sdk/platform/Cart/CartPlatformModel.d.ts +86 -85
- package/sdk/platform/Cart/CartPlatformModel.js +677 -1211
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.d.ts +582 -529
- package/sdk/platform/Catalog/CatalogPlatformApplicationClient.js +2642 -1533
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.d.ts +40 -40
- package/sdk/platform/Catalog/CatalogPlatformApplicationValidator.js +175 -175
- package/sdk/platform/Catalog/CatalogPlatformClient.d.ts +708 -590
- package/sdk/platform/Catalog/CatalogPlatformClient.js +3103 -1362
- package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +293 -284
- package/sdk/platform/Catalog/CatalogPlatformModel.js +2149 -3660
- package/sdk/platform/Catalog/CatalogPlatformValidator.d.ts +66 -64
- package/sdk/platform/Catalog/CatalogPlatformValidator.js +235 -216
- package/sdk/platform/Common/CommonPlatformClient.d.ts +14 -12
- package/sdk/platform/Common/CommonPlatformClient.js +80 -37
- package/sdk/platform/Common/CommonPlatformModel.d.ts +12 -12
- package/sdk/platform/Common/CommonPlatformModel.js +83 -160
- package/sdk/platform/Common/CommonPlatformValidator.d.ts +1 -1
- package/sdk/platform/Common/CommonPlatformValidator.js +6 -6
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +333 -293
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +1687 -855
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +30 -30
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +87 -87
- package/sdk/platform/Communication/CommunicationPlatformClient.d.ts +2 -1
- package/sdk/platform/Communication/CommunicationPlatformClient.js +28 -4
- package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +67 -67
- package/sdk/platform/Communication/CommunicationPlatformModel.js +522 -974
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.d.ts +70 -57
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformClient.js +463 -182
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +28 -28
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +294 -557
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.d.ts +7 -7
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformValidator.js +24 -24
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.d.ts +175 -137
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationClient.js +1168 -521
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.d.ts +22 -21
- package/sdk/platform/Configuration/ConfigurationPlatformApplicationValidator.js +69 -63
- package/sdk/platform/Configuration/ConfigurationPlatformClient.d.ts +137 -119
- package/sdk/platform/Configuration/ConfigurationPlatformClient.js +691 -316
- package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +148 -146
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +854 -1508
- package/sdk/platform/Configuration/ConfigurationPlatformValidator.d.ts +9 -9
- package/sdk/platform/Configuration/ConfigurationPlatformValidator.js +38 -38
- package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +542 -461
- package/sdk/platform/Content/ContentPlatformApplicationClient.js +2600 -1160
- package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +50 -49
- package/sdk/platform/Content/ContentPlatformApplicationValidator.js +159 -152
- package/sdk/platform/Content/ContentPlatformModel.d.ts +79 -75
- package/sdk/platform/Content/ContentPlatformModel.js +486 -867
- package/sdk/platform/Discount/DiscountPlatformClient.d.ts +72 -61
- package/sdk/platform/Discount/DiscountPlatformClient.js +424 -198
- package/sdk/platform/Discount/DiscountPlatformModel.d.ts +7 -7
- package/sdk/platform/Discount/DiscountPlatformModel.js +60 -121
- package/sdk/platform/Discount/DiscountPlatformValidator.d.ts +6 -6
- package/sdk/platform/Discount/DiscountPlatformValidator.js +29 -29
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.d.ts +26 -22
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationClient.js +145 -59
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.d.ts +1 -1
- package/sdk/platform/FileStorage/FileStoragePlatformApplicationValidator.js +8 -8
- package/sdk/platform/FileStorage/FileStoragePlatformClient.d.ts +58 -52
- package/sdk/platform/FileStorage/FileStoragePlatformClient.js +240 -114
- package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +13 -13
- package/sdk/platform/FileStorage/FileStoragePlatformModel.js +86 -169
- package/sdk/platform/FileStorage/FileStoragePlatformValidator.d.ts +3 -3
- package/sdk/platform/FileStorage/FileStoragePlatformValidator.js +11 -11
- package/sdk/platform/Inventory/InventoryPlatformClient.d.ts +76 -63
- package/sdk/platform/Inventory/InventoryPlatformClient.js +461 -197
- package/sdk/platform/Inventory/InventoryPlatformModel.d.ts +30 -30
- package/sdk/platform/Inventory/InventoryPlatformModel.js +497 -964
- package/sdk/platform/Inventory/InventoryPlatformValidator.d.ts +7 -7
- package/sdk/platform/Inventory/InventoryPlatformValidator.js +28 -28
- package/sdk/platform/Lead/LeadPlatformApplicationClient.d.ts +84 -71
- package/sdk/platform/Lead/LeadPlatformApplicationClient.js +441 -182
- package/sdk/platform/Lead/LeadPlatformApplicationValidator.d.ts +7 -7
- package/sdk/platform/Lead/LeadPlatformApplicationValidator.js +28 -28
- package/sdk/platform/Lead/LeadPlatformClient.d.ts +86 -75
- package/sdk/platform/Lead/LeadPlatformClient.js +434 -212
- package/sdk/platform/Lead/LeadPlatformModel.d.ts +35 -35
- package/sdk/platform/Lead/LeadPlatformModel.js +267 -474
- package/sdk/platform/Lead/LeadPlatformValidator.d.ts +6 -6
- package/sdk/platform/Lead/LeadPlatformValidator.js +24 -24
- package/sdk/platform/OAuthClient.js +8 -8
- package/sdk/platform/Order/OrderPlatformApplicationClient.d.ts +14 -11
- package/sdk/platform/Order/OrderPlatformApplicationClient.js +113 -49
- package/sdk/platform/Order/OrderPlatformApplicationValidator.d.ts +1 -1
- package/sdk/platform/Order/OrderPlatformApplicationValidator.js +6 -6
- package/sdk/platform/Order/OrderPlatformClient.d.ts +367 -315
- package/sdk/platform/Order/OrderPlatformClient.js +1775 -893
- package/sdk/platform/Order/OrderPlatformModel.d.ts +198 -192
- package/sdk/platform/Order/OrderPlatformModel.js +1591 -2822
- package/sdk/platform/Order/OrderPlatformValidator.d.ts +32 -32
- package/sdk/platform/Order/OrderPlatformValidator.js +160 -155
- package/sdk/platform/Partner/PartnerPlatformApplicationClient.d.ts +4 -2
- package/sdk/platform/Partner/PartnerPlatformApplicationClient.js +52 -8
- package/sdk/platform/Partner/PartnerPlatformModel.js +6 -22
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.d.ts +65 -54
- package/sdk/platform/Payment/PaymentPlatformApplicationClient.js +395 -164
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.d.ts +6 -6
- package/sdk/platform/Payment/PaymentPlatformApplicationValidator.js +23 -23
- package/sdk/platform/Payment/PaymentPlatformClient.d.ts +55 -45
- package/sdk/platform/Payment/PaymentPlatformClient.js +362 -147
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +27 -27
- package/sdk/platform/Payment/PaymentPlatformModel.js +220 -408
- package/sdk/platform/Payment/PaymentPlatformValidator.d.ts +4 -4
- package/sdk/platform/Payment/PaymentPlatformValidator.js +21 -21
- package/sdk/platform/PlatformApplicationClient.d.ts +1496 -10153
- package/sdk/platform/PlatformApplicationClient.js +1584 -13691
- package/sdk/platform/PlatformClient.d.ts +7918 -7666
- package/sdk/platform/PlatformClient.js +8701 -9926
- package/sdk/platform/Rewards/RewardsPlatformApplicationClient.d.ts +91 -78
- package/sdk/platform/Rewards/RewardsPlatformApplicationClient.js +507 -253
- package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.d.ts +8 -8
- package/sdk/platform/Rewards/RewardsPlatformApplicationValidator.js +34 -34
- package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +15 -15
- package/sdk/platform/Rewards/RewardsPlatformModel.js +92 -194
- package/sdk/platform/Share/SharePlatformApplicationClient.d.ts +16 -12
- package/sdk/platform/Share/SharePlatformApplicationClient.js +130 -52
- package/sdk/platform/Share/SharePlatformApplicationValidator.d.ts +1 -1
- package/sdk/platform/Share/SharePlatformApplicationValidator.js +6 -6
- package/sdk/platform/Share/SharePlatformModel.d.ts +8 -8
- package/sdk/platform/Share/SharePlatformModel.js +60 -118
- package/sdk/platform/Theme/ThemePlatformApplicationClient.d.ts +148 -124
- package/sdk/platform/Theme/ThemePlatformApplicationClient.js +770 -295
- package/sdk/platform/Theme/ThemePlatformApplicationValidator.d.ts +15 -15
- package/sdk/platform/Theme/ThemePlatformApplicationValidator.js +44 -44
- package/sdk/platform/Theme/ThemePlatformModel.d.ts +34 -34
- package/sdk/platform/Theme/ThemePlatformModel.js +190 -336
- package/sdk/platform/User/UserPlatformApplicationClient.d.ts +146 -67
- package/sdk/platform/User/UserPlatformApplicationClient.js +742 -155
- package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +12 -7
- package/sdk/platform/User/UserPlatformApplicationValidator.js +61 -23
- package/sdk/platform/User/UserPlatformModel.d.ts +79 -72
- package/sdk/platform/User/UserPlatformModel.js +440 -689
- package/sdk/platform/Webhook/WebhookPlatformClient.d.ts +35 -29
- package/sdk/platform/Webhook/WebhookPlatformClient.js +218 -91
- package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +7 -7
- package/sdk/platform/Webhook/WebhookPlatformModel.js +68 -136
- package/sdk/platform/Webhook/WebhookPlatformValidator.d.ts +3 -3
- package/sdk/platform/Webhook/WebhookPlatformValidator.js +14 -14
- package/sdk/public/Configuration/ConfigurationPublicClient.d.ts +13 -13
- package/sdk/public/Configuration/ConfigurationPublicClient.js +81 -38
- package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +12 -12
- package/sdk/public/Configuration/ConfigurationPublicModel.js +85 -162
- package/sdk/public/Configuration/ConfigurationPublicValidator.d.ts +1 -1
- package/sdk/public/Configuration/ConfigurationPublicValidator.js +6 -6
- package/sdk/public/Inventory/InventoryPublicClient.d.ts +34 -34
- package/sdk/public/Inventory/InventoryPublicClient.js +228 -105
- package/sdk/public/Inventory/InventoryPublicModel.d.ts +10 -10
- package/sdk/public/Inventory/InventoryPublicModel.js +119 -245
- package/sdk/public/Inventory/InventoryPublicValidator.d.ts +3 -3
- package/sdk/public/Inventory/InventoryPublicValidator.js +15 -15
- package/sdk/public/Webhook/WebhookPublicClient.js +51 -10
- package/sdk/public/Webhook/WebhookPublicModel.d.ts +7 -7
- package/sdk/public/Webhook/WebhookPublicModel.js +68 -136
- package/tests/application/catalog.spec.js +7 -0
|
@@ -2,6 +2,8 @@ const Paginator = require("../../common/Paginator");
|
|
|
2
2
|
const PlatformAPIClient = require("../PlatformAPIClient");
|
|
3
3
|
const { FDKClientValidationError } = require("../../common/FDKError");
|
|
4
4
|
const ShareValidator = require("./SharePlatformApplicationValidator");
|
|
5
|
+
const ShareModel = require("./SharePlatformModel");
|
|
6
|
+
const { Logger } = require("./../../common/Logger");
|
|
5
7
|
|
|
6
8
|
class Share {
|
|
7
9
|
constructor(config, applicationId) {
|
|
@@ -12,10 +14,11 @@ class Share {
|
|
|
12
14
|
/**
|
|
13
15
|
* @param {Object} arg - Arg object.
|
|
14
16
|
* @param {ShortLinkReq} arg.body
|
|
17
|
+
* @returns {Promise<ShortLinkRes>} - Success response
|
|
15
18
|
* @summary: Create short link
|
|
16
19
|
* @description: Create short link
|
|
17
20
|
*/
|
|
18
|
-
createShortLink({ body } = {}) {
|
|
21
|
+
async createShortLink({ body } = {}) {
|
|
19
22
|
const { error } = ShareValidator.createShortLink().validate(
|
|
20
23
|
{
|
|
21
24
|
body,
|
|
@@ -34,19 +37,96 @@ class Share {
|
|
|
34
37
|
{ abortEarly: false, allowUnknown: false }
|
|
35
38
|
);
|
|
36
39
|
if (warrning) {
|
|
37
|
-
|
|
38
|
-
|
|
40
|
+
Logger({
|
|
41
|
+
level: "WARN",
|
|
42
|
+
message: "Parameter Validation warrnings for createShortLink",
|
|
43
|
+
});
|
|
44
|
+
Logger({ level: "WARN", message: warrning });
|
|
39
45
|
}
|
|
40
46
|
|
|
41
47
|
const query_params = {};
|
|
42
48
|
|
|
43
|
-
|
|
49
|
+
const response = await PlatformAPIClient.execute(
|
|
44
50
|
this.config,
|
|
45
51
|
"post",
|
|
46
52
|
`/service/platform/share/v1.0/company/${this.config.companyId}/application/${this.applicationId}/links/short-link/`,
|
|
47
53
|
query_params,
|
|
48
54
|
body
|
|
49
55
|
);
|
|
56
|
+
|
|
57
|
+
const { error: res_error } = ShareModel.ShortLinkRes().validate(response, {
|
|
58
|
+
abortEarly: false,
|
|
59
|
+
allowUnknown: false,
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
if (res_error) {
|
|
63
|
+
Logger({
|
|
64
|
+
level: "WARN",
|
|
65
|
+
message: "Response Validation Warnnings for createShortLink",
|
|
66
|
+
});
|
|
67
|
+
Logger({ level: "WARN", message: res_error });
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
return response;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* @param {Object} arg - Arg object.
|
|
75
|
+
* @param {string} arg.hash - Hash of short url
|
|
76
|
+
* @returns {Promise<ShortLinkRes>} - Success response
|
|
77
|
+
* @summary: Get short link by hash
|
|
78
|
+
* @description: Get short link by hash
|
|
79
|
+
*/
|
|
80
|
+
async getShortLinkByHash({ hash } = {}) {
|
|
81
|
+
const { error } = ShareValidator.getShortLinkByHash().validate(
|
|
82
|
+
{
|
|
83
|
+
hash,
|
|
84
|
+
},
|
|
85
|
+
{ abortEarly: false, allowUnknown: true }
|
|
86
|
+
);
|
|
87
|
+
if (error) {
|
|
88
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
// Showing warrnings if extra unknown parameters are found
|
|
92
|
+
const { error: warrning } = ShareValidator.getShortLinkByHash().validate(
|
|
93
|
+
{
|
|
94
|
+
hash,
|
|
95
|
+
},
|
|
96
|
+
{ abortEarly: false, allowUnknown: false }
|
|
97
|
+
);
|
|
98
|
+
if (warrning) {
|
|
99
|
+
Logger({
|
|
100
|
+
level: "WARN",
|
|
101
|
+
message: "Parameter Validation warrnings for getShortLinkByHash",
|
|
102
|
+
});
|
|
103
|
+
Logger({ level: "WARN", message: warrning });
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
const query_params = {};
|
|
107
|
+
|
|
108
|
+
const response = await PlatformAPIClient.execute(
|
|
109
|
+
this.config,
|
|
110
|
+
"get",
|
|
111
|
+
`/service/platform/share/v1.0/company/${this.config.companyId}/application/${this.applicationId}/links/short-link/${hash}/`,
|
|
112
|
+
query_params,
|
|
113
|
+
undefined
|
|
114
|
+
);
|
|
115
|
+
|
|
116
|
+
const { error: res_error } = ShareModel.ShortLinkRes().validate(response, {
|
|
117
|
+
abortEarly: false,
|
|
118
|
+
allowUnknown: false,
|
|
119
|
+
});
|
|
120
|
+
|
|
121
|
+
if (res_error) {
|
|
122
|
+
Logger({
|
|
123
|
+
level: "WARN",
|
|
124
|
+
message: "Response Validation Warnnings for getShortLinkByHash",
|
|
125
|
+
});
|
|
126
|
+
Logger({ level: "WARN", message: res_error });
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
return response;
|
|
50
130
|
}
|
|
51
131
|
|
|
52
132
|
/**
|
|
@@ -56,10 +136,11 @@ class Share {
|
|
|
56
136
|
* @param {string} [arg.createdBy] - Short link creator
|
|
57
137
|
* @param {string} [arg.active] - Short link active status
|
|
58
138
|
* @param {string} [arg.q] - Search text for original and short url
|
|
139
|
+
* @returns {Promise<ShortLinkList>} - Success response
|
|
59
140
|
* @summary: Get short links
|
|
60
141
|
* @description: Get short links
|
|
61
142
|
*/
|
|
62
|
-
getShortLinks({ pageNo, pageSize, createdBy, active, q } = {}) {
|
|
143
|
+
async getShortLinks({ pageNo, pageSize, createdBy, active, q } = {}) {
|
|
63
144
|
const { error } = ShareValidator.getShortLinks().validate(
|
|
64
145
|
{
|
|
65
146
|
pageNo,
|
|
@@ -86,8 +167,11 @@ class Share {
|
|
|
86
167
|
{ abortEarly: false, allowUnknown: false }
|
|
87
168
|
);
|
|
88
169
|
if (warrning) {
|
|
89
|
-
|
|
90
|
-
|
|
170
|
+
Logger({
|
|
171
|
+
level: "WARN",
|
|
172
|
+
message: "Parameter Validation warrnings for getShortLinks",
|
|
173
|
+
});
|
|
174
|
+
Logger({ level: "WARN", message: warrning });
|
|
91
175
|
}
|
|
92
176
|
|
|
93
177
|
const query_params = {};
|
|
@@ -97,13 +181,28 @@ class Share {
|
|
|
97
181
|
query_params["active"] = active;
|
|
98
182
|
query_params["q"] = q;
|
|
99
183
|
|
|
100
|
-
|
|
184
|
+
const response = await PlatformAPIClient.execute(
|
|
101
185
|
this.config,
|
|
102
186
|
"get",
|
|
103
187
|
`/service/platform/share/v1.0/company/${this.config.companyId}/application/${this.applicationId}/links/short-link/`,
|
|
104
188
|
query_params,
|
|
105
189
|
undefined
|
|
106
190
|
);
|
|
191
|
+
|
|
192
|
+
const { error: res_error } = ShareModel.ShortLinkList().validate(response, {
|
|
193
|
+
abortEarly: false,
|
|
194
|
+
allowUnknown: false,
|
|
195
|
+
});
|
|
196
|
+
|
|
197
|
+
if (res_error) {
|
|
198
|
+
Logger({
|
|
199
|
+
level: "WARN",
|
|
200
|
+
message: "Response Validation Warnnings for getShortLinks",
|
|
201
|
+
});
|
|
202
|
+
Logger({ level: "WARN", message: res_error });
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
return response;
|
|
107
206
|
}
|
|
108
207
|
|
|
109
208
|
/**
|
|
@@ -149,54 +248,15 @@ class Share {
|
|
|
149
248
|
return paginator;
|
|
150
249
|
}
|
|
151
250
|
|
|
152
|
-
/**
|
|
153
|
-
* @param {Object} arg - Arg object.
|
|
154
|
-
* @param {string} arg.hash - Hash of short url
|
|
155
|
-
* @summary: Get short link by hash
|
|
156
|
-
* @description: Get short link by hash
|
|
157
|
-
*/
|
|
158
|
-
getShortLinkByHash({ hash } = {}) {
|
|
159
|
-
const { error } = ShareValidator.getShortLinkByHash().validate(
|
|
160
|
-
{
|
|
161
|
-
hash,
|
|
162
|
-
},
|
|
163
|
-
{ abortEarly: false, allowUnknown: true }
|
|
164
|
-
);
|
|
165
|
-
if (error) {
|
|
166
|
-
return Promise.reject(new FDKClientValidationError(error));
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
// Showing warrnings if extra unknown parameters are found
|
|
170
|
-
const { error: warrning } = ShareValidator.getShortLinkByHash().validate(
|
|
171
|
-
{
|
|
172
|
-
hash,
|
|
173
|
-
},
|
|
174
|
-
{ abortEarly: false, allowUnknown: false }
|
|
175
|
-
);
|
|
176
|
-
if (warrning) {
|
|
177
|
-
console.log("Parameter Validation warrnings for getShortLinkByHash");
|
|
178
|
-
console.log(warrning);
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
const query_params = {};
|
|
182
|
-
|
|
183
|
-
return PlatformAPIClient.execute(
|
|
184
|
-
this.config,
|
|
185
|
-
"get",
|
|
186
|
-
`/service/platform/share/v1.0/company/${this.config.companyId}/application/${this.applicationId}/links/short-link/${hash}/`,
|
|
187
|
-
query_params,
|
|
188
|
-
undefined
|
|
189
|
-
);
|
|
190
|
-
}
|
|
191
|
-
|
|
192
251
|
/**
|
|
193
252
|
* @param {Object} arg - Arg object.
|
|
194
253
|
* @param {string} arg.id - Short link document identifier
|
|
195
254
|
* @param {ShortLinkReq} arg.body
|
|
255
|
+
* @returns {Promise<ShortLinkRes>} - Success response
|
|
196
256
|
* @summary: Update short link by id
|
|
197
257
|
* @description: Update short link by id
|
|
198
258
|
*/
|
|
199
|
-
updateShortLinkById({ id, body } = {}) {
|
|
259
|
+
async updateShortLinkById({ id, body } = {}) {
|
|
200
260
|
const { error } = ShareValidator.updateShortLinkById().validate(
|
|
201
261
|
{
|
|
202
262
|
id,
|
|
@@ -217,19 +277,37 @@ class Share {
|
|
|
217
277
|
{ abortEarly: false, allowUnknown: false }
|
|
218
278
|
);
|
|
219
279
|
if (warrning) {
|
|
220
|
-
|
|
221
|
-
|
|
280
|
+
Logger({
|
|
281
|
+
level: "WARN",
|
|
282
|
+
message: "Parameter Validation warrnings for updateShortLinkById",
|
|
283
|
+
});
|
|
284
|
+
Logger({ level: "WARN", message: warrning });
|
|
222
285
|
}
|
|
223
286
|
|
|
224
287
|
const query_params = {};
|
|
225
288
|
|
|
226
|
-
|
|
289
|
+
const response = await PlatformAPIClient.execute(
|
|
227
290
|
this.config,
|
|
228
291
|
"patch",
|
|
229
292
|
`/service/platform/share/v1.0/company/${this.config.companyId}/application/${this.applicationId}/links/short-link/${id}/`,
|
|
230
293
|
query_params,
|
|
231
294
|
body
|
|
232
295
|
);
|
|
296
|
+
|
|
297
|
+
const { error: res_error } = ShareModel.ShortLinkRes().validate(response, {
|
|
298
|
+
abortEarly: false,
|
|
299
|
+
allowUnknown: false,
|
|
300
|
+
});
|
|
301
|
+
|
|
302
|
+
if (res_error) {
|
|
303
|
+
Logger({
|
|
304
|
+
level: "WARN",
|
|
305
|
+
message: "Response Validation Warnnings for updateShortLinkById",
|
|
306
|
+
});
|
|
307
|
+
Logger({ level: "WARN", message: res_error });
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
return response;
|
|
233
311
|
}
|
|
234
312
|
}
|
|
235
313
|
module.exports = Share;
|
|
@@ -8,6 +8,12 @@ class ShareValidator {
|
|
|
8
8
|
}).required();
|
|
9
9
|
}
|
|
10
10
|
|
|
11
|
+
static getShortLinkByHash() {
|
|
12
|
+
return Joi.object({
|
|
13
|
+
hash: Joi.string().allow("").required(),
|
|
14
|
+
}).required();
|
|
15
|
+
}
|
|
16
|
+
|
|
11
17
|
static getShortLinks() {
|
|
12
18
|
return Joi.object({
|
|
13
19
|
pageNo: Joi.number(),
|
|
@@ -18,12 +24,6 @@ class ShareValidator {
|
|
|
18
24
|
}).required();
|
|
19
25
|
}
|
|
20
26
|
|
|
21
|
-
static getShortLinkByHash() {
|
|
22
|
-
return Joi.object({
|
|
23
|
-
hash: Joi.string().allow("").required(),
|
|
24
|
-
}).required();
|
|
25
|
-
}
|
|
26
|
-
|
|
27
27
|
static updateShortLinkById() {
|
|
28
28
|
return Joi.object({
|
|
29
29
|
id: Joi.string().allow("").required(),
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
export = ShareModel;
|
|
2
2
|
declare class ShareModel {
|
|
3
|
+
static Attribution(): any;
|
|
4
|
+
static CampaignShortLink(): any;
|
|
5
|
+
static ErrorRes(): any;
|
|
6
|
+
static Page(): any;
|
|
3
7
|
static RedirectDevice(): any;
|
|
4
|
-
static WebRedirect(): any;
|
|
5
8
|
static Redirects(): any;
|
|
6
|
-
static
|
|
7
|
-
static Attribution(): any;
|
|
8
|
-
static SocialMediaTags(): any;
|
|
9
|
+
static ShortLinkList(): any;
|
|
9
10
|
static ShortLinkReq(): any;
|
|
10
|
-
static UrlInfo(): any;
|
|
11
11
|
static ShortLinkRes(): any;
|
|
12
|
-
static
|
|
13
|
-
static
|
|
14
|
-
static
|
|
12
|
+
static SocialMediaTags(): any;
|
|
13
|
+
static UrlInfo(): any;
|
|
14
|
+
static WebRedirect(): any;
|
|
15
15
|
}
|
|
@@ -1,169 +1,111 @@
|
|
|
1
1
|
const Joi = require("joi");
|
|
2
2
|
|
|
3
3
|
class ShareModel {
|
|
4
|
-
static
|
|
4
|
+
static Attribution() {
|
|
5
5
|
return Joi.object({
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
type: Joi.string().allow(""),
|
|
6
|
+
campaign_cookie_expiry: Joi.string().allow(""),
|
|
9
7
|
});
|
|
10
8
|
}
|
|
11
|
-
|
|
12
|
-
static WebRedirect() {
|
|
9
|
+
static CampaignShortLink() {
|
|
13
10
|
return Joi.object({
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
type: Joi.string().allow(""),
|
|
11
|
+
medium: Joi.string().allow(""),
|
|
12
|
+
source: Joi.string().allow(""),
|
|
17
13
|
});
|
|
18
14
|
}
|
|
19
|
-
|
|
20
|
-
static Redirects() {
|
|
15
|
+
static ErrorRes() {
|
|
21
16
|
return Joi.object({
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
android: ShareModel.RedirectDevice(),
|
|
25
|
-
|
|
26
|
-
web: ShareModel.WebRedirect(),
|
|
27
|
-
|
|
28
|
-
force_web: Joi.boolean(),
|
|
17
|
+
message: Joi.string().allow(""),
|
|
29
18
|
});
|
|
30
19
|
}
|
|
31
|
-
|
|
32
|
-
static CampaignShortLink() {
|
|
20
|
+
static Page() {
|
|
33
21
|
return Joi.object({
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
22
|
+
current: Joi.number(),
|
|
23
|
+
has_next: Joi.boolean(),
|
|
24
|
+
has_previous: Joi.boolean(),
|
|
25
|
+
item_total: Joi.number(),
|
|
26
|
+
next_id: Joi.string().allow(""),
|
|
27
|
+
size: Joi.number(),
|
|
28
|
+
type: Joi.string().allow("").required(),
|
|
37
29
|
});
|
|
38
30
|
}
|
|
39
|
-
|
|
40
|
-
static Attribution() {
|
|
31
|
+
static RedirectDevice() {
|
|
41
32
|
return Joi.object({
|
|
42
|
-
|
|
33
|
+
link: Joi.string().allow(""),
|
|
34
|
+
type: Joi.string().allow(""),
|
|
43
35
|
});
|
|
44
36
|
}
|
|
45
|
-
|
|
46
|
-
static SocialMediaTags() {
|
|
37
|
+
static Redirects() {
|
|
47
38
|
return Joi.object({
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
39
|
+
android: ShareModel.RedirectDevice(),
|
|
40
|
+
force_web: Joi.boolean(),
|
|
41
|
+
ios: ShareModel.RedirectDevice(),
|
|
42
|
+
web: ShareModel.WebRedirect(),
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
static ShortLinkList() {
|
|
46
|
+
return Joi.object({
|
|
47
|
+
items: Joi.array().items(ShareModel.ShortLinkRes()),
|
|
48
|
+
page: ShareModel.Page(),
|
|
53
49
|
});
|
|
54
50
|
}
|
|
55
|
-
|
|
56
51
|
static ShortLinkReq() {
|
|
57
52
|
return Joi.object({
|
|
58
|
-
title: Joi.string().allow("").required(),
|
|
59
|
-
|
|
60
|
-
url: Joi.string().allow("").required(),
|
|
61
|
-
|
|
62
|
-
hash: Joi.string().allow(""),
|
|
63
|
-
|
|
64
53
|
active: Joi.boolean(),
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
54
|
+
attribution: ShareModel.Attribution(),
|
|
55
|
+
campaign: ShareModel.CampaignShortLink(),
|
|
56
|
+
count: Joi.number(),
|
|
68
57
|
enable_tracking: Joi.boolean(),
|
|
69
|
-
|
|
58
|
+
expire_at: Joi.string().allow(""),
|
|
59
|
+
hash: Joi.string().allow(""),
|
|
70
60
|
personalized: Joi.boolean(),
|
|
71
|
-
|
|
72
|
-
campaign: ShareModel.CampaignShortLink(),
|
|
73
|
-
|
|
74
61
|
redirects: ShareModel.Redirects(),
|
|
75
|
-
|
|
76
|
-
attribution: ShareModel.Attribution(),
|
|
77
|
-
|
|
78
62
|
social_media_tags: ShareModel.SocialMediaTags(),
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
});
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
static UrlInfo() {
|
|
85
|
-
return Joi.object({
|
|
86
|
-
original: Joi.string().allow(""),
|
|
87
|
-
|
|
88
|
-
short: Joi.string().allow(""),
|
|
89
|
-
|
|
90
|
-
hash: Joi.string().allow(""),
|
|
63
|
+
title: Joi.string().allow("").required(),
|
|
64
|
+
url: Joi.string().allow("").required(),
|
|
91
65
|
});
|
|
92
66
|
}
|
|
93
|
-
|
|
94
67
|
static ShortLinkRes() {
|
|
95
68
|
return Joi.object({
|
|
96
|
-
title: Joi.string().allow(""),
|
|
97
|
-
|
|
98
|
-
url: ShareModel.UrlInfo(),
|
|
99
|
-
|
|
100
|
-
created_by: Joi.string().allow(""),
|
|
101
|
-
|
|
102
|
-
app_redirect: Joi.boolean(),
|
|
103
|
-
|
|
104
|
-
fallback: Joi.string().allow(""),
|
|
105
|
-
|
|
106
|
-
active: Joi.boolean(),
|
|
107
|
-
|
|
108
69
|
_id: Joi.string().allow(""),
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
expire_at: Joi.string().allow(""),
|
|
113
|
-
|
|
70
|
+
active: Joi.boolean(),
|
|
71
|
+
app_redirect: Joi.boolean(),
|
|
114
72
|
application: Joi.string().allow(""),
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
73
|
+
attribution: ShareModel.Attribution(),
|
|
74
|
+
campaign: ShareModel.CampaignShortLink(),
|
|
75
|
+
count: Joi.number(),
|
|
118
76
|
created_at: Joi.string().allow(""),
|
|
119
|
-
|
|
77
|
+
created_by: Joi.string().allow(""),
|
|
78
|
+
enable_tracking: Joi.boolean(),
|
|
79
|
+
expire_at: Joi.string().allow(""),
|
|
80
|
+
fallback: Joi.string().allow(""),
|
|
120
81
|
meta: Joi.any(),
|
|
121
|
-
|
|
122
|
-
updated_at: Joi.string().allow(""),
|
|
123
|
-
|
|
124
82
|
personalized: Joi.boolean(),
|
|
125
|
-
|
|
126
|
-
campaign: ShareModel.CampaignShortLink(),
|
|
127
|
-
|
|
128
83
|
redirects: ShareModel.Redirects(),
|
|
129
|
-
|
|
130
|
-
attribution: ShareModel.Attribution(),
|
|
131
|
-
|
|
132
84
|
social_media_tags: ShareModel.SocialMediaTags(),
|
|
133
|
-
|
|
134
|
-
|
|
85
|
+
title: Joi.string().allow(""),
|
|
86
|
+
updated_at: Joi.string().allow(""),
|
|
87
|
+
url: ShareModel.UrlInfo(),
|
|
88
|
+
user_id: Joi.string().allow(""),
|
|
135
89
|
});
|
|
136
90
|
}
|
|
137
|
-
|
|
138
|
-
static Page() {
|
|
91
|
+
static SocialMediaTags() {
|
|
139
92
|
return Joi.object({
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
has_previous: Joi.boolean(),
|
|
145
|
-
|
|
146
|
-
has_next: Joi.boolean(),
|
|
147
|
-
|
|
148
|
-
current: Joi.number(),
|
|
149
|
-
|
|
150
|
-
type: Joi.string().allow("").required(),
|
|
151
|
-
|
|
152
|
-
size: Joi.number(),
|
|
93
|
+
description: Joi.string().allow(""),
|
|
94
|
+
image: Joi.string().allow(""),
|
|
95
|
+
title: Joi.string().allow(""),
|
|
153
96
|
});
|
|
154
97
|
}
|
|
155
|
-
|
|
156
|
-
static ShortLinkList() {
|
|
98
|
+
static UrlInfo() {
|
|
157
99
|
return Joi.object({
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
100
|
+
hash: Joi.string().allow(""),
|
|
101
|
+
original: Joi.string().allow(""),
|
|
102
|
+
short: Joi.string().allow(""),
|
|
161
103
|
});
|
|
162
104
|
}
|
|
163
|
-
|
|
164
|
-
static ErrorRes() {
|
|
105
|
+
static WebRedirect() {
|
|
165
106
|
return Joi.object({
|
|
166
|
-
|
|
107
|
+
link: Joi.string().allow(""),
|
|
108
|
+
type: Joi.string().allow(""),
|
|
167
109
|
});
|
|
168
110
|
}
|
|
169
111
|
}
|