@gofynd/fdk-client-javascript 3.16.2 → 3.16.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 +2 -2
- package/sdk/application/User/UserApplicationClient.d.ts +10 -0
- package/sdk/application/User/UserApplicationClient.js +67 -0
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.d.ts +1 -1
- package/sdk/platform/Communication/CommunicationPlatformApplicationClient.js +18 -1
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.d.ts +25 -0
- package/sdk/platform/Communication/CommunicationPlatformApplicationValidator.js +11 -0
- package/sdk/platform/Communication/CommunicationPlatformModel.d.ts +46 -1
- package/sdk/platform/Communication/CommunicationPlatformModel.js +46 -0
- package/sdk/platform/Content/ContentPlatformApplicationClient.d.ts +1 -1
- package/sdk/platform/Content/ContentPlatformApplicationClient.js +1 -7
- package/sdk/platform/Content/ContentPlatformApplicationValidator.d.ts +0 -14
- package/sdk/platform/Content/ContentPlatformApplicationValidator.js +0 -6
- package/sdk/platform/Content/ContentPlatformModel.d.ts +0 -2
- package/sdk/platform/Content/ContentPlatformModel.js +0 -2
- package/sdk/platform/User/UserPlatformApplicationClient.d.ts +10 -0
- package/sdk/platform/User/UserPlatformApplicationClient.js +79 -0
- package/sdk/platform/User/UserPlatformApplicationValidator.d.ts +13 -1
- package/sdk/platform/User/UserPlatformApplicationValidator.js +12 -0
- package/sdk/platform/User/UserPlatformModel.d.ts +41 -4
- package/sdk/platform/User/UserPlatformModel.js +22 -3
package/README.md
CHANGED
|
@@ -234,7 +234,7 @@ console.log("Active Theme: ", response.information.name);
|
|
|
234
234
|
The above code will log the curl command in the console
|
|
235
235
|
|
|
236
236
|
```bash
|
|
237
|
-
curl --request GET "https://api.fynd.com/service/application/theme/v1.0/applied-theme" --header 'authorization: Bearer <authorization-token>' --header 'x-fp-sdk-version: 3.16.
|
|
237
|
+
curl --request GET "https://api.fynd.com/service/application/theme/v1.0/applied-theme" --header 'authorization: Bearer <authorization-token>' --header 'x-fp-sdk-version: 3.16.3' --header 'x-fp-date: 20230222T115108Z' --header 'x-fp-signature: v1.1:1e3ab3b02b5bc626e3c32a37ee844266ade02bbcbaafc28fc7a0e46a76a7a1a8'
|
|
238
238
|
Active Theme: Emerge
|
|
239
239
|
```
|
|
240
240
|
|
package/package.json
CHANGED
|
@@ -9,6 +9,7 @@ declare class User {
|
|
|
9
9
|
deleteMobileNumber: string;
|
|
10
10
|
deleteUser: string;
|
|
11
11
|
forgotPassword: string;
|
|
12
|
+
getAttributesDefinition: string;
|
|
12
13
|
getListOfActiveSessions: string;
|
|
13
14
|
getLoggedInUser: string;
|
|
14
15
|
getPlatformConfig: string;
|
|
@@ -107,6 +108,15 @@ declare class User {
|
|
|
107
108
|
* @description: Reset a password using the code sent on email or sms the login. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/application/user/forgotPassword/).
|
|
108
109
|
*/
|
|
109
110
|
forgotPassword({ body, requestHeaders }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<LoginSuccess>;
|
|
111
|
+
/**
|
|
112
|
+
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
113
|
+
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
114
|
+
* @returns {Promise<Object>} - Success response
|
|
115
|
+
* @name getAttributesDefinition
|
|
116
|
+
* @summary: Get User Attribute Definitions
|
|
117
|
+
* @description: Retrieve user attribute definitions. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/application/user/getAttributesDefinition/).
|
|
118
|
+
*/
|
|
119
|
+
getAttributesDefinition({ excludingIds, slug, type, customerEditable, encrypted, pinned, pinOrder, isLocked, name, registrationEnabled, registrationType, pageSize, pageNo, requestHeaders, }?: object, { responseHeaders }?: import("../ApplicationAPIClient").Options): Promise<any>;
|
|
110
120
|
/**
|
|
111
121
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
112
122
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
@@ -19,6 +19,8 @@ class User {
|
|
|
19
19
|
deleteUser: "/service/application/user/authentication/v1.0/delete",
|
|
20
20
|
forgotPassword:
|
|
21
21
|
"/service/application/user/authentication/v1.0/login/password/reset/forgot",
|
|
22
|
+
getAttributesDefinition:
|
|
23
|
+
"/service/application/user/profile/v1.0/attributes/definition",
|
|
22
24
|
getListOfActiveSessions:
|
|
23
25
|
"/service/application/user/authentication/v1.0/sessions",
|
|
24
26
|
getLoggedInUser: "/service/application/user/authentication/v1.0/session",
|
|
@@ -353,6 +355,71 @@ class User {
|
|
|
353
355
|
return response;
|
|
354
356
|
}
|
|
355
357
|
|
|
358
|
+
/**
|
|
359
|
+
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
360
|
+
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
361
|
+
* @returns {Promise<Object>} - Success response
|
|
362
|
+
* @name getAttributesDefinition
|
|
363
|
+
* @summary: Get User Attribute Definitions
|
|
364
|
+
* @description: Retrieve user attribute definitions. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/application/user/getAttributesDefinition/).
|
|
365
|
+
*/
|
|
366
|
+
async getAttributesDefinition(
|
|
367
|
+
{
|
|
368
|
+
excludingIds,
|
|
369
|
+
slug,
|
|
370
|
+
type,
|
|
371
|
+
customerEditable,
|
|
372
|
+
encrypted,
|
|
373
|
+
pinned,
|
|
374
|
+
pinOrder,
|
|
375
|
+
isLocked,
|
|
376
|
+
name,
|
|
377
|
+
registrationEnabled,
|
|
378
|
+
registrationType,
|
|
379
|
+
pageSize,
|
|
380
|
+
pageNo,
|
|
381
|
+
requestHeaders,
|
|
382
|
+
} = { requestHeaders: {} },
|
|
383
|
+
{ responseHeaders } = { responseHeaders: false }
|
|
384
|
+
) {
|
|
385
|
+
const query_params = {};
|
|
386
|
+
query_params["excluding_ids"] = excludingIds;
|
|
387
|
+
query_params["slug"] = slug;
|
|
388
|
+
query_params["type"] = type;
|
|
389
|
+
query_params["customer_editable"] = customerEditable;
|
|
390
|
+
query_params["encrypted"] = encrypted;
|
|
391
|
+
query_params["pinned"] = pinned;
|
|
392
|
+
query_params["pin_order"] = pinOrder;
|
|
393
|
+
query_params["is_locked"] = isLocked;
|
|
394
|
+
query_params["name"] = name;
|
|
395
|
+
query_params["registration_enabled"] = registrationEnabled;
|
|
396
|
+
query_params["registration_type"] = registrationType;
|
|
397
|
+
query_params["page_size"] = pageSize;
|
|
398
|
+
query_params["page_no"] = pageNo;
|
|
399
|
+
|
|
400
|
+
const xHeaders = {};
|
|
401
|
+
|
|
402
|
+
const response = await ApplicationAPIClient.execute(
|
|
403
|
+
this._conf,
|
|
404
|
+
"get",
|
|
405
|
+
constructUrl({
|
|
406
|
+
url: this._urls["getAttributesDefinition"],
|
|
407
|
+
params: {},
|
|
408
|
+
}),
|
|
409
|
+
query_params,
|
|
410
|
+
undefined,
|
|
411
|
+
{ ...xHeaders, ...requestHeaders },
|
|
412
|
+
{ responseHeaders }
|
|
413
|
+
);
|
|
414
|
+
|
|
415
|
+
let responseData = response;
|
|
416
|
+
if (responseHeaders) {
|
|
417
|
+
responseData = response[0];
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
return response;
|
|
421
|
+
}
|
|
422
|
+
|
|
356
423
|
/**
|
|
357
424
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
358
425
|
* @param {import("../ApplicationAPIClient").Options} - Options
|
|
@@ -432,7 +432,7 @@ declare class Communication {
|
|
|
432
432
|
* @summary: Get all event subscriptions
|
|
433
433
|
* @description: Retrieves a list of all event subscriptions. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/communication/getEventSubscriptions/).
|
|
434
434
|
*/
|
|
435
|
-
getEventSubscriptions({ pageNo, pageSize, populate, requestHeaders }?: CommunicationPlatformApplicationValidator.GetEventSubscriptionsParam, { responseHeaders }?: object): Promise<CommunicationPlatformModel.EventSubscriptions>;
|
|
435
|
+
getEventSubscriptions({ pageNo, pageSize, populate, group, subGroup, fulfillmentOptionTypes, requestHeaders, }?: CommunicationPlatformApplicationValidator.GetEventSubscriptionsParam, { responseHeaders }?: object): Promise<CommunicationPlatformModel.EventSubscriptions>;
|
|
436
436
|
/**
|
|
437
437
|
* @param {CommunicationPlatformApplicationValidator.GetEventSubscriptionsByIdParam} arg
|
|
438
438
|
* - Arg object
|
|
@@ -2800,7 +2800,15 @@ class Communication {
|
|
|
2800
2800
|
* @description: Retrieves a list of all event subscriptions. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/communication/getEventSubscriptions/).
|
|
2801
2801
|
*/
|
|
2802
2802
|
async getEventSubscriptions(
|
|
2803
|
-
{
|
|
2803
|
+
{
|
|
2804
|
+
pageNo,
|
|
2805
|
+
pageSize,
|
|
2806
|
+
populate,
|
|
2807
|
+
group,
|
|
2808
|
+
subGroup,
|
|
2809
|
+
fulfillmentOptionTypes,
|
|
2810
|
+
requestHeaders,
|
|
2811
|
+
} = { requestHeaders: {} },
|
|
2804
2812
|
{ responseHeaders } = { responseHeaders: false }
|
|
2805
2813
|
) {
|
|
2806
2814
|
const {
|
|
@@ -2810,6 +2818,9 @@ class Communication {
|
|
|
2810
2818
|
pageNo,
|
|
2811
2819
|
pageSize,
|
|
2812
2820
|
populate,
|
|
2821
|
+
group,
|
|
2822
|
+
subGroup,
|
|
2823
|
+
fulfillmentOptionTypes,
|
|
2813
2824
|
},
|
|
2814
2825
|
{ abortEarly: false, allowUnknown: true }
|
|
2815
2826
|
);
|
|
@@ -2825,6 +2836,9 @@ class Communication {
|
|
|
2825
2836
|
pageNo,
|
|
2826
2837
|
pageSize,
|
|
2827
2838
|
populate,
|
|
2839
|
+
group,
|
|
2840
|
+
subGroup,
|
|
2841
|
+
fulfillmentOptionTypes,
|
|
2828
2842
|
},
|
|
2829
2843
|
{ abortEarly: false, allowUnknown: false }
|
|
2830
2844
|
);
|
|
@@ -2839,6 +2853,9 @@ class Communication {
|
|
|
2839
2853
|
query_params["page_no"] = pageNo;
|
|
2840
2854
|
query_params["page_size"] = pageSize;
|
|
2841
2855
|
query_params["populate"] = populate;
|
|
2856
|
+
query_params["group"] = group;
|
|
2857
|
+
query_params["sub_group"] = subGroup;
|
|
2858
|
+
query_params["fulfillment_option_types"] = fulfillmentOptionTypes;
|
|
2842
2859
|
|
|
2843
2860
|
const response = await PlatformAPIClient.execute(
|
|
2844
2861
|
this.config,
|
|
@@ -139,6 +139,14 @@ export = CommunicationPlatformApplicationValidator;
|
|
|
139
139
|
* @property {number} [pageNo] - Current page no
|
|
140
140
|
* @property {number} [pageSize] - Current request items count
|
|
141
141
|
* @property {string} [populate] - Populate Fields
|
|
142
|
+
* @property {string} [group] - An event group is a collection of email and SMS
|
|
143
|
+
* templates. Filtering by event group lets you view or manage all related
|
|
144
|
+
* communication templates together.
|
|
145
|
+
* @property {string} [subGroup] - Filter by event subgroup. Here, a subgroup is
|
|
146
|
+
* a subset within a group, containing specific email and SMS templates for
|
|
147
|
+
* more detailed organization.
|
|
148
|
+
* @property {string} [fulfillmentOptionTypes] - Filter by fulfillment option
|
|
149
|
+
* type. Indicates the delivery choice selected, e.g., standard or express.
|
|
142
150
|
*/
|
|
143
151
|
/**
|
|
144
152
|
* @typedef GetEventSubscriptionsByIdParam
|
|
@@ -619,6 +627,23 @@ type GetEventSubscriptionsParam = {
|
|
|
619
627
|
* - Populate Fields
|
|
620
628
|
*/
|
|
621
629
|
populate?: string;
|
|
630
|
+
/**
|
|
631
|
+
* - An event group is a collection of email and SMS
|
|
632
|
+
* templates. Filtering by event group lets you view or manage all related
|
|
633
|
+
* communication templates together.
|
|
634
|
+
*/
|
|
635
|
+
group?: string;
|
|
636
|
+
/**
|
|
637
|
+
* - Filter by event subgroup. Here, a subgroup is
|
|
638
|
+
* a subset within a group, containing specific email and SMS templates for
|
|
639
|
+
* more detailed organization.
|
|
640
|
+
*/
|
|
641
|
+
subGroup?: string;
|
|
642
|
+
/**
|
|
643
|
+
* - Filter by fulfillment option
|
|
644
|
+
* type. Indicates the delivery choice selected, e.g., standard or express.
|
|
645
|
+
*/
|
|
646
|
+
fulfillmentOptionTypes?: string;
|
|
622
647
|
};
|
|
623
648
|
type GetEventSubscriptionsByIdParam = {
|
|
624
649
|
/**
|
|
@@ -176,6 +176,14 @@ const CommunicationPlatformModel = require("./CommunicationPlatformModel");
|
|
|
176
176
|
* @property {number} [pageNo] - Current page no
|
|
177
177
|
* @property {number} [pageSize] - Current request items count
|
|
178
178
|
* @property {string} [populate] - Populate Fields
|
|
179
|
+
* @property {string} [group] - An event group is a collection of email and SMS
|
|
180
|
+
* templates. Filtering by event group lets you view or manage all related
|
|
181
|
+
* communication templates together.
|
|
182
|
+
* @property {string} [subGroup] - Filter by event subgroup. Here, a subgroup is
|
|
183
|
+
* a subset within a group, containing specific email and SMS templates for
|
|
184
|
+
* more detailed organization.
|
|
185
|
+
* @property {string} [fulfillmentOptionTypes] - Filter by fulfillment option
|
|
186
|
+
* type. Indicates the delivery choice selected, e.g., standard or express.
|
|
179
187
|
*/
|
|
180
188
|
|
|
181
189
|
/**
|
|
@@ -587,6 +595,9 @@ class CommunicationPlatformApplicationValidator {
|
|
|
587
595
|
pageNo: Joi.number(),
|
|
588
596
|
pageSize: Joi.number(),
|
|
589
597
|
populate: Joi.string().allow(""),
|
|
598
|
+
group: Joi.string().allow(""),
|
|
599
|
+
subGroup: Joi.string().allow(""),
|
|
600
|
+
fulfillmentOptionTypes: Joi.string().allow(""),
|
|
590
601
|
}).required();
|
|
591
602
|
}
|
|
592
603
|
|
|
@@ -1,4 +1,19 @@
|
|
|
1
1
|
export = CommunicationPlatformModel;
|
|
2
|
+
/**
|
|
3
|
+
* @typedef GroupMapping
|
|
4
|
+
* @property {EventGroup[]} items
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* @typedef EventGroup
|
|
8
|
+
* @property {string} name - Event group identifier
|
|
9
|
+
* @property {string} display - Human-readable group name
|
|
10
|
+
* @property {EventSubgroup[]} subgroups
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* @typedef EventSubgroup
|
|
14
|
+
* @property {string} name - Sub-group identifier
|
|
15
|
+
* @property {string} display - Human-readable sub-group name
|
|
16
|
+
*/
|
|
2
17
|
/**
|
|
3
18
|
* @typedef EventSubscriptionsBulkUpdatePayload
|
|
4
19
|
* @property {SubscriptionsObject[]} [subscriptions]
|
|
@@ -884,8 +899,38 @@ export = CommunicationPlatformModel;
|
|
|
884
899
|
declare class CommunicationPlatformModel {
|
|
885
900
|
}
|
|
886
901
|
declare namespace CommunicationPlatformModel {
|
|
887
|
-
export { EventSubscriptionsBulkUpdatePayload, EventSubscriptionsBulkUpdateResult, SubscriptionsObject, TemplateObject, CommunicationTemplate, AppProvider, AppProviderRes, AppProviderResVoice, AppProviderResObj, GlobalProviders, GlobalProvidersResObj, AppProviderReq, StatsImported, StatsProcessedEmail, StatsProcessedSms, StatsProcessed, Stats, GetStats, CampaignReq, RecipientHeaders, CampaignEmailTemplate, CampignEmailProvider, CampaignEmail, Campaign, Campaigns, BadRequestSchema, NotFound, AudienceReq, Audience, Audiences, GetNRecordsCsvReq, GetNRecordsCsvResItems, GetNRecordsCsvRes, DummyDatasources, DummyDatasourcesMeta, DummyDatasourcesMetaObj, EmailProviderReqFrom, EmailProviderReq, EmailProvider, EmailProviders, EmailTemplateKeys, EmailTemplateHeaders, EmailTemplateReq, TemplateAndType, EmailTemplate, SystemEmailTemplate, EmailTemplates, SystemEmailTemplates, PayloadEmailTemplateStructure, PayloadEmailProviderStructure, PayloadEmailStructure, PayloadSmsTemplateStructure, PayloadSmsProviderStructure, PayloadSmsStructure, PayloadStructure, MetaStructure, EnginePayload, EngineResult, EventSubscriptionTemplateSms, EventSubscriptionTemplateEmail, EventSubscriptionTemplate, EventSubscription, EventSubscriptionEvents, EventTemplate, EventProviderTemplates, EventSubscriptions, TriggerJobResult, TriggerJobPayload, GetGlobalVariablesResult, CreateGlobalVariablesResult, GlobalVariablesReq, Job, Jobs, CreateJobsRes, CreateJobsReq, JobLog, JobLogs, LogEmail, LogPushnotification, LogMeta, Log, Logs, SendOtpSmsCommsTemplate, SendOtpSmsCommsProvider, SendOtpEmailCommsProvider, SendOtpEmailCommsTemplate, SendOtpCommsReqData, SendOtpCommsReqSms, SendOtpCommsReqEmail, SendOtpCommsResSms, SendOtpCommsResEmail, SendOtpCommsReq, SendOtpCommsRes, VerifyOtpCommsReq, VerifyOtpCommsSuccessRes, VerifyOtpCommsErrorRes, SmsProviderReq, SmsProvider, SmsProviders, DefaultSmsProviders, SmsTemplateMessage, SmsTemplates, SmsTemplate, SystemSmsTemplates, SystemSmsTemplate, metaObj, SmsTemplateReq, Notification, SystemNotificationUser, SystemNotification, SystemNotifications, Page, GenericError, GenericDelete, Message, EnabledObj, OtpConfigurationExpiryDuration, OtpConfigurationExpiry, OtpConfiguration };
|
|
902
|
+
export { GroupMapping, EventGroup, EventSubgroup, EventSubscriptionsBulkUpdatePayload, EventSubscriptionsBulkUpdateResult, SubscriptionsObject, TemplateObject, CommunicationTemplate, AppProvider, AppProviderRes, AppProviderResVoice, AppProviderResObj, GlobalProviders, GlobalProvidersResObj, AppProviderReq, StatsImported, StatsProcessedEmail, StatsProcessedSms, StatsProcessed, Stats, GetStats, CampaignReq, RecipientHeaders, CampaignEmailTemplate, CampignEmailProvider, CampaignEmail, Campaign, Campaigns, BadRequestSchema, NotFound, AudienceReq, Audience, Audiences, GetNRecordsCsvReq, GetNRecordsCsvResItems, GetNRecordsCsvRes, DummyDatasources, DummyDatasourcesMeta, DummyDatasourcesMetaObj, EmailProviderReqFrom, EmailProviderReq, EmailProvider, EmailProviders, EmailTemplateKeys, EmailTemplateHeaders, EmailTemplateReq, TemplateAndType, EmailTemplate, SystemEmailTemplate, EmailTemplates, SystemEmailTemplates, PayloadEmailTemplateStructure, PayloadEmailProviderStructure, PayloadEmailStructure, PayloadSmsTemplateStructure, PayloadSmsProviderStructure, PayloadSmsStructure, PayloadStructure, MetaStructure, EnginePayload, EngineResult, EventSubscriptionTemplateSms, EventSubscriptionTemplateEmail, EventSubscriptionTemplate, EventSubscription, EventSubscriptionEvents, EventTemplate, EventProviderTemplates, EventSubscriptions, TriggerJobResult, TriggerJobPayload, GetGlobalVariablesResult, CreateGlobalVariablesResult, GlobalVariablesReq, Job, Jobs, CreateJobsRes, CreateJobsReq, JobLog, JobLogs, LogEmail, LogPushnotification, LogMeta, Log, Logs, SendOtpSmsCommsTemplate, SendOtpSmsCommsProvider, SendOtpEmailCommsProvider, SendOtpEmailCommsTemplate, SendOtpCommsReqData, SendOtpCommsReqSms, SendOtpCommsReqEmail, SendOtpCommsResSms, SendOtpCommsResEmail, SendOtpCommsReq, SendOtpCommsRes, VerifyOtpCommsReq, VerifyOtpCommsSuccessRes, VerifyOtpCommsErrorRes, SmsProviderReq, SmsProvider, SmsProviders, DefaultSmsProviders, SmsTemplateMessage, SmsTemplates, SmsTemplate, SystemSmsTemplates, SystemSmsTemplate, metaObj, SmsTemplateReq, Notification, SystemNotificationUser, SystemNotification, SystemNotifications, Page, GenericError, GenericDelete, Message, EnabledObj, OtpConfigurationExpiryDuration, OtpConfigurationExpiry, OtpConfiguration };
|
|
888
903
|
}
|
|
904
|
+
/** @returns {GroupMapping} */
|
|
905
|
+
declare function GroupMapping(): GroupMapping;
|
|
906
|
+
type GroupMapping = {
|
|
907
|
+
items: EventGroup[];
|
|
908
|
+
};
|
|
909
|
+
/** @returns {EventGroup} */
|
|
910
|
+
declare function EventGroup(): EventGroup;
|
|
911
|
+
type EventGroup = {
|
|
912
|
+
/**
|
|
913
|
+
* - Event group identifier
|
|
914
|
+
*/
|
|
915
|
+
name: string;
|
|
916
|
+
/**
|
|
917
|
+
* - Human-readable group name
|
|
918
|
+
*/
|
|
919
|
+
display: string;
|
|
920
|
+
subgroups: EventSubgroup[];
|
|
921
|
+
};
|
|
922
|
+
/** @returns {EventSubgroup} */
|
|
923
|
+
declare function EventSubgroup(): EventSubgroup;
|
|
924
|
+
type EventSubgroup = {
|
|
925
|
+
/**
|
|
926
|
+
* - Sub-group identifier
|
|
927
|
+
*/
|
|
928
|
+
name: string;
|
|
929
|
+
/**
|
|
930
|
+
* - Human-readable sub-group name
|
|
931
|
+
*/
|
|
932
|
+
display: string;
|
|
933
|
+
};
|
|
889
934
|
/** @returns {EventSubscriptionsBulkUpdatePayload} */
|
|
890
935
|
declare function EventSubscriptionsBulkUpdatePayload(): EventSubscriptionsBulkUpdatePayload;
|
|
891
936
|
type EventSubscriptionsBulkUpdatePayload = {
|
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
const Joi = require("joi");
|
|
2
2
|
|
|
3
|
+
/**
|
|
4
|
+
* @typedef GroupMapping
|
|
5
|
+
* @property {EventGroup[]} items
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @typedef EventGroup
|
|
10
|
+
* @property {string} name - Event group identifier
|
|
11
|
+
* @property {string} display - Human-readable group name
|
|
12
|
+
* @property {EventSubgroup[]} subgroups
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* @typedef EventSubgroup
|
|
17
|
+
* @property {string} name - Sub-group identifier
|
|
18
|
+
* @property {string} display - Human-readable sub-group name
|
|
19
|
+
*/
|
|
20
|
+
|
|
3
21
|
/**
|
|
4
22
|
* @typedef EventSubscriptionsBulkUpdatePayload
|
|
5
23
|
* @property {SubscriptionsObject[]} [subscriptions]
|
|
@@ -1002,6 +1020,34 @@ const Joi = require("joi");
|
|
|
1002
1020
|
*/
|
|
1003
1021
|
|
|
1004
1022
|
class CommunicationPlatformModel {
|
|
1023
|
+
/** @returns {GroupMapping} */
|
|
1024
|
+
static GroupMapping() {
|
|
1025
|
+
return Joi.object({
|
|
1026
|
+
items: Joi.array()
|
|
1027
|
+
.items(CommunicationPlatformModel.EventGroup())
|
|
1028
|
+
.required(),
|
|
1029
|
+
});
|
|
1030
|
+
}
|
|
1031
|
+
|
|
1032
|
+
/** @returns {EventGroup} */
|
|
1033
|
+
static EventGroup() {
|
|
1034
|
+
return Joi.object({
|
|
1035
|
+
name: Joi.string().allow("").required(),
|
|
1036
|
+
display: Joi.string().allow("").required(),
|
|
1037
|
+
subgroups: Joi.array()
|
|
1038
|
+
.items(CommunicationPlatformModel.EventSubgroup())
|
|
1039
|
+
.required(),
|
|
1040
|
+
});
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
/** @returns {EventSubgroup} */
|
|
1044
|
+
static EventSubgroup() {
|
|
1045
|
+
return Joi.object({
|
|
1046
|
+
name: Joi.string().allow("").required(),
|
|
1047
|
+
display: Joi.string().allow("").required(),
|
|
1048
|
+
});
|
|
1049
|
+
}
|
|
1050
|
+
|
|
1005
1051
|
/** @returns {EventSubscriptionsBulkUpdatePayload} */
|
|
1006
1052
|
static EventSubscriptionsBulkUpdatePayload() {
|
|
1007
1053
|
return Joi.object({
|
|
@@ -757,7 +757,7 @@ declare class Content {
|
|
|
757
757
|
* @summary: Get all HTML tags
|
|
758
758
|
* @description: Retrieve a list of injectable tags. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/content/getInjectableTags/).
|
|
759
759
|
*/
|
|
760
|
-
getInjectableTags({ all,
|
|
760
|
+
getInjectableTags({ all, search, requestHeaders }?: ContentPlatformApplicationValidator.GetInjectableTagsParam, { responseHeaders }?: object): Promise<ContentPlatformModel.TagsSchema>;
|
|
761
761
|
/**
|
|
762
762
|
* @param {ContentPlatformApplicationValidator.GetLandingPagesParam} arg - Arg object
|
|
763
763
|
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
@@ -5207,7 +5207,7 @@ class Content {
|
|
|
5207
5207
|
* @description: Retrieve a list of injectable tags. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/content/getInjectableTags/).
|
|
5208
5208
|
*/
|
|
5209
5209
|
async getInjectableTags(
|
|
5210
|
-
{ all,
|
|
5210
|
+
{ all, search, requestHeaders } = { requestHeaders: {} },
|
|
5211
5211
|
{ responseHeaders } = { responseHeaders: false }
|
|
5212
5212
|
) {
|
|
5213
5213
|
const {
|
|
@@ -5215,8 +5215,6 @@ class Content {
|
|
|
5215
5215
|
} = ContentPlatformApplicationValidator.getInjectableTags().validate(
|
|
5216
5216
|
{
|
|
5217
5217
|
all,
|
|
5218
|
-
pageNo,
|
|
5219
|
-
pageSize,
|
|
5220
5218
|
search,
|
|
5221
5219
|
},
|
|
5222
5220
|
{ abortEarly: false, allowUnknown: true }
|
|
@@ -5231,8 +5229,6 @@ class Content {
|
|
|
5231
5229
|
} = ContentPlatformApplicationValidator.getInjectableTags().validate(
|
|
5232
5230
|
{
|
|
5233
5231
|
all,
|
|
5234
|
-
pageNo,
|
|
5235
|
-
pageSize,
|
|
5236
5232
|
search,
|
|
5237
5233
|
},
|
|
5238
5234
|
{ abortEarly: false, allowUnknown: false }
|
|
@@ -5246,8 +5242,6 @@ class Content {
|
|
|
5246
5242
|
|
|
5247
5243
|
const query_params = {};
|
|
5248
5244
|
query_params["all"] = all;
|
|
5249
|
-
query_params["page_no"] = pageNo;
|
|
5250
|
-
query_params["page_size"] = pageSize;
|
|
5251
5245
|
query_params["search"] = search;
|
|
5252
5246
|
|
|
5253
5247
|
const response = await PlatformAPIClient.execute(
|
|
@@ -294,10 +294,6 @@ export = ContentPlatformApplicationValidator;
|
|
|
294
294
|
/**
|
|
295
295
|
* @typedef GetInjectableTagsParam
|
|
296
296
|
* @property {boolean} [all] - Get all tags irrespective of the creator of tags
|
|
297
|
-
* @property {number} [pageNo] - The page number to navigate through the given
|
|
298
|
-
* set of results. Default value is 1.
|
|
299
|
-
* @property {number} [pageSize] - The number of items to retrieve in each page.
|
|
300
|
-
* Default value is 10.
|
|
301
297
|
* @property {string} [search] - Keyword to filter and find tags by name.
|
|
302
298
|
*/
|
|
303
299
|
/**
|
|
@@ -1061,16 +1057,6 @@ type GetInjectableTagsParam = {
|
|
|
1061
1057
|
* - Get all tags irrespective of the creator of tags
|
|
1062
1058
|
*/
|
|
1063
1059
|
all?: boolean;
|
|
1064
|
-
/**
|
|
1065
|
-
* - The page number to navigate through the given
|
|
1066
|
-
* set of results. Default value is 1.
|
|
1067
|
-
*/
|
|
1068
|
-
pageNo?: number;
|
|
1069
|
-
/**
|
|
1070
|
-
* - The number of items to retrieve in each page.
|
|
1071
|
-
* Default value is 10.
|
|
1072
|
-
*/
|
|
1073
|
-
pageSize?: number;
|
|
1074
1060
|
/**
|
|
1075
1061
|
* - Keyword to filter and find tags by name.
|
|
1076
1062
|
*/
|
|
@@ -360,10 +360,6 @@ const ContentPlatformModel = require("./ContentPlatformModel");
|
|
|
360
360
|
/**
|
|
361
361
|
* @typedef GetInjectableTagsParam
|
|
362
362
|
* @property {boolean} [all] - Get all tags irrespective of the creator of tags
|
|
363
|
-
* @property {number} [pageNo] - The page number to navigate through the given
|
|
364
|
-
* set of results. Default value is 1.
|
|
365
|
-
* @property {number} [pageSize] - The number of items to retrieve in each page.
|
|
366
|
-
* Default value is 10.
|
|
367
363
|
* @property {string} [search] - Keyword to filter and find tags by name.
|
|
368
364
|
*/
|
|
369
365
|
|
|
@@ -1097,8 +1093,6 @@ class ContentPlatformApplicationValidator {
|
|
|
1097
1093
|
static getInjectableTags() {
|
|
1098
1094
|
return Joi.object({
|
|
1099
1095
|
all: Joi.boolean(),
|
|
1100
|
-
pageNo: Joi.number(),
|
|
1101
|
-
pageSize: Joi.number(),
|
|
1102
1096
|
search: Joi.string().allow(""),
|
|
1103
1097
|
}).required();
|
|
1104
1098
|
}
|
|
@@ -774,7 +774,6 @@ export = ContentPlatformModel;
|
|
|
774
774
|
* @property {string} [company] - The ID of the company associated with this tags.
|
|
775
775
|
* @property {TagSchema[]} [tags] - A list of tags (HTML resources like scripts
|
|
776
776
|
* or stylesheets) that are configured for the application.
|
|
777
|
-
* @property {Page} [page]
|
|
778
777
|
*/
|
|
779
778
|
/**
|
|
780
779
|
* @typedef TagSchema
|
|
@@ -2710,7 +2709,6 @@ type TagsSchema = {
|
|
|
2710
2709
|
* or stylesheets) that are configured for the application.
|
|
2711
2710
|
*/
|
|
2712
2711
|
tags?: TagSchema[];
|
|
2713
|
-
page?: Page;
|
|
2714
2712
|
};
|
|
2715
2713
|
/** @returns {TagSchema} */
|
|
2716
2714
|
declare function TagSchema(): TagSchema;
|
|
@@ -876,7 +876,6 @@ const Joi = require("joi");
|
|
|
876
876
|
* @property {string} [company] - The ID of the company associated with this tags.
|
|
877
877
|
* @property {TagSchema[]} [tags] - A list of tags (HTML resources like scripts
|
|
878
878
|
* or stylesheets) that are configured for the application.
|
|
879
|
-
* @property {Page} [page]
|
|
880
879
|
*/
|
|
881
880
|
|
|
882
881
|
/**
|
|
@@ -2871,7 +2870,6 @@ class ContentPlatformModel {
|
|
|
2871
2870
|
_id: Joi.string().allow(""),
|
|
2872
2871
|
company: Joi.string().allow(""),
|
|
2873
2872
|
tags: Joi.array().items(ContentPlatformModel.TagSchema()),
|
|
2874
|
-
page: ContentPlatformModel.Page(),
|
|
2875
2873
|
});
|
|
2876
2874
|
}
|
|
2877
2875
|
|
|
@@ -149,6 +149,16 @@ declare class User {
|
|
|
149
149
|
* @description: This request deletes attribute values for a single user based on the provided user attribute definition. Each user attribute definition represents a distinct attribute, and for each definition, a user can have one corresponding value. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/user/deleteUserAttributesInBulk/).
|
|
150
150
|
*/
|
|
151
151
|
deleteUserAttributesInBulk({ userId, body, requestHeaders }?: UserPlatformApplicationValidator.DeleteUserAttributesInBulkParam, { responseHeaders }?: object): Promise<UserPlatformModel.SuccessMessage>;
|
|
152
|
+
/**
|
|
153
|
+
* @param {UserPlatformApplicationValidator.DeleteUserGroupParam} arg - Arg object
|
|
154
|
+
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
155
|
+
* @param {import("../PlatformAPIClient").Options} - Options
|
|
156
|
+
* @returns {Promise<UserPlatformModel.DeleteUserGroupSuccess>} - Success response
|
|
157
|
+
* @name deleteUserGroup
|
|
158
|
+
* @summary: Delete User Group
|
|
159
|
+
* @description: Permanently delete a user group by its unique identifier. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/user/deleteUserGroup/).
|
|
160
|
+
*/
|
|
161
|
+
deleteUserGroup({ groupId, requestHeaders }?: UserPlatformApplicationValidator.DeleteUserGroupParam, { responseHeaders }?: object): Promise<UserPlatformModel.DeleteUserGroupSuccess>;
|
|
152
162
|
/**
|
|
153
163
|
* @param {UserPlatformApplicationValidator.FilterUsersByAttributesParam} arg
|
|
154
164
|
* - Arg object
|
|
@@ -1062,6 +1062,85 @@ class User {
|
|
|
1062
1062
|
return response;
|
|
1063
1063
|
}
|
|
1064
1064
|
|
|
1065
|
+
/**
|
|
1066
|
+
* @param {UserPlatformApplicationValidator.DeleteUserGroupParam} arg - Arg object
|
|
1067
|
+
* @param {object} [arg.requestHeaders={}] - Request headers. Default is `{}`
|
|
1068
|
+
* @param {import("../PlatformAPIClient").Options} - Options
|
|
1069
|
+
* @returns {Promise<UserPlatformModel.DeleteUserGroupSuccess>} - Success response
|
|
1070
|
+
* @name deleteUserGroup
|
|
1071
|
+
* @summary: Delete User Group
|
|
1072
|
+
* @description: Permanently delete a user group by its unique identifier. - Check out [method documentation](https://docs.fynd.com/partners/commerce/sdk/platform/user/deleteUserGroup/).
|
|
1073
|
+
*/
|
|
1074
|
+
async deleteUserGroup(
|
|
1075
|
+
{ groupId, requestHeaders } = { requestHeaders: {} },
|
|
1076
|
+
{ responseHeaders } = { responseHeaders: false }
|
|
1077
|
+
) {
|
|
1078
|
+
const {
|
|
1079
|
+
error,
|
|
1080
|
+
} = UserPlatformApplicationValidator.deleteUserGroup().validate(
|
|
1081
|
+
{
|
|
1082
|
+
groupId,
|
|
1083
|
+
},
|
|
1084
|
+
{ abortEarly: false, allowUnknown: true }
|
|
1085
|
+
);
|
|
1086
|
+
if (error) {
|
|
1087
|
+
return Promise.reject(new FDKClientValidationError(error));
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
// Showing warrnings if extra unknown parameters are found
|
|
1091
|
+
const {
|
|
1092
|
+
error: warrning,
|
|
1093
|
+
} = UserPlatformApplicationValidator.deleteUserGroup().validate(
|
|
1094
|
+
{
|
|
1095
|
+
groupId,
|
|
1096
|
+
},
|
|
1097
|
+
{ abortEarly: false, allowUnknown: false }
|
|
1098
|
+
);
|
|
1099
|
+
if (warrning) {
|
|
1100
|
+
Logger({
|
|
1101
|
+
level: "WARN",
|
|
1102
|
+
message: `Parameter Validation warrnings for platform > User > deleteUserGroup \n ${warrning}`,
|
|
1103
|
+
});
|
|
1104
|
+
}
|
|
1105
|
+
|
|
1106
|
+
const query_params = {};
|
|
1107
|
+
|
|
1108
|
+
const response = await PlatformAPIClient.execute(
|
|
1109
|
+
this.config,
|
|
1110
|
+
"delete",
|
|
1111
|
+
`/service/platform/user/v1.0/company/${this.config.companyId}/application/${this.applicationId}/user_group/${groupId}`,
|
|
1112
|
+
query_params,
|
|
1113
|
+
undefined,
|
|
1114
|
+
requestHeaders,
|
|
1115
|
+
{ responseHeaders }
|
|
1116
|
+
);
|
|
1117
|
+
|
|
1118
|
+
let responseData = response;
|
|
1119
|
+
if (responseHeaders) {
|
|
1120
|
+
responseData = response[0];
|
|
1121
|
+
}
|
|
1122
|
+
|
|
1123
|
+
const {
|
|
1124
|
+
error: res_error,
|
|
1125
|
+
} = UserPlatformModel.DeleteUserGroupSuccess().validate(responseData, {
|
|
1126
|
+
abortEarly: false,
|
|
1127
|
+
allowUnknown: true,
|
|
1128
|
+
});
|
|
1129
|
+
|
|
1130
|
+
if (res_error) {
|
|
1131
|
+
if (this.config.options.strictResponseCheck === true) {
|
|
1132
|
+
return Promise.reject(new FDKResponseValidationError(res_error));
|
|
1133
|
+
} else {
|
|
1134
|
+
Logger({
|
|
1135
|
+
level: "WARN",
|
|
1136
|
+
message: `Response Validation Warnings for platform > User > deleteUserGroup \n ${res_error}`,
|
|
1137
|
+
});
|
|
1138
|
+
}
|
|
1139
|
+
}
|
|
1140
|
+
|
|
1141
|
+
return response;
|
|
1142
|
+
}
|
|
1143
|
+
|
|
1065
1144
|
/**
|
|
1066
1145
|
* @param {UserPlatformApplicationValidator.FilterUsersByAttributesParam} arg
|
|
1067
1146
|
* - Arg object
|
|
@@ -60,6 +60,10 @@ export = UserPlatformApplicationValidator;
|
|
|
60
60
|
* @property {string} userId - The unique identifier of the user to update.
|
|
61
61
|
* @property {UserPlatformModel.DeleteBulkUserAttribute} body
|
|
62
62
|
*/
|
|
63
|
+
/**
|
|
64
|
+
* @typedef DeleteUserGroupParam
|
|
65
|
+
* @property {string} groupId - Unique ID allotted to a User Group
|
|
66
|
+
*/
|
|
63
67
|
/**
|
|
64
68
|
* @typedef FilterUsersByAttributesParam
|
|
65
69
|
* @property {UserPlatformModel.UserAttributeFilter} body
|
|
@@ -232,6 +236,8 @@ declare class UserPlatformApplicationValidator {
|
|
|
232
236
|
static deleteUserAttributeDefinitionById(): DeleteUserAttributeDefinitionByIdParam;
|
|
233
237
|
/** @returns {DeleteUserAttributesInBulkParam} */
|
|
234
238
|
static deleteUserAttributesInBulk(): DeleteUserAttributesInBulkParam;
|
|
239
|
+
/** @returns {DeleteUserGroupParam} */
|
|
240
|
+
static deleteUserGroup(): DeleteUserGroupParam;
|
|
235
241
|
/** @returns {FilterUsersByAttributesParam} */
|
|
236
242
|
static filterUsersByAttributes(): FilterUsersByAttributesParam;
|
|
237
243
|
/** @returns {GetActiveSessionsParam} */
|
|
@@ -282,7 +288,7 @@ declare class UserPlatformApplicationValidator {
|
|
|
282
288
|
static updateUserGroupPartially(): UpdateUserGroupPartiallyParam;
|
|
283
289
|
}
|
|
284
290
|
declare namespace UserPlatformApplicationValidator {
|
|
285
|
-
export { ArchiveUserParam, BlockOrUnblockUsersParam, BulkImportStoreFrontUsersParam, CreateBulkExportUsersParam, CreateUserParam, CreateUserAttributeDefinitionParam, CreateUserGroupParam, CreateUserSessionParam, DeleteActiveSessionsParam, DeleteSessionParam, DeleteUserAttributeParam, DeleteUserAttributeDefinitionByIdParam, DeleteUserAttributesInBulkParam, FilterUsersByAttributesParam, GetActiveSessionsParam, GetBulkExportUsersListParam, GetBulkImportUsersListParam, GetCustomersParam, GetPlatformConfigParam, GetUserAttributeParam, GetUserAttributeByIdParam, GetUserAttributeDefinitionByIdParam, GetUserAttributeDefinitionsParam, GetUserAttributesForUserParam, GetUserGroupByIdParam, GetUserGroupsParam, GetUserTimelineParam, GetUsersJobByJobIdParam, SearchUsersParam, UnDeleteUserParam, UpdatePlatformConfigParam, UpdateUserParam, UpdateUserAttributeParam, UpdateUserAttributeDefinitionParam, UpdateUserAttributesParam, UpdateUserGroupParam, UpdateUserGroupPartiallyParam };
|
|
291
|
+
export { ArchiveUserParam, BlockOrUnblockUsersParam, BulkImportStoreFrontUsersParam, CreateBulkExportUsersParam, CreateUserParam, CreateUserAttributeDefinitionParam, CreateUserGroupParam, CreateUserSessionParam, DeleteActiveSessionsParam, DeleteSessionParam, DeleteUserAttributeParam, DeleteUserAttributeDefinitionByIdParam, DeleteUserAttributesInBulkParam, DeleteUserGroupParam, FilterUsersByAttributesParam, GetActiveSessionsParam, GetBulkExportUsersListParam, GetBulkImportUsersListParam, GetCustomersParam, GetPlatformConfigParam, GetUserAttributeParam, GetUserAttributeByIdParam, GetUserAttributeDefinitionByIdParam, GetUserAttributeDefinitionsParam, GetUserAttributesForUserParam, GetUserGroupByIdParam, GetUserGroupsParam, GetUserTimelineParam, GetUsersJobByJobIdParam, SearchUsersParam, UnDeleteUserParam, UpdatePlatformConfigParam, UpdateUserParam, UpdateUserAttributeParam, UpdateUserAttributeDefinitionParam, UpdateUserAttributesParam, UpdateUserGroupParam, UpdateUserGroupPartiallyParam };
|
|
286
292
|
}
|
|
287
293
|
type ArchiveUserParam = {
|
|
288
294
|
body: UserPlatformModel.ArchiveUserRequestSchema;
|
|
@@ -362,6 +368,12 @@ type DeleteUserAttributesInBulkParam = {
|
|
|
362
368
|
userId: string;
|
|
363
369
|
body: UserPlatformModel.DeleteBulkUserAttribute;
|
|
364
370
|
};
|
|
371
|
+
type DeleteUserGroupParam = {
|
|
372
|
+
/**
|
|
373
|
+
* - Unique ID allotted to a User Group
|
|
374
|
+
*/
|
|
375
|
+
groupId: string;
|
|
376
|
+
};
|
|
365
377
|
type FilterUsersByAttributesParam = {
|
|
366
378
|
body: UserPlatformModel.UserAttributeFilter;
|
|
367
379
|
};
|
|
@@ -76,6 +76,11 @@ const UserPlatformModel = require("./UserPlatformModel");
|
|
|
76
76
|
* @property {UserPlatformModel.DeleteBulkUserAttribute} body
|
|
77
77
|
*/
|
|
78
78
|
|
|
79
|
+
/**
|
|
80
|
+
* @typedef DeleteUserGroupParam
|
|
81
|
+
* @property {string} groupId - Unique ID allotted to a User Group
|
|
82
|
+
*/
|
|
83
|
+
|
|
79
84
|
/**
|
|
80
85
|
* @typedef FilterUsersByAttributesParam
|
|
81
86
|
* @property {UserPlatformModel.UserAttributeFilter} body
|
|
@@ -344,6 +349,13 @@ class UserPlatformApplicationValidator {
|
|
|
344
349
|
}).required();
|
|
345
350
|
}
|
|
346
351
|
|
|
352
|
+
/** @returns {DeleteUserGroupParam} */
|
|
353
|
+
static deleteUserGroup() {
|
|
354
|
+
return Joi.object({
|
|
355
|
+
groupId: Joi.string().allow("").required(),
|
|
356
|
+
}).required();
|
|
357
|
+
}
|
|
358
|
+
|
|
347
359
|
/** @returns {FilterUsersByAttributesParam} */
|
|
348
360
|
static filterUsersByAttributes() {
|
|
349
361
|
return Joi.object({
|
|
@@ -321,9 +321,12 @@ export = UserPlatformModel;
|
|
|
321
321
|
*/
|
|
322
322
|
/**
|
|
323
323
|
* @typedef ConditionsSchema
|
|
324
|
-
* @property {string} [user_attribute_definition_id]
|
|
325
|
-
*
|
|
326
|
-
* @property {string} [value
|
|
324
|
+
* @property {string} [user_attribute_definition_id] - ID of the user attribute
|
|
325
|
+
* definition used in the condition
|
|
326
|
+
* @property {string} [type] - Type of condition to apply on the attribute value.
|
|
327
|
+
* @property {string} [value] - Value of the condition
|
|
328
|
+
* @property {boolean} [ignore_year] - Indicates if the year should be ignored
|
|
329
|
+
* for the condition
|
|
327
330
|
*/
|
|
328
331
|
/**
|
|
329
332
|
* @typedef DeleteBulkUserAttribute
|
|
@@ -693,6 +696,12 @@ export = UserPlatformModel;
|
|
|
693
696
|
* @typedef UserConsent
|
|
694
697
|
* @property {PrivacyPolicyConsentSchema} [privacy_policy]
|
|
695
698
|
*/
|
|
699
|
+
/**
|
|
700
|
+
* @typedef DeleteUserGroupSuccess
|
|
701
|
+
* @property {string} id - ID of the user group that was deleted
|
|
702
|
+
* @property {boolean} success - Success indicating the user group was deleted
|
|
703
|
+
* successfully.
|
|
704
|
+
*/
|
|
696
705
|
/**
|
|
697
706
|
* @typedef PrivacyPolicyConsentSchema
|
|
698
707
|
* @property {boolean} [value] - Whether the user has consented to the privacy policy
|
|
@@ -701,7 +710,7 @@ export = UserPlatformModel;
|
|
|
701
710
|
declare class UserPlatformModel {
|
|
702
711
|
}
|
|
703
712
|
declare namespace UserPlatformModel {
|
|
704
|
-
export { SuccessMessage, UserAttributeDefinitionList, UserAttributeDefinition, UserAttributeDefinitionDetails, AttributeMaskingProperties, AttributeRegistrationProperties, UserAttributeDefinitionValidation, BulkUserAttribute, UserAttribute, CreateBulkUserAttribute, BulkUserAttributeRequestBody, CreateUserAttribute, CreateUserAttributeDefinition, CreateStoreFrontUsersPayload, BulkUserExportSchema, BulkActionModel, CreatedBySchema, BulkActionLinkSchema, FileLinks, BulkActionCountSchema, BlockUserRequestSchema, ArchiveUserRequestSchema, UnDeleteUserRequestSchema, BlockUserSuccess, ArchiveUserSuccess, UnDeleteUserSuccess, UserSearchResponseSchema, CustomerListResponseSchema, BulkActionPaginationSchema, PaginationSchema, SessionListResponseSchema, SessionDeleteResponseSchema, SessionsDeleteResponseSchema, APIError, SessionListResponseInfo, Conditions, UserResponseErrorSchema, UserGroupResponseSchema, UserGroupListResponseSchema, ConditionsSchema, DeleteBulkUserAttribute, UserAttributeFilter, UserAttributeFilterQuery, UserAttributeFilterRequestConditions, UserAttributeFiltered, UserAttributeFilteredList, CreateUserGroup, CreateUserRequestSchema, CreateUserResponseSchema, CreateUserSessionRequestSchema, CreateUserSessionResponseSchema, PlatformSchema, LookAndFeel, Login, MetaSchema, Social, RequiredFields, PlatformEmail, PlatformMobile, RegisterRequiredFields, RegisterRequiredFieldsEmail, RegisterRequiredFieldsMobile, FlashCard, SocialTokens, DeleteAccountReasons, DeleteAccountConsent, GetUserTimeline, UserTimeline, Facebook, Accountkit, Google, SessionExpiry, UpdateUserGroupSchema, PartialUserGroupUpdateSchema, UserGroupUpdateData, UpdateUserRequestSchema, UserEmails, UserPhoneNumbers, UserSchema, UserSearchSchema, PhoneNumber, Email, UserConsent, PrivacyPolicyConsentSchema };
|
|
713
|
+
export { SuccessMessage, UserAttributeDefinitionList, UserAttributeDefinition, UserAttributeDefinitionDetails, AttributeMaskingProperties, AttributeRegistrationProperties, UserAttributeDefinitionValidation, BulkUserAttribute, UserAttribute, CreateBulkUserAttribute, BulkUserAttributeRequestBody, CreateUserAttribute, CreateUserAttributeDefinition, CreateStoreFrontUsersPayload, BulkUserExportSchema, BulkActionModel, CreatedBySchema, BulkActionLinkSchema, FileLinks, BulkActionCountSchema, BlockUserRequestSchema, ArchiveUserRequestSchema, UnDeleteUserRequestSchema, BlockUserSuccess, ArchiveUserSuccess, UnDeleteUserSuccess, UserSearchResponseSchema, CustomerListResponseSchema, BulkActionPaginationSchema, PaginationSchema, SessionListResponseSchema, SessionDeleteResponseSchema, SessionsDeleteResponseSchema, APIError, SessionListResponseInfo, Conditions, UserResponseErrorSchema, UserGroupResponseSchema, UserGroupListResponseSchema, ConditionsSchema, DeleteBulkUserAttribute, UserAttributeFilter, UserAttributeFilterQuery, UserAttributeFilterRequestConditions, UserAttributeFiltered, UserAttributeFilteredList, CreateUserGroup, CreateUserRequestSchema, CreateUserResponseSchema, CreateUserSessionRequestSchema, CreateUserSessionResponseSchema, PlatformSchema, LookAndFeel, Login, MetaSchema, Social, RequiredFields, PlatformEmail, PlatformMobile, RegisterRequiredFields, RegisterRequiredFieldsEmail, RegisterRequiredFieldsMobile, FlashCard, SocialTokens, DeleteAccountReasons, DeleteAccountConsent, GetUserTimeline, UserTimeline, Facebook, Accountkit, Google, SessionExpiry, UpdateUserGroupSchema, PartialUserGroupUpdateSchema, UserGroupUpdateData, UpdateUserRequestSchema, UserEmails, UserPhoneNumbers, UserSchema, UserSearchSchema, PhoneNumber, Email, UserConsent, DeleteUserGroupSuccess, PrivacyPolicyConsentSchema };
|
|
705
714
|
}
|
|
706
715
|
/** @returns {SuccessMessage} */
|
|
707
716
|
declare function SuccessMessage(): SuccessMessage;
|
|
@@ -1326,9 +1335,24 @@ type UserGroupListResponseSchema = {
|
|
|
1326
1335
|
/** @returns {ConditionsSchema} */
|
|
1327
1336
|
declare function ConditionsSchema(): ConditionsSchema;
|
|
1328
1337
|
type ConditionsSchema = {
|
|
1338
|
+
/**
|
|
1339
|
+
* - ID of the user attribute
|
|
1340
|
+
* definition used in the condition
|
|
1341
|
+
*/
|
|
1329
1342
|
user_attribute_definition_id?: string;
|
|
1343
|
+
/**
|
|
1344
|
+
* - Type of condition to apply on the attribute value.
|
|
1345
|
+
*/
|
|
1330
1346
|
type?: string;
|
|
1347
|
+
/**
|
|
1348
|
+
* - Value of the condition
|
|
1349
|
+
*/
|
|
1331
1350
|
value?: string;
|
|
1351
|
+
/**
|
|
1352
|
+
* - Indicates if the year should be ignored
|
|
1353
|
+
* for the condition
|
|
1354
|
+
*/
|
|
1355
|
+
ignore_year?: boolean;
|
|
1332
1356
|
};
|
|
1333
1357
|
/** @returns {DeleteBulkUserAttribute} */
|
|
1334
1358
|
declare function DeleteBulkUserAttribute(): DeleteBulkUserAttribute;
|
|
@@ -1902,6 +1926,19 @@ declare function UserConsent(): UserConsent;
|
|
|
1902
1926
|
type UserConsent = {
|
|
1903
1927
|
privacy_policy?: PrivacyPolicyConsentSchema;
|
|
1904
1928
|
};
|
|
1929
|
+
/** @returns {DeleteUserGroupSuccess} */
|
|
1930
|
+
declare function DeleteUserGroupSuccess(): DeleteUserGroupSuccess;
|
|
1931
|
+
type DeleteUserGroupSuccess = {
|
|
1932
|
+
/**
|
|
1933
|
+
* - ID of the user group that was deleted
|
|
1934
|
+
*/
|
|
1935
|
+
id: string;
|
|
1936
|
+
/**
|
|
1937
|
+
* - Success indicating the user group was deleted
|
|
1938
|
+
* successfully.
|
|
1939
|
+
*/
|
|
1940
|
+
success: boolean;
|
|
1941
|
+
};
|
|
1905
1942
|
/** @returns {PrivacyPolicyConsentSchema} */
|
|
1906
1943
|
declare function PrivacyPolicyConsentSchema(): PrivacyPolicyConsentSchema;
|
|
1907
1944
|
type PrivacyPolicyConsentSchema = {
|
|
@@ -361,9 +361,12 @@ const Joi = require("joi");
|
|
|
361
361
|
|
|
362
362
|
/**
|
|
363
363
|
* @typedef ConditionsSchema
|
|
364
|
-
* @property {string} [user_attribute_definition_id]
|
|
365
|
-
*
|
|
366
|
-
* @property {string} [value
|
|
364
|
+
* @property {string} [user_attribute_definition_id] - ID of the user attribute
|
|
365
|
+
* definition used in the condition
|
|
366
|
+
* @property {string} [type] - Type of condition to apply on the attribute value.
|
|
367
|
+
* @property {string} [value] - Value of the condition
|
|
368
|
+
* @property {boolean} [ignore_year] - Indicates if the year should be ignored
|
|
369
|
+
* for the condition
|
|
367
370
|
*/
|
|
368
371
|
|
|
369
372
|
/**
|
|
@@ -777,6 +780,13 @@ const Joi = require("joi");
|
|
|
777
780
|
* @property {PrivacyPolicyConsentSchema} [privacy_policy]
|
|
778
781
|
*/
|
|
779
782
|
|
|
783
|
+
/**
|
|
784
|
+
* @typedef DeleteUserGroupSuccess
|
|
785
|
+
* @property {string} id - ID of the user group that was deleted
|
|
786
|
+
* @property {boolean} success - Success indicating the user group was deleted
|
|
787
|
+
* successfully.
|
|
788
|
+
*/
|
|
789
|
+
|
|
780
790
|
/**
|
|
781
791
|
* @typedef PrivacyPolicyConsentSchema
|
|
782
792
|
* @property {boolean} [value] - Whether the user has consented to the privacy policy
|
|
@@ -1197,6 +1207,7 @@ class UserPlatformModel {
|
|
|
1197
1207
|
user_attribute_definition_id: Joi.string().allow(""),
|
|
1198
1208
|
type: Joi.string().allow(""),
|
|
1199
1209
|
value: Joi.string().allow(""),
|
|
1210
|
+
ignore_year: Joi.boolean(),
|
|
1200
1211
|
});
|
|
1201
1212
|
}
|
|
1202
1213
|
|
|
@@ -1674,6 +1685,14 @@ class UserPlatformModel {
|
|
|
1674
1685
|
});
|
|
1675
1686
|
}
|
|
1676
1687
|
|
|
1688
|
+
/** @returns {DeleteUserGroupSuccess} */
|
|
1689
|
+
static DeleteUserGroupSuccess() {
|
|
1690
|
+
return Joi.object({
|
|
1691
|
+
id: Joi.string().allow("").required(),
|
|
1692
|
+
success: Joi.boolean().required(),
|
|
1693
|
+
});
|
|
1694
|
+
}
|
|
1695
|
+
|
|
1677
1696
|
/** @returns {PrivacyPolicyConsentSchema} */
|
|
1678
1697
|
static PrivacyPolicyConsentSchema() {
|
|
1679
1698
|
return Joi.object({
|