@wix/members 1.0.15 → 1.0.16

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.
Files changed (53) hide show
  1. package/build/cjs/index.d.ts +1 -0
  2. package/build/cjs/index.js +2 -1
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +3 -0
  5. package/build/cjs/index.typings.js +26 -0
  6. package/build/cjs/index.typings.js.map +1 -0
  7. package/build/cjs/src/badges-v3-badge.universal.d.ts +21 -12
  8. package/build/cjs/src/badges-v3-badge.universal.js +21 -12
  9. package/build/cjs/src/badges-v3-badge.universal.js.map +1 -1
  10. package/build/cjs/src/identity-members-v1-member.http.d.ts +10 -0
  11. package/build/cjs/src/identity-members-v1-member.http.js +221 -0
  12. package/build/cjs/src/identity-members-v1-member.http.js.map +1 -0
  13. package/build/cjs/src/identity-members-v1-member.public.d.ts +8 -0
  14. package/build/cjs/src/identity-members-v1-member.public.js +19 -0
  15. package/build/cjs/src/identity-members-v1-member.public.js.map +1 -0
  16. package/build/cjs/src/identity-members-v1-member.types.d.ts +655 -0
  17. package/build/cjs/src/identity-members-v1-member.types.js +48 -0
  18. package/build/cjs/src/identity-members-v1-member.types.js.map +1 -0
  19. package/build/cjs/src/identity-members-v1-member.universal.d.ts +682 -0
  20. package/build/cjs/src/identity-members-v1-member.universal.js +158 -0
  21. package/build/cjs/src/identity-members-v1-member.universal.js.map +1 -0
  22. package/build/cjs/src/members-v1-member.public.d.ts +1 -1
  23. package/build/cjs/src/members-v1-member.types.d.ts +30 -11
  24. package/build/cjs/src/members-v1-member.types.js.map +1 -1
  25. package/build/cjs/src/members-v1-member.universal.d.ts +32 -17
  26. package/build/cjs/src/members-v1-member.universal.js.map +1 -1
  27. package/build/es/index.d.ts +1 -0
  28. package/build/es/index.js +1 -0
  29. package/build/es/index.js.map +1 -1
  30. package/build/es/index.typings.d.ts +3 -0
  31. package/build/es/index.typings.js +4 -0
  32. package/build/es/index.typings.js.map +1 -0
  33. package/build/es/src/badges-v3-badge.universal.d.ts +21 -12
  34. package/build/es/src/badges-v3-badge.universal.js +21 -12
  35. package/build/es/src/badges-v3-badge.universal.js.map +1 -1
  36. package/build/es/src/identity-members-v1-member.http.d.ts +10 -0
  37. package/build/es/src/identity-members-v1-member.http.js +217 -0
  38. package/build/es/src/identity-members-v1-member.http.js.map +1 -0
  39. package/build/es/src/identity-members-v1-member.public.d.ts +8 -0
  40. package/build/es/src/identity-members-v1-member.public.js +9 -0
  41. package/build/es/src/identity-members-v1-member.public.js.map +1 -0
  42. package/build/es/src/identity-members-v1-member.types.d.ts +655 -0
  43. package/build/es/src/identity-members-v1-member.types.js +45 -0
  44. package/build/es/src/identity-members-v1-member.types.js.map +1 -0
  45. package/build/es/src/identity-members-v1-member.universal.d.ts +682 -0
  46. package/build/es/src/identity-members-v1-member.universal.js +135 -0
  47. package/build/es/src/identity-members-v1-member.universal.js.map +1 -0
  48. package/build/es/src/members-v1-member.public.d.ts +1 -1
  49. package/build/es/src/members-v1-member.types.d.ts +30 -11
  50. package/build/es/src/members-v1-member.types.js.map +1 -1
  51. package/build/es/src/members-v1-member.universal.d.ts +32 -17
  52. package/build/es/src/members-v1-member.universal.js.map +1 -1
  53. package/package.json +2 -2
@@ -0,0 +1,682 @@
1
+ export declare const __debug: {
2
+ verboseLogging: {
3
+ on: () => boolean;
4
+ off: () => boolean;
5
+ };
6
+ };
7
+ export interface Member {
8
+ /**
9
+ * member's id
10
+ * @readonly
11
+ */
12
+ _id?: string;
13
+ /**
14
+ * `true` if member completed email verification, otherwise `false`
15
+ * @readonly
16
+ */
17
+ emailVerified?: boolean;
18
+ /**
19
+ * member's role:
20
+ *
21
+ * `OWNER` - member that belongs to site owner
22
+ * `CONTRIBUTOR` - member that belongs to a contributor in site
23
+ * `MEMBER` - other members that registered to site
24
+ */
25
+ role?: Role;
26
+ /** email to be used when logging in */
27
+ loginEmail?: string | null;
28
+ /** member's full name */
29
+ memberName?: string | null;
30
+ /** member's first name */
31
+ firstName?: string | null;
32
+ /** member's last name */
33
+ lastName?: string | null;
34
+ /**
35
+ * Deprecated: please use `picture` field instead.
36
+ * URL for member's profile image
37
+ */
38
+ imageUrl?: string | null;
39
+ /** member's nickname (exposed to other members) */
40
+ nickname?: string | null;
41
+ /** `PUBLIC` if other members can view this profile, `PRIVATE` otherwise */
42
+ profilePrivacyStatus?: SiteMemberPrivacyStatus;
43
+ /** url segment for accessing the member's profile */
44
+ slug?: string | null;
45
+ /** member's language */
46
+ language?: string | null;
47
+ /**
48
+ * member's status:
49
+ *
50
+ * `ACTIVE` - when member is approved
51
+ * `APPLICANT` - when pending site owner's approval
52
+ * `BLOCKED` - when member is blocked by the site's owner
53
+ * `INACTIVE` - not used
54
+ */
55
+ status?: SiteMemberStatus;
56
+ /**
57
+ * date the member was created
58
+ * @readonly
59
+ */
60
+ creationDate?: Date;
61
+ /**
62
+ * date the member was last updated
63
+ * @readonly
64
+ */
65
+ lastUpdateDate?: Date;
66
+ /**
67
+ * date of last login
68
+ * @readonly
69
+ */
70
+ lastLoginDate?: Date;
71
+ /**
72
+ * member's email addresses
73
+ * (returned when `include_contact_details` is set to `true`)
74
+ */
75
+ emails?: string[];
76
+ /**
77
+ * member's phone numbers
78
+ * (returned when `include_contact_details` is set to `true`)
79
+ */
80
+ phones?: string[];
81
+ /**
82
+ * member's addresses
83
+ * (returned when `include_contact_details` is set to `true`)
84
+ */
85
+ addresses?: Address[];
86
+ /**
87
+ * labels attached to the member by the owner (in contacts dashboard)
88
+ * (returned when `include_contact_details` is set to `true`)
89
+ */
90
+ labels?: string[];
91
+ /**
92
+ * custom fields set for the member by the owner (in contacts dashboard)
93
+ * (returned when `include_contact_details` is set to `true`)
94
+ */
95
+ customFields?: CustomField[];
96
+ /**
97
+ * member's profile picture
98
+ * supports both media-items and external urls
99
+ */
100
+ picture?: string;
101
+ /** member's user id */
102
+ userId?: string | null;
103
+ /** Groups the the member is registered to */
104
+ groups?: Group[];
105
+ /**
106
+ * member's contact id
107
+ * @readonly
108
+ */
109
+ contactId?: string | null;
110
+ }
111
+ export declare enum Role {
112
+ UNDEFINED_ROLE = "UNDEFINED_ROLE",
113
+ MEMBER = "MEMBER",
114
+ OWNER = "OWNER",
115
+ CONTRIBUTOR = "CONTRIBUTOR"
116
+ }
117
+ export declare enum SiteMemberPrivacyStatus {
118
+ UNDEFINED = "UNDEFINED",
119
+ PUBLIC = "PUBLIC",
120
+ PRIVATE = "PRIVATE",
121
+ COMMUNITY = "COMMUNITY"
122
+ }
123
+ export declare enum SiteMemberStatus {
124
+ UNDEFINED_STATUS = "UNDEFINED_STATUS",
125
+ APPLICANT = "APPLICANT",
126
+ ACTIVE = "ACTIVE",
127
+ INACTIVE = "INACTIVE",
128
+ BLOCKED = "BLOCKED",
129
+ OFFLINE_ONLY = "OFFLINE_ONLY"
130
+ }
131
+ export interface Address {
132
+ /** member's street address */
133
+ street?: string | null;
134
+ /** member's city */
135
+ city?: string | null;
136
+ /** member's region */
137
+ region?: string | null;
138
+ /** member's country */
139
+ country?: string | null;
140
+ /** member's postal code */
141
+ postalCode?: string | null;
142
+ }
143
+ export interface CustomField extends CustomFieldValueOneOf {
144
+ strValue?: string | null;
145
+ numValue?: number;
146
+ dateValue?: Date;
147
+ name?: string;
148
+ }
149
+ /** @oneof */
150
+ export interface CustomFieldValueOneOf {
151
+ strValue?: string | null;
152
+ numValue?: number;
153
+ dateValue?: Date;
154
+ }
155
+ export interface Group {
156
+ _id?: string;
157
+ name?: string;
158
+ type?: string;
159
+ }
160
+ export interface ListMembersRequest {
161
+ /** for paging - maximum number of records to retrieve */
162
+ limit?: number;
163
+ /** for paging - how many records to skip */
164
+ offset?: number;
165
+ /** sort order - list of field and direction tuples. e.g. `["first_name:asc", "last_name:desc"]` */
166
+ order?: string[];
167
+ /** partial response request - list of field names to get back in response */
168
+ fields?: string[];
169
+ /** filter members with specific status */
170
+ status?: SiteMemberStatus;
171
+ /** whether to include contact details */
172
+ includeContactDetails?: boolean;
173
+ }
174
+ export interface ListMembersResponse {
175
+ /** members returned by List request */
176
+ members?: Member[];
177
+ /** pagination information */
178
+ pagination?: PaginationResponse;
179
+ }
180
+ export interface PaginationResponse {
181
+ /** offset that was applied to the request */
182
+ offset?: number;
183
+ /** limit that was applied to the request */
184
+ limit?: number;
185
+ /** total rows available */
186
+ total?: number;
187
+ /** indication that the total count was too expensive to calculate */
188
+ tooManyToCount?: boolean;
189
+ }
190
+ export interface SearchRequest {
191
+ /** paging - offset and limit */
192
+ paging?: Paging;
193
+ /** search by field */
194
+ searchBy?: SearchBy;
195
+ /** partial response request - list of field names to get back in response */
196
+ fields?: string[];
197
+ /** filters */
198
+ filterBy?: FilterBy;
199
+ /** ASC or DESC order */
200
+ sort?: Sorting;
201
+ }
202
+ export interface Paging {
203
+ /** Number of items to load. */
204
+ limit?: number | null;
205
+ /** Number of items to skip in the current sort order. */
206
+ offset?: number | null;
207
+ }
208
+ export interface SearchBy {
209
+ /** nick name filter */
210
+ nickname?: string | null;
211
+ }
212
+ export interface FilterBy {
213
+ /** filter members with specific status */
214
+ status?: string | null;
215
+ /** group Id filter */
216
+ groupId?: string | null;
217
+ /** privacy status filter */
218
+ privacyStatus?: SiteMemberPrivacyStatus;
219
+ /** roles filter */
220
+ roles?: Role[];
221
+ }
222
+ export declare enum Sorting {
223
+ DESC = "DESC",
224
+ ASC = "ASC"
225
+ }
226
+ export interface SearchResponse {
227
+ /** members returned by List request */
228
+ members?: Member[];
229
+ /** pagination information */
230
+ pagination?: PaginationResponse;
231
+ }
232
+ export interface GetCurrentMemberRequest {
233
+ }
234
+ export interface GetMemberResponse {
235
+ member?: Member;
236
+ }
237
+ export interface GetMemberRequest {
238
+ /** unique identifier of the requested member(required) */
239
+ _id?: string;
240
+ /** whether to include contact details */
241
+ includeContactDetails?: boolean;
242
+ /** whether to include groups details */
243
+ includeGroupsDetails?: boolean;
244
+ }
245
+ export interface GetUserMembershipsRequest {
246
+ /** unique identifier of the requested **Wix** user */
247
+ userId?: string;
248
+ /** paging - offset and limit ( the max limit for page is 200) */
249
+ paging?: Paging;
250
+ }
251
+ export interface GetUserMembershipsResponse {
252
+ /** sequence of member's of the user with there metaSiteId */
253
+ userMemberships?: UserMembership[];
254
+ }
255
+ export interface UserMembership {
256
+ /** member id */
257
+ memberId?: string;
258
+ /** meta site id whom the member existing on */
259
+ metasiteId?: string;
260
+ }
261
+ export interface GetMemberRoleRequest {
262
+ _id?: string;
263
+ }
264
+ export interface GetMemberRoleResponse {
265
+ /**
266
+ * member's role:
267
+ *
268
+ * `OWNER` - member that belongs to site owner
269
+ * `CONTRIBUTOR` - member that belongs to a contributor in site
270
+ * `MEMBER` - other members that registered to site
271
+ */
272
+ role?: Role;
273
+ userId?: string | null;
274
+ status?: SiteMemberStatus;
275
+ contactId?: string | null;
276
+ }
277
+ export interface GetMemberRolesRequest {
278
+ /** user_id and/or contact_id */
279
+ ids?: string[];
280
+ }
281
+ export interface GetMemberRolesResponse {
282
+ idsToRoles?: Record<string, MemberRole>;
283
+ }
284
+ export interface MemberRole {
285
+ /**
286
+ * member's role:
287
+ *
288
+ * `OWNER` - member that belongs to site owner
289
+ * `CONTRIBUTOR` - member that belongs to a contributor in site
290
+ * `MEMBER` - other members that registered to site
291
+ */
292
+ role?: Role;
293
+ userId?: string | null;
294
+ status?: SiteMemberStatus;
295
+ contactId?: string | null;
296
+ }
297
+ export interface BatchGetMembersRequest {
298
+ /** unique identifier of the requested member(required) */
299
+ ids?: string[];
300
+ /** whether to include contact details */
301
+ includeContactDetails?: boolean;
302
+ /** whether to include groups details */
303
+ includeGroupsDetails?: boolean;
304
+ }
305
+ export interface BatchGetMembersResponse {
306
+ /** lest of members details */
307
+ members?: Member[];
308
+ }
309
+ export interface GetAuthorizedPagesRequest {
310
+ _id?: string;
311
+ siteId?: string;
312
+ }
313
+ export interface GetAuthorizedPagesResponse {
314
+ authorizedPages?: Record<string, string>;
315
+ }
316
+ export interface UpdateMemberRequest {
317
+ /** member id */
318
+ _id?: string;
319
+ /** the Member object containing the fields to update */
320
+ member?: Member;
321
+ /**
322
+ * an explicit declaration of contact fields that should be updated by this request.
323
+ * *Currently only affects contact fields.
324
+ */
325
+ fieldMask?: string[];
326
+ }
327
+ export interface UpdateMemberResponse {
328
+ /** updated member */
329
+ member?: Member;
330
+ }
331
+ export interface ChangeLoginEmailRequest {
332
+ /** unique identifier of the requested member(required) */
333
+ _id?: string;
334
+ /** Email to update to */
335
+ newEmail?: string;
336
+ /** Should revoke active sessions straight after changing the member's login email */
337
+ revokeCurrentSessions?: boolean | null;
338
+ }
339
+ export interface ChangeLoginEmailResponse {
340
+ /** Updated member with the new email */
341
+ member?: Member;
342
+ }
343
+ export interface QueryMembersRequest {
344
+ /**
345
+ * query - See https://github.com/wix-private/platformization-guidelines/blob/master/Server/API-Query.md
346
+ * supported fields: `id`, `login_email`, `status`, `language`, `date_created`, `last_update_date`, `flags`, `name`, `first_name`, `last_name`, `nickname`, `email_verified`, `privacy_status`
347
+ */
348
+ query?: string;
349
+ /** whether to include contact details */
350
+ includeContactDetails?: boolean;
351
+ /** whether to include offline members */
352
+ includeOfflineMembers?: boolean;
353
+ }
354
+ export interface QueryMembersResponse {
355
+ /** members matching the query criteria */
356
+ members?: Member[];
357
+ /** pagination information */
358
+ pagination?: PaginationResponse;
359
+ }
360
+ export interface DeleteMemberRequest {
361
+ /** id of member that should be deleted (required) */
362
+ _id?: string;
363
+ /** defines if the request is a bulk action */
364
+ isBulkAction?: boolean;
365
+ }
366
+ export interface DeleteMemberResponse {
367
+ }
368
+ export interface ApproveMemberRequest extends ApproveMemberRequestMemberIdentifierOneOf {
369
+ /** ID of the member to approve. */
370
+ _id?: string;
371
+ /** Login email address of the member to approve. */
372
+ email?: string;
373
+ /**
374
+ * <!--ONLY:VELO
375
+ * Approval token returned by `register()`.
376
+ * <!--END:ONLY:VELO-->
377
+ */
378
+ token?: string;
379
+ }
380
+ /** @oneof */
381
+ export interface ApproveMemberRequestMemberIdentifierOneOf {
382
+ /** ID of the member to approve. */
383
+ _id?: string;
384
+ /** Login email address of the member to approve. */
385
+ email?: string;
386
+ /**
387
+ * <!--ONLY:VELO
388
+ * Approval token returned by `register()`.
389
+ * <!--END:ONLY:VELO-->
390
+ */
391
+ token?: string;
392
+ }
393
+ export interface ApproveMemberResponse {
394
+ session?: Session;
395
+ }
396
+ export interface Session {
397
+ token?: string | null;
398
+ }
399
+ export interface BlockMemberRequest extends BlockMemberRequestMemberIdentifierOneOf {
400
+ _id?: string;
401
+ /** Login email address of the member to block. */
402
+ email?: string;
403
+ /** Indicate the source of the block request */
404
+ source?: Source;
405
+ }
406
+ /** @oneof */
407
+ export interface BlockMemberRequestMemberIdentifierOneOf {
408
+ _id?: string;
409
+ /** Login email address of the member to block. */
410
+ email?: string;
411
+ }
412
+ export declare enum Source {
413
+ UNKNOWN = "UNKNOWN",
414
+ HANDLING_SPAM = "HANDLING_SPAM"
415
+ }
416
+ export interface BlockMemberResponse {
417
+ }
418
+ export interface MakeMemberOfflineRequest {
419
+ /** unique identifier of the requested member */
420
+ _id?: string;
421
+ }
422
+ export interface MakeMemberOfflineResponse {
423
+ }
424
+ /** Registration options. */
425
+ export interface RegisterRequest {
426
+ /** Login email address for the new site member. */
427
+ email?: string;
428
+ /**
429
+ * Password the new site member will use to log in.
430
+ *
431
+ * Must be 4 to 15 ASCII-printable characters.
432
+ */
433
+ password?: string;
434
+ /** Contact information for the registered member. */
435
+ contactInfo?: MemberContactInfo;
436
+ /** identification of the app that initiated the register request */
437
+ dialogData?: DialogData;
438
+ /**
439
+ * Sets the privacy status of a new member upon registration.
440
+ *
441
+ * - `PUBLIC`: Member is visible to everyone.
442
+ * - `PRIVATE`: Member is hidden from site visitors and other site members. Member is returned only to site contributors and apps with the appropriate permissions.
443
+ * - `UNKNOWN`: Insufficient permissions to get the status.
444
+ */
445
+ profilePrivacyStatus?: SiteMemberPrivacyStatus;
446
+ /** is registration offline */
447
+ isOfflineRegistration?: boolean;
448
+ recaptchaToken?: string | null;
449
+ invisibleRecaptchaToken?: string | null;
450
+ emailVerification?: EmailVerification;
451
+ /**
452
+ * an indication that the request needs to follow mobile signup flow
453
+ * difference from the regular flow is the OTP email
454
+ */
455
+ isMobile?: boolean | null;
456
+ }
457
+ export interface MemberContactInfo {
458
+ /** First name. */
459
+ firstName?: string | null;
460
+ /** Last name. */
461
+ lastName?: string | null;
462
+ /** Contact's profile picture. */
463
+ picture?: string | null;
464
+ /** Contact's email addresses. */
465
+ emails?: string[];
466
+ /** Contact's phone numbers. */
467
+ phones?: string[];
468
+ /** List of contact's labels. */
469
+ labels?: string[];
470
+ /**
471
+ * Contact's locale, formatted as an
472
+ * [IETF BCP 47 language tag](https://tools.ietf.org/html/rfc5646).
473
+ * Typically, this is a lowercase 2-letter language code,
474
+ * followed by a hyphen,
475
+ * followed by an uppercase 2-letter country code.
476
+ *
477
+ * For example, German from Germany is formatted as `"de-DE"`,
478
+ * and U.S. English is formatted as `"en-US"`.
479
+ */
480
+ locale?: string | null;
481
+ /**
482
+ * Any number of custom fields.
483
+ * [Custom fields](https://support.wix.com/en/article/adding-custom-fields-to-contacts)
484
+ * are used to store additional information about your site's contacts.
485
+ * When setting a custom field, use key:value pairs,
486
+ * where the key matches the names defined in your site's
487
+ * [Contact List](https://support.wix.com/en/article/accessing-your-contact-list).
488
+ * You can only set values for custom fields that already exist in the Contacts application.
489
+ */
490
+ customFields?: CustomField[];
491
+ }
492
+ export interface DialogData {
493
+ visitorId?: string | null;
494
+ appId?: string | null;
495
+ initiator?: string | null;
496
+ }
497
+ export interface EmailVerification {
498
+ /** Id of the verification process */
499
+ verificationId?: string;
500
+ /** 6-digit code to verify (between 100000 and 999999) */
501
+ otp?: string;
502
+ }
503
+ export interface RegisterResponse {
504
+ /** Newly registered member. */
505
+ member?: Member;
506
+ /**
507
+ * in case the site is open for registration, all members are automatically
508
+ * approved. they will get a temporary token for obtaining a valid session
509
+ */
510
+ session?: Session;
511
+ /**
512
+ * in case the site requires members approval, the registered member
513
+ * will be an applicant until he's approved. the token can be used as a member
514
+ * identifier for approval using the `MembersService.Approve` API
515
+ */
516
+ approvalToken?: string | null;
517
+ }
518
+ export interface EmailVerificationRequired {
519
+ /** Id of the verification process. */
520
+ verificationId?: string;
521
+ }
522
+ export interface EmailVerificationFailed {
523
+ /** Id of the failed verification process. */
524
+ verificationId?: string;
525
+ /** Reason for verification failure. */
526
+ verificationFailureReason?: VerificationFailureReason;
527
+ }
528
+ export declare enum VerificationFailureReason {
529
+ /** Default value - means no failure */
530
+ UNSPECIFIED = "UNSPECIFIED",
531
+ /** Bad verification code */
532
+ BAD_CODE = "BAD_CODE",
533
+ /** Verification code was not found */
534
+ NOT_FOUND = "NOT_FOUND",
535
+ /** Error while sending the code to the user */
536
+ SEND_CODE_ERROR = "SEND_CODE_ERROR"
537
+ }
538
+ export interface LoginRequest {
539
+ /** Email address to use when logging the member in. */
540
+ email?: string;
541
+ /** Password to use when logging the member in. */
542
+ password?: string;
543
+ /** recaptcha token */
544
+ recaptchaToken?: string;
545
+ /** invisible recaptcha token */
546
+ invisibleRecaptchaToken?: string;
547
+ emailVerification?: EmailVerification;
548
+ /**
549
+ * an indication that the request needs to follow mobile login flow
550
+ * difference from the regular flow is the OTP email
551
+ */
552
+ isMobile?: boolean | null;
553
+ }
554
+ /** Session token for logging the member in. */
555
+ export interface LoginResponse {
556
+ session?: Session;
557
+ /** the member's details */
558
+ member?: Member;
559
+ }
560
+ export interface GetResetPasswordLinkRequest {
561
+ /** Contact ID of the member whose password will be reset. */
562
+ contactId?: string;
563
+ }
564
+ export interface GetResetPasswordLinkResponse {
565
+ /**
566
+ * Reset password link.
567
+ * Valid for one use, up to two weeks from when it is created.
568
+ */
569
+ resetPasswordLink?: string;
570
+ }
571
+ export interface SendSetPasswordEmailRequest {
572
+ /** Login email of the member whose password will be set. */
573
+ email: string;
574
+ /**
575
+ * > **Deprecated:**
576
+ * > This field has been replaced with
577
+ * > `hideIgnoreMessage`
578
+ * > and will be removed on June 30, 2022.
579
+ * > If your app uses this field,
580
+ * > we recommend updating your code as soon as possible.
581
+ *
582
+ * Whether the email is being sent by member request.
583
+ *
584
+ * If `true`, the email tells the member
585
+ * they can safely ignore
586
+ * if they did not request the password change.
587
+ *
588
+ * Defaults to `false`.
589
+ */
590
+ requestedByMember?: boolean;
591
+ /**
592
+ * Whether to hide the ignore this email message .
593
+ *
594
+ * If `true`, the email tells the member
595
+ * they can safely ignore
596
+ * if they did not request the password change.
597
+ *
598
+ * Defaults to `false`.
599
+ */
600
+ hideIgnoreMessage?: boolean;
601
+ }
602
+ export interface SendSetPasswordEmailResponse {
603
+ /** Indicates if the request was successfully received. */
604
+ accepted?: boolean;
605
+ }
606
+ export interface ResetPasswordRequest {
607
+ /** Contact ID of the member whose password will be reset. */
608
+ contactId?: string;
609
+ }
610
+ export interface ResetPasswordResponse {
611
+ /** Indicates if the request was successfully received. */
612
+ accepted?: boolean;
613
+ }
614
+ export interface SocialLoginRequest extends SocialLoginRequestLoginOneOf {
615
+ appleLogin?: AppleLogin;
616
+ googleLogin?: GoogleLogin;
617
+ facebookLogin?: FacebookLogin;
618
+ /** Must either pass explicit msid OR signed instance with visitor */
619
+ metaSiteId?: string | null;
620
+ }
621
+ /** @oneof */
622
+ export interface SocialLoginRequestLoginOneOf {
623
+ appleLogin?: AppleLogin;
624
+ googleLogin?: GoogleLogin;
625
+ facebookLogin?: FacebookLogin;
626
+ }
627
+ export interface AppleLogin {
628
+ /** JWT signed by apple, contains target (aud), email etc */
629
+ token?: string;
630
+ }
631
+ export interface GoogleLogin {
632
+ /** JWT signed by Google, contains target (aud), email etc */
633
+ token?: string;
634
+ }
635
+ export interface FacebookLogin {
636
+ /** AccessToken created by Facebook, used to later fetch details over API */
637
+ token?: string;
638
+ }
639
+ /**
640
+ * Sends a site member an email with a link to set their password.
641
+ *
642
+ * The set password link is valid for 3 hours,
643
+ * and it can be used only once.
644
+ * If the link expires, the original password remains.
645
+ * @param email - Login email of the member whose password will be set.
646
+ * @public
647
+ * @documentationMaturity preview
648
+ * @requiredField email
649
+ * @permissionScope Manage Members
650
+ * @applicableIdentity APP
651
+ * @applicableIdentity VISITOR
652
+ */
653
+ export declare function sendSetPasswordEmail(email: string, options?: SendSetPasswordEmailOptions): Promise<SendSetPasswordEmailResponse>;
654
+ export interface SendSetPasswordEmailOptions {
655
+ /**
656
+ * > **Deprecated:**
657
+ * > This field has been replaced with
658
+ * > `hideIgnoreMessage`
659
+ * > and will be removed on June 30, 2022.
660
+ * > If your app uses this field,
661
+ * > we recommend updating your code as soon as possible.
662
+ *
663
+ * Whether the email is being sent by member request.
664
+ *
665
+ * If `true`, the email tells the member
666
+ * they can safely ignore
667
+ * if they did not request the password change.
668
+ *
669
+ * Defaults to `false`.
670
+ */
671
+ requestedByMember?: boolean;
672
+ /**
673
+ * Whether to hide the ignore this email message .
674
+ *
675
+ * If `true`, the email tells the member
676
+ * they can safely ignore
677
+ * if they did not request the password change.
678
+ *
679
+ * Defaults to `false`.
680
+ */
681
+ hideIgnoreMessage?: boolean;
682
+ }