@gofynd/fdk-client-javascript 1.4.2-beta.1 → 1.4.2-beta.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/README.md +1 -1
- package/package.json +1 -1
- package/sdk/application/Cart/CartApplicationModel.d.ts +1742 -1726
- package/sdk/application/Cart/CartApplicationModel.js +1497 -1481
- package/sdk/application/Catalog/CatalogApplicationModel.d.ts +1917 -1917
- package/sdk/application/Catalog/CatalogApplicationModel.js +1611 -1611
- package/sdk/application/Common/CommonApplicationModel.d.ts +235 -235
- package/sdk/application/Common/CommonApplicationModel.js +172 -172
- package/sdk/application/Communication/CommunicationApplicationModel.d.ts +72 -72
- package/sdk/application/Communication/CommunicationApplicationModel.js +64 -64
- package/sdk/application/Configuration/ConfigurationApplicationModel.d.ts +1614 -1614
- package/sdk/application/Configuration/ConfigurationApplicationModel.js +1151 -1151
- package/sdk/application/Content/ContentApplicationModel.d.ts +797 -797
- package/sdk/application/Content/ContentApplicationModel.js +757 -757
- package/sdk/application/FileStorage/FileStorageApplicationModel.d.ts +79 -79
- package/sdk/application/FileStorage/FileStorageApplicationModel.js +84 -84
- package/sdk/application/Lead/LeadApplicationModel.d.ts +417 -417
- package/sdk/application/Lead/LeadApplicationModel.js +301 -301
- package/sdk/application/Logistic/LogisticApplicationModel.d.ts +666 -666
- package/sdk/application/Logistic/LogisticApplicationModel.js +601 -601
- package/sdk/application/Order/OrderApplicationModel.d.ts +846 -846
- package/sdk/application/Order/OrderApplicationModel.js +822 -822
- package/sdk/application/Payment/PaymentApplicationClient.d.ts +5 -5
- package/sdk/application/Payment/PaymentApplicationClient.js +10 -10
- package/sdk/application/Payment/PaymentApplicationModel.d.ts +2155 -2150
- package/sdk/application/Payment/PaymentApplicationModel.js +1460 -1458
- package/sdk/application/Payment/PaymentApplicationValidator.d.ts +5 -5
- package/sdk/application/Payment/PaymentApplicationValidator.js +3 -3
- package/sdk/application/PosCart/PosCartApplicationModel.d.ts +1462 -1462
- package/sdk/application/PosCart/PosCartApplicationModel.js +1260 -1260
- package/sdk/application/Rewards/RewardsApplicationModel.d.ts +214 -214
- package/sdk/application/Rewards/RewardsApplicationModel.js +211 -211
- package/sdk/application/Share/ShareApplicationModel.d.ts +114 -114
- package/sdk/application/Share/ShareApplicationModel.js +121 -121
- package/sdk/application/Theme/ThemeApplicationModel.d.ts +895 -895
- package/sdk/application/Theme/ThemeApplicationModel.js +684 -684
- package/sdk/application/User/UserApplicationModel.d.ts +762 -762
- package/sdk/application/User/UserApplicationModel.js +738 -738
- package/sdk/partner/FileStorage/FileStoragePartnerModel.d.ts +63 -63
- package/sdk/partner/FileStorage/FileStoragePartnerModel.js +65 -65
- package/sdk/partner/Lead/LeadPartnerModel.d.ts +661 -661
- package/sdk/partner/Lead/LeadPartnerModel.js +491 -491
- package/sdk/partner/Logistics/LogisticsPartnerModel.d.ts +223 -223
- package/sdk/partner/Logistics/LogisticsPartnerModel.js +235 -235
- package/sdk/partner/Theme/ThemePartnerModel.d.ts +1087 -1087
- package/sdk/partner/Theme/ThemePartnerModel.js +819 -819
- package/sdk/partner/Webhook/WebhookPartnerModel.d.ts +386 -386
- package/sdk/partner/Webhook/WebhookPartnerModel.js +342 -342
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.d.ts +123 -123
- package/sdk/platform/AuditTrail/AuditTrailPlatformModel.js +109 -109
- package/sdk/platform/Billing/BillingPlatformModel.d.ts +801 -801
- package/sdk/platform/Billing/BillingPlatformModel.js +783 -783
- package/sdk/platform/Cart/CartPlatformModel.d.ts +3333 -3317
- package/sdk/platform/Cart/CartPlatformModel.js +2936 -2920
- package/sdk/platform/Catalog/CatalogPlatformModel.d.ts +1013 -1013
- package/sdk/platform/Catalog/CatalogPlatformModel.js +923 -923
- package/sdk/platform/Common/CommonPlatformModel.d.ts +255 -255
- package/sdk/platform/Common/CommonPlatformModel.js +187 -187
- package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +1238 -1238
- package/sdk/platform/Communication/CommunicationPlatformModel.js +1273 -1273
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.d.ts +661 -661
- package/sdk/platform/CompanyProfile/CompanyProfilePlatformModel.js +692 -692
- package/sdk/platform/Configuration/ConfigurationPlatformModel.d.ts +3198 -3198
- package/sdk/platform/Configuration/ConfigurationPlatformModel.js +2247 -2247
- package/sdk/platform/Content/ContentPlatformModel.d.ts +1833 -1833
- package/sdk/platform/Content/ContentPlatformModel.js +1837 -1837
- package/sdk/platform/Discount/DiscountPlatformModel.d.ts +245 -245
- package/sdk/platform/Discount/DiscountPlatformModel.js +248 -248
- package/sdk/platform/FileStorage/FileStoragePlatformModel.d.ts +865 -865
- package/sdk/platform/FileStorage/FileStoragePlatformModel.js +877 -877
- package/sdk/platform/Finance/FinancePlatformModel.d.ts +1044 -1044
- package/sdk/platform/Finance/FinancePlatformModel.js +974 -974
- package/sdk/platform/Inventory/InventoryPlatformModel.d.ts +942 -942
- package/sdk/platform/Inventory/InventoryPlatformModel.js +1003 -1003
- package/sdk/platform/Lead/LeadPlatformModel.d.ts +608 -608
- package/sdk/platform/Lead/LeadPlatformModel.js +465 -465
- package/sdk/platform/Order/OrderPlatformModel.d.ts +5180 -5176
- package/sdk/platform/Order/OrderPlatformModel.js +4740 -4736
- package/sdk/platform/Partner/PartnerPlatformModel.d.ts +22 -22
- package/sdk/platform/Partner/PartnerPlatformModel.js +22 -22
- package/sdk/platform/Payment/PaymentPlatformModel.d.ts +2670 -2660
- package/sdk/platform/Payment/PaymentPlatformModel.js +1831 -1827
- package/sdk/platform/Rewards/RewardsPlatformModel.d.ts +204 -204
- package/sdk/platform/Rewards/RewardsPlatformModel.js +199 -199
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.d.ts +1505 -1507
- package/sdk/platform/Serviceability/ServiceabilityPlatformModel.js +1532 -1536
- package/sdk/platform/Share/SharePlatformModel.d.ts +147 -147
- package/sdk/platform/Share/SharePlatformModel.js +139 -139
- package/sdk/platform/Theme/ThemePlatformModel.d.ts +1046 -1046
- package/sdk/platform/Theme/ThemePlatformModel.js +789 -789
- package/sdk/platform/User/UserPlatformModel.d.ts +758 -758
- package/sdk/platform/User/UserPlatformModel.js +643 -643
- package/sdk/platform/Webhook/WebhookPlatformModel.d.ts +439 -439
- package/sdk/platform/Webhook/WebhookPlatformModel.js +364 -364
- package/sdk/public/Billing/BillingPublicModel.d.ts +55 -55
- package/sdk/public/Billing/BillingPublicModel.js +51 -51
- package/sdk/public/Configuration/ConfigurationPublicModel.d.ts +237 -237
- package/sdk/public/Configuration/ConfigurationPublicModel.js +174 -174
- package/sdk/public/Content/ContentPublicModel.d.ts +26 -26
- package/sdk/public/Content/ContentPublicModel.js +28 -28
- package/sdk/public/Inventory/InventoryPublicModel.d.ts +237 -237
- package/sdk/public/Inventory/InventoryPublicModel.js +257 -257
- package/sdk/public/Partner/PartnerPublicModel.d.ts +104 -104
- package/sdk/public/Partner/PartnerPublicModel.js +113 -113
- package/sdk/public/Webhook/WebhookPublicModel.d.ts +87 -87
- package/sdk/public/Webhook/WebhookPublicModel.js +93 -93
|
@@ -1,65 +1,22 @@
|
|
|
1
1
|
const Joi = require("joi");
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
|
-
* @typedef
|
|
5
|
-
* @property {
|
|
6
|
-
*/
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* @typedef APIError
|
|
10
|
-
* @property {string} [code]
|
|
11
|
-
* @property {string} [info] - Error code description link
|
|
12
|
-
* @property {string} [message]
|
|
13
|
-
* @property {Object} [meta]
|
|
14
|
-
* @property {string} [request_id]
|
|
15
|
-
*/
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* @typedef AuthenticationApiErrorSchema
|
|
19
|
-
* @property {string} [message]
|
|
20
|
-
*/
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* @typedef AuthenticationInternalServerErrorSchema
|
|
24
|
-
* @property {string} [message]
|
|
25
|
-
*/
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* @typedef AuthSuccess
|
|
29
|
-
* @property {string} [register_token]
|
|
30
|
-
* @property {UserSchema} [user]
|
|
31
|
-
* @property {boolean} [user_exists]
|
|
32
|
-
*/
|
|
33
|
-
|
|
34
|
-
/**
|
|
35
|
-
* @typedef CodeRequestBodySchema
|
|
36
|
-
* @property {string} [code]
|
|
37
|
-
*/
|
|
38
|
-
|
|
39
|
-
/**
|
|
40
|
-
* @typedef DeleteAccountConsent
|
|
41
|
-
* @property {string} [consent_text]
|
|
4
|
+
* @typedef UpdateUserAttributesRequest
|
|
5
|
+
* @property {Object} [attributes]
|
|
42
6
|
*/
|
|
43
7
|
|
|
44
8
|
/**
|
|
45
|
-
* @typedef
|
|
46
|
-
* @property {
|
|
47
|
-
* @property {string} [reason_text]
|
|
48
|
-
* @property {boolean} [show_text_area]
|
|
9
|
+
* @typedef UserAttributes
|
|
10
|
+
* @property {Object} [attributes]
|
|
49
11
|
*/
|
|
50
12
|
|
|
51
13
|
/**
|
|
52
14
|
* @typedef DeleteApplicationUserRequestSchema
|
|
53
|
-
* @property {string} [
|
|
15
|
+
* @property {string} [user_id]
|
|
54
16
|
* @property {string} [reason]
|
|
55
17
|
* @property {string} [reason_id]
|
|
56
18
|
* @property {string} [request_id]
|
|
57
|
-
* @property {string} [
|
|
58
|
-
*/
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
* @typedef DeleteUserSuccess
|
|
62
|
-
* @property {boolean} [success]
|
|
19
|
+
* @property {string} [otp]
|
|
63
20
|
*/
|
|
64
21
|
|
|
65
22
|
/**
|
|
@@ -68,136 +25,157 @@ const Joi = require("joi");
|
|
|
68
25
|
*/
|
|
69
26
|
|
|
70
27
|
/**
|
|
71
|
-
* @typedef
|
|
28
|
+
* @typedef SendVerificationLinkMobileRequestSchema
|
|
29
|
+
* @property {boolean} [verified]
|
|
30
|
+
* @property {boolean} [active]
|
|
72
31
|
* @property {string} [country_code]
|
|
73
32
|
* @property {string} [phone]
|
|
33
|
+
* @property {boolean} [primary]
|
|
74
34
|
*/
|
|
75
35
|
|
|
76
36
|
/**
|
|
77
|
-
* @typedef
|
|
37
|
+
* @typedef EditMobileRequestSchema
|
|
78
38
|
* @property {string} [country_code]
|
|
79
39
|
* @property {string} [phone]
|
|
80
40
|
*/
|
|
81
41
|
|
|
82
42
|
/**
|
|
83
43
|
* @typedef EditProfileRequestSchema
|
|
84
|
-
* @property {string} [android_hash]
|
|
85
|
-
* @property {string} [country_code]
|
|
86
|
-
* @property {string} [dob]
|
|
87
|
-
* @property {string} [email]
|
|
88
44
|
* @property {string} [first_name]
|
|
89
|
-
* @property {string} [gender]
|
|
90
45
|
* @property {string} [last_name]
|
|
91
46
|
* @property {EditProfileMobileSchema} [mobile]
|
|
47
|
+
* @property {string} [country_code]
|
|
48
|
+
* @property {string} [email]
|
|
49
|
+
* @property {string} [gender]
|
|
50
|
+
* @property {string} [dob]
|
|
92
51
|
* @property {string} [profile_pic_url]
|
|
93
|
-
* @property {string} [
|
|
52
|
+
* @property {string} [android_hash]
|
|
94
53
|
* @property {string} [sender]
|
|
54
|
+
* @property {string} [register_token]
|
|
95
55
|
*/
|
|
96
56
|
|
|
97
57
|
/**
|
|
98
|
-
* @typedef
|
|
99
|
-
* @property {
|
|
100
|
-
* @property {string} [
|
|
101
|
-
* @property {boolean} [primary]
|
|
102
|
-
* @property {boolean} [verified]
|
|
58
|
+
* @typedef EditProfileMobileSchema
|
|
59
|
+
* @property {string} [phone]
|
|
60
|
+
* @property {string} [country_code]
|
|
103
61
|
*/
|
|
104
62
|
|
|
105
63
|
/**
|
|
106
|
-
* @typedef
|
|
107
|
-
* @property {
|
|
64
|
+
* @typedef SendEmailOtpRequestSchema
|
|
65
|
+
* @property {string} [email]
|
|
66
|
+
* @property {string} [action]
|
|
67
|
+
* @property {string} [token]
|
|
68
|
+
* @property {string} [register_token]
|
|
108
69
|
*/
|
|
109
70
|
|
|
110
71
|
/**
|
|
111
|
-
* @typedef
|
|
112
|
-
* @property {string} [
|
|
72
|
+
* @typedef SendEmailForgotOtpRequestSchema
|
|
73
|
+
* @property {string} [email]
|
|
74
|
+
* @property {string} [action]
|
|
75
|
+
* @property {string} [token]
|
|
113
76
|
*/
|
|
114
77
|
|
|
115
78
|
/**
|
|
116
|
-
* @typedef
|
|
117
|
-
* @property {string} [
|
|
118
|
-
* @property {string} [
|
|
119
|
-
* @property {string} [
|
|
79
|
+
* @typedef VerifyEmailOtpRequestSchema
|
|
80
|
+
* @property {string} [email]
|
|
81
|
+
* @property {string} [action]
|
|
82
|
+
* @property {string} [register_token]
|
|
83
|
+
* @property {string} [otp]
|
|
120
84
|
*/
|
|
121
85
|
|
|
122
86
|
/**
|
|
123
|
-
* @typedef
|
|
124
|
-
* @property {string} [
|
|
125
|
-
* @property {string} [
|
|
87
|
+
* @typedef VerifyEmailForgotOtpRequestSchema
|
|
88
|
+
* @property {string} [email]
|
|
89
|
+
* @property {string} [otp]
|
|
126
90
|
*/
|
|
127
91
|
|
|
128
92
|
/**
|
|
129
|
-
* @typedef
|
|
130
|
-
* @property {string} [
|
|
131
|
-
* @property {string} [first_name]
|
|
132
|
-
* @property {string} [gender]
|
|
133
|
-
* @property {string} [last_name]
|
|
134
|
-
* @property {string} [password]
|
|
135
|
-
* @property {FormRegisterRequestSchemaPhone} [phone]
|
|
93
|
+
* @typedef VerifyOtpRequestSchema
|
|
94
|
+
* @property {string} [request_id]
|
|
136
95
|
* @property {string} [register_token]
|
|
96
|
+
* @property {string} [otp]
|
|
137
97
|
*/
|
|
138
98
|
|
|
139
99
|
/**
|
|
140
|
-
* @typedef
|
|
141
|
-
* @property {string} [
|
|
142
|
-
* @property {string} [
|
|
100
|
+
* @typedef VerifyMobileForgotOtpRequestSchema
|
|
101
|
+
* @property {string} [request_id]
|
|
102
|
+
* @property {string} [otp]
|
|
143
103
|
*/
|
|
144
104
|
|
|
145
105
|
/**
|
|
146
|
-
* @typedef
|
|
147
|
-
* @property {string} [
|
|
106
|
+
* @typedef SendMobileOtpRequestSchema
|
|
107
|
+
* @property {string} [mobile]
|
|
108
|
+
* @property {string} [country_code]
|
|
109
|
+
* @property {string} [action]
|
|
110
|
+
* @property {string} [token]
|
|
111
|
+
* @property {string} [android_hash]
|
|
112
|
+
* @property {string} [force]
|
|
148
113
|
*/
|
|
149
114
|
|
|
150
115
|
/**
|
|
151
|
-
* @typedef
|
|
152
|
-
* @property {
|
|
116
|
+
* @typedef SendMobileForgotOtpRequestSchema
|
|
117
|
+
* @property {string} [mobile]
|
|
118
|
+
* @property {string} [country_code]
|
|
119
|
+
* @property {string} [action]
|
|
120
|
+
* @property {string} [token]
|
|
121
|
+
* @property {string} [android_hash]
|
|
153
122
|
*/
|
|
154
123
|
|
|
155
124
|
/**
|
|
156
|
-
* @typedef
|
|
157
|
-
* @property {
|
|
158
|
-
* @property {
|
|
125
|
+
* @typedef UpdatePasswordRequestSchema
|
|
126
|
+
* @property {string} [old_password]
|
|
127
|
+
* @property {string} [new_password]
|
|
159
128
|
*/
|
|
160
129
|
|
|
161
130
|
/**
|
|
162
|
-
* @typedef
|
|
131
|
+
* @typedef FormRegisterRequestSchema
|
|
132
|
+
* @property {string} [first_name]
|
|
133
|
+
* @property {string} [last_name]
|
|
134
|
+
* @property {string} [gender]
|
|
135
|
+
* @property {string} [email]
|
|
136
|
+
* @property {string} [password]
|
|
137
|
+
* @property {FormRegisterRequestSchemaPhone} [phone]
|
|
163
138
|
* @property {string} [register_token]
|
|
164
|
-
* @property {string} [request_id]
|
|
165
|
-
* @property {UserSchema} [user]
|
|
166
139
|
*/
|
|
167
140
|
|
|
168
141
|
/**
|
|
169
|
-
* @typedef
|
|
170
|
-
* @property {
|
|
142
|
+
* @typedef TokenRequestBodySchema
|
|
143
|
+
* @property {string} [token]
|
|
171
144
|
*/
|
|
172
145
|
|
|
173
146
|
/**
|
|
174
|
-
* @typedef
|
|
175
|
-
* @property {string} [
|
|
176
|
-
* @property {string} [
|
|
147
|
+
* @typedef ForgotPasswordRequestSchema
|
|
148
|
+
* @property {string} [code]
|
|
149
|
+
* @property {string} [password]
|
|
177
150
|
*/
|
|
178
151
|
|
|
179
152
|
/**
|
|
180
|
-
* @typedef
|
|
181
|
-
* @property {
|
|
153
|
+
* @typedef CodeRequestBodySchema
|
|
154
|
+
* @property {string} [code]
|
|
182
155
|
*/
|
|
183
156
|
|
|
184
157
|
/**
|
|
185
|
-
* @typedef
|
|
186
|
-
* @property {
|
|
187
|
-
* @property {OAuthRequestAppleSchemaProfile} [profile]
|
|
188
|
-
* @property {string} [user_identifier]
|
|
158
|
+
* @typedef SendResetPasswordEmailRequestSchema
|
|
159
|
+
* @property {string} [email]
|
|
189
160
|
*/
|
|
190
161
|
|
|
191
162
|
/**
|
|
192
|
-
* @typedef
|
|
193
|
-
* @property {string} [
|
|
163
|
+
* @typedef SendResetPasswordMobileRequestSchema
|
|
164
|
+
* @property {string} [country_code]
|
|
165
|
+
* @property {string} [mobile]
|
|
194
166
|
*/
|
|
195
167
|
|
|
196
168
|
/**
|
|
197
|
-
* @typedef
|
|
198
|
-
* @property {string} [
|
|
199
|
-
* @property {string} [
|
|
200
|
-
|
|
169
|
+
* @typedef PasswordLoginRequestSchema
|
|
170
|
+
* @property {string} [password]
|
|
171
|
+
* @property {string} [username]
|
|
172
|
+
*/
|
|
173
|
+
|
|
174
|
+
/**
|
|
175
|
+
* @typedef SendOtpRequestSchema
|
|
176
|
+
* @property {string} [country_code]
|
|
177
|
+
* @property {string} [mobile]
|
|
178
|
+
* @property {string} [android_hash]
|
|
201
179
|
*/
|
|
202
180
|
|
|
203
181
|
/**
|
|
@@ -208,173 +186,169 @@ const Joi = require("joi");
|
|
|
208
186
|
*/
|
|
209
187
|
|
|
210
188
|
/**
|
|
211
|
-
* @typedef
|
|
212
|
-
* @property {string} [
|
|
213
|
-
* @property {
|
|
214
|
-
* @property {
|
|
189
|
+
* @typedef OAuthRequestAppleSchema
|
|
190
|
+
* @property {string} [user_identifier]
|
|
191
|
+
* @property {OAuthRequestAppleSchemaOauth} [oauth]
|
|
192
|
+
* @property {OAuthRequestAppleSchemaProfile} [profile]
|
|
215
193
|
*/
|
|
216
194
|
|
|
217
195
|
/**
|
|
218
|
-
* @typedef
|
|
219
|
-
* @property {
|
|
220
|
-
* @property {string} [first_name]
|
|
221
|
-
* @property {string} [full_name]
|
|
222
|
-
* @property {string} [id]
|
|
223
|
-
* @property {string} [image]
|
|
224
|
-
* @property {string} [last_name]
|
|
196
|
+
* @typedef UserObjectSchema
|
|
197
|
+
* @property {UserSchema} [user]
|
|
225
198
|
*/
|
|
226
199
|
|
|
227
200
|
/**
|
|
228
|
-
* @typedef
|
|
229
|
-
* @property {string} [country_code]
|
|
230
|
-
* @property {string} [message]
|
|
231
|
-
* @property {string} [mobile]
|
|
201
|
+
* @typedef AuthSuccess
|
|
232
202
|
* @property {string} [register_token]
|
|
233
|
-
* @property {
|
|
234
|
-
* @property {
|
|
235
|
-
* @property {string} [resend_token]
|
|
236
|
-
* @property {boolean} [success]
|
|
203
|
+
* @property {boolean} [user_exists]
|
|
204
|
+
* @property {UserSchema} [user]
|
|
237
205
|
*/
|
|
238
206
|
|
|
239
207
|
/**
|
|
240
|
-
* @typedef
|
|
241
|
-
* @property {
|
|
242
|
-
* @property {string} [username]
|
|
208
|
+
* @typedef UserExistsResponse
|
|
209
|
+
* @property {boolean} [user_exists]
|
|
243
210
|
*/
|
|
244
211
|
|
|
245
212
|
/**
|
|
246
|
-
* @typedef
|
|
247
|
-
* @property {
|
|
248
|
-
* @property {
|
|
249
|
-
* @property {
|
|
250
|
-
* @property {
|
|
251
|
-
* @property {
|
|
213
|
+
* @typedef SendOtpResponse
|
|
214
|
+
* @property {number} [resend_timer]
|
|
215
|
+
* @property {string} [resend_token]
|
|
216
|
+
* @property {boolean} [success]
|
|
217
|
+
* @property {string} [request_id]
|
|
218
|
+
* @property {string} [message]
|
|
219
|
+
* @property {string} [mobile]
|
|
220
|
+
* @property {string} [country_code]
|
|
221
|
+
* @property {string} [email]
|
|
222
|
+
* @property {string} [resend_email_token]
|
|
223
|
+
* @property {string} [register_token]
|
|
224
|
+
* @property {boolean} [verify_email_otp]
|
|
225
|
+
* @property {boolean} [verify_mobile_otp]
|
|
226
|
+
* @property {boolean} [user_exists]
|
|
252
227
|
*/
|
|
253
228
|
|
|
254
229
|
/**
|
|
255
|
-
* @typedef
|
|
256
|
-
* @property {
|
|
257
|
-
* @property {string} [
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
* @
|
|
262
|
-
* @property {boolean} [
|
|
263
|
-
* @property {string} [
|
|
230
|
+
* @typedef ProfileEditSuccess
|
|
231
|
+
* @property {UserSchema} [user]
|
|
232
|
+
* @property {string} [register_token]
|
|
233
|
+
* @property {string} [resend_email_token]
|
|
234
|
+
* @property {boolean} [user_exists]
|
|
235
|
+
* @property {boolean} [verify_email_link]
|
|
236
|
+
* @property {boolean} [verify_email_otp]
|
|
237
|
+
* @property {boolean} [verify_mobile_otp]
|
|
238
|
+
* @property {string} [email]
|
|
239
|
+
* @property {string} [request_id]
|
|
240
|
+
* @property {string} [country_code]
|
|
241
|
+
* @property {string} [mobile]
|
|
242
|
+
* @property {boolean} [success]
|
|
243
|
+
* @property {string} [message]
|
|
244
|
+
* @property {number} [resend_timer]
|
|
245
|
+
* @property {string} [resend_token]
|
|
264
246
|
*/
|
|
265
247
|
|
|
266
248
|
/**
|
|
267
|
-
* @typedef
|
|
268
|
-
* @property {
|
|
269
|
-
* @property {
|
|
270
|
-
* @property {string} [
|
|
271
|
-
* @property {Object} [delete_account_consent]
|
|
272
|
-
* @property {number} [delete_account_day]
|
|
273
|
-
* @property {DeleteAccountReasons[]} [delete_account_reasons]
|
|
274
|
-
* @property {string} [desktop_image]
|
|
275
|
-
* @property {string} [display]
|
|
276
|
-
* @property {FlashCard} [flash_card]
|
|
277
|
-
* @property {boolean} [forgot_password]
|
|
278
|
-
* @property {Login} [login]
|
|
279
|
-
* @property {LookAndFeel} [look_and_feel]
|
|
280
|
-
* @property {MetaSchema} [meta]
|
|
281
|
-
* @property {string} [mobile_image]
|
|
282
|
-
* @property {string} [name]
|
|
283
|
-
* @property {boolean} [register]
|
|
284
|
-
* @property {RegisterRequiredFields} [register_required_fields]
|
|
285
|
-
* @property {RequiredFields} [required_fields]
|
|
286
|
-
* @property {Object} [session_config]
|
|
287
|
-
* @property {boolean} [skip_captcha]
|
|
288
|
-
* @property {boolean} [skip_login]
|
|
289
|
-
* @property {Social} [social]
|
|
290
|
-
* @property {SocialTokens} [social_tokens]
|
|
291
|
-
* @property {string} [subtext]
|
|
292
|
-
* @property {string} [updated_at]
|
|
249
|
+
* @typedef LoginSuccess
|
|
250
|
+
* @property {UserSchema} [user]
|
|
251
|
+
* @property {string} [request_id]
|
|
252
|
+
* @property {string} [register_token]
|
|
293
253
|
*/
|
|
294
254
|
|
|
295
255
|
/**
|
|
296
|
-
* @typedef
|
|
297
|
-
* @property {string} [country_code]
|
|
298
|
-
* @property {string} [email]
|
|
299
|
-
* @property {string} [message]
|
|
300
|
-
* @property {string} [mobile]
|
|
301
|
-
* @property {string} [register_token]
|
|
302
|
-
* @property {string} [request_id]
|
|
303
|
-
* @property {string} [resend_email_token]
|
|
304
|
-
* @property {number} [resend_timer]
|
|
305
|
-
* @property {string} [resend_token]
|
|
256
|
+
* @typedef ResetForgotPasswordSuccess
|
|
306
257
|
* @property {boolean} [success]
|
|
258
|
+
*/
|
|
259
|
+
|
|
260
|
+
/**
|
|
261
|
+
* @typedef VerifyOtpSuccess
|
|
307
262
|
* @property {UserSchema} [user]
|
|
308
263
|
* @property {boolean} [user_exists]
|
|
309
|
-
* @property {
|
|
310
|
-
|
|
311
|
-
|
|
264
|
+
* @property {string} [register_token]
|
|
265
|
+
*/
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* @typedef VerifyForgotOtpSuccess
|
|
269
|
+
* @property {boolean} [success]
|
|
270
|
+
* @property {string} [forgot_token]
|
|
271
|
+
*/
|
|
272
|
+
|
|
273
|
+
/**
|
|
274
|
+
* @typedef ResetPasswordSuccess
|
|
275
|
+
* @property {string} [status]
|
|
312
276
|
*/
|
|
313
277
|
|
|
314
278
|
/**
|
|
315
279
|
* @typedef RegisterFormSuccess
|
|
316
|
-
* @property {string} [country_code]
|
|
317
280
|
* @property {string} [email]
|
|
318
|
-
* @property {string} [message]
|
|
319
|
-
* @property {string} [mobile]
|
|
320
|
-
* @property {string} [register_token]
|
|
321
|
-
* @property {string} [request_id]
|
|
322
|
-
* @property {string} [resend_email_token]
|
|
323
281
|
* @property {number} [resend_timer]
|
|
324
282
|
* @property {string} [resend_token]
|
|
283
|
+
* @property {string} [resend_email_token]
|
|
284
|
+
* @property {string} [register_token]
|
|
325
285
|
* @property {boolean} [success]
|
|
326
|
-
* @property {
|
|
286
|
+
* @property {string} [request_id]
|
|
287
|
+
* @property {string} [message]
|
|
288
|
+
* @property {string} [mobile]
|
|
289
|
+
* @property {string} [country_code]
|
|
327
290
|
* @property {boolean} [verify_email_otp]
|
|
328
291
|
* @property {boolean} [verify_mobile_otp]
|
|
292
|
+
* @property {boolean} [user_exists]
|
|
329
293
|
*/
|
|
330
294
|
|
|
331
295
|
/**
|
|
332
|
-
* @typedef
|
|
333
|
-
* @property {
|
|
334
|
-
* @property {RegisterRequiredFieldsMobile} [mobile]
|
|
296
|
+
* @typedef VerifyEmailSuccess
|
|
297
|
+
* @property {string} [message]
|
|
335
298
|
*/
|
|
336
299
|
|
|
337
300
|
/**
|
|
338
|
-
* @typedef
|
|
339
|
-
* @property {boolean} [
|
|
340
|
-
* @property {string} [level]
|
|
301
|
+
* @typedef HasPasswordSuccess
|
|
302
|
+
* @property {boolean} [result]
|
|
341
303
|
*/
|
|
342
304
|
|
|
343
305
|
/**
|
|
344
|
-
* @typedef
|
|
345
|
-
* @property {boolean} [
|
|
346
|
-
* @property {string} [level]
|
|
306
|
+
* @typedef LogoutSuccess
|
|
307
|
+
* @property {boolean} [logout]
|
|
347
308
|
*/
|
|
348
309
|
|
|
349
310
|
/**
|
|
350
|
-
* @typedef
|
|
351
|
-
* @property {
|
|
352
|
-
* @property {PlatformMobile} [mobile]
|
|
311
|
+
* @typedef DeleteUserSuccess
|
|
312
|
+
* @property {boolean} [success]
|
|
353
313
|
*/
|
|
354
314
|
|
|
355
315
|
/**
|
|
356
|
-
* @typedef
|
|
316
|
+
* @typedef OtpSuccess
|
|
317
|
+
* @property {number} [resend_timer]
|
|
318
|
+
* @property {string} [resend_token]
|
|
319
|
+
* @property {string} [register_token]
|
|
357
320
|
* @property {boolean} [success]
|
|
321
|
+
* @property {string} [request_id]
|
|
322
|
+
* @property {string} [message]
|
|
323
|
+
* @property {string} [mobile]
|
|
324
|
+
* @property {string} [country_code]
|
|
358
325
|
*/
|
|
359
326
|
|
|
360
327
|
/**
|
|
361
|
-
* @typedef
|
|
362
|
-
* @property {
|
|
328
|
+
* @typedef EmailOtpSuccess
|
|
329
|
+
* @property {boolean} [success]
|
|
363
330
|
*/
|
|
364
331
|
|
|
365
332
|
/**
|
|
366
|
-
* @typedef
|
|
367
|
-
* @property {string} [
|
|
368
|
-
* @property {string} [email]
|
|
369
|
-
* @property {string} [token]
|
|
333
|
+
* @typedef SessionListSuccess
|
|
334
|
+
* @property {string[]} [sessions]
|
|
370
335
|
*/
|
|
371
336
|
|
|
372
337
|
/**
|
|
373
|
-
* @typedef
|
|
374
|
-
* @property {
|
|
375
|
-
* @property {
|
|
376
|
-
|
|
377
|
-
|
|
338
|
+
* @typedef VerifyMobileOTPSuccess
|
|
339
|
+
* @property {UserSchema} [user]
|
|
340
|
+
* @property {boolean} [verify_mobile_link]
|
|
341
|
+
*/
|
|
342
|
+
|
|
343
|
+
/**
|
|
344
|
+
* @typedef VerifyEmailOTPSuccess
|
|
345
|
+
* @property {UserSchema} [user]
|
|
346
|
+
* @property {boolean} [verify_email_link]
|
|
347
|
+
*/
|
|
348
|
+
|
|
349
|
+
/**
|
|
350
|
+
* @typedef SendMobileVerifyLinkSuccess
|
|
351
|
+
* @property {boolean} [verify_mobile_link]
|
|
378
352
|
*/
|
|
379
353
|
|
|
380
354
|
/**
|
|
@@ -383,288 +357,257 @@ const Joi = require("joi");
|
|
|
383
357
|
*/
|
|
384
358
|
|
|
385
359
|
/**
|
|
386
|
-
* @typedef
|
|
387
|
-
* @property {string} [
|
|
388
|
-
* @property {string} [android_hash]
|
|
389
|
-
* @property {string} [country_code]
|
|
390
|
-
* @property {string} [mobile]
|
|
391
|
-
* @property {string} [token]
|
|
360
|
+
* @typedef AuthenticationInternalServerErrorSchema
|
|
361
|
+
* @property {string} [message]
|
|
392
362
|
*/
|
|
393
363
|
|
|
394
364
|
/**
|
|
395
|
-
* @typedef
|
|
396
|
-
* @property {string} [
|
|
397
|
-
* @property {string} [android_hash]
|
|
398
|
-
* @property {string} [country_code]
|
|
399
|
-
* @property {string} [force]
|
|
400
|
-
* @property {string} [mobile]
|
|
401
|
-
* @property {string} [token]
|
|
365
|
+
* @typedef AuthenticationApiErrorSchema
|
|
366
|
+
* @property {string} [message]
|
|
402
367
|
*/
|
|
403
368
|
|
|
404
369
|
/**
|
|
405
|
-
* @typedef
|
|
406
|
-
* @property {
|
|
370
|
+
* @typedef APIError
|
|
371
|
+
* @property {string} [code]
|
|
372
|
+
* @property {string} [message]
|
|
373
|
+
* @property {string} [info] - Error code description link
|
|
374
|
+
* @property {string} [request_id]
|
|
375
|
+
* @property {Object} [meta]
|
|
407
376
|
*/
|
|
408
377
|
|
|
409
378
|
/**
|
|
410
|
-
* @typedef
|
|
411
|
-
* @property {string} [android_hash]
|
|
379
|
+
* @typedef FormRegisterRequestSchemaPhone
|
|
412
380
|
* @property {string} [country_code]
|
|
413
381
|
* @property {string} [mobile]
|
|
414
382
|
*/
|
|
415
383
|
|
|
416
384
|
/**
|
|
417
|
-
* @typedef
|
|
418
|
-
* @property {string} [
|
|
419
|
-
* @property {
|
|
420
|
-
* @property {string} [
|
|
421
|
-
* @property {string} [mobile]
|
|
422
|
-
* @property {string} [register_token]
|
|
423
|
-
* @property {string} [request_id]
|
|
424
|
-
* @property {string} [resend_email_token]
|
|
425
|
-
* @property {number} [resend_timer]
|
|
426
|
-
* @property {string} [resend_token]
|
|
427
|
-
* @property {boolean} [success]
|
|
428
|
-
* @property {boolean} [user_exists]
|
|
429
|
-
* @property {boolean} [verify_email_otp]
|
|
430
|
-
* @property {boolean} [verify_mobile_otp]
|
|
385
|
+
* @typedef OAuthRequestSchemaOauth2
|
|
386
|
+
* @property {string} [access_token]
|
|
387
|
+
* @property {number} [expiry]
|
|
388
|
+
* @property {string} [refresh_token]
|
|
431
389
|
*/
|
|
432
390
|
|
|
433
391
|
/**
|
|
434
|
-
* @typedef
|
|
392
|
+
* @typedef OAuthRequestSchemaProfile
|
|
393
|
+
* @property {string} [last_name]
|
|
394
|
+
* @property {string} [image]
|
|
395
|
+
* @property {string} [id]
|
|
435
396
|
* @property {string} [email]
|
|
397
|
+
* @property {string} [full_name]
|
|
398
|
+
* @property {string} [first_name]
|
|
436
399
|
*/
|
|
437
400
|
|
|
438
401
|
/**
|
|
439
|
-
* @typedef
|
|
440
|
-
* @property {string} [
|
|
441
|
-
* @property {string} [mobile]
|
|
402
|
+
* @typedef OAuthRequestAppleSchemaOauth
|
|
403
|
+
* @property {string} [identity_token]
|
|
442
404
|
*/
|
|
443
405
|
|
|
444
406
|
/**
|
|
445
|
-
* @typedef
|
|
407
|
+
* @typedef OAuthRequestAppleSchemaProfile
|
|
408
|
+
* @property {string} [last_name]
|
|
409
|
+
* @property {string} [full_name]
|
|
410
|
+
* @property {string} [first_name]
|
|
411
|
+
*/
|
|
412
|
+
|
|
413
|
+
/**
|
|
414
|
+
* @typedef PlatformSchema
|
|
415
|
+
* @property {string} [display]
|
|
416
|
+
* @property {LookAndFeel} [look_and_feel]
|
|
417
|
+
* @property {string} [updated_at]
|
|
446
418
|
* @property {boolean} [active]
|
|
447
|
-
* @property {
|
|
448
|
-
* @property {
|
|
449
|
-
* @property {boolean} [
|
|
450
|
-
* @property {
|
|
419
|
+
* @property {boolean} [forgot_password]
|
|
420
|
+
* @property {Login} [login]
|
|
421
|
+
* @property {boolean} [skip_captcha]
|
|
422
|
+
* @property {string} [name]
|
|
423
|
+
* @property {MetaSchema} [meta]
|
|
424
|
+
* @property {string} [_id]
|
|
425
|
+
* @property {Social} [social]
|
|
426
|
+
* @property {RequiredFields} [required_fields]
|
|
427
|
+
* @property {RegisterRequiredFields} [register_required_fields]
|
|
428
|
+
* @property {boolean} [skip_login]
|
|
429
|
+
* @property {FlashCard} [flash_card]
|
|
430
|
+
* @property {string} [subtext]
|
|
431
|
+
* @property {SocialTokens} [social_tokens]
|
|
432
|
+
* @property {string} [created_at]
|
|
433
|
+
* @property {boolean} [register]
|
|
434
|
+
* @property {string} [mobile_image]
|
|
435
|
+
* @property {string} [desktop_image]
|
|
436
|
+
* @property {number} [delete_account_day]
|
|
437
|
+
* @property {DeleteAccountReasons[]} [delete_account_reasons]
|
|
438
|
+
* @property {Object} [delete_account_consent]
|
|
439
|
+
* @property {Object} [session_config]
|
|
451
440
|
*/
|
|
452
441
|
|
|
453
442
|
/**
|
|
454
|
-
* @typedef
|
|
455
|
-
* @property {
|
|
456
|
-
* @property {
|
|
457
|
-
* @property {string} [type]
|
|
443
|
+
* @typedef LookAndFeel
|
|
444
|
+
* @property {string} [card_position]
|
|
445
|
+
* @property {string} [background_color]
|
|
458
446
|
*/
|
|
459
447
|
|
|
460
448
|
/**
|
|
461
|
-
* @typedef
|
|
462
|
-
* @property {
|
|
449
|
+
* @typedef Login
|
|
450
|
+
* @property {boolean} [password]
|
|
451
|
+
* @property {boolean} [otp]
|
|
452
|
+
*/
|
|
453
|
+
|
|
454
|
+
/**
|
|
455
|
+
* @typedef MetaSchema
|
|
456
|
+
* @property {boolean} [fynd_default]
|
|
463
457
|
*/
|
|
464
458
|
|
|
465
459
|
/**
|
|
466
460
|
* @typedef Social
|
|
467
461
|
* @property {boolean} [account_kit]
|
|
468
|
-
* @property {boolean} [apple]
|
|
469
462
|
* @property {boolean} [facebook]
|
|
470
463
|
* @property {boolean} [google]
|
|
464
|
+
* @property {boolean} [apple]
|
|
471
465
|
*/
|
|
472
466
|
|
|
473
467
|
/**
|
|
474
|
-
* @typedef
|
|
475
|
-
* @property {
|
|
476
|
-
* @property {
|
|
477
|
-
* @property {Google} [google]
|
|
468
|
+
* @typedef RequiredFields
|
|
469
|
+
* @property {PlatformEmail} [email]
|
|
470
|
+
* @property {PlatformMobile} [mobile]
|
|
478
471
|
*/
|
|
479
472
|
|
|
480
473
|
/**
|
|
481
|
-
* @typedef
|
|
482
|
-
* @property {
|
|
474
|
+
* @typedef PlatformEmail
|
|
475
|
+
* @property {boolean} [is_required]
|
|
476
|
+
* @property {string} [level]
|
|
483
477
|
*/
|
|
484
478
|
|
|
485
479
|
/**
|
|
486
|
-
* @typedef
|
|
487
|
-
* @property {
|
|
488
|
-
* @property {string} [
|
|
480
|
+
* @typedef PlatformMobile
|
|
481
|
+
* @property {boolean} [is_required]
|
|
482
|
+
* @property {string} [level]
|
|
489
483
|
*/
|
|
490
484
|
|
|
491
485
|
/**
|
|
492
|
-
* @typedef
|
|
493
|
-
* @property {
|
|
486
|
+
* @typedef RegisterRequiredFields
|
|
487
|
+
* @property {RegisterRequiredFieldsEmail} [email]
|
|
488
|
+
* @property {RegisterRequiredFieldsMobile} [mobile]
|
|
494
489
|
*/
|
|
495
490
|
|
|
496
491
|
/**
|
|
497
|
-
* @typedef
|
|
498
|
-
* @property {
|
|
492
|
+
* @typedef RegisterRequiredFieldsEmail
|
|
493
|
+
* @property {boolean} [is_required]
|
|
494
|
+
* @property {string} [level]
|
|
499
495
|
*/
|
|
500
496
|
|
|
501
497
|
/**
|
|
502
|
-
* @typedef
|
|
503
|
-
* @property {boolean} [
|
|
498
|
+
* @typedef RegisterRequiredFieldsMobile
|
|
499
|
+
* @property {boolean} [is_required]
|
|
500
|
+
* @property {string} [level]
|
|
504
501
|
*/
|
|
505
502
|
|
|
506
503
|
/**
|
|
507
|
-
* @typedef
|
|
508
|
-
* @property {
|
|
504
|
+
* @typedef FlashCard
|
|
505
|
+
* @property {string} [text]
|
|
506
|
+
* @property {string} [text_color]
|
|
507
|
+
* @property {string} [background_color]
|
|
509
508
|
*/
|
|
510
509
|
|
|
511
510
|
/**
|
|
512
|
-
* @typedef
|
|
513
|
-
* @property {
|
|
514
|
-
* @property {
|
|
515
|
-
* @property {
|
|
516
|
-
* @property {string} [application_id]
|
|
517
|
-
* @property {string} [created_at]
|
|
518
|
-
* @property {string} [dob]
|
|
519
|
-
* @property {Email[]} [emails]
|
|
520
|
-
* @property {string} [first_name]
|
|
521
|
-
* @property {string} [gender]
|
|
522
|
-
* @property {string} [last_name]
|
|
523
|
-
* @property {Object} [meta]
|
|
524
|
-
* @property {PhoneNumber[]} [phone_numbers]
|
|
525
|
-
* @property {string} [profile_pic_url]
|
|
526
|
-
* @property {string} [updated_at]
|
|
527
|
-
* @property {string} [user_id]
|
|
528
|
-
* @property {string} [username]
|
|
511
|
+
* @typedef SocialTokens
|
|
512
|
+
* @property {Facebook} [facebook]
|
|
513
|
+
* @property {Accountkit} [account_kit]
|
|
514
|
+
* @property {Google} [google]
|
|
529
515
|
*/
|
|
530
516
|
|
|
531
517
|
/**
|
|
532
|
-
* @typedef
|
|
533
|
-
* @property {string} [
|
|
534
|
-
* @property {string} [
|
|
518
|
+
* @typedef DeleteAccountReasons
|
|
519
|
+
* @property {string} [reason_text]
|
|
520
|
+
* @property {string} [reason_id]
|
|
521
|
+
* @property {boolean} [show_text_area]
|
|
535
522
|
*/
|
|
536
523
|
|
|
537
524
|
/**
|
|
538
|
-
* @typedef
|
|
539
|
-
* @property {string} [
|
|
540
|
-
* @property {string} [email]
|
|
541
|
-
* @property {string} [otp]
|
|
542
|
-
* @property {string} [register_token]
|
|
525
|
+
* @typedef DeleteAccountConsent
|
|
526
|
+
* @property {string} [consent_text]
|
|
543
527
|
*/
|
|
544
528
|
|
|
545
529
|
/**
|
|
546
|
-
* @typedef
|
|
547
|
-
* @property {
|
|
548
|
-
* @property {boolean} [verify_email_link]
|
|
530
|
+
* @typedef Facebook
|
|
531
|
+
* @property {string} [app_id]
|
|
549
532
|
*/
|
|
550
533
|
|
|
551
534
|
/**
|
|
552
|
-
* @typedef
|
|
553
|
-
* @property {string} [
|
|
535
|
+
* @typedef Accountkit
|
|
536
|
+
* @property {string} [app_id]
|
|
554
537
|
*/
|
|
555
538
|
|
|
556
539
|
/**
|
|
557
|
-
* @typedef
|
|
558
|
-
* @property {string} [
|
|
559
|
-
* @property {boolean} [success]
|
|
540
|
+
* @typedef Google
|
|
541
|
+
* @property {string} [app_id]
|
|
560
542
|
*/
|
|
561
543
|
|
|
562
544
|
/**
|
|
563
|
-
* @typedef
|
|
564
|
-
* @property {
|
|
565
|
-
* @property {string} [
|
|
545
|
+
* @typedef SessionExpiry
|
|
546
|
+
* @property {number} [duration]
|
|
547
|
+
* @property {string} [type]
|
|
548
|
+
* @property {boolean} [is_rolling]
|
|
566
549
|
*/
|
|
567
550
|
|
|
568
551
|
/**
|
|
569
|
-
* @typedef
|
|
570
|
-
* @property {
|
|
571
|
-
* @property {
|
|
552
|
+
* @typedef UserSchema
|
|
553
|
+
* @property {string} [application_id]
|
|
554
|
+
* @property {string} [user_id]
|
|
555
|
+
* @property {string} [first_name]
|
|
556
|
+
* @property {Object} [meta]
|
|
557
|
+
* @property {string} [last_name]
|
|
558
|
+
* @property {PhoneNumber[]} [phone_numbers]
|
|
559
|
+
* @property {Email[]} [emails]
|
|
560
|
+
* @property {string} [gender]
|
|
561
|
+
* @property {string} [dob]
|
|
562
|
+
* @property {boolean} [active]
|
|
563
|
+
* @property {string} [profile_pic_url]
|
|
564
|
+
* @property {string} [username]
|
|
565
|
+
* @property {string} [account_type]
|
|
566
|
+
* @property {string} [_id]
|
|
567
|
+
* @property {string} [created_at]
|
|
568
|
+
* @property {string} [updated_at]
|
|
572
569
|
*/
|
|
573
570
|
|
|
574
571
|
/**
|
|
575
|
-
* @typedef
|
|
576
|
-
* @property {
|
|
577
|
-
* @property {
|
|
578
|
-
* @property {
|
|
572
|
+
* @typedef PhoneNumber
|
|
573
|
+
* @property {boolean} [active]
|
|
574
|
+
* @property {boolean} [primary]
|
|
575
|
+
* @property {boolean} [verified]
|
|
576
|
+
* @property {string} [phone]
|
|
577
|
+
* @property {number} [country_code]
|
|
579
578
|
*/
|
|
580
579
|
|
|
581
580
|
/**
|
|
582
|
-
* @typedef
|
|
583
|
-
* @property {
|
|
584
|
-
* @property {
|
|
585
|
-
* @property {
|
|
581
|
+
* @typedef Email
|
|
582
|
+
* @property {boolean} [primary]
|
|
583
|
+
* @property {boolean} [verified]
|
|
584
|
+
* @property {string} [email]
|
|
585
|
+
* @property {boolean} [active]
|
|
586
586
|
*/
|
|
587
|
-
|
|
588
|
-
class UserApplicationModel {
|
|
589
|
-
/** @returns {
|
|
590
|
-
static
|
|
591
|
-
return Joi.object({
|
|
592
|
-
app_id: Joi.string().allow(""),
|
|
593
|
-
});
|
|
594
|
-
}
|
|
595
|
-
|
|
596
|
-
/** @returns {APIError} */
|
|
597
|
-
static APIError() {
|
|
598
|
-
return Joi.object({
|
|
599
|
-
code: Joi.string().allow(""),
|
|
600
|
-
info: Joi.string().allow(""),
|
|
601
|
-
message: Joi.string().allow(""),
|
|
602
|
-
meta: Joi.any(),
|
|
603
|
-
request_id: Joi.string().allow(""),
|
|
604
|
-
});
|
|
605
|
-
}
|
|
606
|
-
|
|
607
|
-
/** @returns {AuthenticationApiErrorSchema} */
|
|
608
|
-
static AuthenticationApiErrorSchema() {
|
|
609
|
-
return Joi.object({
|
|
610
|
-
message: Joi.string().allow(""),
|
|
611
|
-
});
|
|
612
|
-
}
|
|
613
|
-
|
|
614
|
-
/** @returns {AuthenticationInternalServerErrorSchema} */
|
|
615
|
-
static AuthenticationInternalServerErrorSchema() {
|
|
616
|
-
return Joi.object({
|
|
617
|
-
message: Joi.string().allow(""),
|
|
618
|
-
});
|
|
619
|
-
}
|
|
620
|
-
|
|
621
|
-
/** @returns {AuthSuccess} */
|
|
622
|
-
static AuthSuccess() {
|
|
623
|
-
return Joi.object({
|
|
624
|
-
register_token: Joi.string().allow(""),
|
|
625
|
-
user: UserApplicationModel.UserSchema(),
|
|
626
|
-
user_exists: Joi.boolean(),
|
|
627
|
-
});
|
|
628
|
-
}
|
|
629
|
-
|
|
630
|
-
/** @returns {CodeRequestBodySchema} */
|
|
631
|
-
static CodeRequestBodySchema() {
|
|
632
|
-
return Joi.object({
|
|
633
|
-
code: Joi.string().allow(""),
|
|
634
|
-
});
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
/** @returns {DeleteAccountConsent} */
|
|
638
|
-
static DeleteAccountConsent() {
|
|
587
|
+
|
|
588
|
+
class UserApplicationModel {
|
|
589
|
+
/** @returns {UpdateUserAttributesRequest} */
|
|
590
|
+
static UpdateUserAttributesRequest() {
|
|
639
591
|
return Joi.object({
|
|
640
|
-
|
|
592
|
+
attributes: Joi.any(),
|
|
641
593
|
});
|
|
642
594
|
}
|
|
643
595
|
|
|
644
|
-
/** @returns {
|
|
645
|
-
static
|
|
596
|
+
/** @returns {UserAttributes} */
|
|
597
|
+
static UserAttributes() {
|
|
646
598
|
return Joi.object({
|
|
647
|
-
|
|
648
|
-
reason_text: Joi.string().allow(""),
|
|
649
|
-
show_text_area: Joi.boolean(),
|
|
599
|
+
attributes: Joi.any(),
|
|
650
600
|
});
|
|
651
601
|
}
|
|
652
602
|
|
|
653
603
|
/** @returns {DeleteApplicationUserRequestSchema} */
|
|
654
604
|
static DeleteApplicationUserRequestSchema() {
|
|
655
605
|
return Joi.object({
|
|
656
|
-
|
|
606
|
+
user_id: Joi.string().allow(""),
|
|
657
607
|
reason: Joi.string().allow(""),
|
|
658
608
|
reason_id: Joi.string().allow(""),
|
|
659
609
|
request_id: Joi.string().allow(""),
|
|
660
|
-
|
|
661
|
-
});
|
|
662
|
-
}
|
|
663
|
-
|
|
664
|
-
/** @returns {DeleteUserSuccess} */
|
|
665
|
-
static DeleteUserSuccess() {
|
|
666
|
-
return Joi.object({
|
|
667
|
-
success: Joi.boolean(),
|
|
610
|
+
otp: Joi.string().allow(""),
|
|
668
611
|
});
|
|
669
612
|
}
|
|
670
613
|
|
|
@@ -675,16 +618,19 @@ class UserApplicationModel {
|
|
|
675
618
|
});
|
|
676
619
|
}
|
|
677
620
|
|
|
678
|
-
/** @returns {
|
|
679
|
-
static
|
|
621
|
+
/** @returns {SendVerificationLinkMobileRequestSchema} */
|
|
622
|
+
static SendVerificationLinkMobileRequestSchema() {
|
|
680
623
|
return Joi.object({
|
|
624
|
+
verified: Joi.boolean(),
|
|
625
|
+
active: Joi.boolean(),
|
|
681
626
|
country_code: Joi.string().allow(""),
|
|
682
627
|
phone: Joi.string().allow(""),
|
|
628
|
+
primary: Joi.boolean(),
|
|
683
629
|
});
|
|
684
630
|
}
|
|
685
631
|
|
|
686
|
-
/** @returns {
|
|
687
|
-
static
|
|
632
|
+
/** @returns {EditMobileRequestSchema} */
|
|
633
|
+
static EditMobileRequestSchema() {
|
|
688
634
|
return Joi.object({
|
|
689
635
|
country_code: Joi.string().allow(""),
|
|
690
636
|
phone: Joi.string().allow(""),
|
|
@@ -694,374 +640,396 @@ class UserApplicationModel {
|
|
|
694
640
|
/** @returns {EditProfileRequestSchema} */
|
|
695
641
|
static EditProfileRequestSchema() {
|
|
696
642
|
return Joi.object({
|
|
697
|
-
android_hash: Joi.string().allow(""),
|
|
698
|
-
country_code: Joi.string().allow(""),
|
|
699
|
-
dob: Joi.string().allow(""),
|
|
700
|
-
email: Joi.string().allow(""),
|
|
701
643
|
first_name: Joi.string().allow(""),
|
|
702
|
-
gender: Joi.string().allow(""),
|
|
703
644
|
last_name: Joi.string().allow(""),
|
|
704
645
|
mobile: UserApplicationModel.EditProfileMobileSchema(),
|
|
646
|
+
country_code: Joi.string().allow(""),
|
|
647
|
+
email: Joi.string().allow(""),
|
|
648
|
+
gender: Joi.string().allow(""),
|
|
649
|
+
dob: Joi.string().allow(""),
|
|
705
650
|
profile_pic_url: Joi.string().allow(""),
|
|
706
|
-
|
|
651
|
+
android_hash: Joi.string().allow(""),
|
|
707
652
|
sender: Joi.string().allow(""),
|
|
653
|
+
register_token: Joi.string().allow(""),
|
|
708
654
|
});
|
|
709
655
|
}
|
|
710
656
|
|
|
711
|
-
/** @returns {
|
|
712
|
-
static
|
|
657
|
+
/** @returns {EditProfileMobileSchema} */
|
|
658
|
+
static EditProfileMobileSchema() {
|
|
659
|
+
return Joi.object({
|
|
660
|
+
phone: Joi.string().allow(""),
|
|
661
|
+
country_code: Joi.string().allow(""),
|
|
662
|
+
});
|
|
663
|
+
}
|
|
664
|
+
|
|
665
|
+
/** @returns {SendEmailOtpRequestSchema} */
|
|
666
|
+
static SendEmailOtpRequestSchema() {
|
|
713
667
|
return Joi.object({
|
|
714
|
-
active: Joi.boolean(),
|
|
715
668
|
email: Joi.string().allow(""),
|
|
716
|
-
|
|
717
|
-
|
|
669
|
+
action: Joi.string().allow(""),
|
|
670
|
+
token: Joi.string().allow(""),
|
|
671
|
+
register_token: Joi.string().allow(""),
|
|
718
672
|
});
|
|
719
673
|
}
|
|
720
674
|
|
|
721
|
-
/** @returns {
|
|
722
|
-
static
|
|
675
|
+
/** @returns {SendEmailForgotOtpRequestSchema} */
|
|
676
|
+
static SendEmailForgotOtpRequestSchema() {
|
|
723
677
|
return Joi.object({
|
|
724
|
-
|
|
678
|
+
email: Joi.string().allow(""),
|
|
679
|
+
action: Joi.string().allow(""),
|
|
680
|
+
token: Joi.string().allow(""),
|
|
725
681
|
});
|
|
726
682
|
}
|
|
727
683
|
|
|
728
|
-
/** @returns {
|
|
729
|
-
static
|
|
684
|
+
/** @returns {VerifyEmailOtpRequestSchema} */
|
|
685
|
+
static VerifyEmailOtpRequestSchema() {
|
|
730
686
|
return Joi.object({
|
|
731
|
-
|
|
687
|
+
email: Joi.string().allow(""),
|
|
688
|
+
action: Joi.string().allow(""),
|
|
689
|
+
register_token: Joi.string().allow(""),
|
|
690
|
+
otp: Joi.string().allow(""),
|
|
732
691
|
});
|
|
733
692
|
}
|
|
734
693
|
|
|
735
|
-
/** @returns {
|
|
736
|
-
static
|
|
694
|
+
/** @returns {VerifyEmailForgotOtpRequestSchema} */
|
|
695
|
+
static VerifyEmailForgotOtpRequestSchema() {
|
|
737
696
|
return Joi.object({
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
text_color: Joi.string().allow(""),
|
|
697
|
+
email: Joi.string().allow(""),
|
|
698
|
+
otp: Joi.string().allow(""),
|
|
741
699
|
});
|
|
742
700
|
}
|
|
743
701
|
|
|
744
|
-
/** @returns {
|
|
745
|
-
static
|
|
702
|
+
/** @returns {VerifyOtpRequestSchema} */
|
|
703
|
+
static VerifyOtpRequestSchema() {
|
|
746
704
|
return Joi.object({
|
|
747
|
-
|
|
748
|
-
|
|
705
|
+
request_id: Joi.string().allow(""),
|
|
706
|
+
register_token: Joi.string().allow(""),
|
|
707
|
+
otp: Joi.string().allow(""),
|
|
708
|
+
});
|
|
709
|
+
}
|
|
710
|
+
|
|
711
|
+
/** @returns {VerifyMobileForgotOtpRequestSchema} */
|
|
712
|
+
static VerifyMobileForgotOtpRequestSchema() {
|
|
713
|
+
return Joi.object({
|
|
714
|
+
request_id: Joi.string().allow(""),
|
|
715
|
+
otp: Joi.string().allow(""),
|
|
716
|
+
});
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
/** @returns {SendMobileOtpRequestSchema} */
|
|
720
|
+
static SendMobileOtpRequestSchema() {
|
|
721
|
+
return Joi.object({
|
|
722
|
+
mobile: Joi.string().allow(""),
|
|
723
|
+
country_code: Joi.string().allow(""),
|
|
724
|
+
action: Joi.string().allow(""),
|
|
725
|
+
token: Joi.string().allow(""),
|
|
726
|
+
android_hash: Joi.string().allow(""),
|
|
727
|
+
force: Joi.string().allow(""),
|
|
728
|
+
});
|
|
729
|
+
}
|
|
730
|
+
|
|
731
|
+
/** @returns {SendMobileForgotOtpRequestSchema} */
|
|
732
|
+
static SendMobileForgotOtpRequestSchema() {
|
|
733
|
+
return Joi.object({
|
|
734
|
+
mobile: Joi.string().allow(""),
|
|
735
|
+
country_code: Joi.string().allow(""),
|
|
736
|
+
action: Joi.string().allow(""),
|
|
737
|
+
token: Joi.string().allow(""),
|
|
738
|
+
android_hash: Joi.string().allow(""),
|
|
739
|
+
});
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
/** @returns {UpdatePasswordRequestSchema} */
|
|
743
|
+
static UpdatePasswordRequestSchema() {
|
|
744
|
+
return Joi.object({
|
|
745
|
+
old_password: Joi.string().allow(""),
|
|
746
|
+
new_password: Joi.string().allow(""),
|
|
749
747
|
});
|
|
750
748
|
}
|
|
751
749
|
|
|
752
750
|
/** @returns {FormRegisterRequestSchema} */
|
|
753
751
|
static FormRegisterRequestSchema() {
|
|
754
752
|
return Joi.object({
|
|
755
|
-
email: Joi.string().allow(""),
|
|
756
753
|
first_name: Joi.string().allow(""),
|
|
757
|
-
gender: Joi.string().allow(""),
|
|
758
754
|
last_name: Joi.string().allow(""),
|
|
755
|
+
gender: Joi.string().allow(""),
|
|
756
|
+
email: Joi.string().allow(""),
|
|
759
757
|
password: Joi.string().allow(""),
|
|
760
758
|
phone: UserApplicationModel.FormRegisterRequestSchemaPhone(),
|
|
761
759
|
register_token: Joi.string().allow(""),
|
|
762
760
|
});
|
|
763
761
|
}
|
|
764
762
|
|
|
765
|
-
/** @returns {
|
|
766
|
-
static
|
|
763
|
+
/** @returns {TokenRequestBodySchema} */
|
|
764
|
+
static TokenRequestBodySchema() {
|
|
767
765
|
return Joi.object({
|
|
768
|
-
|
|
769
|
-
mobile: Joi.string().allow(""),
|
|
766
|
+
token: Joi.string().allow(""),
|
|
770
767
|
});
|
|
771
768
|
}
|
|
772
769
|
|
|
773
|
-
/** @returns {
|
|
774
|
-
static
|
|
770
|
+
/** @returns {ForgotPasswordRequestSchema} */
|
|
771
|
+
static ForgotPasswordRequestSchema() {
|
|
775
772
|
return Joi.object({
|
|
776
|
-
|
|
773
|
+
code: Joi.string().allow(""),
|
|
774
|
+
password: Joi.string().allow(""),
|
|
777
775
|
});
|
|
778
776
|
}
|
|
779
777
|
|
|
780
|
-
/** @returns {
|
|
781
|
-
static
|
|
778
|
+
/** @returns {CodeRequestBodySchema} */
|
|
779
|
+
static CodeRequestBodySchema() {
|
|
782
780
|
return Joi.object({
|
|
783
|
-
|
|
781
|
+
code: Joi.string().allow(""),
|
|
784
782
|
});
|
|
785
783
|
}
|
|
786
784
|
|
|
787
|
-
/** @returns {
|
|
788
|
-
static
|
|
785
|
+
/** @returns {SendResetPasswordEmailRequestSchema} */
|
|
786
|
+
static SendResetPasswordEmailRequestSchema() {
|
|
789
787
|
return Joi.object({
|
|
790
|
-
|
|
791
|
-
password: Joi.boolean(),
|
|
788
|
+
email: Joi.string().allow(""),
|
|
792
789
|
});
|
|
793
790
|
}
|
|
794
791
|
|
|
795
|
-
/** @returns {
|
|
796
|
-
static
|
|
792
|
+
/** @returns {SendResetPasswordMobileRequestSchema} */
|
|
793
|
+
static SendResetPasswordMobileRequestSchema() {
|
|
797
794
|
return Joi.object({
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
user: UserApplicationModel.UserSchema(),
|
|
795
|
+
country_code: Joi.string().allow(""),
|
|
796
|
+
mobile: Joi.string().allow(""),
|
|
801
797
|
});
|
|
802
798
|
}
|
|
803
799
|
|
|
804
|
-
/** @returns {
|
|
805
|
-
static
|
|
800
|
+
/** @returns {PasswordLoginRequestSchema} */
|
|
801
|
+
static PasswordLoginRequestSchema() {
|
|
806
802
|
return Joi.object({
|
|
807
|
-
|
|
803
|
+
password: Joi.string().allow(""),
|
|
804
|
+
username: Joi.string().allow(""),
|
|
808
805
|
});
|
|
809
806
|
}
|
|
810
807
|
|
|
811
|
-
/** @returns {
|
|
812
|
-
static
|
|
808
|
+
/** @returns {SendOtpRequestSchema} */
|
|
809
|
+
static SendOtpRequestSchema() {
|
|
813
810
|
return Joi.object({
|
|
814
|
-
|
|
815
|
-
|
|
811
|
+
country_code: Joi.string().allow(""),
|
|
812
|
+
mobile: Joi.string().allow(""),
|
|
813
|
+
android_hash: Joi.string().allow(""),
|
|
816
814
|
});
|
|
817
815
|
}
|
|
818
816
|
|
|
819
|
-
/** @returns {
|
|
820
|
-
static
|
|
817
|
+
/** @returns {OAuthRequestSchema} */
|
|
818
|
+
static OAuthRequestSchema() {
|
|
821
819
|
return Joi.object({
|
|
822
|
-
|
|
820
|
+
is_signed_in: Joi.boolean(),
|
|
821
|
+
oauth2: UserApplicationModel.OAuthRequestSchemaOauth2(),
|
|
822
|
+
profile: UserApplicationModel.OAuthRequestSchemaProfile(),
|
|
823
823
|
});
|
|
824
824
|
}
|
|
825
825
|
|
|
826
826
|
/** @returns {OAuthRequestAppleSchema} */
|
|
827
827
|
static OAuthRequestAppleSchema() {
|
|
828
828
|
return Joi.object({
|
|
829
|
+
user_identifier: Joi.string().allow(""),
|
|
829
830
|
oauth: UserApplicationModel.OAuthRequestAppleSchemaOauth(),
|
|
830
831
|
profile: UserApplicationModel.OAuthRequestAppleSchemaProfile(),
|
|
831
|
-
user_identifier: Joi.string().allow(""),
|
|
832
|
-
});
|
|
833
|
-
}
|
|
834
|
-
|
|
835
|
-
/** @returns {OAuthRequestAppleSchemaOauth} */
|
|
836
|
-
static OAuthRequestAppleSchemaOauth() {
|
|
837
|
-
return Joi.object({
|
|
838
|
-
identity_token: Joi.string().allow(""),
|
|
839
832
|
});
|
|
840
833
|
}
|
|
841
834
|
|
|
842
|
-
/** @returns {
|
|
843
|
-
static
|
|
835
|
+
/** @returns {UserObjectSchema} */
|
|
836
|
+
static UserObjectSchema() {
|
|
844
837
|
return Joi.object({
|
|
845
|
-
|
|
846
|
-
full_name: Joi.string().allow(""),
|
|
847
|
-
last_name: Joi.string().allow(""),
|
|
838
|
+
user: UserApplicationModel.UserSchema(),
|
|
848
839
|
});
|
|
849
840
|
}
|
|
850
841
|
|
|
851
|
-
/** @returns {
|
|
852
|
-
static
|
|
842
|
+
/** @returns {AuthSuccess} */
|
|
843
|
+
static AuthSuccess() {
|
|
853
844
|
return Joi.object({
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
845
|
+
register_token: Joi.string().allow(""),
|
|
846
|
+
user_exists: Joi.boolean(),
|
|
847
|
+
user: UserApplicationModel.UserSchema(),
|
|
857
848
|
});
|
|
858
849
|
}
|
|
859
850
|
|
|
860
|
-
/** @returns {
|
|
861
|
-
static
|
|
851
|
+
/** @returns {UserExistsResponse} */
|
|
852
|
+
static UserExistsResponse() {
|
|
862
853
|
return Joi.object({
|
|
863
|
-
|
|
864
|
-
expiry: Joi.number(),
|
|
865
|
-
refresh_token: Joi.string().allow(""),
|
|
854
|
+
user_exists: Joi.boolean(),
|
|
866
855
|
});
|
|
867
856
|
}
|
|
868
857
|
|
|
869
|
-
/** @returns {
|
|
870
|
-
static
|
|
858
|
+
/** @returns {SendOtpResponse} */
|
|
859
|
+
static SendOtpResponse() {
|
|
871
860
|
return Joi.object({
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
861
|
+
resend_timer: Joi.number(),
|
|
862
|
+
resend_token: Joi.string().allow(""),
|
|
863
|
+
success: Joi.boolean(),
|
|
864
|
+
request_id: Joi.string().allow(""),
|
|
865
|
+
message: Joi.string().allow(""),
|
|
866
|
+
mobile: Joi.string().allow(""),
|
|
867
|
+
country_code: Joi.string().allow(""),
|
|
868
|
+
email: Joi.string().allow(""),
|
|
869
|
+
resend_email_token: Joi.string().allow(""),
|
|
870
|
+
register_token: Joi.string().allow(""),
|
|
871
|
+
verify_email_otp: Joi.boolean(),
|
|
872
|
+
verify_mobile_otp: Joi.boolean(),
|
|
873
|
+
user_exists: Joi.boolean(),
|
|
878
874
|
});
|
|
879
875
|
}
|
|
880
876
|
|
|
881
|
-
/** @returns {
|
|
882
|
-
static
|
|
877
|
+
/** @returns {ProfileEditSuccess} */
|
|
878
|
+
static ProfileEditSuccess() {
|
|
883
879
|
return Joi.object({
|
|
884
|
-
|
|
885
|
-
message: Joi.string().allow(""),
|
|
886
|
-
mobile: Joi.string().allow(""),
|
|
880
|
+
user: UserApplicationModel.UserSchema(),
|
|
887
881
|
register_token: Joi.string().allow(""),
|
|
882
|
+
resend_email_token: Joi.string().allow(""),
|
|
883
|
+
user_exists: Joi.boolean(),
|
|
884
|
+
verify_email_link: Joi.boolean(),
|
|
885
|
+
verify_email_otp: Joi.boolean(),
|
|
886
|
+
verify_mobile_otp: Joi.boolean(),
|
|
887
|
+
email: Joi.string().allow(""),
|
|
888
888
|
request_id: Joi.string().allow(""),
|
|
889
|
+
country_code: Joi.string().allow(""),
|
|
890
|
+
mobile: Joi.string().allow(""),
|
|
891
|
+
success: Joi.boolean(),
|
|
892
|
+
message: Joi.string().allow(""),
|
|
889
893
|
resend_timer: Joi.number(),
|
|
890
894
|
resend_token: Joi.string().allow(""),
|
|
891
|
-
success: Joi.boolean(),
|
|
892
895
|
});
|
|
893
896
|
}
|
|
894
897
|
|
|
895
|
-
/** @returns {
|
|
896
|
-
static
|
|
898
|
+
/** @returns {LoginSuccess} */
|
|
899
|
+
static LoginSuccess() {
|
|
897
900
|
return Joi.object({
|
|
898
|
-
|
|
899
|
-
|
|
901
|
+
user: UserApplicationModel.UserSchema(),
|
|
902
|
+
request_id: Joi.string().allow(""),
|
|
903
|
+
register_token: Joi.string().allow(""),
|
|
900
904
|
});
|
|
901
905
|
}
|
|
902
906
|
|
|
903
|
-
/** @returns {
|
|
904
|
-
static
|
|
907
|
+
/** @returns {ResetForgotPasswordSuccess} */
|
|
908
|
+
static ResetForgotPasswordSuccess() {
|
|
905
909
|
return Joi.object({
|
|
906
|
-
|
|
907
|
-
country_code: Joi.number(),
|
|
908
|
-
phone: Joi.string().allow(""),
|
|
909
|
-
primary: Joi.boolean(),
|
|
910
|
-
verified: Joi.boolean(),
|
|
910
|
+
success: Joi.boolean(),
|
|
911
911
|
});
|
|
912
912
|
}
|
|
913
913
|
|
|
914
|
-
/** @returns {
|
|
915
|
-
static
|
|
914
|
+
/** @returns {VerifyOtpSuccess} */
|
|
915
|
+
static VerifyOtpSuccess() {
|
|
916
916
|
return Joi.object({
|
|
917
|
-
|
|
918
|
-
|
|
917
|
+
user: UserApplicationModel.UserSchema(),
|
|
918
|
+
user_exists: Joi.boolean(),
|
|
919
|
+
register_token: Joi.string().allow(""),
|
|
919
920
|
});
|
|
920
921
|
}
|
|
921
922
|
|
|
922
|
-
/** @returns {
|
|
923
|
-
static
|
|
923
|
+
/** @returns {VerifyForgotOtpSuccess} */
|
|
924
|
+
static VerifyForgotOtpSuccess() {
|
|
924
925
|
return Joi.object({
|
|
925
|
-
|
|
926
|
-
|
|
926
|
+
success: Joi.boolean(),
|
|
927
|
+
forgot_token: Joi.string().allow(""),
|
|
927
928
|
});
|
|
928
929
|
}
|
|
929
930
|
|
|
930
|
-
/** @returns {
|
|
931
|
-
static
|
|
931
|
+
/** @returns {ResetPasswordSuccess} */
|
|
932
|
+
static ResetPasswordSuccess() {
|
|
932
933
|
return Joi.object({
|
|
933
|
-
|
|
934
|
-
active: Joi.boolean(),
|
|
935
|
-
created_at: Joi.string().allow(""),
|
|
936
|
-
delete_account_consent: Joi.any(),
|
|
937
|
-
delete_account_day: Joi.number(),
|
|
938
|
-
delete_account_reasons: Joi.array().items(
|
|
939
|
-
UserApplicationModel.DeleteAccountReasons()
|
|
940
|
-
),
|
|
941
|
-
desktop_image: Joi.string().allow(""),
|
|
942
|
-
display: Joi.string().allow(""),
|
|
943
|
-
flash_card: UserApplicationModel.FlashCard(),
|
|
944
|
-
forgot_password: Joi.boolean(),
|
|
945
|
-
login: UserApplicationModel.Login(),
|
|
946
|
-
look_and_feel: UserApplicationModel.LookAndFeel(),
|
|
947
|
-
meta: UserApplicationModel.MetaSchema(),
|
|
948
|
-
mobile_image: Joi.string().allow(""),
|
|
949
|
-
name: Joi.string().allow(""),
|
|
950
|
-
register: Joi.boolean(),
|
|
951
|
-
register_required_fields: UserApplicationModel.RegisterRequiredFields(),
|
|
952
|
-
required_fields: UserApplicationModel.RequiredFields(),
|
|
953
|
-
session_config: Joi.any(),
|
|
954
|
-
skip_captcha: Joi.boolean(),
|
|
955
|
-
skip_login: Joi.boolean(),
|
|
956
|
-
social: UserApplicationModel.Social(),
|
|
957
|
-
social_tokens: UserApplicationModel.SocialTokens(),
|
|
958
|
-
subtext: Joi.string().allow(""),
|
|
959
|
-
updated_at: Joi.string().allow(""),
|
|
934
|
+
status: Joi.string().allow(""),
|
|
960
935
|
});
|
|
961
936
|
}
|
|
962
937
|
|
|
963
|
-
/** @returns {
|
|
964
|
-
static
|
|
938
|
+
/** @returns {RegisterFormSuccess} */
|
|
939
|
+
static RegisterFormSuccess() {
|
|
965
940
|
return Joi.object({
|
|
966
|
-
country_code: Joi.string().allow(""),
|
|
967
941
|
email: Joi.string().allow(""),
|
|
968
|
-
message: Joi.string().allow(""),
|
|
969
|
-
mobile: Joi.string().allow(""),
|
|
970
|
-
register_token: Joi.string().allow(""),
|
|
971
|
-
request_id: Joi.string().allow(""),
|
|
972
|
-
resend_email_token: Joi.string().allow(""),
|
|
973
942
|
resend_timer: Joi.number(),
|
|
974
943
|
resend_token: Joi.string().allow(""),
|
|
944
|
+
resend_email_token: Joi.string().allow(""),
|
|
945
|
+
register_token: Joi.string().allow(""),
|
|
975
946
|
success: Joi.boolean(),
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
947
|
+
request_id: Joi.string().allow(""),
|
|
948
|
+
message: Joi.string().allow(""),
|
|
949
|
+
mobile: Joi.string().allow(""),
|
|
950
|
+
country_code: Joi.string().allow(""),
|
|
979
951
|
verify_email_otp: Joi.boolean(),
|
|
980
952
|
verify_mobile_otp: Joi.boolean(),
|
|
953
|
+
user_exists: Joi.boolean(),
|
|
981
954
|
});
|
|
982
955
|
}
|
|
983
956
|
|
|
984
|
-
/** @returns {
|
|
985
|
-
static
|
|
957
|
+
/** @returns {VerifyEmailSuccess} */
|
|
958
|
+
static VerifyEmailSuccess() {
|
|
986
959
|
return Joi.object({
|
|
987
|
-
country_code: Joi.string().allow(""),
|
|
988
|
-
email: Joi.string().allow(""),
|
|
989
960
|
message: Joi.string().allow(""),
|
|
990
|
-
mobile: Joi.string().allow(""),
|
|
991
|
-
register_token: Joi.string().allow(""),
|
|
992
|
-
request_id: Joi.string().allow(""),
|
|
993
|
-
resend_email_token: Joi.string().allow(""),
|
|
994
|
-
resend_timer: Joi.number(),
|
|
995
|
-
resend_token: Joi.string().allow(""),
|
|
996
|
-
success: Joi.boolean(),
|
|
997
|
-
user_exists: Joi.boolean(),
|
|
998
|
-
verify_email_otp: Joi.boolean(),
|
|
999
|
-
verify_mobile_otp: Joi.boolean(),
|
|
1000
961
|
});
|
|
1001
962
|
}
|
|
1002
963
|
|
|
1003
|
-
/** @returns {
|
|
1004
|
-
static
|
|
964
|
+
/** @returns {HasPasswordSuccess} */
|
|
965
|
+
static HasPasswordSuccess() {
|
|
1005
966
|
return Joi.object({
|
|
1006
|
-
|
|
1007
|
-
mobile: UserApplicationModel.RegisterRequiredFieldsMobile(),
|
|
967
|
+
result: Joi.boolean(),
|
|
1008
968
|
});
|
|
1009
969
|
}
|
|
1010
970
|
|
|
1011
|
-
/** @returns {
|
|
1012
|
-
static
|
|
971
|
+
/** @returns {LogoutSuccess} */
|
|
972
|
+
static LogoutSuccess() {
|
|
1013
973
|
return Joi.object({
|
|
1014
|
-
|
|
1015
|
-
level: Joi.string().allow(""),
|
|
974
|
+
logout: Joi.boolean(),
|
|
1016
975
|
});
|
|
1017
976
|
}
|
|
1018
977
|
|
|
1019
|
-
/** @returns {
|
|
1020
|
-
static
|
|
978
|
+
/** @returns {DeleteUserSuccess} */
|
|
979
|
+
static DeleteUserSuccess() {
|
|
1021
980
|
return Joi.object({
|
|
1022
|
-
|
|
1023
|
-
level: Joi.string().allow(""),
|
|
981
|
+
success: Joi.boolean(),
|
|
1024
982
|
});
|
|
1025
983
|
}
|
|
1026
984
|
|
|
1027
|
-
/** @returns {
|
|
1028
|
-
static
|
|
985
|
+
/** @returns {OtpSuccess} */
|
|
986
|
+
static OtpSuccess() {
|
|
1029
987
|
return Joi.object({
|
|
1030
|
-
|
|
1031
|
-
|
|
988
|
+
resend_timer: Joi.number(),
|
|
989
|
+
resend_token: Joi.string().allow(""),
|
|
990
|
+
register_token: Joi.string().allow(""),
|
|
991
|
+
success: Joi.boolean(),
|
|
992
|
+
request_id: Joi.string().allow(""),
|
|
993
|
+
message: Joi.string().allow(""),
|
|
994
|
+
mobile: Joi.string().allow(""),
|
|
995
|
+
country_code: Joi.string().allow(""),
|
|
1032
996
|
});
|
|
1033
997
|
}
|
|
1034
998
|
|
|
1035
|
-
/** @returns {
|
|
1036
|
-
static
|
|
999
|
+
/** @returns {EmailOtpSuccess} */
|
|
1000
|
+
static EmailOtpSuccess() {
|
|
1037
1001
|
return Joi.object({
|
|
1038
1002
|
success: Joi.boolean(),
|
|
1039
1003
|
});
|
|
1040
1004
|
}
|
|
1041
1005
|
|
|
1042
|
-
/** @returns {
|
|
1043
|
-
static
|
|
1006
|
+
/** @returns {SessionListSuccess} */
|
|
1007
|
+
static SessionListSuccess() {
|
|
1044
1008
|
return Joi.object({
|
|
1045
|
-
|
|
1009
|
+
sessions: Joi.array().items(Joi.string().allow("")),
|
|
1046
1010
|
});
|
|
1047
1011
|
}
|
|
1048
1012
|
|
|
1049
|
-
/** @returns {
|
|
1050
|
-
static
|
|
1013
|
+
/** @returns {VerifyMobileOTPSuccess} */
|
|
1014
|
+
static VerifyMobileOTPSuccess() {
|
|
1051
1015
|
return Joi.object({
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
token: Joi.string().allow(""),
|
|
1016
|
+
user: UserApplicationModel.UserSchema(),
|
|
1017
|
+
verify_mobile_link: Joi.boolean(),
|
|
1055
1018
|
});
|
|
1056
1019
|
}
|
|
1057
1020
|
|
|
1058
|
-
/** @returns {
|
|
1059
|
-
static
|
|
1021
|
+
/** @returns {VerifyEmailOTPSuccess} */
|
|
1022
|
+
static VerifyEmailOTPSuccess() {
|
|
1060
1023
|
return Joi.object({
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1024
|
+
user: UserApplicationModel.UserSchema(),
|
|
1025
|
+
verify_email_link: Joi.boolean(),
|
|
1026
|
+
});
|
|
1027
|
+
}
|
|
1028
|
+
|
|
1029
|
+
/** @returns {SendMobileVerifyLinkSuccess} */
|
|
1030
|
+
static SendMobileVerifyLinkSuccess() {
|
|
1031
|
+
return Joi.object({
|
|
1032
|
+
verify_mobile_link: Joi.boolean(),
|
|
1065
1033
|
});
|
|
1066
1034
|
}
|
|
1067
1035
|
|
|
@@ -1072,103 +1040,129 @@ class UserApplicationModel {
|
|
|
1072
1040
|
});
|
|
1073
1041
|
}
|
|
1074
1042
|
|
|
1075
|
-
/** @returns {
|
|
1076
|
-
static
|
|
1043
|
+
/** @returns {AuthenticationInternalServerErrorSchema} */
|
|
1044
|
+
static AuthenticationInternalServerErrorSchema() {
|
|
1077
1045
|
return Joi.object({
|
|
1078
|
-
|
|
1079
|
-
android_hash: Joi.string().allow(""),
|
|
1080
|
-
country_code: Joi.string().allow(""),
|
|
1081
|
-
mobile: Joi.string().allow(""),
|
|
1082
|
-
token: Joi.string().allow(""),
|
|
1046
|
+
message: Joi.string().allow(""),
|
|
1083
1047
|
});
|
|
1084
1048
|
}
|
|
1085
1049
|
|
|
1086
|
-
/** @returns {
|
|
1087
|
-
static
|
|
1050
|
+
/** @returns {AuthenticationApiErrorSchema} */
|
|
1051
|
+
static AuthenticationApiErrorSchema() {
|
|
1088
1052
|
return Joi.object({
|
|
1089
|
-
|
|
1090
|
-
android_hash: Joi.string().allow(""),
|
|
1091
|
-
country_code: Joi.string().allow(""),
|
|
1092
|
-
force: Joi.string().allow(""),
|
|
1093
|
-
mobile: Joi.string().allow(""),
|
|
1094
|
-
token: Joi.string().allow(""),
|
|
1053
|
+
message: Joi.string().allow(""),
|
|
1095
1054
|
});
|
|
1096
1055
|
}
|
|
1097
1056
|
|
|
1098
|
-
/** @returns {
|
|
1099
|
-
static
|
|
1057
|
+
/** @returns {APIError} */
|
|
1058
|
+
static APIError() {
|
|
1100
1059
|
return Joi.object({
|
|
1101
|
-
|
|
1060
|
+
code: Joi.string().allow(""),
|
|
1061
|
+
message: Joi.string().allow(""),
|
|
1062
|
+
info: Joi.string().allow(""),
|
|
1063
|
+
request_id: Joi.string().allow(""),
|
|
1064
|
+
meta: Joi.any(),
|
|
1102
1065
|
});
|
|
1103
1066
|
}
|
|
1104
1067
|
|
|
1105
|
-
/** @returns {
|
|
1106
|
-
static
|
|
1068
|
+
/** @returns {FormRegisterRequestSchemaPhone} */
|
|
1069
|
+
static FormRegisterRequestSchemaPhone() {
|
|
1107
1070
|
return Joi.object({
|
|
1108
|
-
android_hash: Joi.string().allow(""),
|
|
1109
1071
|
country_code: Joi.string().allow(""),
|
|
1110
1072
|
mobile: Joi.string().allow(""),
|
|
1111
1073
|
});
|
|
1112
1074
|
}
|
|
1113
1075
|
|
|
1114
|
-
/** @returns {
|
|
1115
|
-
static
|
|
1076
|
+
/** @returns {OAuthRequestSchemaOauth2} */
|
|
1077
|
+
static OAuthRequestSchemaOauth2() {
|
|
1078
|
+
return Joi.object({
|
|
1079
|
+
access_token: Joi.string().allow(""),
|
|
1080
|
+
expiry: Joi.number(),
|
|
1081
|
+
refresh_token: Joi.string().allow(""),
|
|
1082
|
+
});
|
|
1083
|
+
}
|
|
1084
|
+
|
|
1085
|
+
/** @returns {OAuthRequestSchemaProfile} */
|
|
1086
|
+
static OAuthRequestSchemaProfile() {
|
|
1087
|
+
return Joi.object({
|
|
1088
|
+
last_name: Joi.string().allow(""),
|
|
1089
|
+
image: Joi.string().allow(""),
|
|
1090
|
+
id: Joi.string().allow(""),
|
|
1091
|
+
email: Joi.string().allow(""),
|
|
1092
|
+
full_name: Joi.string().allow(""),
|
|
1093
|
+
first_name: Joi.string().allow(""),
|
|
1094
|
+
});
|
|
1095
|
+
}
|
|
1096
|
+
|
|
1097
|
+
/** @returns {OAuthRequestAppleSchemaOauth} */
|
|
1098
|
+
static OAuthRequestAppleSchemaOauth() {
|
|
1116
1099
|
return Joi.object({
|
|
1117
|
-
|
|
1118
|
-
email: Joi.string().allow(""),
|
|
1119
|
-
message: Joi.string().allow(""),
|
|
1120
|
-
mobile: Joi.string().allow(""),
|
|
1121
|
-
register_token: Joi.string().allow(""),
|
|
1122
|
-
request_id: Joi.string().allow(""),
|
|
1123
|
-
resend_email_token: Joi.string().allow(""),
|
|
1124
|
-
resend_timer: Joi.number(),
|
|
1125
|
-
resend_token: Joi.string().allow(""),
|
|
1126
|
-
success: Joi.boolean(),
|
|
1127
|
-
user_exists: Joi.boolean(),
|
|
1128
|
-
verify_email_otp: Joi.boolean(),
|
|
1129
|
-
verify_mobile_otp: Joi.boolean(),
|
|
1100
|
+
identity_token: Joi.string().allow(""),
|
|
1130
1101
|
});
|
|
1131
1102
|
}
|
|
1132
1103
|
|
|
1133
|
-
/** @returns {
|
|
1134
|
-
static
|
|
1104
|
+
/** @returns {OAuthRequestAppleSchemaProfile} */
|
|
1105
|
+
static OAuthRequestAppleSchemaProfile() {
|
|
1135
1106
|
return Joi.object({
|
|
1136
|
-
|
|
1107
|
+
last_name: Joi.string().allow(""),
|
|
1108
|
+
full_name: Joi.string().allow(""),
|
|
1109
|
+
first_name: Joi.string().allow(""),
|
|
1137
1110
|
});
|
|
1138
1111
|
}
|
|
1139
1112
|
|
|
1140
|
-
/** @returns {
|
|
1141
|
-
static
|
|
1113
|
+
/** @returns {PlatformSchema} */
|
|
1114
|
+
static PlatformSchema() {
|
|
1142
1115
|
return Joi.object({
|
|
1143
|
-
|
|
1144
|
-
|
|
1116
|
+
display: Joi.string().allow(""),
|
|
1117
|
+
look_and_feel: UserApplicationModel.LookAndFeel(),
|
|
1118
|
+
updated_at: Joi.string().allow(""),
|
|
1119
|
+
active: Joi.boolean(),
|
|
1120
|
+
forgot_password: Joi.boolean(),
|
|
1121
|
+
login: UserApplicationModel.Login(),
|
|
1122
|
+
skip_captcha: Joi.boolean(),
|
|
1123
|
+
name: Joi.string().allow(""),
|
|
1124
|
+
meta: UserApplicationModel.MetaSchema(),
|
|
1125
|
+
_id: Joi.string().allow(""),
|
|
1126
|
+
social: UserApplicationModel.Social(),
|
|
1127
|
+
required_fields: UserApplicationModel.RequiredFields(),
|
|
1128
|
+
register_required_fields: UserApplicationModel.RegisterRequiredFields(),
|
|
1129
|
+
skip_login: Joi.boolean(),
|
|
1130
|
+
flash_card: UserApplicationModel.FlashCard(),
|
|
1131
|
+
subtext: Joi.string().allow(""),
|
|
1132
|
+
social_tokens: UserApplicationModel.SocialTokens(),
|
|
1133
|
+
created_at: Joi.string().allow(""),
|
|
1134
|
+
register: Joi.boolean(),
|
|
1135
|
+
mobile_image: Joi.string().allow(""),
|
|
1136
|
+
desktop_image: Joi.string().allow(""),
|
|
1137
|
+
delete_account_day: Joi.number(),
|
|
1138
|
+
delete_account_reasons: Joi.array().items(
|
|
1139
|
+
UserApplicationModel.DeleteAccountReasons()
|
|
1140
|
+
),
|
|
1141
|
+
delete_account_consent: Joi.any(),
|
|
1142
|
+
session_config: Joi.any(),
|
|
1145
1143
|
});
|
|
1146
1144
|
}
|
|
1147
1145
|
|
|
1148
|
-
/** @returns {
|
|
1149
|
-
static
|
|
1146
|
+
/** @returns {LookAndFeel} */
|
|
1147
|
+
static LookAndFeel() {
|
|
1150
1148
|
return Joi.object({
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
phone: Joi.string().allow(""),
|
|
1154
|
-
primary: Joi.boolean(),
|
|
1155
|
-
verified: Joi.boolean(),
|
|
1149
|
+
card_position: Joi.string().allow(""),
|
|
1150
|
+
background_color: Joi.string().allow(""),
|
|
1156
1151
|
});
|
|
1157
1152
|
}
|
|
1158
1153
|
|
|
1159
|
-
/** @returns {
|
|
1160
|
-
static
|
|
1154
|
+
/** @returns {Login} */
|
|
1155
|
+
static Login() {
|
|
1161
1156
|
return Joi.object({
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
type: Joi.string().allow(""),
|
|
1157
|
+
password: Joi.boolean(),
|
|
1158
|
+
otp: Joi.boolean(),
|
|
1165
1159
|
});
|
|
1166
1160
|
}
|
|
1167
1161
|
|
|
1168
|
-
/** @returns {
|
|
1169
|
-
static
|
|
1162
|
+
/** @returns {MetaSchema} */
|
|
1163
|
+
static MetaSchema() {
|
|
1170
1164
|
return Joi.object({
|
|
1171
|
-
|
|
1165
|
+
fynd_default: Joi.boolean(),
|
|
1172
1166
|
});
|
|
1173
1167
|
}
|
|
1174
1168
|
|
|
@@ -1176,158 +1170,164 @@ class UserApplicationModel {
|
|
|
1176
1170
|
static Social() {
|
|
1177
1171
|
return Joi.object({
|
|
1178
1172
|
account_kit: Joi.boolean(),
|
|
1179
|
-
apple: Joi.boolean(),
|
|
1180
1173
|
facebook: Joi.boolean(),
|
|
1181
1174
|
google: Joi.boolean(),
|
|
1175
|
+
apple: Joi.boolean(),
|
|
1182
1176
|
});
|
|
1183
1177
|
}
|
|
1184
1178
|
|
|
1185
|
-
/** @returns {
|
|
1186
|
-
static
|
|
1179
|
+
/** @returns {RequiredFields} */
|
|
1180
|
+
static RequiredFields() {
|
|
1187
1181
|
return Joi.object({
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
google: UserApplicationModel.Google(),
|
|
1182
|
+
email: UserApplicationModel.PlatformEmail(),
|
|
1183
|
+
mobile: UserApplicationModel.PlatformMobile(),
|
|
1191
1184
|
});
|
|
1192
1185
|
}
|
|
1193
1186
|
|
|
1194
|
-
/** @returns {
|
|
1195
|
-
static
|
|
1187
|
+
/** @returns {PlatformEmail} */
|
|
1188
|
+
static PlatformEmail() {
|
|
1196
1189
|
return Joi.object({
|
|
1197
|
-
|
|
1190
|
+
is_required: Joi.boolean(),
|
|
1191
|
+
level: Joi.string().allow(""),
|
|
1198
1192
|
});
|
|
1199
1193
|
}
|
|
1200
1194
|
|
|
1201
|
-
/** @returns {
|
|
1202
|
-
static
|
|
1195
|
+
/** @returns {PlatformMobile} */
|
|
1196
|
+
static PlatformMobile() {
|
|
1203
1197
|
return Joi.object({
|
|
1204
|
-
|
|
1205
|
-
|
|
1198
|
+
is_required: Joi.boolean(),
|
|
1199
|
+
level: Joi.string().allow(""),
|
|
1206
1200
|
});
|
|
1207
1201
|
}
|
|
1208
1202
|
|
|
1209
|
-
/** @returns {
|
|
1210
|
-
static
|
|
1203
|
+
/** @returns {RegisterRequiredFields} */
|
|
1204
|
+
static RegisterRequiredFields() {
|
|
1211
1205
|
return Joi.object({
|
|
1212
|
-
|
|
1206
|
+
email: UserApplicationModel.RegisterRequiredFieldsEmail(),
|
|
1207
|
+
mobile: UserApplicationModel.RegisterRequiredFieldsMobile(),
|
|
1213
1208
|
});
|
|
1214
1209
|
}
|
|
1215
1210
|
|
|
1216
|
-
/** @returns {
|
|
1217
|
-
static
|
|
1211
|
+
/** @returns {RegisterRequiredFieldsEmail} */
|
|
1212
|
+
static RegisterRequiredFieldsEmail() {
|
|
1218
1213
|
return Joi.object({
|
|
1219
|
-
|
|
1214
|
+
is_required: Joi.boolean(),
|
|
1215
|
+
level: Joi.string().allow(""),
|
|
1220
1216
|
});
|
|
1221
1217
|
}
|
|
1222
1218
|
|
|
1223
|
-
/** @returns {
|
|
1224
|
-
static
|
|
1219
|
+
/** @returns {RegisterRequiredFieldsMobile} */
|
|
1220
|
+
static RegisterRequiredFieldsMobile() {
|
|
1225
1221
|
return Joi.object({
|
|
1226
|
-
|
|
1222
|
+
is_required: Joi.boolean(),
|
|
1223
|
+
level: Joi.string().allow(""),
|
|
1227
1224
|
});
|
|
1228
1225
|
}
|
|
1229
1226
|
|
|
1230
|
-
/** @returns {
|
|
1231
|
-
static
|
|
1227
|
+
/** @returns {FlashCard} */
|
|
1228
|
+
static FlashCard() {
|
|
1232
1229
|
return Joi.object({
|
|
1233
|
-
|
|
1230
|
+
text: Joi.string().allow(""),
|
|
1231
|
+
text_color: Joi.string().allow(""),
|
|
1232
|
+
background_color: Joi.string().allow(""),
|
|
1234
1233
|
});
|
|
1235
1234
|
}
|
|
1236
1235
|
|
|
1237
|
-
/** @returns {
|
|
1238
|
-
static
|
|
1236
|
+
/** @returns {SocialTokens} */
|
|
1237
|
+
static SocialTokens() {
|
|
1239
1238
|
return Joi.object({
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
application_id: Joi.string().allow(""),
|
|
1244
|
-
created_at: Joi.string().allow(""),
|
|
1245
|
-
dob: Joi.string().allow(""),
|
|
1246
|
-
emails: Joi.array().items(UserApplicationModel.Email()),
|
|
1247
|
-
first_name: Joi.string().allow(""),
|
|
1248
|
-
gender: Joi.string().allow(""),
|
|
1249
|
-
last_name: Joi.string().allow(""),
|
|
1250
|
-
meta: Joi.any(),
|
|
1251
|
-
phone_numbers: Joi.array().items(UserApplicationModel.PhoneNumber()),
|
|
1252
|
-
profile_pic_url: Joi.string().allow(""),
|
|
1253
|
-
updated_at: Joi.string().allow(""),
|
|
1254
|
-
user_id: Joi.string().allow(""),
|
|
1255
|
-
username: Joi.string().allow(""),
|
|
1239
|
+
facebook: UserApplicationModel.Facebook(),
|
|
1240
|
+
account_kit: UserApplicationModel.Accountkit(),
|
|
1241
|
+
google: UserApplicationModel.Google(),
|
|
1256
1242
|
});
|
|
1257
1243
|
}
|
|
1258
1244
|
|
|
1259
|
-
/** @returns {
|
|
1260
|
-
static
|
|
1245
|
+
/** @returns {DeleteAccountReasons} */
|
|
1246
|
+
static DeleteAccountReasons() {
|
|
1261
1247
|
return Joi.object({
|
|
1262
|
-
|
|
1263
|
-
|
|
1248
|
+
reason_text: Joi.string().allow(""),
|
|
1249
|
+
reason_id: Joi.string().allow(""),
|
|
1250
|
+
show_text_area: Joi.boolean(),
|
|
1264
1251
|
});
|
|
1265
1252
|
}
|
|
1266
1253
|
|
|
1267
|
-
/** @returns {
|
|
1268
|
-
static
|
|
1254
|
+
/** @returns {DeleteAccountConsent} */
|
|
1255
|
+
static DeleteAccountConsent() {
|
|
1269
1256
|
return Joi.object({
|
|
1270
|
-
|
|
1271
|
-
email: Joi.string().allow(""),
|
|
1272
|
-
otp: Joi.string().allow(""),
|
|
1273
|
-
register_token: Joi.string().allow(""),
|
|
1257
|
+
consent_text: Joi.string().allow(""),
|
|
1274
1258
|
});
|
|
1275
1259
|
}
|
|
1276
1260
|
|
|
1277
|
-
/** @returns {
|
|
1278
|
-
static
|
|
1261
|
+
/** @returns {Facebook} */
|
|
1262
|
+
static Facebook() {
|
|
1279
1263
|
return Joi.object({
|
|
1280
|
-
|
|
1281
|
-
verify_email_link: Joi.boolean(),
|
|
1264
|
+
app_id: Joi.string().allow(""),
|
|
1282
1265
|
});
|
|
1283
1266
|
}
|
|
1284
1267
|
|
|
1285
|
-
/** @returns {
|
|
1286
|
-
static
|
|
1268
|
+
/** @returns {Accountkit} */
|
|
1269
|
+
static Accountkit() {
|
|
1287
1270
|
return Joi.object({
|
|
1288
|
-
|
|
1271
|
+
app_id: Joi.string().allow(""),
|
|
1289
1272
|
});
|
|
1290
1273
|
}
|
|
1291
1274
|
|
|
1292
|
-
/** @returns {
|
|
1293
|
-
static
|
|
1275
|
+
/** @returns {Google} */
|
|
1276
|
+
static Google() {
|
|
1294
1277
|
return Joi.object({
|
|
1295
|
-
|
|
1296
|
-
success: Joi.boolean(),
|
|
1278
|
+
app_id: Joi.string().allow(""),
|
|
1297
1279
|
});
|
|
1298
1280
|
}
|
|
1299
1281
|
|
|
1300
|
-
/** @returns {
|
|
1301
|
-
static
|
|
1282
|
+
/** @returns {SessionExpiry} */
|
|
1283
|
+
static SessionExpiry() {
|
|
1302
1284
|
return Joi.object({
|
|
1303
|
-
|
|
1304
|
-
|
|
1285
|
+
duration: Joi.number(),
|
|
1286
|
+
type: Joi.string().allow(""),
|
|
1287
|
+
is_rolling: Joi.boolean(),
|
|
1305
1288
|
});
|
|
1306
1289
|
}
|
|
1307
1290
|
|
|
1308
|
-
/** @returns {
|
|
1309
|
-
static
|
|
1291
|
+
/** @returns {UserSchema} */
|
|
1292
|
+
static UserSchema() {
|
|
1310
1293
|
return Joi.object({
|
|
1311
|
-
|
|
1312
|
-
|
|
1294
|
+
application_id: Joi.string().allow(""),
|
|
1295
|
+
user_id: Joi.string().allow(""),
|
|
1296
|
+
first_name: Joi.string().allow(""),
|
|
1297
|
+
meta: Joi.any(),
|
|
1298
|
+
last_name: Joi.string().allow(""),
|
|
1299
|
+
phone_numbers: Joi.array().items(UserApplicationModel.PhoneNumber()),
|
|
1300
|
+
emails: Joi.array().items(UserApplicationModel.Email()),
|
|
1301
|
+
gender: Joi.string().allow(""),
|
|
1302
|
+
dob: Joi.string().allow(""),
|
|
1303
|
+
active: Joi.boolean(),
|
|
1304
|
+
profile_pic_url: Joi.string().allow(""),
|
|
1305
|
+
username: Joi.string().allow(""),
|
|
1306
|
+
account_type: Joi.string().allow(""),
|
|
1307
|
+
_id: Joi.string().allow(""),
|
|
1308
|
+
created_at: Joi.string().allow(""),
|
|
1309
|
+
updated_at: Joi.string().allow(""),
|
|
1313
1310
|
});
|
|
1314
1311
|
}
|
|
1315
1312
|
|
|
1316
|
-
/** @returns {
|
|
1317
|
-
static
|
|
1313
|
+
/** @returns {PhoneNumber} */
|
|
1314
|
+
static PhoneNumber() {
|
|
1318
1315
|
return Joi.object({
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1316
|
+
active: Joi.boolean(),
|
|
1317
|
+
primary: Joi.boolean(),
|
|
1318
|
+
verified: Joi.boolean(),
|
|
1319
|
+
phone: Joi.string().allow(""),
|
|
1320
|
+
country_code: Joi.number(),
|
|
1322
1321
|
});
|
|
1323
1322
|
}
|
|
1324
1323
|
|
|
1325
|
-
/** @returns {
|
|
1326
|
-
static
|
|
1324
|
+
/** @returns {Email} */
|
|
1325
|
+
static Email() {
|
|
1327
1326
|
return Joi.object({
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1327
|
+
primary: Joi.boolean(),
|
|
1328
|
+
verified: Joi.boolean(),
|
|
1329
|
+
email: Joi.string().allow(""),
|
|
1330
|
+
active: Joi.boolean(),
|
|
1331
1331
|
});
|
|
1332
1332
|
}
|
|
1333
1333
|
}
|