@wix/referral 1.0.6 → 1.0.7
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/package.json +8 -8
- package/type-bundles/context.bundle.d.ts +2344 -711
- package/type-bundles/index.bundle.d.ts +284 -771
- package/type-bundles/meta.bundle.d.ts +418 -992
|
@@ -20,9 +20,9 @@ interface ReferralProgram {
|
|
|
20
20
|
*/
|
|
21
21
|
_updatedDate?: Date;
|
|
22
22
|
/** Referred friend reward configuration. */
|
|
23
|
-
referredFriendReward?: Reward$
|
|
23
|
+
referredFriendReward?: Reward$2;
|
|
24
24
|
/** Referring customer reward configuration. */
|
|
25
|
-
referringCustomerReward?: Reward$
|
|
25
|
+
referringCustomerReward?: Reward$2;
|
|
26
26
|
/** List of actions that complete referral. */
|
|
27
27
|
successfulReferralActions?: Action[];
|
|
28
28
|
/**
|
|
@@ -30,7 +30,7 @@ interface ReferralProgram {
|
|
|
30
30
|
* @readonly
|
|
31
31
|
* @deprecated Set to true if user has required plan to activate program.
|
|
32
32
|
* @replacedBy GetReferralProgramPremiumFeatures
|
|
33
|
-
* @
|
|
33
|
+
* @targetRemovalDate 2024-09-01
|
|
34
34
|
*/
|
|
35
35
|
isPremium?: boolean;
|
|
36
36
|
/** Emails configuration. */
|
|
@@ -46,22 +46,22 @@ declare enum ProgramStatus {
|
|
|
46
46
|
/** program was manually disabled by the user (this action can be reverted, meaning user can set it to be active again). */
|
|
47
47
|
PAUSED = "PAUSED"
|
|
48
48
|
}
|
|
49
|
-
interface Reward$
|
|
49
|
+
interface Reward$2 extends RewardOptionsOneOf$1 {
|
|
50
50
|
/** Options for coupon reward type. */
|
|
51
51
|
couponOptions?: Coupon$2;
|
|
52
52
|
/** Options for Loyalty points reward type. */
|
|
53
|
-
loyaltyPointsOptions?: LoyaltyPoints$
|
|
53
|
+
loyaltyPointsOptions?: LoyaltyPoints$2;
|
|
54
54
|
/** Type of the reward. */
|
|
55
|
-
type?: Type;
|
|
55
|
+
type?: Type$1;
|
|
56
56
|
}
|
|
57
57
|
/** @oneof */
|
|
58
|
-
interface RewardOptionsOneOf {
|
|
58
|
+
interface RewardOptionsOneOf$1 {
|
|
59
59
|
/** Options for coupon reward type. */
|
|
60
60
|
couponOptions?: Coupon$2;
|
|
61
61
|
/** Options for Loyalty points reward type. */
|
|
62
|
-
loyaltyPointsOptions?: LoyaltyPoints$
|
|
62
|
+
loyaltyPointsOptions?: LoyaltyPoints$2;
|
|
63
63
|
}
|
|
64
|
-
declare enum Type {
|
|
64
|
+
declare enum Type$1 {
|
|
65
65
|
/** Unknown reward type. */
|
|
66
66
|
UNKNOWN = "UNKNOWN",
|
|
67
67
|
/** Coupon reward type. */
|
|
@@ -135,7 +135,7 @@ interface Group$2 {
|
|
|
135
135
|
/** Entity ID of the group. */
|
|
136
136
|
entityId?: string | null;
|
|
137
137
|
}
|
|
138
|
-
interface LoyaltyPoints$
|
|
138
|
+
interface LoyaltyPoints$2 {
|
|
139
139
|
/** Amount of points to give. */
|
|
140
140
|
amount?: number;
|
|
141
141
|
}
|
|
@@ -173,28 +173,127 @@ declare enum App {
|
|
|
173
173
|
/** Wix restaurants. */
|
|
174
174
|
RESTAURANTS = "RESTAURANTS"
|
|
175
175
|
}
|
|
176
|
+
interface GetReferralProgramRequest {
|
|
177
|
+
}
|
|
176
178
|
interface GetReferralProgramResponse {
|
|
177
179
|
/** The retrieved ReferralProgram. */
|
|
178
180
|
referralProgram?: ReferralProgram;
|
|
179
181
|
}
|
|
182
|
+
interface BulkGetReferralProgramRequest {
|
|
183
|
+
}
|
|
184
|
+
interface BulkGetReferralProgramResponse {
|
|
185
|
+
/** Referral programs. */
|
|
186
|
+
programInSites?: ProgramInSite[];
|
|
187
|
+
}
|
|
188
|
+
interface ProgramInSite {
|
|
189
|
+
/** Metasite ID. */
|
|
190
|
+
metaSiteId?: string;
|
|
191
|
+
/** Referral program. */
|
|
192
|
+
referralProgram?: ReferralProgram;
|
|
193
|
+
}
|
|
194
|
+
interface QueryReferralProgramsRequest {
|
|
195
|
+
/** Query to filter ReferralPrograms. */
|
|
196
|
+
query: CursorQuery$4;
|
|
197
|
+
}
|
|
198
|
+
interface CursorQuery$4 extends CursorQueryPagingMethodOneOf$4 {
|
|
199
|
+
/**
|
|
200
|
+
* Cursor paging options.
|
|
201
|
+
*
|
|
202
|
+
* Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging).
|
|
203
|
+
*/
|
|
204
|
+
cursorPaging?: CursorPaging$4;
|
|
205
|
+
/**
|
|
206
|
+
* Filter object.
|
|
207
|
+
*
|
|
208
|
+
* Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section).
|
|
209
|
+
*/
|
|
210
|
+
filter?: Record<string, any> | null;
|
|
211
|
+
/**
|
|
212
|
+
* Sort object.
|
|
213
|
+
*
|
|
214
|
+
* Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section).
|
|
215
|
+
*/
|
|
216
|
+
sort?: Sorting$4[];
|
|
217
|
+
}
|
|
218
|
+
/** @oneof */
|
|
219
|
+
interface CursorQueryPagingMethodOneOf$4 {
|
|
220
|
+
/**
|
|
221
|
+
* Cursor paging options.
|
|
222
|
+
*
|
|
223
|
+
* Learn more about [cursor paging](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#cursor-paging).
|
|
224
|
+
*/
|
|
225
|
+
cursorPaging?: CursorPaging$4;
|
|
226
|
+
}
|
|
227
|
+
interface Sorting$4 {
|
|
228
|
+
/** Name of the field to sort by. */
|
|
229
|
+
fieldName?: string;
|
|
230
|
+
/** Sort order. */
|
|
231
|
+
order?: SortOrder$4;
|
|
232
|
+
}
|
|
233
|
+
declare enum SortOrder$4 {
|
|
234
|
+
ASC = "ASC",
|
|
235
|
+
DESC = "DESC"
|
|
236
|
+
}
|
|
237
|
+
interface CursorPaging$4 {
|
|
238
|
+
/** Maximum number of items to return in the results. */
|
|
239
|
+
limit?: number | null;
|
|
240
|
+
/**
|
|
241
|
+
* Pointer to the next or previous page in the list of results.
|
|
242
|
+
*
|
|
243
|
+
* Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
|
|
244
|
+
* Not relevant for the first request.
|
|
245
|
+
*/
|
|
246
|
+
cursor?: string | null;
|
|
247
|
+
}
|
|
248
|
+
interface QueryReferralProgramsResponse {
|
|
249
|
+
/** ReferralPrograms that match the query. */
|
|
250
|
+
referralPrograms?: ReferralProgram[];
|
|
251
|
+
/** Paging metadata. */
|
|
252
|
+
pagingMetadata?: CursorPagingMetadata$4;
|
|
253
|
+
}
|
|
254
|
+
interface CursorPagingMetadata$4 {
|
|
255
|
+
/** Number of items returned in the response. */
|
|
256
|
+
count?: number | null;
|
|
257
|
+
/** Cursor strings that point to the next page, previous page, or both. */
|
|
258
|
+
cursors?: Cursors$4;
|
|
259
|
+
/**
|
|
260
|
+
* Whether there are more pages to retrieve following the current page.
|
|
261
|
+
*
|
|
262
|
+
* + `true`: Another page of results can be retrieved.
|
|
263
|
+
* + `false`: This is the last page.
|
|
264
|
+
*/
|
|
265
|
+
hasNext?: boolean | null;
|
|
266
|
+
}
|
|
180
267
|
interface Cursors$4 {
|
|
181
268
|
/** Cursor string pointing to the next page in the list of results. */
|
|
182
269
|
next?: string | null;
|
|
183
270
|
/** Cursor pointing to the previous page in the list of results. */
|
|
184
271
|
prev?: string | null;
|
|
185
272
|
}
|
|
273
|
+
interface UpdateReferralProgramRequest {
|
|
274
|
+
/** ReferralProgram to be updated, may be partial. */
|
|
275
|
+
referralProgram: ReferralProgram;
|
|
276
|
+
}
|
|
186
277
|
interface UpdateReferralProgramResponse {
|
|
187
278
|
/** The updated ReferralProgram. */
|
|
188
279
|
referralProgram?: ReferralProgram;
|
|
189
280
|
}
|
|
281
|
+
interface ActivateReferralProgramRequest {
|
|
282
|
+
}
|
|
190
283
|
interface ActivateReferralProgramResponse {
|
|
191
284
|
/** The activated ReferralProgram. */
|
|
192
285
|
referralProgram?: ReferralProgram;
|
|
193
286
|
}
|
|
287
|
+
interface PauseReferralProgramRequest {
|
|
288
|
+
}
|
|
194
289
|
interface PauseReferralProgramResponse {
|
|
195
290
|
/** The paused ReferralProgram. */
|
|
196
291
|
referralProgram?: ReferralProgram;
|
|
197
292
|
}
|
|
293
|
+
interface GetAISocialMediaPostsSuggestionsRequest {
|
|
294
|
+
/** The topic to generate suggestions for. */
|
|
295
|
+
topic?: string;
|
|
296
|
+
}
|
|
198
297
|
interface GetAISocialMediaPostsSuggestionsResponse {
|
|
199
298
|
/** The generated suggestions. */
|
|
200
299
|
suggestions?: AISocialMediaPostSuggestion[];
|
|
@@ -207,12 +306,18 @@ interface AISocialMediaPostSuggestion {
|
|
|
207
306
|
/** The suggested hashtags. */
|
|
208
307
|
hashtags?: string[];
|
|
209
308
|
}
|
|
309
|
+
interface GenerateAISocialMediaPostsSuggestionsRequest {
|
|
310
|
+
/** The topic to generate suggestions for. */
|
|
311
|
+
topic?: string;
|
|
312
|
+
}
|
|
210
313
|
interface GenerateAISocialMediaPostsSuggestionsResponse {
|
|
211
314
|
/** The generated suggestions. */
|
|
212
315
|
suggestions?: AISocialMediaPostSuggestion[];
|
|
213
316
|
/** The refer friends page URL. */
|
|
214
317
|
referFriendsPageUrl?: string | null;
|
|
215
318
|
}
|
|
319
|
+
interface GetReferralProgramPremiumFeaturesRequest {
|
|
320
|
+
}
|
|
216
321
|
interface GetReferralProgramPremiumFeaturesResponse {
|
|
217
322
|
/**
|
|
218
323
|
* Set to true if user has referral program feature.
|
|
@@ -220,7 +325,915 @@ interface GetReferralProgramPremiumFeaturesResponse {
|
|
|
220
325
|
*/
|
|
221
326
|
referralProgram?: boolean;
|
|
222
327
|
}
|
|
223
|
-
interface
|
|
328
|
+
interface DomainEvent$4 extends DomainEventBodyOneOf$4 {
|
|
329
|
+
createdEvent?: EntityCreatedEvent$4;
|
|
330
|
+
updatedEvent?: EntityUpdatedEvent$4;
|
|
331
|
+
deletedEvent?: EntityDeletedEvent$4;
|
|
332
|
+
actionEvent?: ActionEvent$4;
|
|
333
|
+
/**
|
|
334
|
+
* Unique event ID.
|
|
335
|
+
* Allows clients to ignore duplicate webhooks.
|
|
336
|
+
*/
|
|
337
|
+
_id?: string;
|
|
338
|
+
/**
|
|
339
|
+
* Assumes actions are also always typed to an entity_type
|
|
340
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
341
|
+
*/
|
|
342
|
+
entityFqdn?: string;
|
|
343
|
+
/**
|
|
344
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
345
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
346
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
347
|
+
*/
|
|
348
|
+
slug?: string;
|
|
349
|
+
/** ID of the entity associated with the event. */
|
|
350
|
+
entityId?: string;
|
|
351
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */
|
|
352
|
+
eventTime?: Date;
|
|
353
|
+
/**
|
|
354
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
355
|
+
* (for example, GDPR).
|
|
356
|
+
*/
|
|
357
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
358
|
+
/** If present, indicates the action that triggered the event. */
|
|
359
|
+
originatedFrom?: string | null;
|
|
360
|
+
/**
|
|
361
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
362
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
363
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
364
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
365
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
366
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
367
|
+
*/
|
|
368
|
+
entityEventSequence?: string | null;
|
|
369
|
+
}
|
|
370
|
+
/** @oneof */
|
|
371
|
+
interface DomainEventBodyOneOf$4 {
|
|
372
|
+
createdEvent?: EntityCreatedEvent$4;
|
|
373
|
+
updatedEvent?: EntityUpdatedEvent$4;
|
|
374
|
+
deletedEvent?: EntityDeletedEvent$4;
|
|
375
|
+
actionEvent?: ActionEvent$4;
|
|
376
|
+
}
|
|
377
|
+
interface EntityCreatedEvent$4 {
|
|
378
|
+
entity?: string;
|
|
379
|
+
}
|
|
380
|
+
interface RestoreInfo {
|
|
381
|
+
deletedDate?: Date;
|
|
382
|
+
}
|
|
383
|
+
interface EntityUpdatedEvent$4 {
|
|
384
|
+
/**
|
|
385
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
386
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
387
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
388
|
+
*/
|
|
389
|
+
currentEntity?: string;
|
|
390
|
+
}
|
|
391
|
+
interface EntityDeletedEvent$4 {
|
|
392
|
+
/** Entity that was deleted */
|
|
393
|
+
deletedEntity?: string | null;
|
|
394
|
+
}
|
|
395
|
+
interface ActionEvent$4 {
|
|
396
|
+
body?: string;
|
|
397
|
+
}
|
|
398
|
+
interface Empty$3 {
|
|
399
|
+
}
|
|
400
|
+
interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf {
|
|
401
|
+
/** Emitted on a meta site creation. */
|
|
402
|
+
siteCreated?: SiteCreated;
|
|
403
|
+
/** Emitted on a meta site transfer completion. */
|
|
404
|
+
siteTransferred?: SiteTransferred;
|
|
405
|
+
/** Emitted on a meta site deletion. */
|
|
406
|
+
siteDeleted?: SiteDeleted;
|
|
407
|
+
/** Emitted on a meta site restoration. */
|
|
408
|
+
siteUndeleted?: SiteUndeleted;
|
|
409
|
+
/** Emitted on the first* publish of the meta site (* switching from unpublished to published state). */
|
|
410
|
+
sitePublished?: SitePublished;
|
|
411
|
+
/** Emitted on a meta site unpublish. */
|
|
412
|
+
siteUnpublished?: SiteUnpublished;
|
|
413
|
+
/** Emitted when meta site is marked as template. */
|
|
414
|
+
siteMarkedAsTemplate?: SiteMarkedAsTemplate;
|
|
415
|
+
/** Emitted when meta site is marked as a WixSite. */
|
|
416
|
+
siteMarkedAsWixSite?: SiteMarkedAsWixSite;
|
|
417
|
+
/** Emitted when an application is provisioned (installed). */
|
|
418
|
+
serviceProvisioned?: ServiceProvisioned;
|
|
419
|
+
/** Emitted when an application is removed (uninstalled). */
|
|
420
|
+
serviceRemoved?: ServiceRemoved;
|
|
421
|
+
/** Emitted when meta site name (URL slug) is changed. */
|
|
422
|
+
siteRenamedPayload?: SiteRenamed;
|
|
423
|
+
/** Emitted when meta site was permanently deleted. */
|
|
424
|
+
hardDeleted?: SiteHardDeleted;
|
|
425
|
+
/** Emitted on a namespace change. */
|
|
426
|
+
namespaceChanged?: NamespaceChanged;
|
|
427
|
+
/** Emitted when Studio is attached. */
|
|
428
|
+
studioAssigned?: StudioAssigned;
|
|
429
|
+
/** Emitted when Studio is detached. */
|
|
430
|
+
studioUnassigned?: StudioUnassigned;
|
|
431
|
+
/** A meta site id. */
|
|
432
|
+
metaSiteId?: string;
|
|
433
|
+
/** A meta site version. Monotonically increasing. */
|
|
434
|
+
version?: string;
|
|
435
|
+
/** A timestamp of the event. */
|
|
436
|
+
timestamp?: string;
|
|
437
|
+
/** A list of "assets" (applications). The same as MetaSiteContext. */
|
|
438
|
+
assets?: Asset[];
|
|
439
|
+
}
|
|
440
|
+
/** @oneof */
|
|
441
|
+
interface MetaSiteSpecialEventPayloadOneOf {
|
|
442
|
+
/** Emitted on a meta site creation. */
|
|
443
|
+
siteCreated?: SiteCreated;
|
|
444
|
+
/** Emitted on a meta site transfer completion. */
|
|
445
|
+
siteTransferred?: SiteTransferred;
|
|
446
|
+
/** Emitted on a meta site deletion. */
|
|
447
|
+
siteDeleted?: SiteDeleted;
|
|
448
|
+
/** Emitted on a meta site restoration. */
|
|
449
|
+
siteUndeleted?: SiteUndeleted;
|
|
450
|
+
/** Emitted on the first* publish of the meta site (* switching from unpublished to published state). */
|
|
451
|
+
sitePublished?: SitePublished;
|
|
452
|
+
/** Emitted on a meta site unpublish. */
|
|
453
|
+
siteUnpublished?: SiteUnpublished;
|
|
454
|
+
/** Emitted when meta site is marked as template. */
|
|
455
|
+
siteMarkedAsTemplate?: SiteMarkedAsTemplate;
|
|
456
|
+
/** Emitted when meta site is marked as a WixSite. */
|
|
457
|
+
siteMarkedAsWixSite?: SiteMarkedAsWixSite;
|
|
458
|
+
/** Emitted when an application is provisioned (installed). */
|
|
459
|
+
serviceProvisioned?: ServiceProvisioned;
|
|
460
|
+
/** Emitted when an application is removed (uninstalled). */
|
|
461
|
+
serviceRemoved?: ServiceRemoved;
|
|
462
|
+
/** Emitted when meta site name (URL slug) is changed. */
|
|
463
|
+
siteRenamedPayload?: SiteRenamed;
|
|
464
|
+
/** Emitted when meta site was permanently deleted. */
|
|
465
|
+
hardDeleted?: SiteHardDeleted;
|
|
466
|
+
/** Emitted on a namespace change. */
|
|
467
|
+
namespaceChanged?: NamespaceChanged;
|
|
468
|
+
/** Emitted when Studio is attached. */
|
|
469
|
+
studioAssigned?: StudioAssigned;
|
|
470
|
+
/** Emitted when Studio is detached. */
|
|
471
|
+
studioUnassigned?: StudioUnassigned;
|
|
472
|
+
}
|
|
473
|
+
interface Asset {
|
|
474
|
+
/** An application definition id (app_id in dev-center). For legacy reasons may be UUID or a string (from Java Enum). */
|
|
475
|
+
appDefId?: string;
|
|
476
|
+
/** An instance id. For legacy reasons may be UUID or a string. */
|
|
477
|
+
instanceId?: string;
|
|
478
|
+
/** An application state. */
|
|
479
|
+
state?: State;
|
|
480
|
+
}
|
|
481
|
+
declare enum State {
|
|
482
|
+
UNKNOWN = "UNKNOWN",
|
|
483
|
+
ENABLED = "ENABLED",
|
|
484
|
+
DISABLED = "DISABLED",
|
|
485
|
+
PENDING = "PENDING",
|
|
486
|
+
DEMO = "DEMO"
|
|
487
|
+
}
|
|
488
|
+
interface SiteCreated {
|
|
489
|
+
/** A template identifier (empty if not created from a template). */
|
|
490
|
+
originTemplateId?: string;
|
|
491
|
+
/** An account id of the owner. */
|
|
492
|
+
ownerId?: string;
|
|
493
|
+
/** A context in which meta site was created. */
|
|
494
|
+
context?: SiteCreatedContext;
|
|
495
|
+
/**
|
|
496
|
+
* A meta site id from which this site was created.
|
|
497
|
+
*
|
|
498
|
+
* In case of a creation from a template it's a template id.
|
|
499
|
+
* In case of a site duplication ("Save As" in dashboard or duplicate in UM) it's an id of a source site.
|
|
500
|
+
*/
|
|
501
|
+
originMetaSiteId?: string | null;
|
|
502
|
+
/** A meta site name (URL slug). */
|
|
503
|
+
siteName?: string;
|
|
504
|
+
/** A namespace. */
|
|
505
|
+
namespace?: Namespace;
|
|
506
|
+
}
|
|
507
|
+
declare enum SiteCreatedContext {
|
|
508
|
+
/** A valid option, we don't expose all reasons why site might be created. */
|
|
509
|
+
OTHER = "OTHER",
|
|
510
|
+
/** A meta site was created from template. */
|
|
511
|
+
FROM_TEMPLATE = "FROM_TEMPLATE",
|
|
512
|
+
/** A meta site was created by copying of the transfferred meta site. */
|
|
513
|
+
DUPLICATE_BY_SITE_TRANSFER = "DUPLICATE_BY_SITE_TRANSFER",
|
|
514
|
+
/** A copy of existing meta site. */
|
|
515
|
+
DUPLICATE = "DUPLICATE",
|
|
516
|
+
/** A meta site was created as a transfferred site (copy of the original), old flow, should die soon. */
|
|
517
|
+
OLD_SITE_TRANSFER = "OLD_SITE_TRANSFER",
|
|
518
|
+
/** deprecated A meta site was created for Flash editor. */
|
|
519
|
+
FLASH = "FLASH"
|
|
520
|
+
}
|
|
521
|
+
declare enum Namespace {
|
|
522
|
+
UNKNOWN_NAMESPACE = "UNKNOWN_NAMESPACE",
|
|
523
|
+
/** Default namespace for UGC sites. MetaSites with this namespace will be shown in a user's site list by default. */
|
|
524
|
+
WIX = "WIX",
|
|
525
|
+
/** ShoutOut stand alone product. These are siteless (no actual Wix site, no HtmlWeb). MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
526
|
+
SHOUT_OUT = "SHOUT_OUT",
|
|
527
|
+
/** MetaSites created by the Albums product, they appear as part of the Albums app. MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
528
|
+
ALBUMS = "ALBUMS",
|
|
529
|
+
/** Part of the WixStores migration flow, a user tries to migrate and gets this site to view and if the user likes it then stores removes this namespace and deletes the old site with the old stores. MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
530
|
+
WIX_STORES_TEST_DRIVE = "WIX_STORES_TEST_DRIVE",
|
|
531
|
+
/** Hotels standalone (siteless). MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
532
|
+
HOTELS = "HOTELS",
|
|
533
|
+
/** Clubs siteless MetaSites, a club without a wix website. MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
534
|
+
CLUBS = "CLUBS",
|
|
535
|
+
/** A partially created ADI website. MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
536
|
+
ONBOARDING_DRAFT = "ONBOARDING_DRAFT",
|
|
537
|
+
/** AppBuilder for AppStudio / shmite (c). MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
538
|
+
DEV_SITE = "DEV_SITE",
|
|
539
|
+
/** LogoMaker websites offered to the user after logo purchase. MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
540
|
+
LOGOS = "LOGOS",
|
|
541
|
+
/** VideoMaker websites offered to the user after video purchase. MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
542
|
+
VIDEO_MAKER = "VIDEO_MAKER",
|
|
543
|
+
/** MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
544
|
+
PARTNER_DASHBOARD = "PARTNER_DASHBOARD",
|
|
545
|
+
/** MetaSites with this namespace will *not* be shown in a user's site list by default. */
|
|
546
|
+
DEV_CENTER_COMPANY = "DEV_CENTER_COMPANY",
|
|
547
|
+
/**
|
|
548
|
+
* A draft created by HTML editor on open. Upon "first save" it will be moved to be of WIX domain.
|
|
549
|
+
*
|
|
550
|
+
* Meta site with this namespace will *not* be shown in a user's site list by default.
|
|
551
|
+
*/
|
|
552
|
+
HTML_DRAFT = "HTML_DRAFT",
|
|
553
|
+
/**
|
|
554
|
+
* the user-journey for Fitness users who want to start from managing their business instead of designing their website.
|
|
555
|
+
* Will be accessible from Site List and will not have a website app.
|
|
556
|
+
* Once the user attaches a site, the site will become a regular wixsite.
|
|
557
|
+
*/
|
|
558
|
+
SITELESS_BUSINESS = "SITELESS_BUSINESS",
|
|
559
|
+
/** Belongs to "strategic products" company. Supports new product in the creator's economy space. */
|
|
560
|
+
CREATOR_ECONOMY = "CREATOR_ECONOMY",
|
|
561
|
+
/** It is to be used in the Business First efforts. */
|
|
562
|
+
DASHBOARD_FIRST = "DASHBOARD_FIRST",
|
|
563
|
+
/** Bookings business flow with no site. */
|
|
564
|
+
ANYWHERE = "ANYWHERE",
|
|
565
|
+
/** Namespace for Headless Backoffice with no editor */
|
|
566
|
+
HEADLESS = "HEADLESS",
|
|
567
|
+
/**
|
|
568
|
+
* Namespace for master site that will exist in parent account that will be referenced by subaccounts
|
|
569
|
+
* The site will be used for account level CSM feature for enterprise
|
|
570
|
+
*/
|
|
571
|
+
ACCOUNT_MASTER_CMS = "ACCOUNT_MASTER_CMS",
|
|
572
|
+
/** Rise.ai Siteless account management for Gift Cards and Store Credit. */
|
|
573
|
+
RISE = "RISE",
|
|
574
|
+
/**
|
|
575
|
+
* As part of the branded app new funnel, users now can create a meta site that will be branded app first.
|
|
576
|
+
* There's a blank site behind the scene but it's blank).
|
|
577
|
+
* The Mobile company will be the owner of this namespace.
|
|
578
|
+
*/
|
|
579
|
+
BRANDED_FIRST = "BRANDED_FIRST",
|
|
580
|
+
/** Nownia.com Siteless account management for Ai Scheduling Assistant. */
|
|
581
|
+
NOWNIA = "NOWNIA"
|
|
582
|
+
}
|
|
583
|
+
/** Site transferred to another user. */
|
|
584
|
+
interface SiteTransferred {
|
|
585
|
+
/** A previous owner id (user that transfers meta site). */
|
|
586
|
+
oldOwnerId?: string;
|
|
587
|
+
/** A new owner id (user that accepts meta site). */
|
|
588
|
+
newOwnerId?: string;
|
|
589
|
+
}
|
|
590
|
+
/** Soft deletion of the meta site. Could be restored. */
|
|
591
|
+
interface SiteDeleted {
|
|
592
|
+
/** A deletion context. */
|
|
593
|
+
deleteContext?: DeleteContext;
|
|
594
|
+
}
|
|
595
|
+
interface DeleteContext {
|
|
596
|
+
/** When the meta site was deleted. */
|
|
597
|
+
dateDeleted?: Date;
|
|
598
|
+
/** A status. */
|
|
599
|
+
deleteStatus?: DeleteStatus;
|
|
600
|
+
/** A reason (flow). */
|
|
601
|
+
deleteOrigin?: string;
|
|
602
|
+
/** A service that deleted it. */
|
|
603
|
+
initiatorId?: string | null;
|
|
604
|
+
}
|
|
605
|
+
declare enum DeleteStatus {
|
|
606
|
+
UNKNOWN = "UNKNOWN",
|
|
607
|
+
TRASH = "TRASH",
|
|
608
|
+
DELETED = "DELETED",
|
|
609
|
+
PENDING_PURGE = "PENDING_PURGE"
|
|
610
|
+
}
|
|
611
|
+
/** Restoration of the meta site. */
|
|
612
|
+
interface SiteUndeleted {
|
|
613
|
+
}
|
|
614
|
+
/** First publish of a meta site. Or subsequent publish after unpublish. */
|
|
615
|
+
interface SitePublished {
|
|
616
|
+
}
|
|
617
|
+
interface SiteUnpublished {
|
|
618
|
+
/** A list of URLs previously associated with the meta site. */
|
|
619
|
+
urls?: string[];
|
|
620
|
+
}
|
|
621
|
+
interface SiteMarkedAsTemplate {
|
|
622
|
+
}
|
|
623
|
+
interface SiteMarkedAsWixSite {
|
|
624
|
+
}
|
|
625
|
+
interface ServiceProvisioned {
|
|
626
|
+
/** Either UUID or EmbeddedServiceType. */
|
|
627
|
+
appDefId?: string;
|
|
628
|
+
/** Not only UUID. Something here could be something weird. */
|
|
629
|
+
instanceId?: string;
|
|
630
|
+
/** An instance id from which this instance is originated. */
|
|
631
|
+
originInstanceId?: string;
|
|
632
|
+
/** A version. */
|
|
633
|
+
version?: string | null;
|
|
634
|
+
}
|
|
635
|
+
interface ServiceRemoved {
|
|
636
|
+
/** Either UUID or EmbeddedServiceType. */
|
|
637
|
+
appDefId?: string;
|
|
638
|
+
/** Not only UUID. Something here could be something weird. */
|
|
639
|
+
instanceId?: string;
|
|
640
|
+
/** A version. */
|
|
641
|
+
version?: string | null;
|
|
642
|
+
}
|
|
643
|
+
/** Rename of the site. Meaning, free public url has been changed as well. */
|
|
644
|
+
interface SiteRenamed {
|
|
645
|
+
/** A new meta site name (URL slug). */
|
|
646
|
+
newSiteName?: string;
|
|
647
|
+
/** A previous meta site name (URL slug). */
|
|
648
|
+
oldSiteName?: string;
|
|
649
|
+
}
|
|
650
|
+
/**
|
|
651
|
+
* Hard deletion of the meta site.
|
|
652
|
+
*
|
|
653
|
+
* Could not be restored. Therefore it's desirable to cleanup data.
|
|
654
|
+
*/
|
|
655
|
+
interface SiteHardDeleted {
|
|
656
|
+
/** A deletion context. */
|
|
657
|
+
deleteContext?: DeleteContext;
|
|
658
|
+
}
|
|
659
|
+
interface NamespaceChanged {
|
|
660
|
+
/** A previous namespace. */
|
|
661
|
+
oldNamespace?: Namespace;
|
|
662
|
+
/** A new namespace. */
|
|
663
|
+
newNamespace?: Namespace;
|
|
664
|
+
}
|
|
665
|
+
/** Assigned Studio editor */
|
|
666
|
+
interface StudioAssigned {
|
|
667
|
+
}
|
|
668
|
+
/** Unassigned Studio editor */
|
|
669
|
+
interface StudioUnassigned {
|
|
670
|
+
}
|
|
671
|
+
interface HtmlSitePublished {
|
|
672
|
+
/** Application instance ID */
|
|
673
|
+
appInstanceId?: string;
|
|
674
|
+
/** Application type */
|
|
675
|
+
appType?: string;
|
|
676
|
+
/** Revision */
|
|
677
|
+
revision?: string;
|
|
678
|
+
/** MSID */
|
|
679
|
+
metaSiteId?: string | null;
|
|
680
|
+
/** optional branch id if publish is done from branch */
|
|
681
|
+
branchId?: string | null;
|
|
682
|
+
/** The site's last transactionId */
|
|
683
|
+
lastTransactionId?: string | null;
|
|
684
|
+
/** A list of the site's pages */
|
|
685
|
+
pages?: Page[];
|
|
686
|
+
/** Site's publish date */
|
|
687
|
+
publishDate?: string;
|
|
688
|
+
}
|
|
689
|
+
interface Page {
|
|
690
|
+
/** Page's Id */
|
|
691
|
+
_id?: string;
|
|
692
|
+
}
|
|
693
|
+
interface SubscriptionEvent extends SubscriptionEventEventOneOf {
|
|
694
|
+
/** Triggered when a subscription is created. */
|
|
695
|
+
created?: SubscriptionCreated;
|
|
696
|
+
/**
|
|
697
|
+
* Triggered when a subscription is assigned to a Wix site, including the initial
|
|
698
|
+
* assignment of a floating subscription or a re-assignement from a different site.
|
|
699
|
+
*/
|
|
700
|
+
assigned?: SubscriptionAssigned;
|
|
701
|
+
/** Triggered when a subscription is canceled. */
|
|
702
|
+
cancelled?: SubscriptionCancelled;
|
|
703
|
+
/** Triggered when the subscription's auto renew is turned on. */
|
|
704
|
+
autoRenewTurnedOn?: SubscriptionAutoRenewTurnedOn;
|
|
705
|
+
/** Triggered when the subscription's auto renew is turned off. */
|
|
706
|
+
autoRenewTurnedOff?: SubscriptionAutoRenewTurnedOff;
|
|
707
|
+
/**
|
|
708
|
+
* Triggered when a subscription is unassigned from a Wix site and becomes
|
|
709
|
+
* floating.
|
|
710
|
+
*/
|
|
711
|
+
unassigned?: SubscriptionUnassigned;
|
|
712
|
+
/**
|
|
713
|
+
* Triggered when a subscription is transferred from one Wix account to another.
|
|
714
|
+
* A transfer includes cancelling the original subscription and creating a new
|
|
715
|
+
* subscription for the target account. The event returns both the original
|
|
716
|
+
* and the new subscription.
|
|
717
|
+
*/
|
|
718
|
+
transferred?: SubscriptionTransferred;
|
|
719
|
+
/** Triggered when a recurring charge succeeds for a subscription. */
|
|
720
|
+
recurringChargeSucceeded?: RecurringChargeSucceeded;
|
|
721
|
+
/**
|
|
722
|
+
* Triggered when a subscription was updated including when its product has been
|
|
723
|
+
* up- or downgraded or the billing cycle is changed.
|
|
724
|
+
*/
|
|
725
|
+
contractSwitched?: ContractSwitched;
|
|
726
|
+
/**
|
|
727
|
+
* Triggered when a subscription gets close to the end of its billing cycle.
|
|
728
|
+
* The exact number of days is defined in the billing system.
|
|
729
|
+
*/
|
|
730
|
+
nearEndOfPeriod?: SubscriptionNearEndOfPeriod;
|
|
731
|
+
/**
|
|
732
|
+
* Triggered when a subscription is updated and the change doesn't happen
|
|
733
|
+
* immediately but at the end of the current billing cycle.
|
|
734
|
+
*/
|
|
735
|
+
pendingChange?: SubscriptionPendingChange;
|
|
736
|
+
/** ID of the subscription's event. */
|
|
737
|
+
eventId?: string | null;
|
|
738
|
+
/**
|
|
739
|
+
* Date and time of the event in
|
|
740
|
+
* [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
|
|
741
|
+
* `YYYY-MM-DDThh:mm:ss.sssZ` format.
|
|
742
|
+
*/
|
|
743
|
+
eventDate?: Date;
|
|
744
|
+
}
|
|
745
|
+
/** @oneof */
|
|
746
|
+
interface SubscriptionEventEventOneOf {
|
|
747
|
+
/** Triggered when a subscription is created. */
|
|
748
|
+
created?: SubscriptionCreated;
|
|
749
|
+
/**
|
|
750
|
+
* Triggered when a subscription is assigned to a Wix site, including the initial
|
|
751
|
+
* assignment of a floating subscription or a re-assignement from a different site.
|
|
752
|
+
*/
|
|
753
|
+
assigned?: SubscriptionAssigned;
|
|
754
|
+
/** Triggered when a subscription is canceled. */
|
|
755
|
+
cancelled?: SubscriptionCancelled;
|
|
756
|
+
/** Triggered when the subscription's auto renew is turned on. */
|
|
757
|
+
autoRenewTurnedOn?: SubscriptionAutoRenewTurnedOn;
|
|
758
|
+
/** Triggered when the subscription's auto renew is turned off. */
|
|
759
|
+
autoRenewTurnedOff?: SubscriptionAutoRenewTurnedOff;
|
|
760
|
+
/**
|
|
761
|
+
* Triggered when a subscription is unassigned from a Wix site and becomes
|
|
762
|
+
* floating.
|
|
763
|
+
*/
|
|
764
|
+
unassigned?: SubscriptionUnassigned;
|
|
765
|
+
/**
|
|
766
|
+
* Triggered when a subscription is transferred from one Wix account to another.
|
|
767
|
+
* A transfer includes cancelling the original subscription and creating a new
|
|
768
|
+
* subscription for the target account. The event returns both the original
|
|
769
|
+
* and the new subscription.
|
|
770
|
+
*/
|
|
771
|
+
transferred?: SubscriptionTransferred;
|
|
772
|
+
/** Triggered when a recurring charge succeeds for a subscription. */
|
|
773
|
+
recurringChargeSucceeded?: RecurringChargeSucceeded;
|
|
774
|
+
/**
|
|
775
|
+
* Triggered when a subscription was updated including when its product has been
|
|
776
|
+
* up- or downgraded or the billing cycle is changed.
|
|
777
|
+
*/
|
|
778
|
+
contractSwitched?: ContractSwitched;
|
|
779
|
+
/**
|
|
780
|
+
* Triggered when a subscription gets close to the end of its billing cycle.
|
|
781
|
+
* The exact number of days is defined in the billing system.
|
|
782
|
+
*/
|
|
783
|
+
nearEndOfPeriod?: SubscriptionNearEndOfPeriod;
|
|
784
|
+
/**
|
|
785
|
+
* Triggered when a subscription is updated and the change doesn't happen
|
|
786
|
+
* immediately but at the end of the current billing cycle.
|
|
787
|
+
*/
|
|
788
|
+
pendingChange?: SubscriptionPendingChange;
|
|
789
|
+
}
|
|
790
|
+
/** Triggered when a subscription is created. */
|
|
791
|
+
interface SubscriptionCreated {
|
|
792
|
+
/** Created subscription. */
|
|
793
|
+
subscription?: Subscription;
|
|
794
|
+
/** Metadata for the `created` event. */
|
|
795
|
+
metadata?: Record<string, string>;
|
|
796
|
+
/**
|
|
797
|
+
* Subscription reactivation data.
|
|
798
|
+
* A subscription can be reactivated for example if it was incorrectly canceled because of fraud and then reactivated
|
|
799
|
+
* by the billing system
|
|
800
|
+
*/
|
|
801
|
+
reactivationData?: ReactivationData;
|
|
802
|
+
}
|
|
803
|
+
/**
|
|
804
|
+
* A subscription holds information about a Premium product that a Wix account
|
|
805
|
+
* owner has purchased including details about the billing.
|
|
806
|
+
*/
|
|
807
|
+
interface Subscription {
|
|
808
|
+
/** ID of the subscription. */
|
|
809
|
+
_id?: string;
|
|
810
|
+
/** ID of the Wix account that purchased the subscription. */
|
|
811
|
+
userId?: string;
|
|
812
|
+
/**
|
|
813
|
+
* ID of the [product](https://bo.wix.com/wix-docs/rest/premium/premium-product-catalog-v2/products/product-object)
|
|
814
|
+
* for which the subscription was purchased.
|
|
815
|
+
*/
|
|
816
|
+
productId?: string;
|
|
817
|
+
/**
|
|
818
|
+
* Date and time the subscription was created in
|
|
819
|
+
* [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
|
|
820
|
+
* `YYYY-MM-DDThh:mm:ss.sssZ` format.
|
|
821
|
+
*/
|
|
822
|
+
createdAt?: Date;
|
|
823
|
+
/**
|
|
824
|
+
* Date and time the subscription was last updated in
|
|
825
|
+
* [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
|
|
826
|
+
* `YYYY-MM-DDThh:mm:ss.sssZ` format.
|
|
827
|
+
*/
|
|
828
|
+
updatedAt?: Date;
|
|
829
|
+
/**
|
|
830
|
+
* ID of the metasite that the subscription is assigned to.
|
|
831
|
+
* Available only when the subscription is assigned to a Wix site.
|
|
832
|
+
* Subscriptions for account level products can't be assigned to a Wix site.
|
|
833
|
+
*/
|
|
834
|
+
metaSiteId?: string | null;
|
|
835
|
+
/** Information about the system that manages the subscription's billing. */
|
|
836
|
+
billingReference?: BillingReference;
|
|
837
|
+
/** Information about the billing cycle of the subscription. */
|
|
838
|
+
cycle?: Cycle;
|
|
839
|
+
/**
|
|
840
|
+
* Subscription status.
|
|
841
|
+
*
|
|
842
|
+
* + `UNKNOWN`: Default status.
|
|
843
|
+
* + `AUTO_RENEW_ON`: Subscription is active and automatically renews at the end of the current billing cycle.
|
|
844
|
+
* + `AUTO_RENEW_OFF`: Subscription is active but expires at the end of the current billing cycle.
|
|
845
|
+
* + `MANUAL_RECURRING`: Subscription is active and renews at the end of the current billing cycle, in case the customer takes an action related to the payment.
|
|
846
|
+
* + `CANCELLED`: Subscription isn't active because it has been canceled.
|
|
847
|
+
* + `TRANSFERRED`: Subscription isn't active because it has been transferred to a different account. A different active subscription was created for the target account.
|
|
848
|
+
*/
|
|
849
|
+
status?: SubscriptionStatus;
|
|
850
|
+
/**
|
|
851
|
+
* Date and time the subscription was last transferred from one Wix account to
|
|
852
|
+
* another in
|
|
853
|
+
* [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
|
|
854
|
+
* `YYYY-MM-DDThh:mm:ss.sssZ` format.
|
|
855
|
+
*/
|
|
856
|
+
transferredAt?: Date;
|
|
857
|
+
/**
|
|
858
|
+
* ID of the [product type](https://bo.wix.com/wix-docs/rest/premium/premium-product-catalog-v2/product-types/product-type-object)
|
|
859
|
+
* that the product, for which the subscription was purchased, belongs to.
|
|
860
|
+
*/
|
|
861
|
+
productTypeId?: string;
|
|
862
|
+
/** Version number, which increments by 1 each time the subscription is updated. */
|
|
863
|
+
version?: number;
|
|
864
|
+
/**
|
|
865
|
+
* Whether the subscription is active. Includes the statuses
|
|
866
|
+
* `"AUTO_RENEW_ON"`, `"AUTO_RENEW_OFF"`, and `"MANUAL_RECURRING"`.
|
|
867
|
+
*/
|
|
868
|
+
active?: boolean;
|
|
869
|
+
/**
|
|
870
|
+
* Date and time the subscription was originally created in
|
|
871
|
+
* [UTC datetime](https://en.wikipedia.org/wiki/Coordinated_Universal_Time)
|
|
872
|
+
* `YYYY-MM-DDThh:mm:ss.sssZ` format.
|
|
873
|
+
* Differs from `createdAt` in case the subscription was originally created for a different Wix account and has been transferred.
|
|
874
|
+
*/
|
|
875
|
+
originalCreationDate?: Date;
|
|
876
|
+
/** Custom metadata about the subscription. */
|
|
877
|
+
metadata?: Record<string, string>;
|
|
878
|
+
/**
|
|
879
|
+
* 2-letter country code in
|
|
880
|
+
* [ISO-3166 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2#Officially_assigned_code_elements)
|
|
881
|
+
* format.
|
|
882
|
+
*/
|
|
883
|
+
countryCode?: string | null;
|
|
884
|
+
}
|
|
885
|
+
interface BillingReference {
|
|
886
|
+
/**
|
|
887
|
+
* Name of the billing system that manages the subscription.
|
|
888
|
+
*
|
|
889
|
+
* + `"UNKNOWN"`: Default value.
|
|
890
|
+
* + `"SBS"`: [Wix Billing](https://github.com/wix-p/premium-billing/tree/master/sbs).
|
|
891
|
+
* + `"LICENSER"`:
|
|
892
|
+
* + `"BASS"`: [Billing and Subscriptions System](https://dev.wix.com/docs/rest/internal-only/premium/subscriptions-by-billing-by-wix/introduction).
|
|
893
|
+
* + `"RESELLER"`: [External Reseller](https://dev.wix.com/api/rest/account-level-apis/resellers/introduction).
|
|
894
|
+
*/
|
|
895
|
+
providerName?: ProviderName;
|
|
896
|
+
/** Current provider reference ID. */
|
|
897
|
+
providerReferenceId?: string | null;
|
|
898
|
+
/** Previous provider reference IDs. Used for when a subscription is extended, specifically for domains. */
|
|
899
|
+
previousProviderReferenceIds?: string[];
|
|
900
|
+
}
|
|
901
|
+
declare enum ProviderName {
|
|
902
|
+
UNKNOWN = "UNKNOWN",
|
|
903
|
+
SBS = "SBS",
|
|
904
|
+
LICENSER = "LICENSER",
|
|
905
|
+
BASS = "BASS",
|
|
906
|
+
RESELLER = "RESELLER",
|
|
907
|
+
RECURRING_INVOICES = "RECURRING_INVOICES"
|
|
908
|
+
}
|
|
909
|
+
interface Cycle extends CycleCycleSelectorOneOf {
|
|
910
|
+
/** repetitive interval */
|
|
911
|
+
interval?: Interval;
|
|
912
|
+
/** one time */
|
|
913
|
+
oneTime?: OneTime;
|
|
914
|
+
}
|
|
915
|
+
/** @oneof */
|
|
916
|
+
interface CycleCycleSelectorOneOf {
|
|
917
|
+
/** repetitive interval */
|
|
918
|
+
interval?: Interval;
|
|
919
|
+
/** one time */
|
|
920
|
+
oneTime?: OneTime;
|
|
921
|
+
}
|
|
922
|
+
interface Interval {
|
|
923
|
+
/** interval unit of measure */
|
|
924
|
+
unit?: IntervalUnit;
|
|
925
|
+
/** number of interval */
|
|
926
|
+
count?: number;
|
|
927
|
+
}
|
|
928
|
+
declare enum IntervalUnit {
|
|
929
|
+
/** unknown interval unit */
|
|
930
|
+
UNKNOWN = "UNKNOWN",
|
|
931
|
+
/** day */
|
|
932
|
+
DAY = "DAY",
|
|
933
|
+
/** week */
|
|
934
|
+
WEEK = "WEEK",
|
|
935
|
+
/** month */
|
|
936
|
+
MONTH = "MONTH",
|
|
937
|
+
/** year */
|
|
938
|
+
YEAR = "YEAR"
|
|
939
|
+
}
|
|
940
|
+
interface OneTime {
|
|
941
|
+
}
|
|
942
|
+
declare enum SubscriptionStatus {
|
|
943
|
+
UNKNOWN = "UNKNOWN",
|
|
944
|
+
AUTO_RENEW_ON = "AUTO_RENEW_ON",
|
|
945
|
+
AUTO_RENEW_OFF = "AUTO_RENEW_OFF",
|
|
946
|
+
MANUAL_RECURRING = "MANUAL_RECURRING",
|
|
947
|
+
CANCELLED = "CANCELLED",
|
|
948
|
+
TRANSFERRED = "TRANSFERRED"
|
|
949
|
+
}
|
|
950
|
+
/** Triggered when a subscription is reactivated. */
|
|
951
|
+
interface ReactivationData {
|
|
952
|
+
reactivationReason?: ReactivationReasonEnum;
|
|
953
|
+
/**
|
|
954
|
+
* In the event of reactivation after chargeback dispute, the subscription may be extended according to the
|
|
955
|
+
* number of days it was inactive during the time of resolving the dispute
|
|
956
|
+
*/
|
|
957
|
+
newEndOfPeriod?: Date;
|
|
958
|
+
/** The original end date, before the inactive period. */
|
|
959
|
+
oldEndOfPeriod?: Date;
|
|
960
|
+
/** The difference in days between the new new_end_of_period and old_end_of_period */
|
|
961
|
+
differenceInDays?: number | null;
|
|
962
|
+
}
|
|
963
|
+
/** Reason for subscription reactivation */
|
|
964
|
+
declare enum ReactivationReasonEnum {
|
|
965
|
+
UNKNOWN = "UNKNOWN",
|
|
966
|
+
/**
|
|
967
|
+
* Subscription was reactivated due to billing status change from CANCELED to ACTIVE, for example if it was incorrectly
|
|
968
|
+
* canceled because of suspicion of fraud
|
|
969
|
+
*/
|
|
970
|
+
BILLING_STATUS_CHANGE = "BILLING_STATUS_CHANGE",
|
|
971
|
+
/** Subscription was reactivated after a chargeback dispute */
|
|
972
|
+
REACTIVATED_AFTER_CHARGEBACK = "REACTIVATED_AFTER_CHARGEBACK"
|
|
973
|
+
}
|
|
974
|
+
/**
|
|
975
|
+
* Triggered when a subscription is assigned to a Wix site, including the initial
|
|
976
|
+
* assignment of a floating subscription or a re-assignement from a different site.
|
|
977
|
+
*/
|
|
978
|
+
interface SubscriptionAssigned {
|
|
979
|
+
/** Assigned subscription. */
|
|
980
|
+
subscription?: Subscription;
|
|
981
|
+
/** ID of the metasite that the subscription has been assigned to before the update. */
|
|
982
|
+
previousMetaSiteId?: string | null;
|
|
983
|
+
}
|
|
984
|
+
/** Triggered when a subscription is canceled. */
|
|
985
|
+
interface SubscriptionCancelled {
|
|
986
|
+
/** Canceled subscription. */
|
|
987
|
+
subscription?: Subscription;
|
|
988
|
+
/** Details about the cancellation including who canceled the subscription and why. */
|
|
989
|
+
cancellationDetails?: CancellationDetails;
|
|
990
|
+
/**
|
|
991
|
+
* Whether the subscription is canceled immediately or expires at the end of the current billing cycle.
|
|
992
|
+
*
|
|
993
|
+
* Default: `false`
|
|
994
|
+
*/
|
|
995
|
+
immediateCancel?: boolean;
|
|
996
|
+
/** Whether the subscription was canceled during the free trial period. */
|
|
997
|
+
canceledInFreeTrial?: boolean;
|
|
998
|
+
}
|
|
999
|
+
/** Information about the cancellation flow including who canceled the subscription and why it was canceled. */
|
|
1000
|
+
interface CancellationDetails {
|
|
1001
|
+
/**
|
|
1002
|
+
* Cancellation code.
|
|
1003
|
+
*
|
|
1004
|
+
* Values supported for cancellations on behalf of the billing system: `-1`, `-2`, `-3`, `-4`, `-5`, `-6`, `-7`, `-8`.
|
|
1005
|
+
* For cancellations on behalf of the site owner or the service provider `cancellationCode`
|
|
1006
|
+
* is taken from the request of
|
|
1007
|
+
* [Cancel Immediately Offline](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately-offline).
|
|
1008
|
+
*
|
|
1009
|
+
* + `-1`: The subscription has been cancelled by the billing system but none of the listed cancellation reasons applies.
|
|
1010
|
+
* + `-2`: There were payment problems.
|
|
1011
|
+
* + `-3`: There was a chargeback.
|
|
1012
|
+
* + `-4`: Customer support has canceled the subscription and issued a refund.
|
|
1013
|
+
* + `-5`: The site owner has changed their existing subscription.
|
|
1014
|
+
* + `-6`: The subscription has been transferred to a different Wix account.
|
|
1015
|
+
* + `-7`: The subscription has been canceled because the site owner hasn't manually authenticated the recurring payment during the subscription's grace period. For example, site owners must manually confirm recurring payments within 40 days when paying with boleto.
|
|
1016
|
+
* + `-8`: The Wix account that the subscription belonged to has been deleted.
|
|
1017
|
+
*/
|
|
1018
|
+
cancellationCode?: number | null;
|
|
1019
|
+
/**
|
|
1020
|
+
* Cancellation reason. For cancellations on behalf of the site owner or the service provider `cancellationReason`
|
|
1021
|
+
* is taken from the request of
|
|
1022
|
+
* [Cancel Immediately Offline](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately-offline).
|
|
1023
|
+
* For cancellations on behalf of the billing system `cancellationReason` is `null` or an empty string.
|
|
1024
|
+
*/
|
|
1025
|
+
cancellationReason?: string | null;
|
|
1026
|
+
/**
|
|
1027
|
+
* Initiator of the cancellation. For `"USER_REQUESTED"` and `"APP_MANAGED"`,
|
|
1028
|
+
* `cancellationCode` and `cancellationReason` are taken from the request of
|
|
1029
|
+
* [Cancel Immediately](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately)
|
|
1030
|
+
* or [Cancel Immediately Offline](https://bo.wix.com/wix-docs/rest/premium/premium-subscriptions-manager/cancel-immediately-offline).
|
|
1031
|
+
* For `"PASSIVE"`, cancellations `cancellationCode` is automatically calculated and `cancellationReason`
|
|
1032
|
+
* is `null` or an empty string.
|
|
1033
|
+
*
|
|
1034
|
+
* + `"UNKNOWN`: Default value.
|
|
1035
|
+
* + `"USER_REQUESTED"`: The Wix account owner has canceled the subscription.
|
|
1036
|
+
* + `"APP_MANAGED"`: The service provider has canceled the subscription.
|
|
1037
|
+
* + `"PASSIVE"`: The billing system has canceled the subscription. For example, in case of payment failure or fraud.
|
|
1038
|
+
*/
|
|
1039
|
+
initiator?: Initiator;
|
|
1040
|
+
}
|
|
1041
|
+
declare enum Initiator {
|
|
1042
|
+
UNKNOWN = "UNKNOWN",
|
|
1043
|
+
USER_REQUESTED = "USER_REQUESTED",
|
|
1044
|
+
APP_MANAGED = "APP_MANAGED",
|
|
1045
|
+
PASSIVE = "PASSIVE"
|
|
1046
|
+
}
|
|
1047
|
+
/** Triggered when the subscription's auto renew is turned on. */
|
|
1048
|
+
interface SubscriptionAutoRenewTurnedOn {
|
|
1049
|
+
/** Subscription for which auto renew is turned on. */
|
|
1050
|
+
subscription?: Subscription;
|
|
1051
|
+
/**
|
|
1052
|
+
* Supported values: `USER`, `APP`.
|
|
1053
|
+
*
|
|
1054
|
+
* Information about who turned auto renew on.
|
|
1055
|
+
* + `"USER"`: The site owner who purchased the subscription has turned auto renew on.
|
|
1056
|
+
* + `"APP"`: The service provider has turned auto renew on.
|
|
1057
|
+
*/
|
|
1058
|
+
initiator?: string | null;
|
|
1059
|
+
}
|
|
1060
|
+
/** Triggered when the subscription's auto renew is turned off. */
|
|
1061
|
+
interface SubscriptionAutoRenewTurnedOff {
|
|
1062
|
+
/** Subscription for which auto renew is turned off. */
|
|
1063
|
+
subscription?: Subscription;
|
|
1064
|
+
/** Details about the cancellation including who canceled the subscription and why. */
|
|
1065
|
+
cancellationDetails?: CancellationDetails;
|
|
1066
|
+
/**
|
|
1067
|
+
* Whether the subscription is immediately canceled or expires at the end of the current billing cycle.
|
|
1068
|
+
*
|
|
1069
|
+
* Default: `false`
|
|
1070
|
+
*/
|
|
1071
|
+
immediateCancel?: boolean;
|
|
1072
|
+
}
|
|
1073
|
+
/**
|
|
1074
|
+
* Triggered when a subscription is unassigned from a Wix site and becomes
|
|
1075
|
+
* floating.
|
|
1076
|
+
*/
|
|
1077
|
+
interface SubscriptionUnassigned {
|
|
1078
|
+
/** Unassigned subscription. */
|
|
1079
|
+
subscription?: Subscription;
|
|
1080
|
+
/** ID of the metasite that the subscription has been assigned to before the event. */
|
|
1081
|
+
previousMetaSiteId?: string;
|
|
1082
|
+
/**
|
|
1083
|
+
* Reason why the subscription is unassigned.
|
|
1084
|
+
*
|
|
1085
|
+
* + `"UNKNOWN"`: Default value.
|
|
1086
|
+
* + `"USER_REQUESTED"`: The Wix account owner has unassigned the subscription.
|
|
1087
|
+
* + `"REPLACED_BY_ANOTHER_SUBSCRIPTION"`: A different subscription that replaces this subscription is assigned to the site.
|
|
1088
|
+
*/
|
|
1089
|
+
unassignReason?: UnassignReason;
|
|
1090
|
+
}
|
|
1091
|
+
declare enum UnassignReason {
|
|
1092
|
+
UNKNOWN = "UNKNOWN",
|
|
1093
|
+
USER_REQUESTED = "USER_REQUESTED",
|
|
1094
|
+
REPLACED_BY_ANOTHER_SUBSCRIPTION = "REPLACED_BY_ANOTHER_SUBSCRIPTION"
|
|
1095
|
+
}
|
|
1096
|
+
/**
|
|
1097
|
+
* Triggered when a subscription is transferred from one Wix account to another.
|
|
1098
|
+
* A transfer includes cancelling the original subscription and creating a new
|
|
1099
|
+
* subscription for the target account. The event returns both the original
|
|
1100
|
+
* and the new subscription.
|
|
1101
|
+
*/
|
|
1102
|
+
interface SubscriptionTransferred {
|
|
1103
|
+
/** Original subscription that was canceled for the transfer. */
|
|
1104
|
+
originSubscription?: Subscription;
|
|
1105
|
+
/** Newly created subscription for the target account. */
|
|
1106
|
+
targetSubscription?: Subscription;
|
|
1107
|
+
}
|
|
1108
|
+
/** Triggered when a recurring charge succeeds for a subscription. */
|
|
1109
|
+
interface RecurringChargeSucceeded {
|
|
1110
|
+
/** Subscription for which the recurring charge has succeeded. */
|
|
1111
|
+
subscription?: Subscription;
|
|
1112
|
+
/** Indication that there was a successful charge at the end of the free trial period */
|
|
1113
|
+
freeTrialPeriodEnd?: boolean;
|
|
1114
|
+
}
|
|
1115
|
+
/**
|
|
1116
|
+
* Triggered when a subscription was updated including when its product has been
|
|
1117
|
+
* up- or downgraded or the billing cycle is changed.
|
|
1118
|
+
*/
|
|
1119
|
+
interface ContractSwitched {
|
|
1120
|
+
/** Updated subscription. */
|
|
1121
|
+
subscription?: Subscription;
|
|
1122
|
+
/** Billing cycle before the update. */
|
|
1123
|
+
previousCycle?: Cycle;
|
|
1124
|
+
/** ID of the product belonging to the subscription before the update. */
|
|
1125
|
+
previousProductId?: string;
|
|
1126
|
+
/** ID of the product type that the subscription's original product belonged to before the update. */
|
|
1127
|
+
previousProductTypeId?: string;
|
|
1128
|
+
/**
|
|
1129
|
+
* Update type. __Note__: Doesn't include information about a product adjustment.
|
|
1130
|
+
* For that purpose, see `productAdjustment`.
|
|
1131
|
+
*
|
|
1132
|
+
* + `"NOT_APPLICABLE"`: Default value.
|
|
1133
|
+
* + `"ADDITIONAL_QUANTITY"`: An increased usage quota is added to the subscription. For example, a second mailbox is added to a subscription that previously included a single mailbox.
|
|
1134
|
+
* + `"CREDIT_UNUSED_PERIOD"`: The subscription is upgraded and the new price is less than the regular price. The new price applies to every billing cycle, not just the first cycle.
|
|
1135
|
+
* + `"REFUND_PRICE_DIFF"`: Not implemented.
|
|
1136
|
+
* + `"ADJUST_PERIOD_END"`: Not implemented.
|
|
1137
|
+
* + `"DOWNGRADE_GRACE_PERIOD"`: For downgrades during the grace period. In this situation, the site owner hasn’t paid yet and must immediately pay for the downgraded subscription.
|
|
1138
|
+
* + `"FULL_AMOUNT_PERIOD"`: For upgrades in which the site owner retains unused benefits. For example, site owners upgrading a Facebook Ads subscription retain their unused FB Ads credit. The unused credit is added to the new credit.
|
|
1139
|
+
* + `"END_OF_PERIOD"`: The subscription's billing current cycle is extended because of a downgrade.
|
|
1140
|
+
* + `"PENDING_CHANGES"`: The subscription's billing is updated, but the change doesn't apply immediately. Instead, the update becomes effective at the end of current billing cycle.
|
|
1141
|
+
* + `"DOWNGRADE_RENEWAL"`: The subscription is downgraded because of a declined payment. This prevents subscriptions from churning.
|
|
1142
|
+
*/
|
|
1143
|
+
contractSwitchType?: ContractSwitchType;
|
|
1144
|
+
/**
|
|
1145
|
+
* ID of the metasite the subscription has been assigned to previously.
|
|
1146
|
+
* Available only in case the subscription is assigned to a different site.
|
|
1147
|
+
*/
|
|
1148
|
+
previousMetaSiteId?: string | null;
|
|
1149
|
+
/**
|
|
1150
|
+
* Update reason.
|
|
1151
|
+
*
|
|
1152
|
+
* + `"PRICE_INCREASE"`: The subscription's price has been increased.
|
|
1153
|
+
* + `"EXTERNAL_PROVIDER_TRIGGER"`: Any reason other than a price increase.
|
|
1154
|
+
*/
|
|
1155
|
+
contractSwitchReason?: ContractSwitchReason;
|
|
1156
|
+
/** Information about the price update. Available only for updates with a price increase. */
|
|
1157
|
+
productPriceIncreaseData?: ProductPriceIncreaseData;
|
|
1158
|
+
/**
|
|
1159
|
+
* Information about a product adjustment. For example, a downgrade.
|
|
1160
|
+
* __Note__: This isn't the same as `contractSwitchType`.
|
|
1161
|
+
*
|
|
1162
|
+
* + `NOT_APPLICABLE`: There is no information about whether the product has been up- or downgraded.
|
|
1163
|
+
* + `DOWNGRADE`: The product has been downgraded.
|
|
1164
|
+
*/
|
|
1165
|
+
productAdjustment?: ProductAdjustment;
|
|
1166
|
+
}
|
|
1167
|
+
/** Copied from SBS */
|
|
1168
|
+
declare enum ContractSwitchType {
|
|
1169
|
+
NOT_APPLICABLE = "NOT_APPLICABLE",
|
|
1170
|
+
ADDITIONAL_QUANTITY = "ADDITIONAL_QUANTITY",
|
|
1171
|
+
CREDIT_UNUSED_PERIOD = "CREDIT_UNUSED_PERIOD",
|
|
1172
|
+
REFUND_PRICE_DIFF = "REFUND_PRICE_DIFF",
|
|
1173
|
+
ADJUST_PERIOD_END = "ADJUST_PERIOD_END",
|
|
1174
|
+
DOWNGRADE_GRACE_PERIOD = "DOWNGRADE_GRACE_PERIOD",
|
|
1175
|
+
FULL_AMOUNT_PERIOD = "FULL_AMOUNT_PERIOD",
|
|
1176
|
+
END_OF_PERIOD = "END_OF_PERIOD",
|
|
1177
|
+
PENDING_CHANGES = "PENDING_CHANGES",
|
|
1178
|
+
DOWNGRADE_RENEWAL = "DOWNGRADE_RENEWAL"
|
|
1179
|
+
}
|
|
1180
|
+
declare enum ContractSwitchReason {
|
|
1181
|
+
EXTERNAL_PROVIDER_TRIGGER = "EXTERNAL_PROVIDER_TRIGGER",
|
|
1182
|
+
PRICE_INCREASE = "PRICE_INCREASE"
|
|
1183
|
+
}
|
|
1184
|
+
/** Triggered when a subscription's price is increased. */
|
|
1185
|
+
interface ProductPriceIncreaseData {
|
|
1186
|
+
/** Price of the subscription before the update. */
|
|
1187
|
+
previousPrice?: string | null;
|
|
1188
|
+
/** A value that is used in order to select the correct email template to send the user regarding the price increase. */
|
|
1189
|
+
emailTemplateSelector?: string | null;
|
|
1190
|
+
/** Used to differentiate between migration segments. Does not have to be unique per segment. */
|
|
1191
|
+
segmentName?: string | null;
|
|
1192
|
+
/** Used to determine how the price increase was triggered. */
|
|
1193
|
+
priceIncreaseTrigger?: PriceIncreaseTrigger;
|
|
1194
|
+
}
|
|
1195
|
+
/** Reason for Price Increase Trigger */
|
|
1196
|
+
declare enum PriceIncreaseTrigger {
|
|
1197
|
+
NEAR_RENEWAL = "NEAR_RENEWAL",
|
|
1198
|
+
RECURRING_SUCCESS = "RECURRING_SUCCESS",
|
|
1199
|
+
MANUAL = "MANUAL"
|
|
1200
|
+
}
|
|
1201
|
+
/** Triggered when a subscription's product is adusted. */
|
|
1202
|
+
declare enum ProductAdjustment {
|
|
1203
|
+
/** flag to show that the ContractSwitchedEvent is not applicable / needed */
|
|
1204
|
+
NOT_APPLICABLE = "NOT_APPLICABLE",
|
|
1205
|
+
/** flag to show that the ContractSwitchedEvent is a Downgrade */
|
|
1206
|
+
DOWNGRADE = "DOWNGRADE"
|
|
1207
|
+
}
|
|
1208
|
+
/**
|
|
1209
|
+
* Triggered when a subscription gets close to the end of its billing cycle.
|
|
1210
|
+
* The exact number of days is defined in the billing system.
|
|
1211
|
+
*/
|
|
1212
|
+
interface SubscriptionNearEndOfPeriod {
|
|
1213
|
+
/** Subscription that got close to the end of its billing cycle. */
|
|
1214
|
+
subscription?: Subscription;
|
|
1215
|
+
/** Whether the subscription is within the free trial period. */
|
|
1216
|
+
inFreeTrial?: boolean;
|
|
1217
|
+
}
|
|
1218
|
+
/**
|
|
1219
|
+
* Triggered when a subscription is updated and the change doesn't happen
|
|
1220
|
+
* immediately but at the end of the current billing cycle.
|
|
1221
|
+
*/
|
|
1222
|
+
interface SubscriptionPendingChange {
|
|
1223
|
+
/** Subscription for which a pending update is triggered. */
|
|
1224
|
+
subscription?: Subscription;
|
|
1225
|
+
}
|
|
1226
|
+
interface MessageEnvelope$4 {
|
|
1227
|
+
/** App instance ID. */
|
|
1228
|
+
instanceId?: string | null;
|
|
1229
|
+
/** Event type. */
|
|
1230
|
+
eventType?: string;
|
|
1231
|
+
/** The identification type and identity data. */
|
|
1232
|
+
identity?: IdentificationData$4;
|
|
1233
|
+
/** Stringify payload. */
|
|
1234
|
+
data?: string;
|
|
1235
|
+
}
|
|
1236
|
+
interface IdentificationData$4 extends IdentificationDataIdOneOf$4 {
|
|
224
1237
|
/** ID of a site visitor that has not logged in to the site. */
|
|
225
1238
|
anonymousVisitorId?: string;
|
|
226
1239
|
/** ID of a site visitor that has logged in to the site. */
|
|
@@ -230,10 +1243,10 @@ interface IdentificationData$3 extends IdentificationDataIdOneOf$3 {
|
|
|
230
1243
|
/** ID of an app. */
|
|
231
1244
|
appId?: string;
|
|
232
1245
|
/** @readonly */
|
|
233
|
-
identityType?: WebhookIdentityType$
|
|
1246
|
+
identityType?: WebhookIdentityType$4;
|
|
234
1247
|
}
|
|
235
1248
|
/** @oneof */
|
|
236
|
-
interface IdentificationDataIdOneOf$
|
|
1249
|
+
interface IdentificationDataIdOneOf$4 {
|
|
237
1250
|
/** ID of a site visitor that has not logged in to the site. */
|
|
238
1251
|
anonymousVisitorId?: string;
|
|
239
1252
|
/** ID of a site visitor that has logged in to the site. */
|
|
@@ -243,252 +1256,78 @@ interface IdentificationDataIdOneOf$3 {
|
|
|
243
1256
|
/** ID of an app. */
|
|
244
1257
|
appId?: string;
|
|
245
1258
|
}
|
|
246
|
-
declare enum WebhookIdentityType$
|
|
1259
|
+
declare enum WebhookIdentityType$4 {
|
|
247
1260
|
UNKNOWN = "UNKNOWN",
|
|
248
1261
|
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
249
1262
|
MEMBER = "MEMBER",
|
|
250
1263
|
WIX_USER = "WIX_USER",
|
|
251
1264
|
APP = "APP"
|
|
252
1265
|
}
|
|
1266
|
+
interface FixedAmountDiscountNonNullableFields$2 {
|
|
1267
|
+
amount: number;
|
|
1268
|
+
}
|
|
1269
|
+
interface PercentageDiscountNonNullableFields$2 {
|
|
1270
|
+
percentage: number;
|
|
1271
|
+
}
|
|
1272
|
+
interface GroupNonNullableFields$2 {
|
|
1273
|
+
name: string;
|
|
1274
|
+
}
|
|
1275
|
+
interface CouponScopeNonNullableFields$2 {
|
|
1276
|
+
namespace: string;
|
|
1277
|
+
group?: GroupNonNullableFields$2;
|
|
1278
|
+
}
|
|
1279
|
+
interface CouponNonNullableFields$2 {
|
|
1280
|
+
fixedAmountOptions?: FixedAmountDiscountNonNullableFields$2;
|
|
1281
|
+
percentageOptions?: PercentageDiscountNonNullableFields$2;
|
|
1282
|
+
minimumSubtotal: number;
|
|
1283
|
+
scope?: CouponScopeNonNullableFields$2;
|
|
1284
|
+
name: string;
|
|
1285
|
+
discountType: DiscountType$2;
|
|
1286
|
+
}
|
|
1287
|
+
interface LoyaltyPointsNonNullableFields$1 {
|
|
1288
|
+
amount: number;
|
|
1289
|
+
}
|
|
1290
|
+
interface RewardNonNullableFields {
|
|
1291
|
+
couponOptions?: CouponNonNullableFields$2;
|
|
1292
|
+
loyaltyPointsOptions?: LoyaltyPointsNonNullableFields$1;
|
|
1293
|
+
type: Type$1;
|
|
1294
|
+
}
|
|
1295
|
+
interface EmailsNonNullableFields {
|
|
1296
|
+
encourageToReferFriends: App[];
|
|
1297
|
+
notifyCustomersAboutReward: boolean;
|
|
1298
|
+
}
|
|
1299
|
+
interface ReferralProgramNonNullableFields {
|
|
1300
|
+
status: ProgramStatus;
|
|
1301
|
+
referredFriendReward?: RewardNonNullableFields;
|
|
1302
|
+
referringCustomerReward?: RewardNonNullableFields;
|
|
1303
|
+
successfulReferralActions: Action[];
|
|
1304
|
+
isPremium: boolean;
|
|
1305
|
+
emails?: EmailsNonNullableFields;
|
|
1306
|
+
}
|
|
253
1307
|
interface GetReferralProgramResponseNonNullableFields {
|
|
254
|
-
referralProgram?:
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
fixedAmountOptions?: {
|
|
259
|
-
amount: number;
|
|
260
|
-
};
|
|
261
|
-
percentageOptions?: {
|
|
262
|
-
percentage: number;
|
|
263
|
-
};
|
|
264
|
-
minimumSubtotal: number;
|
|
265
|
-
scope?: {
|
|
266
|
-
namespace: string;
|
|
267
|
-
group?: {
|
|
268
|
-
name: string;
|
|
269
|
-
};
|
|
270
|
-
};
|
|
271
|
-
name: string;
|
|
272
|
-
discountType: DiscountType$2;
|
|
273
|
-
};
|
|
274
|
-
loyaltyPointsOptions?: {
|
|
275
|
-
amount: number;
|
|
276
|
-
};
|
|
277
|
-
type: Type;
|
|
278
|
-
};
|
|
279
|
-
referringCustomerReward?: {
|
|
280
|
-
couponOptions?: {
|
|
281
|
-
fixedAmountOptions?: {
|
|
282
|
-
amount: number;
|
|
283
|
-
};
|
|
284
|
-
percentageOptions?: {
|
|
285
|
-
percentage: number;
|
|
286
|
-
};
|
|
287
|
-
minimumSubtotal: number;
|
|
288
|
-
scope?: {
|
|
289
|
-
namespace: string;
|
|
290
|
-
group?: {
|
|
291
|
-
name: string;
|
|
292
|
-
};
|
|
293
|
-
};
|
|
294
|
-
name: string;
|
|
295
|
-
discountType: DiscountType$2;
|
|
296
|
-
};
|
|
297
|
-
loyaltyPointsOptions?: {
|
|
298
|
-
amount: number;
|
|
299
|
-
};
|
|
300
|
-
type: Type;
|
|
301
|
-
};
|
|
302
|
-
successfulReferralActions: Action[];
|
|
303
|
-
isPremium: boolean;
|
|
304
|
-
emails?: {
|
|
305
|
-
encourageToReferFriends: App[];
|
|
306
|
-
notifyCustomersAboutReward: boolean;
|
|
307
|
-
};
|
|
308
|
-
};
|
|
1308
|
+
referralProgram?: ReferralProgramNonNullableFields;
|
|
1309
|
+
}
|
|
1310
|
+
interface QueryReferralProgramsResponseNonNullableFields {
|
|
1311
|
+
referralPrograms: ReferralProgramNonNullableFields[];
|
|
309
1312
|
}
|
|
310
1313
|
interface UpdateReferralProgramResponseNonNullableFields {
|
|
311
|
-
referralProgram?:
|
|
312
|
-
status: ProgramStatus;
|
|
313
|
-
referredFriendReward?: {
|
|
314
|
-
couponOptions?: {
|
|
315
|
-
fixedAmountOptions?: {
|
|
316
|
-
amount: number;
|
|
317
|
-
};
|
|
318
|
-
percentageOptions?: {
|
|
319
|
-
percentage: number;
|
|
320
|
-
};
|
|
321
|
-
minimumSubtotal: number;
|
|
322
|
-
scope?: {
|
|
323
|
-
namespace: string;
|
|
324
|
-
group?: {
|
|
325
|
-
name: string;
|
|
326
|
-
};
|
|
327
|
-
};
|
|
328
|
-
name: string;
|
|
329
|
-
discountType: DiscountType$2;
|
|
330
|
-
};
|
|
331
|
-
loyaltyPointsOptions?: {
|
|
332
|
-
amount: number;
|
|
333
|
-
};
|
|
334
|
-
type: Type;
|
|
335
|
-
};
|
|
336
|
-
referringCustomerReward?: {
|
|
337
|
-
couponOptions?: {
|
|
338
|
-
fixedAmountOptions?: {
|
|
339
|
-
amount: number;
|
|
340
|
-
};
|
|
341
|
-
percentageOptions?: {
|
|
342
|
-
percentage: number;
|
|
343
|
-
};
|
|
344
|
-
minimumSubtotal: number;
|
|
345
|
-
scope?: {
|
|
346
|
-
namespace: string;
|
|
347
|
-
group?: {
|
|
348
|
-
name: string;
|
|
349
|
-
};
|
|
350
|
-
};
|
|
351
|
-
name: string;
|
|
352
|
-
discountType: DiscountType$2;
|
|
353
|
-
};
|
|
354
|
-
loyaltyPointsOptions?: {
|
|
355
|
-
amount: number;
|
|
356
|
-
};
|
|
357
|
-
type: Type;
|
|
358
|
-
};
|
|
359
|
-
successfulReferralActions: Action[];
|
|
360
|
-
isPremium: boolean;
|
|
361
|
-
emails?: {
|
|
362
|
-
encourageToReferFriends: App[];
|
|
363
|
-
notifyCustomersAboutReward: boolean;
|
|
364
|
-
};
|
|
365
|
-
};
|
|
1314
|
+
referralProgram?: ReferralProgramNonNullableFields;
|
|
366
1315
|
}
|
|
367
1316
|
interface ActivateReferralProgramResponseNonNullableFields {
|
|
368
|
-
referralProgram?:
|
|
369
|
-
status: ProgramStatus;
|
|
370
|
-
referredFriendReward?: {
|
|
371
|
-
couponOptions?: {
|
|
372
|
-
fixedAmountOptions?: {
|
|
373
|
-
amount: number;
|
|
374
|
-
};
|
|
375
|
-
percentageOptions?: {
|
|
376
|
-
percentage: number;
|
|
377
|
-
};
|
|
378
|
-
minimumSubtotal: number;
|
|
379
|
-
scope?: {
|
|
380
|
-
namespace: string;
|
|
381
|
-
group?: {
|
|
382
|
-
name: string;
|
|
383
|
-
};
|
|
384
|
-
};
|
|
385
|
-
name: string;
|
|
386
|
-
discountType: DiscountType$2;
|
|
387
|
-
};
|
|
388
|
-
loyaltyPointsOptions?: {
|
|
389
|
-
amount: number;
|
|
390
|
-
};
|
|
391
|
-
type: Type;
|
|
392
|
-
};
|
|
393
|
-
referringCustomerReward?: {
|
|
394
|
-
couponOptions?: {
|
|
395
|
-
fixedAmountOptions?: {
|
|
396
|
-
amount: number;
|
|
397
|
-
};
|
|
398
|
-
percentageOptions?: {
|
|
399
|
-
percentage: number;
|
|
400
|
-
};
|
|
401
|
-
minimumSubtotal: number;
|
|
402
|
-
scope?: {
|
|
403
|
-
namespace: string;
|
|
404
|
-
group?: {
|
|
405
|
-
name: string;
|
|
406
|
-
};
|
|
407
|
-
};
|
|
408
|
-
name: string;
|
|
409
|
-
discountType: DiscountType$2;
|
|
410
|
-
};
|
|
411
|
-
loyaltyPointsOptions?: {
|
|
412
|
-
amount: number;
|
|
413
|
-
};
|
|
414
|
-
type: Type;
|
|
415
|
-
};
|
|
416
|
-
successfulReferralActions: Action[];
|
|
417
|
-
isPremium: boolean;
|
|
418
|
-
emails?: {
|
|
419
|
-
encourageToReferFriends: App[];
|
|
420
|
-
notifyCustomersAboutReward: boolean;
|
|
421
|
-
};
|
|
422
|
-
};
|
|
1317
|
+
referralProgram?: ReferralProgramNonNullableFields;
|
|
423
1318
|
}
|
|
424
1319
|
interface PauseReferralProgramResponseNonNullableFields {
|
|
425
|
-
referralProgram?:
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
amount: number;
|
|
431
|
-
};
|
|
432
|
-
percentageOptions?: {
|
|
433
|
-
percentage: number;
|
|
434
|
-
};
|
|
435
|
-
minimumSubtotal: number;
|
|
436
|
-
scope?: {
|
|
437
|
-
namespace: string;
|
|
438
|
-
group?: {
|
|
439
|
-
name: string;
|
|
440
|
-
};
|
|
441
|
-
};
|
|
442
|
-
name: string;
|
|
443
|
-
discountType: DiscountType$2;
|
|
444
|
-
};
|
|
445
|
-
loyaltyPointsOptions?: {
|
|
446
|
-
amount: number;
|
|
447
|
-
};
|
|
448
|
-
type: Type;
|
|
449
|
-
};
|
|
450
|
-
referringCustomerReward?: {
|
|
451
|
-
couponOptions?: {
|
|
452
|
-
fixedAmountOptions?: {
|
|
453
|
-
amount: number;
|
|
454
|
-
};
|
|
455
|
-
percentageOptions?: {
|
|
456
|
-
percentage: number;
|
|
457
|
-
};
|
|
458
|
-
minimumSubtotal: number;
|
|
459
|
-
scope?: {
|
|
460
|
-
namespace: string;
|
|
461
|
-
group?: {
|
|
462
|
-
name: string;
|
|
463
|
-
};
|
|
464
|
-
};
|
|
465
|
-
name: string;
|
|
466
|
-
discountType: DiscountType$2;
|
|
467
|
-
};
|
|
468
|
-
loyaltyPointsOptions?: {
|
|
469
|
-
amount: number;
|
|
470
|
-
};
|
|
471
|
-
type: Type;
|
|
472
|
-
};
|
|
473
|
-
successfulReferralActions: Action[];
|
|
474
|
-
isPremium: boolean;
|
|
475
|
-
emails?: {
|
|
476
|
-
encourageToReferFriends: App[];
|
|
477
|
-
notifyCustomersAboutReward: boolean;
|
|
478
|
-
};
|
|
479
|
-
};
|
|
1320
|
+
referralProgram?: ReferralProgramNonNullableFields;
|
|
1321
|
+
}
|
|
1322
|
+
interface AISocialMediaPostSuggestionNonNullableFields {
|
|
1323
|
+
postContent: string;
|
|
1324
|
+
hashtags: string[];
|
|
480
1325
|
}
|
|
481
1326
|
interface GetAISocialMediaPostsSuggestionsResponseNonNullableFields {
|
|
482
|
-
suggestions:
|
|
483
|
-
postContent: string;
|
|
484
|
-
hashtags: string[];
|
|
485
|
-
}[];
|
|
1327
|
+
suggestions: AISocialMediaPostSuggestionNonNullableFields[];
|
|
486
1328
|
}
|
|
487
1329
|
interface GenerateAISocialMediaPostsSuggestionsResponseNonNullableFields {
|
|
488
|
-
suggestions:
|
|
489
|
-
postContent: string;
|
|
490
|
-
hashtags: string[];
|
|
491
|
-
}[];
|
|
1330
|
+
suggestions: AISocialMediaPostSuggestionNonNullableFields[];
|
|
492
1331
|
}
|
|
493
1332
|
interface GetReferralProgramPremiumFeaturesResponseNonNullableFields {
|
|
494
1333
|
referralProgram: boolean;
|
|
@@ -499,7 +1338,7 @@ interface BaseEventMetadata$3 {
|
|
|
499
1338
|
/** Event type. */
|
|
500
1339
|
eventType?: string;
|
|
501
1340
|
/** The identification type and identity data. */
|
|
502
|
-
identity?: IdentificationData$
|
|
1341
|
+
identity?: IdentificationData$4;
|
|
503
1342
|
}
|
|
504
1343
|
interface EventMetadata$3 extends BaseEventMetadata$3 {
|
|
505
1344
|
/**
|
|
@@ -520,7 +1359,7 @@ interface EventMetadata$3 extends BaseEventMetadata$3 {
|
|
|
520
1359
|
slug?: string;
|
|
521
1360
|
/** ID of the entity associated with the event. */
|
|
522
1361
|
entityId?: string;
|
|
523
|
-
/** Event timestamp. */
|
|
1362
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */
|
|
524
1363
|
eventTime?: Date;
|
|
525
1364
|
/**
|
|
526
1365
|
* Whether the event was triggered as a result of a privacy regulation application
|
|
@@ -577,41 +1416,42 @@ interface GenerateAiSocialMediaPostsSuggestionsOptions {
|
|
|
577
1416
|
topic?: string;
|
|
578
1417
|
}
|
|
579
1418
|
|
|
580
|
-
type RESTFunctionDescriptor
|
|
581
|
-
interface HttpClient
|
|
582
|
-
request<TResponse, TData = any>(req: RequestOptionsFactory
|
|
583
|
-
fetchWithAuth:
|
|
1419
|
+
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
1420
|
+
interface HttpClient {
|
|
1421
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
1422
|
+
fetchWithAuth: typeof fetch;
|
|
1423
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
584
1424
|
}
|
|
585
|
-
type RequestOptionsFactory
|
|
586
|
-
type HttpResponse
|
|
1425
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
1426
|
+
type HttpResponse<T = any> = {
|
|
587
1427
|
data: T;
|
|
588
1428
|
status: number;
|
|
589
1429
|
statusText: string;
|
|
590
1430
|
headers: any;
|
|
591
1431
|
request?: any;
|
|
592
1432
|
};
|
|
593
|
-
type RequestOptions
|
|
1433
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
|
594
1434
|
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
595
1435
|
url: string;
|
|
596
1436
|
data?: Data;
|
|
597
1437
|
params?: URLSearchParams;
|
|
598
|
-
} & APIMetadata
|
|
599
|
-
type APIMetadata
|
|
1438
|
+
} & APIMetadata;
|
|
1439
|
+
type APIMetadata = {
|
|
600
1440
|
methodFqn?: string;
|
|
601
1441
|
entityFqdn?: string;
|
|
602
1442
|
packageName?: string;
|
|
603
1443
|
};
|
|
604
|
-
type BuildRESTFunction
|
|
605
|
-
type EventDefinition
|
|
1444
|
+
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
1445
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
606
1446
|
__type: 'event-definition';
|
|
607
1447
|
type: Type;
|
|
608
1448
|
isDomainEvent?: boolean;
|
|
609
1449
|
transformations?: (envelope: unknown) => Payload;
|
|
610
1450
|
__payload: Payload;
|
|
611
1451
|
};
|
|
612
|
-
declare function EventDefinition
|
|
613
|
-
type EventHandler
|
|
614
|
-
type BuildEventDefinition
|
|
1452
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
1453
|
+
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
1454
|
+
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
615
1455
|
|
|
616
1456
|
declare global {
|
|
617
1457
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -620,26 +1460,133 @@ declare global {
|
|
|
620
1460
|
}
|
|
621
1461
|
}
|
|
622
1462
|
|
|
623
|
-
declare function
|
|
624
|
-
|
|
625
|
-
declare function
|
|
626
|
-
declare function activateReferralProgram$1(httpClient: HttpClient$4): () => Promise<ActivateReferralProgramResponse & ActivateReferralProgramResponseNonNullableFields>;
|
|
627
|
-
declare function pauseReferralProgram$1(httpClient: HttpClient$4): () => Promise<PauseReferralProgramResponse & PauseReferralProgramResponseNonNullableFields>;
|
|
628
|
-
declare function getAiSocialMediaPostsSuggestions$1(httpClient: HttpClient$4): (options?: GetAiSocialMediaPostsSuggestionsOptions) => Promise<GetAISocialMediaPostsSuggestionsResponse & GetAISocialMediaPostsSuggestionsResponseNonNullableFields>;
|
|
629
|
-
declare function generateAiSocialMediaPostsSuggestions$1(httpClient: HttpClient$4): (options?: GenerateAiSocialMediaPostsSuggestionsOptions) => Promise<GenerateAISocialMediaPostsSuggestionsResponse & GenerateAISocialMediaPostsSuggestionsResponseNonNullableFields>;
|
|
630
|
-
declare function getReferralProgramPremiumFeatures$1(httpClient: HttpClient$4): () => Promise<GetReferralProgramPremiumFeaturesResponse & GetReferralProgramPremiumFeaturesResponseNonNullableFields>;
|
|
631
|
-
declare const onProgramUpdated$1: EventDefinition$3<ProgramUpdatedEnvelope, "wix.loyalty.referral.v1.program_updated">;
|
|
1463
|
+
declare function createRESTModule$4<T extends RESTFunctionDescriptor>(descriptor: T, elevated?: boolean): BuildRESTFunction<T> & T;
|
|
1464
|
+
|
|
1465
|
+
declare function createEventModule$3<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
632
1466
|
|
|
633
|
-
declare const getReferralProgram:
|
|
634
|
-
declare const queryReferralPrograms:
|
|
635
|
-
declare const updateReferralProgram:
|
|
636
|
-
declare const activateReferralProgram:
|
|
637
|
-
declare const pauseReferralProgram:
|
|
638
|
-
declare const getAiSocialMediaPostsSuggestions:
|
|
639
|
-
declare const generateAiSocialMediaPostsSuggestions:
|
|
640
|
-
declare const getReferralProgramPremiumFeatures:
|
|
641
|
-
declare const onProgramUpdated:
|
|
1467
|
+
declare const getReferralProgram: ReturnType<typeof createRESTModule$4<typeof publicGetReferralProgram>>;
|
|
1468
|
+
declare const queryReferralPrograms: ReturnType<typeof createRESTModule$4<typeof publicQueryReferralPrograms>>;
|
|
1469
|
+
declare const updateReferralProgram: ReturnType<typeof createRESTModule$4<typeof publicUpdateReferralProgram>>;
|
|
1470
|
+
declare const activateReferralProgram: ReturnType<typeof createRESTModule$4<typeof publicActivateReferralProgram>>;
|
|
1471
|
+
declare const pauseReferralProgram: ReturnType<typeof createRESTModule$4<typeof publicPauseReferralProgram>>;
|
|
1472
|
+
declare const getAiSocialMediaPostsSuggestions: ReturnType<typeof createRESTModule$4<typeof publicGetAiSocialMediaPostsSuggestions>>;
|
|
1473
|
+
declare const generateAiSocialMediaPostsSuggestions: ReturnType<typeof createRESTModule$4<typeof publicGenerateAiSocialMediaPostsSuggestions>>;
|
|
1474
|
+
declare const getReferralProgramPremiumFeatures: ReturnType<typeof createRESTModule$4<typeof publicGetReferralProgramPremiumFeatures>>;
|
|
1475
|
+
declare const onProgramUpdated: ReturnType<typeof createEventModule$3<typeof publicOnProgramUpdated>>;
|
|
642
1476
|
|
|
1477
|
+
type context$4_AISocialMediaPostSuggestion = AISocialMediaPostSuggestion;
|
|
1478
|
+
type context$4_Action = Action;
|
|
1479
|
+
declare const context$4_Action: typeof Action;
|
|
1480
|
+
type context$4_ActivateReferralProgramRequest = ActivateReferralProgramRequest;
|
|
1481
|
+
type context$4_ActivateReferralProgramResponse = ActivateReferralProgramResponse;
|
|
1482
|
+
type context$4_ActivateReferralProgramResponseNonNullableFields = ActivateReferralProgramResponseNonNullableFields;
|
|
1483
|
+
type context$4_App = App;
|
|
1484
|
+
declare const context$4_App: typeof App;
|
|
1485
|
+
type context$4_Asset = Asset;
|
|
1486
|
+
type context$4_BillingReference = BillingReference;
|
|
1487
|
+
type context$4_BulkGetReferralProgramRequest = BulkGetReferralProgramRequest;
|
|
1488
|
+
type context$4_BulkGetReferralProgramResponse = BulkGetReferralProgramResponse;
|
|
1489
|
+
type context$4_CancellationDetails = CancellationDetails;
|
|
1490
|
+
type context$4_ContractSwitchReason = ContractSwitchReason;
|
|
1491
|
+
declare const context$4_ContractSwitchReason: typeof ContractSwitchReason;
|
|
1492
|
+
type context$4_ContractSwitchType = ContractSwitchType;
|
|
1493
|
+
declare const context$4_ContractSwitchType: typeof ContractSwitchType;
|
|
1494
|
+
type context$4_ContractSwitched = ContractSwitched;
|
|
1495
|
+
type context$4_Cycle = Cycle;
|
|
1496
|
+
type context$4_CycleCycleSelectorOneOf = CycleCycleSelectorOneOf;
|
|
1497
|
+
type context$4_DeleteContext = DeleteContext;
|
|
1498
|
+
type context$4_DeleteStatus = DeleteStatus;
|
|
1499
|
+
declare const context$4_DeleteStatus: typeof DeleteStatus;
|
|
1500
|
+
type context$4_Emails = Emails;
|
|
1501
|
+
type context$4_GenerateAISocialMediaPostsSuggestionsRequest = GenerateAISocialMediaPostsSuggestionsRequest;
|
|
1502
|
+
type context$4_GenerateAISocialMediaPostsSuggestionsResponse = GenerateAISocialMediaPostsSuggestionsResponse;
|
|
1503
|
+
type context$4_GenerateAISocialMediaPostsSuggestionsResponseNonNullableFields = GenerateAISocialMediaPostsSuggestionsResponseNonNullableFields;
|
|
1504
|
+
type context$4_GenerateAiSocialMediaPostsSuggestionsOptions = GenerateAiSocialMediaPostsSuggestionsOptions;
|
|
1505
|
+
type context$4_GetAISocialMediaPostsSuggestionsRequest = GetAISocialMediaPostsSuggestionsRequest;
|
|
1506
|
+
type context$4_GetAISocialMediaPostsSuggestionsResponse = GetAISocialMediaPostsSuggestionsResponse;
|
|
1507
|
+
type context$4_GetAISocialMediaPostsSuggestionsResponseNonNullableFields = GetAISocialMediaPostsSuggestionsResponseNonNullableFields;
|
|
1508
|
+
type context$4_GetAiSocialMediaPostsSuggestionsOptions = GetAiSocialMediaPostsSuggestionsOptions;
|
|
1509
|
+
type context$4_GetReferralProgramPremiumFeaturesRequest = GetReferralProgramPremiumFeaturesRequest;
|
|
1510
|
+
type context$4_GetReferralProgramPremiumFeaturesResponse = GetReferralProgramPremiumFeaturesResponse;
|
|
1511
|
+
type context$4_GetReferralProgramPremiumFeaturesResponseNonNullableFields = GetReferralProgramPremiumFeaturesResponseNonNullableFields;
|
|
1512
|
+
type context$4_GetReferralProgramRequest = GetReferralProgramRequest;
|
|
1513
|
+
type context$4_GetReferralProgramResponse = GetReferralProgramResponse;
|
|
1514
|
+
type context$4_GetReferralProgramResponseNonNullableFields = GetReferralProgramResponseNonNullableFields;
|
|
1515
|
+
type context$4_HtmlSitePublished = HtmlSitePublished;
|
|
1516
|
+
type context$4_Initiator = Initiator;
|
|
1517
|
+
declare const context$4_Initiator: typeof Initiator;
|
|
1518
|
+
type context$4_Interval = Interval;
|
|
1519
|
+
type context$4_IntervalUnit = IntervalUnit;
|
|
1520
|
+
declare const context$4_IntervalUnit: typeof IntervalUnit;
|
|
1521
|
+
type context$4_MetaSiteSpecialEvent = MetaSiteSpecialEvent;
|
|
1522
|
+
type context$4_MetaSiteSpecialEventPayloadOneOf = MetaSiteSpecialEventPayloadOneOf;
|
|
1523
|
+
type context$4_Namespace = Namespace;
|
|
1524
|
+
declare const context$4_Namespace: typeof Namespace;
|
|
1525
|
+
type context$4_NamespaceChanged = NamespaceChanged;
|
|
1526
|
+
type context$4_OneTime = OneTime;
|
|
1527
|
+
type context$4_Page = Page;
|
|
1528
|
+
type context$4_PauseReferralProgramRequest = PauseReferralProgramRequest;
|
|
1529
|
+
type context$4_PauseReferralProgramResponse = PauseReferralProgramResponse;
|
|
1530
|
+
type context$4_PauseReferralProgramResponseNonNullableFields = PauseReferralProgramResponseNonNullableFields;
|
|
1531
|
+
type context$4_PriceIncreaseTrigger = PriceIncreaseTrigger;
|
|
1532
|
+
declare const context$4_PriceIncreaseTrigger: typeof PriceIncreaseTrigger;
|
|
1533
|
+
type context$4_ProductAdjustment = ProductAdjustment;
|
|
1534
|
+
declare const context$4_ProductAdjustment: typeof ProductAdjustment;
|
|
1535
|
+
type context$4_ProductPriceIncreaseData = ProductPriceIncreaseData;
|
|
1536
|
+
type context$4_ProgramInSite = ProgramInSite;
|
|
1537
|
+
type context$4_ProgramStatus = ProgramStatus;
|
|
1538
|
+
declare const context$4_ProgramStatus: typeof ProgramStatus;
|
|
1539
|
+
type context$4_ProgramUpdatedEnvelope = ProgramUpdatedEnvelope;
|
|
1540
|
+
type context$4_ProviderName = ProviderName;
|
|
1541
|
+
declare const context$4_ProviderName: typeof ProviderName;
|
|
1542
|
+
type context$4_QueryReferralProgramsRequest = QueryReferralProgramsRequest;
|
|
1543
|
+
type context$4_QueryReferralProgramsResponse = QueryReferralProgramsResponse;
|
|
1544
|
+
type context$4_QueryReferralProgramsResponseNonNullableFields = QueryReferralProgramsResponseNonNullableFields;
|
|
1545
|
+
type context$4_ReactivationData = ReactivationData;
|
|
1546
|
+
type context$4_ReactivationReasonEnum = ReactivationReasonEnum;
|
|
1547
|
+
declare const context$4_ReactivationReasonEnum: typeof ReactivationReasonEnum;
|
|
1548
|
+
type context$4_RecurringChargeSucceeded = RecurringChargeSucceeded;
|
|
1549
|
+
type context$4_ReferralProgram = ReferralProgram;
|
|
1550
|
+
type context$4_ReferralProgramsQueryBuilder = ReferralProgramsQueryBuilder;
|
|
1551
|
+
type context$4_ReferralProgramsQueryResult = ReferralProgramsQueryResult;
|
|
1552
|
+
type context$4_RestoreInfo = RestoreInfo;
|
|
1553
|
+
type context$4_ServiceProvisioned = ServiceProvisioned;
|
|
1554
|
+
type context$4_ServiceRemoved = ServiceRemoved;
|
|
1555
|
+
type context$4_SiteCreated = SiteCreated;
|
|
1556
|
+
type context$4_SiteCreatedContext = SiteCreatedContext;
|
|
1557
|
+
declare const context$4_SiteCreatedContext: typeof SiteCreatedContext;
|
|
1558
|
+
type context$4_SiteDeleted = SiteDeleted;
|
|
1559
|
+
type context$4_SiteHardDeleted = SiteHardDeleted;
|
|
1560
|
+
type context$4_SiteMarkedAsTemplate = SiteMarkedAsTemplate;
|
|
1561
|
+
type context$4_SiteMarkedAsWixSite = SiteMarkedAsWixSite;
|
|
1562
|
+
type context$4_SitePublished = SitePublished;
|
|
1563
|
+
type context$4_SiteRenamed = SiteRenamed;
|
|
1564
|
+
type context$4_SiteTransferred = SiteTransferred;
|
|
1565
|
+
type context$4_SiteUndeleted = SiteUndeleted;
|
|
1566
|
+
type context$4_SiteUnpublished = SiteUnpublished;
|
|
1567
|
+
type context$4_State = State;
|
|
1568
|
+
declare const context$4_State: typeof State;
|
|
1569
|
+
type context$4_StudioAssigned = StudioAssigned;
|
|
1570
|
+
type context$4_StudioUnassigned = StudioUnassigned;
|
|
1571
|
+
type context$4_Subscription = Subscription;
|
|
1572
|
+
type context$4_SubscriptionAssigned = SubscriptionAssigned;
|
|
1573
|
+
type context$4_SubscriptionAutoRenewTurnedOff = SubscriptionAutoRenewTurnedOff;
|
|
1574
|
+
type context$4_SubscriptionAutoRenewTurnedOn = SubscriptionAutoRenewTurnedOn;
|
|
1575
|
+
type context$4_SubscriptionCancelled = SubscriptionCancelled;
|
|
1576
|
+
type context$4_SubscriptionCreated = SubscriptionCreated;
|
|
1577
|
+
type context$4_SubscriptionEvent = SubscriptionEvent;
|
|
1578
|
+
type context$4_SubscriptionEventEventOneOf = SubscriptionEventEventOneOf;
|
|
1579
|
+
type context$4_SubscriptionNearEndOfPeriod = SubscriptionNearEndOfPeriod;
|
|
1580
|
+
type context$4_SubscriptionPendingChange = SubscriptionPendingChange;
|
|
1581
|
+
type context$4_SubscriptionStatus = SubscriptionStatus;
|
|
1582
|
+
declare const context$4_SubscriptionStatus: typeof SubscriptionStatus;
|
|
1583
|
+
type context$4_SubscriptionTransferred = SubscriptionTransferred;
|
|
1584
|
+
type context$4_SubscriptionUnassigned = SubscriptionUnassigned;
|
|
1585
|
+
type context$4_UnassignReason = UnassignReason;
|
|
1586
|
+
declare const context$4_UnassignReason: typeof UnassignReason;
|
|
1587
|
+
type context$4_UpdateReferralProgramRequest = UpdateReferralProgramRequest;
|
|
1588
|
+
type context$4_UpdateReferralProgramResponse = UpdateReferralProgramResponse;
|
|
1589
|
+
type context$4_UpdateReferralProgramResponseNonNullableFields = UpdateReferralProgramResponseNonNullableFields;
|
|
643
1590
|
declare const context$4_activateReferralProgram: typeof activateReferralProgram;
|
|
644
1591
|
declare const context$4_generateAiSocialMediaPostsSuggestions: typeof generateAiSocialMediaPostsSuggestions;
|
|
645
1592
|
declare const context$4_getAiSocialMediaPostsSuggestions: typeof getAiSocialMediaPostsSuggestions;
|
|
@@ -650,7 +1597,7 @@ declare const context$4_pauseReferralProgram: typeof pauseReferralProgram;
|
|
|
650
1597
|
declare const context$4_queryReferralPrograms: typeof queryReferralPrograms;
|
|
651
1598
|
declare const context$4_updateReferralProgram: typeof updateReferralProgram;
|
|
652
1599
|
declare namespace context$4 {
|
|
653
|
-
export { context$4_activateReferralProgram as activateReferralProgram, context$4_generateAiSocialMediaPostsSuggestions as generateAiSocialMediaPostsSuggestions, context$4_getAiSocialMediaPostsSuggestions as getAiSocialMediaPostsSuggestions, context$4_getReferralProgram as getReferralProgram, context$4_getReferralProgramPremiumFeatures as getReferralProgramPremiumFeatures, context$4_onProgramUpdated as onProgramUpdated, context$4_pauseReferralProgram as pauseReferralProgram, context$4_queryReferralPrograms as queryReferralPrograms, context$4_updateReferralProgram as updateReferralProgram };
|
|
1600
|
+
export { type context$4_AISocialMediaPostSuggestion as AISocialMediaPostSuggestion, context$4_Action as Action, type ActionEvent$4 as ActionEvent, type context$4_ActivateReferralProgramRequest as ActivateReferralProgramRequest, type context$4_ActivateReferralProgramResponse as ActivateReferralProgramResponse, type context$4_ActivateReferralProgramResponseNonNullableFields as ActivateReferralProgramResponseNonNullableFields, context$4_App as App, type context$4_Asset as Asset, type BaseEventMetadata$3 as BaseEventMetadata, type context$4_BillingReference as BillingReference, type context$4_BulkGetReferralProgramRequest as BulkGetReferralProgramRequest, type context$4_BulkGetReferralProgramResponse as BulkGetReferralProgramResponse, type context$4_CancellationDetails as CancellationDetails, context$4_ContractSwitchReason as ContractSwitchReason, context$4_ContractSwitchType as ContractSwitchType, type context$4_ContractSwitched as ContractSwitched, type Coupon$2 as Coupon, type CouponDiscountTypeOptionsOneOf$2 as CouponDiscountTypeOptionsOneOf, type CouponScope$2 as CouponScope, type CouponScopeOrMinSubtotalOneOf$2 as CouponScopeOrMinSubtotalOneOf, type CursorPaging$4 as CursorPaging, type CursorPagingMetadata$4 as CursorPagingMetadata, type CursorQuery$4 as CursorQuery, type CursorQueryPagingMethodOneOf$4 as CursorQueryPagingMethodOneOf, type Cursors$4 as Cursors, type context$4_Cycle as Cycle, type context$4_CycleCycleSelectorOneOf as CycleCycleSelectorOneOf, type context$4_DeleteContext as DeleteContext, context$4_DeleteStatus as DeleteStatus, DiscountType$2 as DiscountType, type DomainEvent$4 as DomainEvent, type DomainEventBodyOneOf$4 as DomainEventBodyOneOf, type context$4_Emails as Emails, type Empty$3 as Empty, type EntityCreatedEvent$4 as EntityCreatedEvent, type EntityDeletedEvent$4 as EntityDeletedEvent, type EntityUpdatedEvent$4 as EntityUpdatedEvent, type EventMetadata$3 as EventMetadata, type FixedAmountDiscount$2 as FixedAmountDiscount, type context$4_GenerateAISocialMediaPostsSuggestionsRequest as GenerateAISocialMediaPostsSuggestionsRequest, type context$4_GenerateAISocialMediaPostsSuggestionsResponse as GenerateAISocialMediaPostsSuggestionsResponse, type context$4_GenerateAISocialMediaPostsSuggestionsResponseNonNullableFields as GenerateAISocialMediaPostsSuggestionsResponseNonNullableFields, type context$4_GenerateAiSocialMediaPostsSuggestionsOptions as GenerateAiSocialMediaPostsSuggestionsOptions, type context$4_GetAISocialMediaPostsSuggestionsRequest as GetAISocialMediaPostsSuggestionsRequest, type context$4_GetAISocialMediaPostsSuggestionsResponse as GetAISocialMediaPostsSuggestionsResponse, type context$4_GetAISocialMediaPostsSuggestionsResponseNonNullableFields as GetAISocialMediaPostsSuggestionsResponseNonNullableFields, type context$4_GetAiSocialMediaPostsSuggestionsOptions as GetAiSocialMediaPostsSuggestionsOptions, type context$4_GetReferralProgramPremiumFeaturesRequest as GetReferralProgramPremiumFeaturesRequest, type context$4_GetReferralProgramPremiumFeaturesResponse as GetReferralProgramPremiumFeaturesResponse, type context$4_GetReferralProgramPremiumFeaturesResponseNonNullableFields as GetReferralProgramPremiumFeaturesResponseNonNullableFields, type context$4_GetReferralProgramRequest as GetReferralProgramRequest, type context$4_GetReferralProgramResponse as GetReferralProgramResponse, type context$4_GetReferralProgramResponseNonNullableFields as GetReferralProgramResponseNonNullableFields, type Group$2 as Group, type context$4_HtmlSitePublished as HtmlSitePublished, type IdentificationData$4 as IdentificationData, type IdentificationDataIdOneOf$4 as IdentificationDataIdOneOf, context$4_Initiator as Initiator, type context$4_Interval as Interval, context$4_IntervalUnit as IntervalUnit, type LoyaltyPoints$2 as LoyaltyPoints, type MessageEnvelope$4 as MessageEnvelope, type context$4_MetaSiteSpecialEvent as MetaSiteSpecialEvent, type context$4_MetaSiteSpecialEventPayloadOneOf as MetaSiteSpecialEventPayloadOneOf, context$4_Namespace as Namespace, type context$4_NamespaceChanged as NamespaceChanged, type context$4_OneTime as OneTime, type context$4_Page as Page, type context$4_PauseReferralProgramRequest as PauseReferralProgramRequest, type context$4_PauseReferralProgramResponse as PauseReferralProgramResponse, type context$4_PauseReferralProgramResponseNonNullableFields as PauseReferralProgramResponseNonNullableFields, type PercentageDiscount$2 as PercentageDiscount, context$4_PriceIncreaseTrigger as PriceIncreaseTrigger, context$4_ProductAdjustment as ProductAdjustment, type context$4_ProductPriceIncreaseData as ProductPriceIncreaseData, type context$4_ProgramInSite as ProgramInSite, context$4_ProgramStatus as ProgramStatus, type context$4_ProgramUpdatedEnvelope as ProgramUpdatedEnvelope, context$4_ProviderName as ProviderName, type context$4_QueryReferralProgramsRequest as QueryReferralProgramsRequest, type context$4_QueryReferralProgramsResponse as QueryReferralProgramsResponse, type context$4_QueryReferralProgramsResponseNonNullableFields as QueryReferralProgramsResponseNonNullableFields, type context$4_ReactivationData as ReactivationData, context$4_ReactivationReasonEnum as ReactivationReasonEnum, type context$4_RecurringChargeSucceeded as RecurringChargeSucceeded, type context$4_ReferralProgram as ReferralProgram, type context$4_ReferralProgramsQueryBuilder as ReferralProgramsQueryBuilder, type context$4_ReferralProgramsQueryResult as ReferralProgramsQueryResult, type context$4_RestoreInfo as RestoreInfo, type Reward$2 as Reward, type RewardOptionsOneOf$1 as RewardOptionsOneOf, type context$4_ServiceProvisioned as ServiceProvisioned, type context$4_ServiceRemoved as ServiceRemoved, type context$4_SiteCreated as SiteCreated, context$4_SiteCreatedContext as SiteCreatedContext, type context$4_SiteDeleted as SiteDeleted, type context$4_SiteHardDeleted as SiteHardDeleted, type context$4_SiteMarkedAsTemplate as SiteMarkedAsTemplate, type context$4_SiteMarkedAsWixSite as SiteMarkedAsWixSite, type context$4_SitePublished as SitePublished, type context$4_SiteRenamed as SiteRenamed, type context$4_SiteTransferred as SiteTransferred, type context$4_SiteUndeleted as SiteUndeleted, type context$4_SiteUnpublished as SiteUnpublished, SortOrder$4 as SortOrder, type Sorting$4 as Sorting, context$4_State as State, type context$4_StudioAssigned as StudioAssigned, type context$4_StudioUnassigned as StudioUnassigned, type context$4_Subscription as Subscription, type context$4_SubscriptionAssigned as SubscriptionAssigned, type context$4_SubscriptionAutoRenewTurnedOff as SubscriptionAutoRenewTurnedOff, type context$4_SubscriptionAutoRenewTurnedOn as SubscriptionAutoRenewTurnedOn, type context$4_SubscriptionCancelled as SubscriptionCancelled, type context$4_SubscriptionCreated as SubscriptionCreated, type context$4_SubscriptionEvent as SubscriptionEvent, type context$4_SubscriptionEventEventOneOf as SubscriptionEventEventOneOf, type context$4_SubscriptionNearEndOfPeriod as SubscriptionNearEndOfPeriod, type context$4_SubscriptionPendingChange as SubscriptionPendingChange, context$4_SubscriptionStatus as SubscriptionStatus, type context$4_SubscriptionTransferred as SubscriptionTransferred, type context$4_SubscriptionUnassigned as SubscriptionUnassigned, Type$1 as Type, context$4_UnassignReason as UnassignReason, type context$4_UpdateReferralProgramRequest as UpdateReferralProgramRequest, type context$4_UpdateReferralProgramResponse as UpdateReferralProgramResponse, type context$4_UpdateReferralProgramResponseNonNullableFields as UpdateReferralProgramResponseNonNullableFields, WebhookIdentityType$4 as WebhookIdentityType, context$4_activateReferralProgram as activateReferralProgram, context$4_generateAiSocialMediaPostsSuggestions as generateAiSocialMediaPostsSuggestions, context$4_getAiSocialMediaPostsSuggestions as getAiSocialMediaPostsSuggestions, context$4_getReferralProgram as getReferralProgram, context$4_getReferralProgramPremiumFeatures as getReferralProgramPremiumFeatures, context$4_onProgramUpdated as onProgramUpdated, context$4_pauseReferralProgram as pauseReferralProgram, context$4_queryReferralPrograms as queryReferralPrograms, context$4_updateReferralProgram as updateReferralProgram };
|
|
654
1601
|
}
|
|
655
1602
|
|
|
656
1603
|
/** ReferralEvent. */
|
|
@@ -736,7 +1683,7 @@ interface RewardEvent extends RewardEventReceiverOneOf {
|
|
|
736
1683
|
/** The referral reward ID. */
|
|
737
1684
|
referralRewardId?: string;
|
|
738
1685
|
/** The reward type. */
|
|
739
|
-
rewardType?: Reward;
|
|
1686
|
+
rewardType?: Reward$1;
|
|
740
1687
|
}
|
|
741
1688
|
/** @oneof */
|
|
742
1689
|
interface RewardEventReceiverOneOf {
|
|
@@ -751,7 +1698,7 @@ interface RewardEventReceiverOneOf {
|
|
|
751
1698
|
*/
|
|
752
1699
|
rewardedReferredFriendId?: string;
|
|
753
1700
|
}
|
|
754
|
-
declare enum Reward {
|
|
1701
|
+
declare enum Reward$1 {
|
|
755
1702
|
/** Unknown reward type. */
|
|
756
1703
|
UNKNOWN = "UNKNOWN",
|
|
757
1704
|
/** Reward is a coupon. */
|
|
@@ -761,9 +1708,29 @@ declare enum Reward {
|
|
|
761
1708
|
/** No reward. */
|
|
762
1709
|
NOTHING = "NOTHING"
|
|
763
1710
|
}
|
|
764
|
-
interface
|
|
1711
|
+
interface CreateReferralEventRequest {
|
|
1712
|
+
/** ReferralEvent to be created */
|
|
1713
|
+
referralEvent?: ReferralEvent;
|
|
1714
|
+
}
|
|
1715
|
+
interface CreateReferralEventResponse {
|
|
1716
|
+
/** The created ReferralEvent */
|
|
1717
|
+
referralEvent?: ReferralEvent;
|
|
1718
|
+
}
|
|
1719
|
+
interface GetReferralEventRequest {
|
|
1720
|
+
/** Id of the ReferralEvent to retrieve */
|
|
1721
|
+
referralEventId: string;
|
|
1722
|
+
}
|
|
1723
|
+
interface GetReferralEventResponse {
|
|
1724
|
+
/** The retrieved ReferralEvent */
|
|
1725
|
+
referralEvent?: ReferralEvent;
|
|
1726
|
+
}
|
|
1727
|
+
interface QueryReferralEventRequest {
|
|
1728
|
+
/** Query to filter ReferralEvents. */
|
|
1729
|
+
query: CursorQuery$3;
|
|
1730
|
+
}
|
|
1731
|
+
interface CursorQuery$3 extends CursorQueryPagingMethodOneOf$3 {
|
|
765
1732
|
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
766
|
-
cursorPaging?: CursorPaging$
|
|
1733
|
+
cursorPaging?: CursorPaging$3;
|
|
767
1734
|
/**
|
|
768
1735
|
* Filter object in the following format:
|
|
769
1736
|
* `"filter" : {
|
|
@@ -777,24 +1744,24 @@ interface CursorQuery$1 extends CursorQueryPagingMethodOneOf$1 {
|
|
|
777
1744
|
* Sort object in the following format:
|
|
778
1745
|
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
779
1746
|
*/
|
|
780
|
-
sort?: Sorting$
|
|
1747
|
+
sort?: Sorting$3[];
|
|
781
1748
|
}
|
|
782
1749
|
/** @oneof */
|
|
783
|
-
interface CursorQueryPagingMethodOneOf$
|
|
1750
|
+
interface CursorQueryPagingMethodOneOf$3 {
|
|
784
1751
|
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
785
|
-
cursorPaging?: CursorPaging$
|
|
1752
|
+
cursorPaging?: CursorPaging$3;
|
|
786
1753
|
}
|
|
787
|
-
interface Sorting$
|
|
1754
|
+
interface Sorting$3 {
|
|
788
1755
|
/** Name of the field to sort by. */
|
|
789
1756
|
fieldName?: string;
|
|
790
1757
|
/** Sort order. */
|
|
791
|
-
order?: SortOrder$
|
|
1758
|
+
order?: SortOrder$3;
|
|
792
1759
|
}
|
|
793
|
-
declare enum SortOrder$
|
|
1760
|
+
declare enum SortOrder$3 {
|
|
794
1761
|
ASC = "ASC",
|
|
795
1762
|
DESC = "DESC"
|
|
796
1763
|
}
|
|
797
|
-
interface CursorPaging$
|
|
1764
|
+
interface CursorPaging$3 {
|
|
798
1765
|
/** Maximum number of items to return in the results. */
|
|
799
1766
|
limit?: number | null;
|
|
800
1767
|
/**
|
|
@@ -805,7 +1772,13 @@ interface CursorPaging$1 {
|
|
|
805
1772
|
*/
|
|
806
1773
|
cursor?: string | null;
|
|
807
1774
|
}
|
|
808
|
-
interface
|
|
1775
|
+
interface QueryReferralEventResponse {
|
|
1776
|
+
/** List of ReferralEvents that match the query. */
|
|
1777
|
+
referralEvents?: ReferralEvent[];
|
|
1778
|
+
/** Paging metadata. */
|
|
1779
|
+
metadata?: CursorPagingMetadata$3;
|
|
1780
|
+
}
|
|
1781
|
+
interface CursorPagingMetadata$3 {
|
|
809
1782
|
/** Number of items returned in the response. */
|
|
810
1783
|
count?: number | null;
|
|
811
1784
|
/** Cursor strings that point to the next page, previous page, or both. */
|
|
@@ -824,6 +1797,8 @@ interface Cursors$3 {
|
|
|
824
1797
|
/** Cursor pointing to the previous page in the list of results. */
|
|
825
1798
|
prev?: string | null;
|
|
826
1799
|
}
|
|
1800
|
+
interface GetReferralStatisticsRequest {
|
|
1801
|
+
}
|
|
827
1802
|
interface GetReferralStatisticsResponse {
|
|
828
1803
|
/** Total sign ups completed by referred friends */
|
|
829
1804
|
totalSignUpsCompleted?: number;
|
|
@@ -832,11 +1807,17 @@ interface GetReferralStatisticsResponse {
|
|
|
832
1807
|
/** Total amount of purchases made by referred friends */
|
|
833
1808
|
totalAmountGenerated?: string;
|
|
834
1809
|
}
|
|
1810
|
+
interface QueryReferringCustomerTotalsRequest {
|
|
1811
|
+
/** Query to filter ReferringCustomerTotals. */
|
|
1812
|
+
query?: CursorQuery$3;
|
|
1813
|
+
/** List of contact ids to filter ReferringCustomerTotals. */
|
|
1814
|
+
contactIds?: string[];
|
|
1815
|
+
}
|
|
835
1816
|
interface QueryReferringCustomerTotalsResponse {
|
|
836
1817
|
/** List of ReferringCustomerTotals that match the query. */
|
|
837
1818
|
referringCustomerTotals?: ReferringCustomerTotal[];
|
|
838
1819
|
/** Paging metadata. */
|
|
839
|
-
metadata?: CursorPagingMetadata$
|
|
1820
|
+
metadata?: CursorPagingMetadata$3;
|
|
840
1821
|
}
|
|
841
1822
|
interface ReferringCustomerTotal {
|
|
842
1823
|
/**
|
|
@@ -875,17 +1856,23 @@ interface ReferringCustomerTotal {
|
|
|
875
1856
|
*/
|
|
876
1857
|
totalFriendsWithActions?: number;
|
|
877
1858
|
}
|
|
1859
|
+
interface QueryReferredFriendActionsRequest {
|
|
1860
|
+
/** Query to filter ReferredFriendActions. */
|
|
1861
|
+
query?: CursorQuery$3;
|
|
1862
|
+
/** List of contact ids to filter ReferredFriendActions. */
|
|
1863
|
+
contactIds?: string[];
|
|
1864
|
+
}
|
|
878
1865
|
interface QueryReferredFriendActionsResponse {
|
|
879
1866
|
/** List of ReferredFriendActions that match the query. */
|
|
880
1867
|
referredFriendActions?: ReferredFriendAction[];
|
|
881
1868
|
/** Paging metadata. */
|
|
882
|
-
metadata?: CursorPagingMetadata$
|
|
1869
|
+
metadata?: CursorPagingMetadata$3;
|
|
883
1870
|
}
|
|
884
1871
|
interface ReferredFriendAction extends ReferredFriendActionRewardTypeOptionsOneOf {
|
|
885
1872
|
/** Coupon reward type options. */
|
|
886
1873
|
coupon?: V1Coupon$1;
|
|
887
1874
|
/** Loyalty points reward type options. */
|
|
888
|
-
loyaltyPoints?: LoyaltyPoints;
|
|
1875
|
+
loyaltyPoints?: LoyaltyPoints$1;
|
|
889
1876
|
/**
|
|
890
1877
|
* Referred friend id.
|
|
891
1878
|
* @readonly
|
|
@@ -907,7 +1894,7 @@ interface ReferredFriendAction extends ReferredFriendActionRewardTypeOptionsOneO
|
|
|
907
1894
|
*/
|
|
908
1895
|
actionDate?: Date;
|
|
909
1896
|
/** Issued reward type. */
|
|
910
|
-
rewardType?: Reward;
|
|
1897
|
+
rewardType?: Reward$1;
|
|
911
1898
|
/** Total number of actions. */
|
|
912
1899
|
totalActions?: number;
|
|
913
1900
|
/**
|
|
@@ -926,7 +1913,7 @@ interface ReferredFriendActionRewardTypeOptionsOneOf {
|
|
|
926
1913
|
/** Coupon reward type options. */
|
|
927
1914
|
coupon?: V1Coupon$1;
|
|
928
1915
|
/** Loyalty points reward type options. */
|
|
929
|
-
loyaltyPoints?: LoyaltyPoints;
|
|
1916
|
+
loyaltyPoints?: LoyaltyPoints$1;
|
|
930
1917
|
}
|
|
931
1918
|
interface V1Coupon$1 {
|
|
932
1919
|
/**
|
|
@@ -1024,7 +2011,7 @@ interface Group$1 {
|
|
|
1024
2011
|
/** Entity ID of the group. */
|
|
1025
2012
|
entityId?: string | null;
|
|
1026
2013
|
}
|
|
1027
|
-
interface LoyaltyPoints {
|
|
2014
|
+
interface LoyaltyPoints$1 {
|
|
1028
2015
|
/**
|
|
1029
2016
|
* Loyalty transaction ID.
|
|
1030
2017
|
* @readonly
|
|
@@ -1036,7 +2023,128 @@ interface LoyaltyPoints {
|
|
|
1036
2023
|
*/
|
|
1037
2024
|
amount?: number;
|
|
1038
2025
|
}
|
|
1039
|
-
interface
|
|
2026
|
+
interface DomainEvent$3 extends DomainEventBodyOneOf$3 {
|
|
2027
|
+
createdEvent?: EntityCreatedEvent$3;
|
|
2028
|
+
updatedEvent?: EntityUpdatedEvent$3;
|
|
2029
|
+
deletedEvent?: EntityDeletedEvent$3;
|
|
2030
|
+
actionEvent?: ActionEvent$3;
|
|
2031
|
+
/**
|
|
2032
|
+
* Unique event ID.
|
|
2033
|
+
* Allows clients to ignore duplicate webhooks.
|
|
2034
|
+
*/
|
|
2035
|
+
_id?: string;
|
|
2036
|
+
/**
|
|
2037
|
+
* Assumes actions are also always typed to an entity_type
|
|
2038
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
2039
|
+
*/
|
|
2040
|
+
entityFqdn?: string;
|
|
2041
|
+
/**
|
|
2042
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
2043
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
2044
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
2045
|
+
*/
|
|
2046
|
+
slug?: string;
|
|
2047
|
+
/** ID of the entity associated with the event. */
|
|
2048
|
+
entityId?: string;
|
|
2049
|
+
/** Event timestamp. */
|
|
2050
|
+
eventTime?: Date;
|
|
2051
|
+
/**
|
|
2052
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
2053
|
+
* (for example, GDPR).
|
|
2054
|
+
*/
|
|
2055
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
2056
|
+
/** If present, indicates the action that triggered the event. */
|
|
2057
|
+
originatedFrom?: string | null;
|
|
2058
|
+
/**
|
|
2059
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
2060
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
2061
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
2062
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
2063
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
2064
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
2065
|
+
*/
|
|
2066
|
+
entityEventSequence?: string | null;
|
|
2067
|
+
}
|
|
2068
|
+
/** @oneof */
|
|
2069
|
+
interface DomainEventBodyOneOf$3 {
|
|
2070
|
+
createdEvent?: EntityCreatedEvent$3;
|
|
2071
|
+
updatedEvent?: EntityUpdatedEvent$3;
|
|
2072
|
+
deletedEvent?: EntityDeletedEvent$3;
|
|
2073
|
+
actionEvent?: ActionEvent$3;
|
|
2074
|
+
}
|
|
2075
|
+
interface EntityCreatedEvent$3 {
|
|
2076
|
+
entity?: string;
|
|
2077
|
+
}
|
|
2078
|
+
interface UndeleteInfo$3 {
|
|
2079
|
+
deletedDate?: Date;
|
|
2080
|
+
}
|
|
2081
|
+
interface EntityUpdatedEvent$3 {
|
|
2082
|
+
/**
|
|
2083
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
2084
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
2085
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
2086
|
+
*/
|
|
2087
|
+
currentEntity?: string;
|
|
2088
|
+
}
|
|
2089
|
+
interface EntityDeletedEvent$3 {
|
|
2090
|
+
/** Entity that was deleted */
|
|
2091
|
+
deletedEntity?: string | null;
|
|
2092
|
+
}
|
|
2093
|
+
interface ActionEvent$3 {
|
|
2094
|
+
body?: string;
|
|
2095
|
+
}
|
|
2096
|
+
interface Empty$2 {
|
|
2097
|
+
}
|
|
2098
|
+
interface SuccessfulReferralEvent$2 {
|
|
2099
|
+
/** ReferredFriend that completed his referral details. */
|
|
2100
|
+
referredFriendDetails?: ReferredFriendDetails$2;
|
|
2101
|
+
}
|
|
2102
|
+
interface ReferredFriendDetails$2 {
|
|
2103
|
+
/**
|
|
2104
|
+
* ReferredFriend ID.
|
|
2105
|
+
* @readonly
|
|
2106
|
+
*/
|
|
2107
|
+
referredFriendId?: string;
|
|
2108
|
+
/**
|
|
2109
|
+
* ReferredFriend Contact ID.
|
|
2110
|
+
* @readonly
|
|
2111
|
+
*/
|
|
2112
|
+
contactId?: string;
|
|
2113
|
+
/**
|
|
2114
|
+
* Customer who referred this ReferredFriend.
|
|
2115
|
+
* @readonly
|
|
2116
|
+
*/
|
|
2117
|
+
referringCustomerId?: string;
|
|
2118
|
+
}
|
|
2119
|
+
interface ReferredFriendActionEvent {
|
|
2120
|
+
/** ReferredFriend details. */
|
|
2121
|
+
referredFriendDetails?: ReferredFriendDetails$2;
|
|
2122
|
+
/** Trigger details. */
|
|
2123
|
+
trigger?: Trigger;
|
|
2124
|
+
/** Amount. */
|
|
2125
|
+
amount?: string | null;
|
|
2126
|
+
/** Currency. */
|
|
2127
|
+
currency?: string | null;
|
|
2128
|
+
/** Order ID. */
|
|
2129
|
+
orderId?: string | null;
|
|
2130
|
+
}
|
|
2131
|
+
interface Trigger {
|
|
2132
|
+
/** App ID. */
|
|
2133
|
+
appId?: string;
|
|
2134
|
+
/** Activity type. */
|
|
2135
|
+
activityType?: string;
|
|
2136
|
+
}
|
|
2137
|
+
interface MessageEnvelope$3 {
|
|
2138
|
+
/** App instance ID. */
|
|
2139
|
+
instanceId?: string | null;
|
|
2140
|
+
/** Event type. */
|
|
2141
|
+
eventType?: string;
|
|
2142
|
+
/** The identification type and identity data. */
|
|
2143
|
+
identity?: IdentificationData$3;
|
|
2144
|
+
/** Stringify payload. */
|
|
2145
|
+
data?: string;
|
|
2146
|
+
}
|
|
2147
|
+
interface IdentificationData$3 extends IdentificationDataIdOneOf$3 {
|
|
1040
2148
|
/** ID of a site visitor that has not logged in to the site. */
|
|
1041
2149
|
anonymousVisitorId?: string;
|
|
1042
2150
|
/** ID of a site visitor that has logged in to the site. */
|
|
@@ -1046,10 +2154,10 @@ interface IdentificationData$2 extends IdentificationDataIdOneOf$2 {
|
|
|
1046
2154
|
/** ID of an app. */
|
|
1047
2155
|
appId?: string;
|
|
1048
2156
|
/** @readonly */
|
|
1049
|
-
identityType?: WebhookIdentityType$
|
|
2157
|
+
identityType?: WebhookIdentityType$3;
|
|
1050
2158
|
}
|
|
1051
2159
|
/** @oneof */
|
|
1052
|
-
interface IdentificationDataIdOneOf$
|
|
2160
|
+
interface IdentificationDataIdOneOf$3 {
|
|
1053
2161
|
/** ID of a site visitor that has not logged in to the site. */
|
|
1054
2162
|
anonymousVisitorId?: string;
|
|
1055
2163
|
/** ID of a site visitor that has logged in to the site. */
|
|
@@ -1059,65 +2167,105 @@ interface IdentificationDataIdOneOf$2 {
|
|
|
1059
2167
|
/** ID of an app. */
|
|
1060
2168
|
appId?: string;
|
|
1061
2169
|
}
|
|
1062
|
-
declare enum WebhookIdentityType$
|
|
2170
|
+
declare enum WebhookIdentityType$3 {
|
|
1063
2171
|
UNKNOWN = "UNKNOWN",
|
|
1064
2172
|
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
1065
2173
|
MEMBER = "MEMBER",
|
|
1066
2174
|
WIX_USER = "WIX_USER",
|
|
1067
2175
|
APP = "APP"
|
|
1068
2176
|
}
|
|
2177
|
+
interface ReferredFriendSignupEventNonNullableFields {
|
|
2178
|
+
referredFriendId: string;
|
|
2179
|
+
}
|
|
2180
|
+
interface V1SuccessfulReferralEventNonNullableFields {
|
|
2181
|
+
referredFriendId: string;
|
|
2182
|
+
referringCustomerId: string;
|
|
2183
|
+
}
|
|
2184
|
+
interface V1TriggerNonNullableFields {
|
|
2185
|
+
appId: string;
|
|
2186
|
+
activityType: string;
|
|
2187
|
+
}
|
|
2188
|
+
interface V1ActionEventNonNullableFields {
|
|
2189
|
+
referredFriendId: string;
|
|
2190
|
+
referringCustomerId: string;
|
|
2191
|
+
trigger?: V1TriggerNonNullableFields;
|
|
2192
|
+
}
|
|
2193
|
+
interface RewardEventNonNullableFields {
|
|
2194
|
+
rewardedReferringCustomerId: string;
|
|
2195
|
+
rewardedReferredFriendId: string;
|
|
2196
|
+
referralRewardId: string;
|
|
2197
|
+
rewardType: Reward$1;
|
|
2198
|
+
}
|
|
2199
|
+
interface ReferralEventNonNullableFields {
|
|
2200
|
+
referredFriendSignupEvent?: ReferredFriendSignupEventNonNullableFields;
|
|
2201
|
+
successfulReferralEvent?: V1SuccessfulReferralEventNonNullableFields;
|
|
2202
|
+
actionEvent?: V1ActionEventNonNullableFields;
|
|
2203
|
+
rewardEvent?: RewardEventNonNullableFields;
|
|
2204
|
+
}
|
|
2205
|
+
interface GetReferralEventResponseNonNullableFields {
|
|
2206
|
+
referralEvent?: ReferralEventNonNullableFields;
|
|
2207
|
+
}
|
|
2208
|
+
interface QueryReferralEventResponseNonNullableFields {
|
|
2209
|
+
referralEvents: ReferralEventNonNullableFields[];
|
|
2210
|
+
}
|
|
1069
2211
|
interface GetReferralStatisticsResponseNonNullableFields {
|
|
1070
2212
|
totalSignUpsCompleted: number;
|
|
1071
2213
|
totalActionsCompleted: number;
|
|
1072
2214
|
totalAmountGenerated: string;
|
|
1073
2215
|
}
|
|
2216
|
+
interface ReferringCustomerTotalNonNullableFields {
|
|
2217
|
+
referringCustomerId: string;
|
|
2218
|
+
contactId: string;
|
|
2219
|
+
totalSuccessfulReferrals: number;
|
|
2220
|
+
totalAmountGenerated: string;
|
|
2221
|
+
totalFriendsWithActions: number;
|
|
2222
|
+
}
|
|
1074
2223
|
interface QueryReferringCustomerTotalsResponseNonNullableFields {
|
|
1075
|
-
referringCustomerTotals:
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
2224
|
+
referringCustomerTotals: ReferringCustomerTotalNonNullableFields[];
|
|
2225
|
+
}
|
|
2226
|
+
interface FixedAmountDiscountNonNullableFields$1 {
|
|
2227
|
+
amount: number;
|
|
2228
|
+
}
|
|
2229
|
+
interface PercentageDiscountNonNullableFields$1 {
|
|
2230
|
+
percentage: number;
|
|
2231
|
+
}
|
|
2232
|
+
interface GroupNonNullableFields$1 {
|
|
2233
|
+
name: string;
|
|
2234
|
+
}
|
|
2235
|
+
interface CouponScopeNonNullableFields$1 {
|
|
2236
|
+
namespace: string;
|
|
2237
|
+
group?: GroupNonNullableFields$1;
|
|
2238
|
+
}
|
|
2239
|
+
interface CouponNonNullableFields$1 {
|
|
2240
|
+
fixedAmountOptions?: FixedAmountDiscountNonNullableFields$1;
|
|
2241
|
+
percentageOptions?: PercentageDiscountNonNullableFields$1;
|
|
2242
|
+
minimumSubtotal: number;
|
|
2243
|
+
scope?: CouponScopeNonNullableFields$1;
|
|
2244
|
+
name: string;
|
|
2245
|
+
discountType: DiscountType$1;
|
|
2246
|
+
}
|
|
2247
|
+
interface V1CouponNonNullableFields$1 {
|
|
2248
|
+
_id: string;
|
|
2249
|
+
code: string;
|
|
2250
|
+
status: Status$2;
|
|
2251
|
+
couponSpecification?: CouponNonNullableFields$1;
|
|
2252
|
+
}
|
|
2253
|
+
interface LoyaltyPointsNonNullableFields {
|
|
2254
|
+
transactionId: string;
|
|
2255
|
+
amount: number;
|
|
2256
|
+
}
|
|
2257
|
+
interface ReferredFriendActionNonNullableFields {
|
|
2258
|
+
coupon?: V1CouponNonNullableFields$1;
|
|
2259
|
+
loyaltyPoints?: LoyaltyPointsNonNullableFields;
|
|
2260
|
+
referredFriendId: string;
|
|
2261
|
+
contactId: string;
|
|
2262
|
+
trigger?: V1TriggerNonNullableFields;
|
|
2263
|
+
rewardType: Reward$1;
|
|
2264
|
+
totalActions: number;
|
|
2265
|
+
totalAmountSpent: string;
|
|
1082
2266
|
}
|
|
1083
2267
|
interface QueryReferredFriendActionsResponseNonNullableFields {
|
|
1084
|
-
referredFriendActions:
|
|
1085
|
-
coupon?: {
|
|
1086
|
-
_id: string;
|
|
1087
|
-
code: string;
|
|
1088
|
-
status: Status$2;
|
|
1089
|
-
couponSpecification?: {
|
|
1090
|
-
fixedAmountOptions?: {
|
|
1091
|
-
amount: number;
|
|
1092
|
-
};
|
|
1093
|
-
percentageOptions?: {
|
|
1094
|
-
percentage: number;
|
|
1095
|
-
};
|
|
1096
|
-
minimumSubtotal: number;
|
|
1097
|
-
scope?: {
|
|
1098
|
-
namespace: string;
|
|
1099
|
-
group?: {
|
|
1100
|
-
name: string;
|
|
1101
|
-
};
|
|
1102
|
-
};
|
|
1103
|
-
name: string;
|
|
1104
|
-
discountType: DiscountType$1;
|
|
1105
|
-
};
|
|
1106
|
-
};
|
|
1107
|
-
loyaltyPoints?: {
|
|
1108
|
-
transactionId: string;
|
|
1109
|
-
amount: number;
|
|
1110
|
-
};
|
|
1111
|
-
referredFriendId: string;
|
|
1112
|
-
contactId: string;
|
|
1113
|
-
trigger?: {
|
|
1114
|
-
appId: string;
|
|
1115
|
-
activityType: string;
|
|
1116
|
-
};
|
|
1117
|
-
rewardType: Reward;
|
|
1118
|
-
totalActions: number;
|
|
1119
|
-
totalAmountSpent: string;
|
|
1120
|
-
}[];
|
|
2268
|
+
referredFriendActions: ReferredFriendActionNonNullableFields[];
|
|
1121
2269
|
}
|
|
1122
2270
|
interface BaseEventMetadata$2 {
|
|
1123
2271
|
/** App instance ID. */
|
|
@@ -1125,7 +2273,7 @@ interface BaseEventMetadata$2 {
|
|
|
1125
2273
|
/** Event type. */
|
|
1126
2274
|
eventType?: string;
|
|
1127
2275
|
/** The identification type and identity data. */
|
|
1128
|
-
identity?: IdentificationData$
|
|
2276
|
+
identity?: IdentificationData$3;
|
|
1129
2277
|
}
|
|
1130
2278
|
interface EventMetadata$2 extends BaseEventMetadata$2 {
|
|
1131
2279
|
/**
|
|
@@ -1243,96 +2391,64 @@ interface ReferralEventsQueryBuilder {
|
|
|
1243
2391
|
}
|
|
1244
2392
|
interface QueryReferringCustomerTotalsOptions {
|
|
1245
2393
|
/** Query to filter ReferringCustomerTotals. */
|
|
1246
|
-
query?: CursorQuery$
|
|
2394
|
+
query?: CursorQuery$3;
|
|
1247
2395
|
/** List of contact ids to filter ReferringCustomerTotals. */
|
|
1248
2396
|
contactIds?: string[];
|
|
1249
2397
|
}
|
|
1250
2398
|
interface QueryReferredFriendActionsOptions {
|
|
1251
2399
|
/** Query to filter ReferredFriendActions. */
|
|
1252
|
-
query?: CursorQuery$
|
|
2400
|
+
query?: CursorQuery$3;
|
|
1253
2401
|
/** List of contact ids to filter ReferredFriendActions. */
|
|
1254
2402
|
contactIds?: string[];
|
|
1255
2403
|
}
|
|
1256
2404
|
|
|
1257
|
-
|
|
1258
|
-
interface HttpClient$3 {
|
|
1259
|
-
request<TResponse, TData = any>(req: RequestOptionsFactory$3<TResponse, TData>): Promise<HttpResponse$3<TResponse>>;
|
|
1260
|
-
fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
|
|
1261
|
-
}
|
|
1262
|
-
type RequestOptionsFactory$3<TResponse = any, TData = any> = (context: any) => RequestOptions$3<TResponse, TData>;
|
|
1263
|
-
type HttpResponse$3<T = any> = {
|
|
1264
|
-
data: T;
|
|
1265
|
-
status: number;
|
|
1266
|
-
statusText: string;
|
|
1267
|
-
headers: any;
|
|
1268
|
-
request?: any;
|
|
1269
|
-
};
|
|
1270
|
-
type RequestOptions$3<_TResponse = any, Data = any> = {
|
|
1271
|
-
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
1272
|
-
url: string;
|
|
1273
|
-
data?: Data;
|
|
1274
|
-
params?: URLSearchParams;
|
|
1275
|
-
} & APIMetadata$3;
|
|
1276
|
-
type APIMetadata$3 = {
|
|
1277
|
-
methodFqn?: string;
|
|
1278
|
-
entityFqdn?: string;
|
|
1279
|
-
packageName?: string;
|
|
1280
|
-
};
|
|
1281
|
-
type BuildRESTFunction$3<T extends RESTFunctionDescriptor$3> = T extends RESTFunctionDescriptor$3<infer U> ? U : never;
|
|
1282
|
-
type EventDefinition$2<Payload = unknown, Type extends string = string> = {
|
|
1283
|
-
__type: 'event-definition';
|
|
1284
|
-
type: Type;
|
|
1285
|
-
isDomainEvent?: boolean;
|
|
1286
|
-
transformations?: (envelope: unknown) => Payload;
|
|
1287
|
-
__payload: Payload;
|
|
1288
|
-
};
|
|
1289
|
-
declare function EventDefinition$2<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$2<Payload, Type>;
|
|
1290
|
-
type EventHandler$2<T extends EventDefinition$2> = (payload: T['__payload']) => void | Promise<void>;
|
|
1291
|
-
type BuildEventDefinition$2<T extends EventDefinition$2<any, string>> = (handler: EventHandler$2<T>) => void;
|
|
1292
|
-
|
|
1293
|
-
declare global {
|
|
1294
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
1295
|
-
interface SymbolConstructor {
|
|
1296
|
-
readonly observable: symbol;
|
|
1297
|
-
}
|
|
1298
|
-
}
|
|
2405
|
+
declare function createRESTModule$3<T extends RESTFunctionDescriptor>(descriptor: T, elevated?: boolean): BuildRESTFunction<T> & T;
|
|
1299
2406
|
|
|
1300
|
-
declare function
|
|
1301
|
-
referredFriendSignupEvent?: {
|
|
1302
|
-
referredFriendId: string;
|
|
1303
|
-
} | undefined;
|
|
1304
|
-
successfulReferralEvent?: {
|
|
1305
|
-
referredFriendId: string;
|
|
1306
|
-
referringCustomerId: string;
|
|
1307
|
-
} | undefined;
|
|
1308
|
-
actionEvent?: {
|
|
1309
|
-
referredFriendId: string;
|
|
1310
|
-
referringCustomerId: string;
|
|
1311
|
-
trigger?: {
|
|
1312
|
-
appId: string;
|
|
1313
|
-
activityType: string;
|
|
1314
|
-
} | undefined;
|
|
1315
|
-
} | undefined;
|
|
1316
|
-
rewardEvent?: {
|
|
1317
|
-
rewardedReferringCustomerId: string;
|
|
1318
|
-
rewardedReferredFriendId: string;
|
|
1319
|
-
referralRewardId: string;
|
|
1320
|
-
rewardType: Reward;
|
|
1321
|
-
} | undefined;
|
|
1322
|
-
}>;
|
|
1323
|
-
declare function queryReferralEvent$1(httpClient: HttpClient$3): () => ReferralEventsQueryBuilder;
|
|
1324
|
-
declare function getReferralStatistics$1(httpClient: HttpClient$3): () => Promise<GetReferralStatisticsResponse & GetReferralStatisticsResponseNonNullableFields>;
|
|
1325
|
-
declare function queryReferringCustomerTotals$1(httpClient: HttpClient$3): (options?: QueryReferringCustomerTotalsOptions) => Promise<QueryReferringCustomerTotalsResponse & QueryReferringCustomerTotalsResponseNonNullableFields>;
|
|
1326
|
-
declare function queryReferredFriendActions$1(httpClient: HttpClient$3): (options?: QueryReferredFriendActionsOptions) => Promise<QueryReferredFriendActionsResponse & QueryReferredFriendActionsResponseNonNullableFields>;
|
|
1327
|
-
declare const onReferralEventCreated$1: EventDefinition$2<ReferralEventCreatedEnvelope, "wix.loyalty.referral.v1.referral_event_created">;
|
|
2407
|
+
declare function createEventModule$2<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
1328
2408
|
|
|
1329
|
-
declare const getReferralEvent:
|
|
1330
|
-
declare const queryReferralEvent:
|
|
1331
|
-
declare const getReferralStatistics:
|
|
1332
|
-
declare const queryReferringCustomerTotals:
|
|
1333
|
-
declare const queryReferredFriendActions:
|
|
1334
|
-
declare const onReferralEventCreated:
|
|
2409
|
+
declare const getReferralEvent: ReturnType<typeof createRESTModule$3<typeof publicGetReferralEvent>>;
|
|
2410
|
+
declare const queryReferralEvent: ReturnType<typeof createRESTModule$3<typeof publicQueryReferralEvent>>;
|
|
2411
|
+
declare const getReferralStatistics: ReturnType<typeof createRESTModule$3<typeof publicGetReferralStatistics>>;
|
|
2412
|
+
declare const queryReferringCustomerTotals: ReturnType<typeof createRESTModule$3<typeof publicQueryReferringCustomerTotals>>;
|
|
2413
|
+
declare const queryReferredFriendActions: ReturnType<typeof createRESTModule$3<typeof publicQueryReferredFriendActions>>;
|
|
2414
|
+
declare const onReferralEventCreated: ReturnType<typeof createEventModule$2<typeof publicOnReferralEventCreated>>;
|
|
1335
2415
|
|
|
2416
|
+
type context$3_CreateReferralEventRequest = CreateReferralEventRequest;
|
|
2417
|
+
type context$3_CreateReferralEventResponse = CreateReferralEventResponse;
|
|
2418
|
+
type context$3_GetReferralEventRequest = GetReferralEventRequest;
|
|
2419
|
+
type context$3_GetReferralEventResponse = GetReferralEventResponse;
|
|
2420
|
+
type context$3_GetReferralEventResponseNonNullableFields = GetReferralEventResponseNonNullableFields;
|
|
2421
|
+
type context$3_GetReferralStatisticsRequest = GetReferralStatisticsRequest;
|
|
2422
|
+
type context$3_GetReferralStatisticsResponse = GetReferralStatisticsResponse;
|
|
2423
|
+
type context$3_GetReferralStatisticsResponseNonNullableFields = GetReferralStatisticsResponseNonNullableFields;
|
|
2424
|
+
type context$3_QueryReferralEventRequest = QueryReferralEventRequest;
|
|
2425
|
+
type context$3_QueryReferralEventResponse = QueryReferralEventResponse;
|
|
2426
|
+
type context$3_QueryReferralEventResponseNonNullableFields = QueryReferralEventResponseNonNullableFields;
|
|
2427
|
+
type context$3_QueryReferredFriendActionsOptions = QueryReferredFriendActionsOptions;
|
|
2428
|
+
type context$3_QueryReferredFriendActionsRequest = QueryReferredFriendActionsRequest;
|
|
2429
|
+
type context$3_QueryReferredFriendActionsResponse = QueryReferredFriendActionsResponse;
|
|
2430
|
+
type context$3_QueryReferredFriendActionsResponseNonNullableFields = QueryReferredFriendActionsResponseNonNullableFields;
|
|
2431
|
+
type context$3_QueryReferringCustomerTotalsOptions = QueryReferringCustomerTotalsOptions;
|
|
2432
|
+
type context$3_QueryReferringCustomerTotalsRequest = QueryReferringCustomerTotalsRequest;
|
|
2433
|
+
type context$3_QueryReferringCustomerTotalsResponse = QueryReferringCustomerTotalsResponse;
|
|
2434
|
+
type context$3_QueryReferringCustomerTotalsResponseNonNullableFields = QueryReferringCustomerTotalsResponseNonNullableFields;
|
|
2435
|
+
type context$3_ReferralEvent = ReferralEvent;
|
|
2436
|
+
type context$3_ReferralEventCreatedEnvelope = ReferralEventCreatedEnvelope;
|
|
2437
|
+
type context$3_ReferralEventEventTypeOneOf = ReferralEventEventTypeOneOf;
|
|
2438
|
+
type context$3_ReferralEventNonNullableFields = ReferralEventNonNullableFields;
|
|
2439
|
+
type context$3_ReferralEventsQueryBuilder = ReferralEventsQueryBuilder;
|
|
2440
|
+
type context$3_ReferralEventsQueryResult = ReferralEventsQueryResult;
|
|
2441
|
+
type context$3_ReferredFriendAction = ReferredFriendAction;
|
|
2442
|
+
type context$3_ReferredFriendActionEvent = ReferredFriendActionEvent;
|
|
2443
|
+
type context$3_ReferredFriendActionRewardTypeOptionsOneOf = ReferredFriendActionRewardTypeOptionsOneOf;
|
|
2444
|
+
type context$3_ReferredFriendSignupEvent = ReferredFriendSignupEvent;
|
|
2445
|
+
type context$3_ReferringCustomerTotal = ReferringCustomerTotal;
|
|
2446
|
+
type context$3_RewardEvent = RewardEvent;
|
|
2447
|
+
type context$3_RewardEventReceiverOneOf = RewardEventReceiverOneOf;
|
|
2448
|
+
type context$3_Trigger = Trigger;
|
|
2449
|
+
type context$3_V1ActionEvent = V1ActionEvent;
|
|
2450
|
+
type context$3_V1SuccessfulReferralEvent = V1SuccessfulReferralEvent;
|
|
2451
|
+
type context$3_V1Trigger = V1Trigger;
|
|
1336
2452
|
declare const context$3_getReferralEvent: typeof getReferralEvent;
|
|
1337
2453
|
declare const context$3_getReferralStatistics: typeof getReferralStatistics;
|
|
1338
2454
|
declare const context$3_onReferralEventCreated: typeof onReferralEventCreated;
|
|
@@ -1340,7 +2456,7 @@ declare const context$3_queryReferralEvent: typeof queryReferralEvent;
|
|
|
1340
2456
|
declare const context$3_queryReferredFriendActions: typeof queryReferredFriendActions;
|
|
1341
2457
|
declare const context$3_queryReferringCustomerTotals: typeof queryReferringCustomerTotals;
|
|
1342
2458
|
declare namespace context$3 {
|
|
1343
|
-
export { context$3_getReferralEvent as getReferralEvent, context$3_getReferralStatistics as getReferralStatistics, context$3_onReferralEventCreated as onReferralEventCreated, context$3_queryReferralEvent as queryReferralEvent, context$3_queryReferredFriendActions as queryReferredFriendActions, context$3_queryReferringCustomerTotals as queryReferringCustomerTotals };
|
|
2459
|
+
export { type ActionEvent$3 as ActionEvent, type BaseEventMetadata$2 as BaseEventMetadata, type Coupon$1 as Coupon, type CouponDiscountTypeOptionsOneOf$1 as CouponDiscountTypeOptionsOneOf, type CouponScope$1 as CouponScope, type CouponScopeOrMinSubtotalOneOf$1 as CouponScopeOrMinSubtotalOneOf, type context$3_CreateReferralEventRequest as CreateReferralEventRequest, type context$3_CreateReferralEventResponse as CreateReferralEventResponse, type CursorPaging$3 as CursorPaging, type CursorPagingMetadata$3 as CursorPagingMetadata, type CursorQuery$3 as CursorQuery, type CursorQueryPagingMethodOneOf$3 as CursorQueryPagingMethodOneOf, type Cursors$3 as Cursors, DiscountType$1 as DiscountType, type DomainEvent$3 as DomainEvent, type DomainEventBodyOneOf$3 as DomainEventBodyOneOf, type Empty$2 as Empty, type EntityCreatedEvent$3 as EntityCreatedEvent, type EntityDeletedEvent$3 as EntityDeletedEvent, type EntityUpdatedEvent$3 as EntityUpdatedEvent, type EventMetadata$2 as EventMetadata, type FixedAmountDiscount$1 as FixedAmountDiscount, type context$3_GetReferralEventRequest as GetReferralEventRequest, type context$3_GetReferralEventResponse as GetReferralEventResponse, type context$3_GetReferralEventResponseNonNullableFields as GetReferralEventResponseNonNullableFields, type context$3_GetReferralStatisticsRequest as GetReferralStatisticsRequest, type context$3_GetReferralStatisticsResponse as GetReferralStatisticsResponse, type context$3_GetReferralStatisticsResponseNonNullableFields as GetReferralStatisticsResponseNonNullableFields, type Group$1 as Group, type IdentificationData$3 as IdentificationData, type IdentificationDataIdOneOf$3 as IdentificationDataIdOneOf, type LoyaltyPoints$1 as LoyaltyPoints, type MessageEnvelope$3 as MessageEnvelope, type PercentageDiscount$1 as PercentageDiscount, type context$3_QueryReferralEventRequest as QueryReferralEventRequest, type context$3_QueryReferralEventResponse as QueryReferralEventResponse, type context$3_QueryReferralEventResponseNonNullableFields as QueryReferralEventResponseNonNullableFields, type context$3_QueryReferredFriendActionsOptions as QueryReferredFriendActionsOptions, type context$3_QueryReferredFriendActionsRequest as QueryReferredFriendActionsRequest, type context$3_QueryReferredFriendActionsResponse as QueryReferredFriendActionsResponse, type context$3_QueryReferredFriendActionsResponseNonNullableFields as QueryReferredFriendActionsResponseNonNullableFields, type context$3_QueryReferringCustomerTotalsOptions as QueryReferringCustomerTotalsOptions, type context$3_QueryReferringCustomerTotalsRequest as QueryReferringCustomerTotalsRequest, type context$3_QueryReferringCustomerTotalsResponse as QueryReferringCustomerTotalsResponse, type context$3_QueryReferringCustomerTotalsResponseNonNullableFields as QueryReferringCustomerTotalsResponseNonNullableFields, type context$3_ReferralEvent as ReferralEvent, type context$3_ReferralEventCreatedEnvelope as ReferralEventCreatedEnvelope, type context$3_ReferralEventEventTypeOneOf as ReferralEventEventTypeOneOf, type context$3_ReferralEventNonNullableFields as ReferralEventNonNullableFields, type context$3_ReferralEventsQueryBuilder as ReferralEventsQueryBuilder, type context$3_ReferralEventsQueryResult as ReferralEventsQueryResult, type context$3_ReferredFriendAction as ReferredFriendAction, type context$3_ReferredFriendActionEvent as ReferredFriendActionEvent, type context$3_ReferredFriendActionRewardTypeOptionsOneOf as ReferredFriendActionRewardTypeOptionsOneOf, type ReferredFriendDetails$2 as ReferredFriendDetails, type context$3_ReferredFriendSignupEvent as ReferredFriendSignupEvent, type context$3_ReferringCustomerTotal as ReferringCustomerTotal, Reward$1 as Reward, type context$3_RewardEvent as RewardEvent, type context$3_RewardEventReceiverOneOf as RewardEventReceiverOneOf, SortOrder$3 as SortOrder, type Sorting$3 as Sorting, Status$2 as Status, type SuccessfulReferralEvent$2 as SuccessfulReferralEvent, type context$3_Trigger as Trigger, type UndeleteInfo$3 as UndeleteInfo, type context$3_V1ActionEvent as V1ActionEvent, type V1Coupon$1 as V1Coupon, type context$3_V1SuccessfulReferralEvent as V1SuccessfulReferralEvent, type context$3_V1Trigger as V1Trigger, WebhookIdentityType$3 as WebhookIdentityType, context$3_getReferralEvent as getReferralEvent, context$3_getReferralStatistics as getReferralStatistics, context$3_onReferralEventCreated as onReferralEventCreated, context$3_queryReferralEvent as queryReferralEvent, context$3_queryReferredFriendActions as queryReferredFriendActions, context$3_queryReferringCustomerTotals as queryReferringCustomerTotals };
|
|
1344
2460
|
}
|
|
1345
2461
|
|
|
1346
2462
|
/** ReferralReward is the main entity of ReferralRewards that can be used for lorem ipsum dolor */
|
|
@@ -1511,9 +2627,23 @@ interface V1LoyaltyPoints {
|
|
|
1511
2627
|
*/
|
|
1512
2628
|
amount?: number;
|
|
1513
2629
|
}
|
|
1514
|
-
interface
|
|
2630
|
+
interface GetReferralRewardRequest {
|
|
2631
|
+
/** Id of the ReferralReward to retrieve. */
|
|
2632
|
+
_id: string;
|
|
2633
|
+
}
|
|
2634
|
+
interface GetReferralRewardResponse {
|
|
2635
|
+
/** The retrieved ReferralReward. */
|
|
2636
|
+
referralReward?: ReferralReward;
|
|
2637
|
+
}
|
|
2638
|
+
interface QueryReferralRewardsRequest {
|
|
2639
|
+
/** Query to filter ReferralRewards. */
|
|
2640
|
+
query: CursorQuery$2;
|
|
2641
|
+
/** Filter by contact id or set to "me" for current identity's rewards. */
|
|
2642
|
+
contactId?: string | null;
|
|
2643
|
+
}
|
|
2644
|
+
interface CursorQuery$2 extends CursorQueryPagingMethodOneOf$2 {
|
|
1515
2645
|
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
1516
|
-
cursorPaging?: CursorPaging;
|
|
2646
|
+
cursorPaging?: CursorPaging$2;
|
|
1517
2647
|
/**
|
|
1518
2648
|
* Filter object in the following format:
|
|
1519
2649
|
* `"filter" : {
|
|
@@ -1527,24 +2657,24 @@ interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
|
1527
2657
|
* Sort object in the following format:
|
|
1528
2658
|
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
1529
2659
|
*/
|
|
1530
|
-
sort?: Sorting[];
|
|
2660
|
+
sort?: Sorting$2[];
|
|
1531
2661
|
}
|
|
1532
2662
|
/** @oneof */
|
|
1533
|
-
interface CursorQueryPagingMethodOneOf {
|
|
2663
|
+
interface CursorQueryPagingMethodOneOf$2 {
|
|
1534
2664
|
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
1535
|
-
cursorPaging?: CursorPaging;
|
|
2665
|
+
cursorPaging?: CursorPaging$2;
|
|
1536
2666
|
}
|
|
1537
|
-
interface Sorting {
|
|
2667
|
+
interface Sorting$2 {
|
|
1538
2668
|
/** Name of the field to sort by. */
|
|
1539
2669
|
fieldName?: string;
|
|
1540
2670
|
/** Sort order. */
|
|
1541
|
-
order?: SortOrder;
|
|
2671
|
+
order?: SortOrder$2;
|
|
1542
2672
|
}
|
|
1543
|
-
declare enum SortOrder {
|
|
2673
|
+
declare enum SortOrder$2 {
|
|
1544
2674
|
ASC = "ASC",
|
|
1545
2675
|
DESC = "DESC"
|
|
1546
2676
|
}
|
|
1547
|
-
interface CursorPaging {
|
|
2677
|
+
interface CursorPaging$2 {
|
|
1548
2678
|
/** Maximum number of items to return in the results. */
|
|
1549
2679
|
limit?: number | null;
|
|
1550
2680
|
/**
|
|
@@ -1559,9 +2689,9 @@ interface QueryReferralRewardsResponse {
|
|
|
1559
2689
|
/** The retrieved ReferralRewards. */
|
|
1560
2690
|
referralRewards?: ReferralReward[];
|
|
1561
2691
|
/** Metadata for paging. */
|
|
1562
|
-
metadata?: CursorPagingMetadata;
|
|
2692
|
+
metadata?: CursorPagingMetadata$2;
|
|
1563
2693
|
}
|
|
1564
|
-
interface CursorPagingMetadata {
|
|
2694
|
+
interface CursorPagingMetadata$2 {
|
|
1565
2695
|
/** Number of items returned in the response. */
|
|
1566
2696
|
count?: number | null;
|
|
1567
2697
|
/** Cursor strings that point to the next page, previous page, or both. */
|
|
@@ -1580,142 +2710,302 @@ interface Cursors$2 {
|
|
|
1580
2710
|
/** Cursor pointing to the previous page in the list of results. */
|
|
1581
2711
|
prev?: string | null;
|
|
1582
2712
|
}
|
|
1583
|
-
interface
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
rewardedReferredFriendId: string;
|
|
1587
|
-
coupon?: {
|
|
1588
|
-
_id: string;
|
|
1589
|
-
code: string;
|
|
1590
|
-
status: Status$1;
|
|
1591
|
-
couponSpecification?: {
|
|
1592
|
-
fixedAmountOptions?: {
|
|
1593
|
-
amount: number;
|
|
1594
|
-
};
|
|
1595
|
-
percentageOptions?: {
|
|
1596
|
-
percentage: number;
|
|
1597
|
-
};
|
|
1598
|
-
minimumSubtotal: number;
|
|
1599
|
-
scope?: {
|
|
1600
|
-
namespace: string;
|
|
1601
|
-
group?: {
|
|
1602
|
-
name: string;
|
|
1603
|
-
};
|
|
1604
|
-
};
|
|
1605
|
-
name: string;
|
|
1606
|
-
discountType: DiscountType;
|
|
1607
|
-
};
|
|
1608
|
-
};
|
|
1609
|
-
loyaltyPoints?: {
|
|
1610
|
-
transactionId: string;
|
|
1611
|
-
amount: number;
|
|
1612
|
-
};
|
|
1613
|
-
rewardType: RewardTypeType;
|
|
1614
|
-
}[];
|
|
2713
|
+
interface ValidateReferralRewardRequest {
|
|
2714
|
+
/** Reward to validate. */
|
|
2715
|
+
reward?: Reward;
|
|
1615
2716
|
}
|
|
1616
|
-
interface
|
|
1617
|
-
/**
|
|
1618
|
-
|
|
2717
|
+
interface Reward extends RewardOptionsOneOf {
|
|
2718
|
+
/** Options for coupon reward type */
|
|
2719
|
+
couponOptions?: Coupon;
|
|
2720
|
+
/** Options for Loyalty points reward type */
|
|
2721
|
+
loyaltyPointsOptions?: LoyaltyPoints;
|
|
2722
|
+
/** Type of the reward */
|
|
2723
|
+
type?: Type;
|
|
1619
2724
|
}
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
2725
|
+
/** @oneof */
|
|
2726
|
+
interface RewardOptionsOneOf {
|
|
2727
|
+
/** Options for coupon reward type */
|
|
2728
|
+
couponOptions?: Coupon;
|
|
2729
|
+
/** Options for Loyalty points reward type */
|
|
2730
|
+
loyaltyPointsOptions?: LoyaltyPoints;
|
|
1625
2731
|
}
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
type RequestOptions$2<_TResponse = any, Data = any> = {
|
|
1635
|
-
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
1636
|
-
url: string;
|
|
1637
|
-
data?: Data;
|
|
1638
|
-
params?: URLSearchParams;
|
|
1639
|
-
} & APIMetadata$2;
|
|
1640
|
-
type APIMetadata$2 = {
|
|
1641
|
-
methodFqn?: string;
|
|
1642
|
-
entityFqdn?: string;
|
|
1643
|
-
packageName?: string;
|
|
1644
|
-
};
|
|
1645
|
-
type BuildRESTFunction$2<T extends RESTFunctionDescriptor$2> = T extends RESTFunctionDescriptor$2<infer U> ? U : never;
|
|
1646
|
-
|
|
1647
|
-
declare global {
|
|
1648
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
1649
|
-
interface SymbolConstructor {
|
|
1650
|
-
readonly observable: symbol;
|
|
1651
|
-
}
|
|
2732
|
+
declare enum Type {
|
|
2733
|
+
UNKNOWN = "UNKNOWN",
|
|
2734
|
+
/** Coupon reward type */
|
|
2735
|
+
COUPON = "COUPON",
|
|
2736
|
+
/** Loyalty points reward type */
|
|
2737
|
+
LOYALTY_POINTS = "LOYALTY_POINTS",
|
|
2738
|
+
/** No reward type */
|
|
2739
|
+
NOTHING = "NOTHING"
|
|
1652
2740
|
}
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
rewardedReferredFriendId: string;
|
|
1657
|
-
coupon?: {
|
|
1658
|
-
_id: string;
|
|
1659
|
-
code: string;
|
|
1660
|
-
status: Status$1;
|
|
1661
|
-
couponSpecification?: {
|
|
1662
|
-
fixedAmountOptions?: {
|
|
1663
|
-
amount: number;
|
|
1664
|
-
} | undefined;
|
|
1665
|
-
percentageOptions?: {
|
|
1666
|
-
percentage: number;
|
|
1667
|
-
} | undefined;
|
|
1668
|
-
minimumSubtotal: number;
|
|
1669
|
-
scope?: {
|
|
1670
|
-
namespace: string;
|
|
1671
|
-
group?: {
|
|
1672
|
-
name: string;
|
|
1673
|
-
} | undefined;
|
|
1674
|
-
} | undefined;
|
|
1675
|
-
name: string;
|
|
1676
|
-
discountType: DiscountType;
|
|
1677
|
-
} | undefined;
|
|
1678
|
-
} | undefined;
|
|
1679
|
-
loyaltyPoints?: {
|
|
1680
|
-
transactionId: string;
|
|
1681
|
-
amount: number;
|
|
1682
|
-
} | undefined;
|
|
1683
|
-
rewardType: RewardTypeType;
|
|
1684
|
-
}>;
|
|
1685
|
-
declare function queryReferralRewards$1(httpClient: HttpClient$2): (query: CursorQuery, options?: QueryReferralRewardsOptions) => Promise<QueryReferralRewardsResponse & QueryReferralRewardsResponseNonNullableFields>;
|
|
1686
|
-
|
|
1687
|
-
declare const getReferralReward: BuildRESTFunction$2<typeof getReferralReward$1>;
|
|
1688
|
-
declare const queryReferralRewards: BuildRESTFunction$2<typeof queryReferralRewards$1>;
|
|
1689
|
-
|
|
1690
|
-
declare const context$2_getReferralReward: typeof getReferralReward;
|
|
1691
|
-
declare const context$2_queryReferralRewards: typeof queryReferralRewards;
|
|
1692
|
-
declare namespace context$2 {
|
|
1693
|
-
export { context$2_getReferralReward as getReferralReward, context$2_queryReferralRewards as queryReferralRewards };
|
|
2741
|
+
interface LoyaltyPoints {
|
|
2742
|
+
/** Amount of points to give */
|
|
2743
|
+
amount?: number;
|
|
1694
2744
|
}
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
interface
|
|
2745
|
+
interface ValidateReferralRewardResponse {
|
|
2746
|
+
}
|
|
2747
|
+
interface BulkGetReferralRewardsRequest {
|
|
2748
|
+
}
|
|
2749
|
+
interface BulkGetReferralRewardsResponse {
|
|
2750
|
+
/** Found rewards per site. */
|
|
2751
|
+
rewardsInSite?: RewardsInSite[];
|
|
2752
|
+
}
|
|
2753
|
+
interface RewardsInSite {
|
|
2754
|
+
/** Metasite ID. */
|
|
2755
|
+
metaSiteId?: string;
|
|
2756
|
+
/** Rewards. */
|
|
2757
|
+
rewards?: ReferralReward[];
|
|
2758
|
+
}
|
|
2759
|
+
interface DomainEvent$2 extends DomainEventBodyOneOf$2 {
|
|
2760
|
+
createdEvent?: EntityCreatedEvent$2;
|
|
2761
|
+
updatedEvent?: EntityUpdatedEvent$2;
|
|
2762
|
+
deletedEvent?: EntityDeletedEvent$2;
|
|
2763
|
+
actionEvent?: ActionEvent$2;
|
|
1698
2764
|
/**
|
|
1699
|
-
*
|
|
1700
|
-
*
|
|
2765
|
+
* Unique event ID.
|
|
2766
|
+
* Allows clients to ignore duplicate webhooks.
|
|
1701
2767
|
*/
|
|
1702
2768
|
_id?: string;
|
|
1703
2769
|
/**
|
|
1704
|
-
*
|
|
1705
|
-
*
|
|
2770
|
+
* Assumes actions are also always typed to an entity_type
|
|
2771
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
1706
2772
|
*/
|
|
1707
|
-
|
|
2773
|
+
entityFqdn?: string;
|
|
1708
2774
|
/**
|
|
1709
|
-
*
|
|
1710
|
-
*
|
|
2775
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
2776
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
2777
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
1711
2778
|
*/
|
|
1712
|
-
|
|
1713
|
-
/**
|
|
1714
|
-
|
|
2779
|
+
slug?: string;
|
|
2780
|
+
/** ID of the entity associated with the event. */
|
|
2781
|
+
entityId?: string;
|
|
2782
|
+
/** Event timestamp. */
|
|
2783
|
+
eventTime?: Date;
|
|
1715
2784
|
/**
|
|
1716
|
-
*
|
|
1717
|
-
*
|
|
1718
|
-
*/
|
|
2785
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
2786
|
+
* (for example, GDPR).
|
|
2787
|
+
*/
|
|
2788
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
2789
|
+
/** If present, indicates the action that triggered the event. */
|
|
2790
|
+
originatedFrom?: string | null;
|
|
2791
|
+
/**
|
|
2792
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
2793
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
2794
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
2795
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
2796
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
2797
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
2798
|
+
*/
|
|
2799
|
+
entityEventSequence?: string | null;
|
|
2800
|
+
}
|
|
2801
|
+
/** @oneof */
|
|
2802
|
+
interface DomainEventBodyOneOf$2 {
|
|
2803
|
+
createdEvent?: EntityCreatedEvent$2;
|
|
2804
|
+
updatedEvent?: EntityUpdatedEvent$2;
|
|
2805
|
+
deletedEvent?: EntityDeletedEvent$2;
|
|
2806
|
+
actionEvent?: ActionEvent$2;
|
|
2807
|
+
}
|
|
2808
|
+
interface EntityCreatedEvent$2 {
|
|
2809
|
+
entity?: string;
|
|
2810
|
+
}
|
|
2811
|
+
interface UndeleteInfo$2 {
|
|
2812
|
+
deletedDate?: Date;
|
|
2813
|
+
}
|
|
2814
|
+
interface EntityUpdatedEvent$2 {
|
|
2815
|
+
/**
|
|
2816
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
2817
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
2818
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
2819
|
+
*/
|
|
2820
|
+
currentEntity?: string;
|
|
2821
|
+
}
|
|
2822
|
+
interface EntityDeletedEvent$2 {
|
|
2823
|
+
/** Entity that was deleted */
|
|
2824
|
+
deletedEntity?: string | null;
|
|
2825
|
+
}
|
|
2826
|
+
interface ActionEvent$2 {
|
|
2827
|
+
body?: string;
|
|
2828
|
+
}
|
|
2829
|
+
interface Empty$1 {
|
|
2830
|
+
}
|
|
2831
|
+
interface SuccessfulReferralEvent$1 {
|
|
2832
|
+
/** ReferredFriend that completed his referral details. */
|
|
2833
|
+
referredFriendDetails?: ReferredFriendDetails$1;
|
|
2834
|
+
}
|
|
2835
|
+
interface ReferredFriendDetails$1 {
|
|
2836
|
+
/**
|
|
2837
|
+
* ReferredFriend ID.
|
|
2838
|
+
* @readonly
|
|
2839
|
+
*/
|
|
2840
|
+
referredFriendId?: string;
|
|
2841
|
+
/**
|
|
2842
|
+
* ReferredFriend Contact ID.
|
|
2843
|
+
* @readonly
|
|
2844
|
+
*/
|
|
2845
|
+
contactId?: string;
|
|
2846
|
+
/**
|
|
2847
|
+
* Customer who referred this ReferredFriend.
|
|
2848
|
+
* @readonly
|
|
2849
|
+
*/
|
|
2850
|
+
referringCustomerId?: string;
|
|
2851
|
+
}
|
|
2852
|
+
interface MessageEnvelope$2 {
|
|
2853
|
+
/** App instance ID. */
|
|
2854
|
+
instanceId?: string | null;
|
|
2855
|
+
/** Event type. */
|
|
2856
|
+
eventType?: string;
|
|
2857
|
+
/** The identification type and identity data. */
|
|
2858
|
+
identity?: IdentificationData$2;
|
|
2859
|
+
/** Stringify payload. */
|
|
2860
|
+
data?: string;
|
|
2861
|
+
}
|
|
2862
|
+
interface IdentificationData$2 extends IdentificationDataIdOneOf$2 {
|
|
2863
|
+
/** ID of a site visitor that has not logged in to the site. */
|
|
2864
|
+
anonymousVisitorId?: string;
|
|
2865
|
+
/** ID of a site visitor that has logged in to the site. */
|
|
2866
|
+
memberId?: string;
|
|
2867
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
|
2868
|
+
wixUserId?: string;
|
|
2869
|
+
/** ID of an app. */
|
|
2870
|
+
appId?: string;
|
|
2871
|
+
/** @readonly */
|
|
2872
|
+
identityType?: WebhookIdentityType$2;
|
|
2873
|
+
}
|
|
2874
|
+
/** @oneof */
|
|
2875
|
+
interface IdentificationDataIdOneOf$2 {
|
|
2876
|
+
/** ID of a site visitor that has not logged in to the site. */
|
|
2877
|
+
anonymousVisitorId?: string;
|
|
2878
|
+
/** ID of a site visitor that has logged in to the site. */
|
|
2879
|
+
memberId?: string;
|
|
2880
|
+
/** ID of a Wix user (site owner, contributor, etc.). */
|
|
2881
|
+
wixUserId?: string;
|
|
2882
|
+
/** ID of an app. */
|
|
2883
|
+
appId?: string;
|
|
2884
|
+
}
|
|
2885
|
+
declare enum WebhookIdentityType$2 {
|
|
2886
|
+
UNKNOWN = "UNKNOWN",
|
|
2887
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
2888
|
+
MEMBER = "MEMBER",
|
|
2889
|
+
WIX_USER = "WIX_USER",
|
|
2890
|
+
APP = "APP"
|
|
2891
|
+
}
|
|
2892
|
+
interface FixedAmountDiscountNonNullableFields {
|
|
2893
|
+
amount: number;
|
|
2894
|
+
}
|
|
2895
|
+
interface PercentageDiscountNonNullableFields {
|
|
2896
|
+
percentage: number;
|
|
2897
|
+
}
|
|
2898
|
+
interface GroupNonNullableFields {
|
|
2899
|
+
name: string;
|
|
2900
|
+
}
|
|
2901
|
+
interface CouponScopeNonNullableFields {
|
|
2902
|
+
namespace: string;
|
|
2903
|
+
group?: GroupNonNullableFields;
|
|
2904
|
+
}
|
|
2905
|
+
interface CouponNonNullableFields {
|
|
2906
|
+
fixedAmountOptions?: FixedAmountDiscountNonNullableFields;
|
|
2907
|
+
percentageOptions?: PercentageDiscountNonNullableFields;
|
|
2908
|
+
minimumSubtotal: number;
|
|
2909
|
+
scope?: CouponScopeNonNullableFields;
|
|
2910
|
+
name: string;
|
|
2911
|
+
discountType: DiscountType;
|
|
2912
|
+
}
|
|
2913
|
+
interface V1CouponNonNullableFields {
|
|
2914
|
+
_id: string;
|
|
2915
|
+
code: string;
|
|
2916
|
+
status: Status$1;
|
|
2917
|
+
couponSpecification?: CouponNonNullableFields;
|
|
2918
|
+
}
|
|
2919
|
+
interface V1LoyaltyPointsNonNullableFields {
|
|
2920
|
+
transactionId: string;
|
|
2921
|
+
amount: number;
|
|
2922
|
+
}
|
|
2923
|
+
interface ReferralRewardNonNullableFields {
|
|
2924
|
+
rewardedReferringCustomerId: string;
|
|
2925
|
+
rewardedReferredFriendId: string;
|
|
2926
|
+
coupon?: V1CouponNonNullableFields;
|
|
2927
|
+
loyaltyPoints?: V1LoyaltyPointsNonNullableFields;
|
|
2928
|
+
rewardType: RewardTypeType;
|
|
2929
|
+
}
|
|
2930
|
+
interface GetReferralRewardResponseNonNullableFields {
|
|
2931
|
+
referralReward?: ReferralRewardNonNullableFields;
|
|
2932
|
+
}
|
|
2933
|
+
interface QueryReferralRewardsResponseNonNullableFields {
|
|
2934
|
+
referralRewards: ReferralRewardNonNullableFields[];
|
|
2935
|
+
}
|
|
2936
|
+
interface QueryReferralRewardsOptions {
|
|
2937
|
+
/** Filter by contact id or set to "me" for current identity's rewards. */
|
|
2938
|
+
contactId?: string | null;
|
|
2939
|
+
}
|
|
2940
|
+
|
|
2941
|
+
declare function createRESTModule$2<T extends RESTFunctionDescriptor>(descriptor: T, elevated?: boolean): BuildRESTFunction<T> & T;
|
|
2942
|
+
|
|
2943
|
+
declare const getReferralReward: ReturnType<typeof createRESTModule$2<typeof publicGetReferralReward>>;
|
|
2944
|
+
declare const queryReferralRewards: ReturnType<typeof createRESTModule$2<typeof publicQueryReferralRewards>>;
|
|
2945
|
+
|
|
2946
|
+
type context$2_BulkGetReferralRewardsRequest = BulkGetReferralRewardsRequest;
|
|
2947
|
+
type context$2_BulkGetReferralRewardsResponse = BulkGetReferralRewardsResponse;
|
|
2948
|
+
type context$2_Coupon = Coupon;
|
|
2949
|
+
type context$2_CouponDiscountTypeOptionsOneOf = CouponDiscountTypeOptionsOneOf;
|
|
2950
|
+
type context$2_CouponScope = CouponScope;
|
|
2951
|
+
type context$2_CouponScopeOrMinSubtotalOneOf = CouponScopeOrMinSubtotalOneOf;
|
|
2952
|
+
type context$2_DiscountType = DiscountType;
|
|
2953
|
+
declare const context$2_DiscountType: typeof DiscountType;
|
|
2954
|
+
type context$2_FixedAmountDiscount = FixedAmountDiscount;
|
|
2955
|
+
type context$2_GetReferralRewardRequest = GetReferralRewardRequest;
|
|
2956
|
+
type context$2_GetReferralRewardResponse = GetReferralRewardResponse;
|
|
2957
|
+
type context$2_GetReferralRewardResponseNonNullableFields = GetReferralRewardResponseNonNullableFields;
|
|
2958
|
+
type context$2_Group = Group;
|
|
2959
|
+
type context$2_LoyaltyPoints = LoyaltyPoints;
|
|
2960
|
+
type context$2_PercentageDiscount = PercentageDiscount;
|
|
2961
|
+
type context$2_QueryReferralRewardsOptions = QueryReferralRewardsOptions;
|
|
2962
|
+
type context$2_QueryReferralRewardsRequest = QueryReferralRewardsRequest;
|
|
2963
|
+
type context$2_QueryReferralRewardsResponse = QueryReferralRewardsResponse;
|
|
2964
|
+
type context$2_QueryReferralRewardsResponseNonNullableFields = QueryReferralRewardsResponseNonNullableFields;
|
|
2965
|
+
type context$2_ReferralReward = ReferralReward;
|
|
2966
|
+
type context$2_ReferralRewardNonNullableFields = ReferralRewardNonNullableFields;
|
|
2967
|
+
type context$2_ReferralRewardReceiverOneOf = ReferralRewardReceiverOneOf;
|
|
2968
|
+
type context$2_ReferralRewardRewardTypeOptionsOneOf = ReferralRewardRewardTypeOptionsOneOf;
|
|
2969
|
+
type context$2_Reward = Reward;
|
|
2970
|
+
type context$2_RewardOptionsOneOf = RewardOptionsOneOf;
|
|
2971
|
+
type context$2_RewardTypeType = RewardTypeType;
|
|
2972
|
+
declare const context$2_RewardTypeType: typeof RewardTypeType;
|
|
2973
|
+
type context$2_RewardsInSite = RewardsInSite;
|
|
2974
|
+
type context$2_Type = Type;
|
|
2975
|
+
declare const context$2_Type: typeof Type;
|
|
2976
|
+
type context$2_V1Coupon = V1Coupon;
|
|
2977
|
+
type context$2_V1LoyaltyPoints = V1LoyaltyPoints;
|
|
2978
|
+
type context$2_ValidateReferralRewardRequest = ValidateReferralRewardRequest;
|
|
2979
|
+
type context$2_ValidateReferralRewardResponse = ValidateReferralRewardResponse;
|
|
2980
|
+
declare const context$2_getReferralReward: typeof getReferralReward;
|
|
2981
|
+
declare const context$2_queryReferralRewards: typeof queryReferralRewards;
|
|
2982
|
+
declare namespace context$2 {
|
|
2983
|
+
export { type ActionEvent$2 as ActionEvent, type context$2_BulkGetReferralRewardsRequest as BulkGetReferralRewardsRequest, type context$2_BulkGetReferralRewardsResponse as BulkGetReferralRewardsResponse, type context$2_Coupon as Coupon, type context$2_CouponDiscountTypeOptionsOneOf as CouponDiscountTypeOptionsOneOf, type context$2_CouponScope as CouponScope, type context$2_CouponScopeOrMinSubtotalOneOf as CouponScopeOrMinSubtotalOneOf, type CursorPaging$2 as CursorPaging, type CursorPagingMetadata$2 as CursorPagingMetadata, type CursorQuery$2 as CursorQuery, type CursorQueryPagingMethodOneOf$2 as CursorQueryPagingMethodOneOf, type Cursors$2 as Cursors, context$2_DiscountType as DiscountType, type DomainEvent$2 as DomainEvent, type DomainEventBodyOneOf$2 as DomainEventBodyOneOf, type Empty$1 as Empty, type EntityCreatedEvent$2 as EntityCreatedEvent, type EntityDeletedEvent$2 as EntityDeletedEvent, type EntityUpdatedEvent$2 as EntityUpdatedEvent, type context$2_FixedAmountDiscount as FixedAmountDiscount, type context$2_GetReferralRewardRequest as GetReferralRewardRequest, type context$2_GetReferralRewardResponse as GetReferralRewardResponse, type context$2_GetReferralRewardResponseNonNullableFields as GetReferralRewardResponseNonNullableFields, type context$2_Group as Group, type IdentificationData$2 as IdentificationData, type IdentificationDataIdOneOf$2 as IdentificationDataIdOneOf, type context$2_LoyaltyPoints as LoyaltyPoints, type MessageEnvelope$2 as MessageEnvelope, type context$2_PercentageDiscount as PercentageDiscount, type context$2_QueryReferralRewardsOptions as QueryReferralRewardsOptions, type context$2_QueryReferralRewardsRequest as QueryReferralRewardsRequest, type context$2_QueryReferralRewardsResponse as QueryReferralRewardsResponse, type context$2_QueryReferralRewardsResponseNonNullableFields as QueryReferralRewardsResponseNonNullableFields, type context$2_ReferralReward as ReferralReward, type context$2_ReferralRewardNonNullableFields as ReferralRewardNonNullableFields, type context$2_ReferralRewardReceiverOneOf as ReferralRewardReceiverOneOf, type context$2_ReferralRewardRewardTypeOptionsOneOf as ReferralRewardRewardTypeOptionsOneOf, type ReferredFriendDetails$1 as ReferredFriendDetails, type context$2_Reward as Reward, type context$2_RewardOptionsOneOf as RewardOptionsOneOf, context$2_RewardTypeType as RewardTypeType, type context$2_RewardsInSite as RewardsInSite, SortOrder$2 as SortOrder, type Sorting$2 as Sorting, Status$1 as Status, type SuccessfulReferralEvent$1 as SuccessfulReferralEvent, context$2_Type as Type, type UndeleteInfo$2 as UndeleteInfo, type context$2_V1Coupon as V1Coupon, type context$2_V1LoyaltyPoints as V1LoyaltyPoints, type context$2_ValidateReferralRewardRequest as ValidateReferralRewardRequest, type context$2_ValidateReferralRewardResponse as ValidateReferralRewardResponse, WebhookIdentityType$2 as WebhookIdentityType, context$2_getReferralReward as getReferralReward, context$2_queryReferralRewards as queryReferralRewards };
|
|
2984
|
+
}
|
|
2985
|
+
|
|
2986
|
+
/** ReferredFriend is the main entity of ReferredFriends that can be used for lorem ipsum dolor */
|
|
2987
|
+
interface ReferredFriend {
|
|
2988
|
+
/**
|
|
2989
|
+
* ReferredFriend ID.
|
|
2990
|
+
* @readonly
|
|
2991
|
+
*/
|
|
2992
|
+
_id?: string;
|
|
2993
|
+
/**
|
|
2994
|
+
* ReferredFriend Contact ID.
|
|
2995
|
+
* @readonly
|
|
2996
|
+
*/
|
|
2997
|
+
contactId?: string;
|
|
2998
|
+
/**
|
|
2999
|
+
* Customer who referred.
|
|
3000
|
+
* @readonly
|
|
3001
|
+
*/
|
|
3002
|
+
referringCustomerId?: string;
|
|
3003
|
+
/** Status of the ReferredFriend. */
|
|
3004
|
+
status?: Status;
|
|
3005
|
+
/**
|
|
3006
|
+
* Represents the current state of an item. Each time the item is modified, its `revision` changes by the server. for an update operation to succeed, you MUST pass the latest revision.
|
|
3007
|
+
* @readonly
|
|
3008
|
+
*/
|
|
1719
3009
|
revision?: string | null;
|
|
1720
3010
|
/**
|
|
1721
3011
|
* Represents the time this ReferredFriend was created.
|
|
@@ -1736,20 +3026,220 @@ declare enum Status {
|
|
|
1736
3026
|
/** After complete some actions (eg. Purchase Order), Action Completed Status is used. */
|
|
1737
3027
|
ACTIONS_COMPLETED = "ACTIONS_COMPLETED"
|
|
1738
3028
|
}
|
|
3029
|
+
interface CreateReferredFriendRequest {
|
|
3030
|
+
}
|
|
1739
3031
|
interface CreateReferredFriendResponse {
|
|
1740
3032
|
/** The created ReferredFriend. */
|
|
1741
3033
|
referredFriend?: ReferredFriend;
|
|
1742
3034
|
}
|
|
3035
|
+
interface GetReferredFriendRequest {
|
|
3036
|
+
/** Id of the ReferredFriend to retrieve. */
|
|
3037
|
+
referredFriendId: string;
|
|
3038
|
+
}
|
|
1743
3039
|
interface GetReferredFriendResponse {
|
|
1744
3040
|
/** The retrieved ReferredFriend. */
|
|
1745
3041
|
referredFriend?: ReferredFriend;
|
|
1746
3042
|
}
|
|
3043
|
+
interface GetReferredFriendByContactIdRequest {
|
|
3044
|
+
/** Contact id or "me" to get current identity's Contact. */
|
|
3045
|
+
contactId: string;
|
|
3046
|
+
}
|
|
3047
|
+
interface GetReferredFriendByContactIdResponse {
|
|
3048
|
+
/** The retrieved ReferredFriend. */
|
|
3049
|
+
referredFriend?: ReferredFriend;
|
|
3050
|
+
}
|
|
3051
|
+
interface UpdateReferredFriendRequest {
|
|
3052
|
+
/** ReferredFriend to be updated, may be partial. */
|
|
3053
|
+
referredFriend: ReferredFriend;
|
|
3054
|
+
}
|
|
3055
|
+
interface UpdateReferredFriendResponse {
|
|
3056
|
+
/** The updated ReferredFriend. */
|
|
3057
|
+
referredFriend?: ReferredFriend;
|
|
3058
|
+
}
|
|
3059
|
+
interface DeleteReferredFriendRequest {
|
|
3060
|
+
/** Id of the ReferredFriend to delete. */
|
|
3061
|
+
referredFriendId: string;
|
|
3062
|
+
/** The revision of the ReferredFriend. */
|
|
3063
|
+
revision?: string;
|
|
3064
|
+
}
|
|
3065
|
+
interface DeleteReferredFriendResponse {
|
|
3066
|
+
}
|
|
3067
|
+
interface QueryReferredFriendRequest {
|
|
3068
|
+
/** Query options. */
|
|
3069
|
+
query: CursorQuery$1;
|
|
3070
|
+
}
|
|
3071
|
+
interface CursorQuery$1 extends CursorQueryPagingMethodOneOf$1 {
|
|
3072
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
3073
|
+
cursorPaging?: CursorPaging$1;
|
|
3074
|
+
/**
|
|
3075
|
+
* Filter object in the following format:
|
|
3076
|
+
* `"filter" : {
|
|
3077
|
+
* "fieldName1": "value1",
|
|
3078
|
+
* "fieldName2":{"$operator":"value2"}
|
|
3079
|
+
* }`
|
|
3080
|
+
* Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
|
|
3081
|
+
*/
|
|
3082
|
+
filter?: Record<string, any> | null;
|
|
3083
|
+
/**
|
|
3084
|
+
* Sort object in the following format:
|
|
3085
|
+
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
3086
|
+
*/
|
|
3087
|
+
sort?: Sorting$1[];
|
|
3088
|
+
}
|
|
3089
|
+
/** @oneof */
|
|
3090
|
+
interface CursorQueryPagingMethodOneOf$1 {
|
|
3091
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
3092
|
+
cursorPaging?: CursorPaging$1;
|
|
3093
|
+
}
|
|
3094
|
+
interface Sorting$1 {
|
|
3095
|
+
/** Name of the field to sort by. */
|
|
3096
|
+
fieldName?: string;
|
|
3097
|
+
/** Sort order. */
|
|
3098
|
+
order?: SortOrder$1;
|
|
3099
|
+
}
|
|
3100
|
+
declare enum SortOrder$1 {
|
|
3101
|
+
ASC = "ASC",
|
|
3102
|
+
DESC = "DESC"
|
|
3103
|
+
}
|
|
3104
|
+
interface CursorPaging$1 {
|
|
3105
|
+
/** Maximum number of items to return in the results. */
|
|
3106
|
+
limit?: number | null;
|
|
3107
|
+
/**
|
|
3108
|
+
* Pointer to the next or previous page in the list of results.
|
|
3109
|
+
*
|
|
3110
|
+
* Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
|
|
3111
|
+
* Not relevant for the first request.
|
|
3112
|
+
*/
|
|
3113
|
+
cursor?: string | null;
|
|
3114
|
+
}
|
|
3115
|
+
interface QueryReferredFriendResponse {
|
|
3116
|
+
/** The retrieved ReferredFriends. */
|
|
3117
|
+
referredFriends?: ReferredFriend[];
|
|
3118
|
+
/** CursorPagingMetadata. */
|
|
3119
|
+
metadata?: CursorPagingMetadata$1;
|
|
3120
|
+
}
|
|
3121
|
+
interface CursorPagingMetadata$1 {
|
|
3122
|
+
/** Number of items returned in the response. */
|
|
3123
|
+
count?: number | null;
|
|
3124
|
+
/** Cursor strings that point to the next page, previous page, or both. */
|
|
3125
|
+
cursors?: Cursors$1;
|
|
3126
|
+
/**
|
|
3127
|
+
* Whether there are more pages to retrieve following the current page.
|
|
3128
|
+
*
|
|
3129
|
+
* + `true`: Another page of results can be retrieved.
|
|
3130
|
+
* + `false`: This is the last page.
|
|
3131
|
+
*/
|
|
3132
|
+
hasNext?: boolean | null;
|
|
3133
|
+
}
|
|
1747
3134
|
interface Cursors$1 {
|
|
1748
3135
|
/** Cursor string pointing to the next page in the list of results. */
|
|
1749
3136
|
next?: string | null;
|
|
1750
3137
|
/** Cursor pointing to the previous page in the list of results. */
|
|
1751
3138
|
prev?: string | null;
|
|
1752
3139
|
}
|
|
3140
|
+
interface DomainEvent$1 extends DomainEventBodyOneOf$1 {
|
|
3141
|
+
createdEvent?: EntityCreatedEvent$1;
|
|
3142
|
+
updatedEvent?: EntityUpdatedEvent$1;
|
|
3143
|
+
deletedEvent?: EntityDeletedEvent$1;
|
|
3144
|
+
actionEvent?: ActionEvent$1;
|
|
3145
|
+
/**
|
|
3146
|
+
* Unique event ID.
|
|
3147
|
+
* Allows clients to ignore duplicate webhooks.
|
|
3148
|
+
*/
|
|
3149
|
+
_id?: string;
|
|
3150
|
+
/**
|
|
3151
|
+
* Assumes actions are also always typed to an entity_type
|
|
3152
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
3153
|
+
*/
|
|
3154
|
+
entityFqdn?: string;
|
|
3155
|
+
/**
|
|
3156
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
3157
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
3158
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
3159
|
+
*/
|
|
3160
|
+
slug?: string;
|
|
3161
|
+
/** ID of the entity associated with the event. */
|
|
3162
|
+
entityId?: string;
|
|
3163
|
+
/** Event timestamp. */
|
|
3164
|
+
eventTime?: Date;
|
|
3165
|
+
/**
|
|
3166
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
3167
|
+
* (for example, GDPR).
|
|
3168
|
+
*/
|
|
3169
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
3170
|
+
/** If present, indicates the action that triggered the event. */
|
|
3171
|
+
originatedFrom?: string | null;
|
|
3172
|
+
/**
|
|
3173
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
3174
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
3175
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
3176
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
3177
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
3178
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
3179
|
+
*/
|
|
3180
|
+
entityEventSequence?: string | null;
|
|
3181
|
+
}
|
|
3182
|
+
/** @oneof */
|
|
3183
|
+
interface DomainEventBodyOneOf$1 {
|
|
3184
|
+
createdEvent?: EntityCreatedEvent$1;
|
|
3185
|
+
updatedEvent?: EntityUpdatedEvent$1;
|
|
3186
|
+
deletedEvent?: EntityDeletedEvent$1;
|
|
3187
|
+
actionEvent?: ActionEvent$1;
|
|
3188
|
+
}
|
|
3189
|
+
interface EntityCreatedEvent$1 {
|
|
3190
|
+
entity?: string;
|
|
3191
|
+
}
|
|
3192
|
+
interface UndeleteInfo$1 {
|
|
3193
|
+
deletedDate?: Date;
|
|
3194
|
+
}
|
|
3195
|
+
interface EntityUpdatedEvent$1 {
|
|
3196
|
+
/**
|
|
3197
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
3198
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
3199
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
3200
|
+
*/
|
|
3201
|
+
currentEntity?: string;
|
|
3202
|
+
}
|
|
3203
|
+
interface EntityDeletedEvent$1 {
|
|
3204
|
+
/** Entity that was deleted */
|
|
3205
|
+
deletedEntity?: string | null;
|
|
3206
|
+
}
|
|
3207
|
+
interface ActionEvent$1 {
|
|
3208
|
+
body?: string;
|
|
3209
|
+
}
|
|
3210
|
+
interface Empty {
|
|
3211
|
+
}
|
|
3212
|
+
interface SuccessfulReferralEvent {
|
|
3213
|
+
/** ReferredFriend that completed his referral details. */
|
|
3214
|
+
referredFriendDetails?: ReferredFriendDetails;
|
|
3215
|
+
}
|
|
3216
|
+
interface ReferredFriendDetails {
|
|
3217
|
+
/**
|
|
3218
|
+
* ReferredFriend ID.
|
|
3219
|
+
* @readonly
|
|
3220
|
+
*/
|
|
3221
|
+
referredFriendId?: string;
|
|
3222
|
+
/**
|
|
3223
|
+
* ReferredFriend Contact ID.
|
|
3224
|
+
* @readonly
|
|
3225
|
+
*/
|
|
3226
|
+
contactId?: string;
|
|
3227
|
+
/**
|
|
3228
|
+
* Customer who referred this ReferredFriend.
|
|
3229
|
+
* @readonly
|
|
3230
|
+
*/
|
|
3231
|
+
referringCustomerId?: string;
|
|
3232
|
+
}
|
|
3233
|
+
interface MessageEnvelope$1 {
|
|
3234
|
+
/** App instance ID. */
|
|
3235
|
+
instanceId?: string | null;
|
|
3236
|
+
/** Event type. */
|
|
3237
|
+
eventType?: string;
|
|
3238
|
+
/** The identification type and identity data. */
|
|
3239
|
+
identity?: IdentificationData$1;
|
|
3240
|
+
/** Stringify payload. */
|
|
3241
|
+
data?: string;
|
|
3242
|
+
}
|
|
1753
3243
|
interface IdentificationData$1 extends IdentificationDataIdOneOf$1 {
|
|
1754
3244
|
/** ID of a site visitor that has not logged in to the site. */
|
|
1755
3245
|
anonymousVisitorId?: string;
|
|
@@ -1780,21 +3270,26 @@ declare enum WebhookIdentityType$1 {
|
|
|
1780
3270
|
WIX_USER = "WIX_USER",
|
|
1781
3271
|
APP = "APP"
|
|
1782
3272
|
}
|
|
3273
|
+
interface ReferredFriendNonNullableFields {
|
|
3274
|
+
_id: string;
|
|
3275
|
+
contactId: string;
|
|
3276
|
+
referringCustomerId: string;
|
|
3277
|
+
status: Status;
|
|
3278
|
+
}
|
|
1783
3279
|
interface CreateReferredFriendResponseNonNullableFields {
|
|
1784
|
-
referredFriend?:
|
|
1785
|
-
_id: string;
|
|
1786
|
-
contactId: string;
|
|
1787
|
-
referringCustomerId: string;
|
|
1788
|
-
status: Status;
|
|
1789
|
-
};
|
|
3280
|
+
referredFriend?: ReferredFriendNonNullableFields;
|
|
1790
3281
|
}
|
|
1791
3282
|
interface GetReferredFriendResponseNonNullableFields {
|
|
1792
|
-
referredFriend?:
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
3283
|
+
referredFriend?: ReferredFriendNonNullableFields;
|
|
3284
|
+
}
|
|
3285
|
+
interface GetReferredFriendByContactIdResponseNonNullableFields {
|
|
3286
|
+
referredFriend?: ReferredFriendNonNullableFields;
|
|
3287
|
+
}
|
|
3288
|
+
interface UpdateReferredFriendResponseNonNullableFields {
|
|
3289
|
+
referredFriend?: ReferredFriendNonNullableFields;
|
|
3290
|
+
}
|
|
3291
|
+
interface QueryReferredFriendResponseNonNullableFields {
|
|
3292
|
+
referredFriends: ReferredFriendNonNullableFields[];
|
|
1798
3293
|
}
|
|
1799
3294
|
interface BaseEventMetadata$1 {
|
|
1800
3295
|
/** App instance ID. */
|
|
@@ -1969,79 +3464,51 @@ interface ReferredFriendsQueryBuilder {
|
|
|
1969
3464
|
find: () => Promise<ReferredFriendsQueryResult>;
|
|
1970
3465
|
}
|
|
1971
3466
|
|
|
1972
|
-
|
|
1973
|
-
interface HttpClient$1 {
|
|
1974
|
-
request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
|
|
1975
|
-
fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
|
|
1976
|
-
}
|
|
1977
|
-
type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
|
|
1978
|
-
type HttpResponse$1<T = any> = {
|
|
1979
|
-
data: T;
|
|
1980
|
-
status: number;
|
|
1981
|
-
statusText: string;
|
|
1982
|
-
headers: any;
|
|
1983
|
-
request?: any;
|
|
1984
|
-
};
|
|
1985
|
-
type RequestOptions$1<_TResponse = any, Data = any> = {
|
|
1986
|
-
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
1987
|
-
url: string;
|
|
1988
|
-
data?: Data;
|
|
1989
|
-
params?: URLSearchParams;
|
|
1990
|
-
} & APIMetadata$1;
|
|
1991
|
-
type APIMetadata$1 = {
|
|
1992
|
-
methodFqn?: string;
|
|
1993
|
-
entityFqdn?: string;
|
|
1994
|
-
packageName?: string;
|
|
1995
|
-
};
|
|
1996
|
-
type BuildRESTFunction$1<T extends RESTFunctionDescriptor$1> = T extends RESTFunctionDescriptor$1<infer U> ? U : never;
|
|
1997
|
-
type EventDefinition$1<Payload = unknown, Type extends string = string> = {
|
|
1998
|
-
__type: 'event-definition';
|
|
1999
|
-
type: Type;
|
|
2000
|
-
isDomainEvent?: boolean;
|
|
2001
|
-
transformations?: (envelope: unknown) => Payload;
|
|
2002
|
-
__payload: Payload;
|
|
2003
|
-
};
|
|
2004
|
-
declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
|
|
2005
|
-
type EventHandler$1<T extends EventDefinition$1> = (payload: T['__payload']) => void | Promise<void>;
|
|
2006
|
-
type BuildEventDefinition$1<T extends EventDefinition$1<any, string>> = (handler: EventHandler$1<T>) => void;
|
|
3467
|
+
declare function createRESTModule$1<T extends RESTFunctionDescriptor>(descriptor: T, elevated?: boolean): BuildRESTFunction<T> & T;
|
|
2007
3468
|
|
|
2008
|
-
declare
|
|
2009
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
2010
|
-
interface SymbolConstructor {
|
|
2011
|
-
readonly observable: symbol;
|
|
2012
|
-
}
|
|
2013
|
-
}
|
|
3469
|
+
declare function createEventModule$1<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
2014
3470
|
|
|
2015
|
-
declare
|
|
2016
|
-
declare
|
|
2017
|
-
declare
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
declare
|
|
2024
|
-
_id: string;
|
|
2025
|
-
contactId: string;
|
|
2026
|
-
referringCustomerId: string;
|
|
2027
|
-
status: Status;
|
|
2028
|
-
}>;
|
|
2029
|
-
declare function deleteReferredFriend$1(httpClient: HttpClient$1): (referredFriendId: string, options?: DeleteReferredFriendOptions) => Promise<void>;
|
|
2030
|
-
declare function queryReferredFriend$1(httpClient: HttpClient$1): () => ReferredFriendsQueryBuilder;
|
|
2031
|
-
declare const onReferredFriendCreated$1: EventDefinition$1<ReferredFriendCreatedEnvelope, "wix.loyalty.referral.v1.referred_friend_created">;
|
|
2032
|
-
declare const onReferredFriendUpdated$1: EventDefinition$1<ReferredFriendUpdatedEnvelope, "wix.loyalty.referral.v1.referred_friend_updated">;
|
|
2033
|
-
declare const onReferredFriendDeleted$1: EventDefinition$1<ReferredFriendDeletedEnvelope, "wix.loyalty.referral.v1.referred_friend_deleted">;
|
|
2034
|
-
|
|
2035
|
-
declare const createReferredFriend: BuildRESTFunction$1<typeof createReferredFriend$1>;
|
|
2036
|
-
declare const getReferredFriend: BuildRESTFunction$1<typeof getReferredFriend$1>;
|
|
2037
|
-
declare const getReferredFriendByContactId: BuildRESTFunction$1<typeof getReferredFriendByContactId$1>;
|
|
2038
|
-
declare const updateReferredFriend: BuildRESTFunction$1<typeof updateReferredFriend$1>;
|
|
2039
|
-
declare const deleteReferredFriend: BuildRESTFunction$1<typeof deleteReferredFriend$1>;
|
|
2040
|
-
declare const queryReferredFriend: BuildRESTFunction$1<typeof queryReferredFriend$1>;
|
|
2041
|
-
declare const onReferredFriendCreated: BuildEventDefinition$1<typeof onReferredFriendCreated$1>;
|
|
2042
|
-
declare const onReferredFriendUpdated: BuildEventDefinition$1<typeof onReferredFriendUpdated$1>;
|
|
2043
|
-
declare const onReferredFriendDeleted: BuildEventDefinition$1<typeof onReferredFriendDeleted$1>;
|
|
3471
|
+
declare const createReferredFriend: ReturnType<typeof createRESTModule$1<typeof publicCreateReferredFriend>>;
|
|
3472
|
+
declare const getReferredFriend: ReturnType<typeof createRESTModule$1<typeof publicGetReferredFriend>>;
|
|
3473
|
+
declare const getReferredFriendByContactId: ReturnType<typeof createRESTModule$1<typeof publicGetReferredFriendByContactId>>;
|
|
3474
|
+
declare const updateReferredFriend: ReturnType<typeof createRESTModule$1<typeof publicUpdateReferredFriend>>;
|
|
3475
|
+
declare const deleteReferredFriend: ReturnType<typeof createRESTModule$1<typeof publicDeleteReferredFriend>>;
|
|
3476
|
+
declare const queryReferredFriend: ReturnType<typeof createRESTModule$1<typeof publicQueryReferredFriend>>;
|
|
3477
|
+
declare const onReferredFriendCreated: ReturnType<typeof createEventModule$1<typeof publicOnReferredFriendCreated>>;
|
|
3478
|
+
declare const onReferredFriendUpdated: ReturnType<typeof createEventModule$1<typeof publicOnReferredFriendUpdated>>;
|
|
3479
|
+
declare const onReferredFriendDeleted: ReturnType<typeof createEventModule$1<typeof publicOnReferredFriendDeleted>>;
|
|
2044
3480
|
|
|
3481
|
+
type context$1_CreateReferredFriendRequest = CreateReferredFriendRequest;
|
|
3482
|
+
type context$1_CreateReferredFriendResponse = CreateReferredFriendResponse;
|
|
3483
|
+
type context$1_CreateReferredFriendResponseNonNullableFields = CreateReferredFriendResponseNonNullableFields;
|
|
3484
|
+
type context$1_DeleteReferredFriendOptions = DeleteReferredFriendOptions;
|
|
3485
|
+
type context$1_DeleteReferredFriendRequest = DeleteReferredFriendRequest;
|
|
3486
|
+
type context$1_DeleteReferredFriendResponse = DeleteReferredFriendResponse;
|
|
3487
|
+
type context$1_Empty = Empty;
|
|
3488
|
+
type context$1_GetReferredFriendByContactIdRequest = GetReferredFriendByContactIdRequest;
|
|
3489
|
+
type context$1_GetReferredFriendByContactIdResponse = GetReferredFriendByContactIdResponse;
|
|
3490
|
+
type context$1_GetReferredFriendByContactIdResponseNonNullableFields = GetReferredFriendByContactIdResponseNonNullableFields;
|
|
3491
|
+
type context$1_GetReferredFriendRequest = GetReferredFriendRequest;
|
|
3492
|
+
type context$1_GetReferredFriendResponse = GetReferredFriendResponse;
|
|
3493
|
+
type context$1_GetReferredFriendResponseNonNullableFields = GetReferredFriendResponseNonNullableFields;
|
|
3494
|
+
type context$1_QueryReferredFriendRequest = QueryReferredFriendRequest;
|
|
3495
|
+
type context$1_QueryReferredFriendResponse = QueryReferredFriendResponse;
|
|
3496
|
+
type context$1_QueryReferredFriendResponseNonNullableFields = QueryReferredFriendResponseNonNullableFields;
|
|
3497
|
+
type context$1_ReferredFriend = ReferredFriend;
|
|
3498
|
+
type context$1_ReferredFriendCreatedEnvelope = ReferredFriendCreatedEnvelope;
|
|
3499
|
+
type context$1_ReferredFriendDeletedEnvelope = ReferredFriendDeletedEnvelope;
|
|
3500
|
+
type context$1_ReferredFriendDetails = ReferredFriendDetails;
|
|
3501
|
+
type context$1_ReferredFriendNonNullableFields = ReferredFriendNonNullableFields;
|
|
3502
|
+
type context$1_ReferredFriendUpdatedEnvelope = ReferredFriendUpdatedEnvelope;
|
|
3503
|
+
type context$1_ReferredFriendsQueryBuilder = ReferredFriendsQueryBuilder;
|
|
3504
|
+
type context$1_ReferredFriendsQueryResult = ReferredFriendsQueryResult;
|
|
3505
|
+
type context$1_Status = Status;
|
|
3506
|
+
declare const context$1_Status: typeof Status;
|
|
3507
|
+
type context$1_SuccessfulReferralEvent = SuccessfulReferralEvent;
|
|
3508
|
+
type context$1_UpdateReferredFriend = UpdateReferredFriend;
|
|
3509
|
+
type context$1_UpdateReferredFriendRequest = UpdateReferredFriendRequest;
|
|
3510
|
+
type context$1_UpdateReferredFriendResponse = UpdateReferredFriendResponse;
|
|
3511
|
+
type context$1_UpdateReferredFriendResponseNonNullableFields = UpdateReferredFriendResponseNonNullableFields;
|
|
2045
3512
|
declare const context$1_createReferredFriend: typeof createReferredFriend;
|
|
2046
3513
|
declare const context$1_deleteReferredFriend: typeof deleteReferredFriend;
|
|
2047
3514
|
declare const context$1_getReferredFriend: typeof getReferredFriend;
|
|
@@ -2052,7 +3519,7 @@ declare const context$1_onReferredFriendUpdated: typeof onReferredFriendUpdated;
|
|
|
2052
3519
|
declare const context$1_queryReferredFriend: typeof queryReferredFriend;
|
|
2053
3520
|
declare const context$1_updateReferredFriend: typeof updateReferredFriend;
|
|
2054
3521
|
declare namespace context$1 {
|
|
2055
|
-
export { context$1_createReferredFriend as createReferredFriend, context$1_deleteReferredFriend as deleteReferredFriend, context$1_getReferredFriend as getReferredFriend, context$1_getReferredFriendByContactId as getReferredFriendByContactId, context$1_onReferredFriendCreated as onReferredFriendCreated, context$1_onReferredFriendDeleted as onReferredFriendDeleted, context$1_onReferredFriendUpdated as onReferredFriendUpdated, context$1_queryReferredFriend as queryReferredFriend, context$1_updateReferredFriend as updateReferredFriend };
|
|
3522
|
+
export { type ActionEvent$1 as ActionEvent, type BaseEventMetadata$1 as BaseEventMetadata, type context$1_CreateReferredFriendRequest as CreateReferredFriendRequest, type context$1_CreateReferredFriendResponse as CreateReferredFriendResponse, type context$1_CreateReferredFriendResponseNonNullableFields as CreateReferredFriendResponseNonNullableFields, type CursorPaging$1 as CursorPaging, type CursorPagingMetadata$1 as CursorPagingMetadata, type CursorQuery$1 as CursorQuery, type CursorQueryPagingMethodOneOf$1 as CursorQueryPagingMethodOneOf, type Cursors$1 as Cursors, type context$1_DeleteReferredFriendOptions as DeleteReferredFriendOptions, type context$1_DeleteReferredFriendRequest as DeleteReferredFriendRequest, type context$1_DeleteReferredFriendResponse as DeleteReferredFriendResponse, type DomainEvent$1 as DomainEvent, type DomainEventBodyOneOf$1 as DomainEventBodyOneOf, type context$1_Empty as Empty, type EntityCreatedEvent$1 as EntityCreatedEvent, type EntityDeletedEvent$1 as EntityDeletedEvent, type EntityUpdatedEvent$1 as EntityUpdatedEvent, type EventMetadata$1 as EventMetadata, type context$1_GetReferredFriendByContactIdRequest as GetReferredFriendByContactIdRequest, type context$1_GetReferredFriendByContactIdResponse as GetReferredFriendByContactIdResponse, type context$1_GetReferredFriendByContactIdResponseNonNullableFields as GetReferredFriendByContactIdResponseNonNullableFields, type context$1_GetReferredFriendRequest as GetReferredFriendRequest, type context$1_GetReferredFriendResponse as GetReferredFriendResponse, type context$1_GetReferredFriendResponseNonNullableFields as GetReferredFriendResponseNonNullableFields, type IdentificationData$1 as IdentificationData, type IdentificationDataIdOneOf$1 as IdentificationDataIdOneOf, type MessageEnvelope$1 as MessageEnvelope, type context$1_QueryReferredFriendRequest as QueryReferredFriendRequest, type context$1_QueryReferredFriendResponse as QueryReferredFriendResponse, type context$1_QueryReferredFriendResponseNonNullableFields as QueryReferredFriendResponseNonNullableFields, type context$1_ReferredFriend as ReferredFriend, type context$1_ReferredFriendCreatedEnvelope as ReferredFriendCreatedEnvelope, type context$1_ReferredFriendDeletedEnvelope as ReferredFriendDeletedEnvelope, type context$1_ReferredFriendDetails as ReferredFriendDetails, type context$1_ReferredFriendNonNullableFields as ReferredFriendNonNullableFields, type context$1_ReferredFriendUpdatedEnvelope as ReferredFriendUpdatedEnvelope, type context$1_ReferredFriendsQueryBuilder as ReferredFriendsQueryBuilder, type context$1_ReferredFriendsQueryResult as ReferredFriendsQueryResult, SortOrder$1 as SortOrder, type Sorting$1 as Sorting, context$1_Status as Status, type context$1_SuccessfulReferralEvent as SuccessfulReferralEvent, type UndeleteInfo$1 as UndeleteInfo, type context$1_UpdateReferredFriend as UpdateReferredFriend, type context$1_UpdateReferredFriendRequest as UpdateReferredFriendRequest, type context$1_UpdateReferredFriendResponse as UpdateReferredFriendResponse, type context$1_UpdateReferredFriendResponseNonNullableFields as UpdateReferredFriendResponseNonNullableFields, WebhookIdentityType$1 as WebhookIdentityType, context$1_createReferredFriend as createReferredFriend, context$1_deleteReferredFriend as deleteReferredFriend, context$1_getReferredFriend as getReferredFriend, context$1_getReferredFriendByContactId as getReferredFriendByContactId, context$1_onReferredFriendCreated as onReferredFriendCreated, context$1_onReferredFriendDeleted as onReferredFriendDeleted, context$1_onReferredFriendUpdated as onReferredFriendUpdated, context$1_queryReferredFriend as queryReferredFriend, context$1_updateReferredFriend as updateReferredFriend };
|
|
2056
3523
|
}
|
|
2057
3524
|
|
|
2058
3525
|
/** ReferringCustomer is the main entity of ReferringCustomers. */
|
|
@@ -2085,20 +3552,191 @@ interface ReferringCustomer {
|
|
|
2085
3552
|
*/
|
|
2086
3553
|
_updatedDate?: Date;
|
|
2087
3554
|
}
|
|
3555
|
+
interface GenerateReferringCustomerForContactRequest {
|
|
3556
|
+
/** Contact id or "me" to generate current identity's referring customer. */
|
|
3557
|
+
contactId: string;
|
|
3558
|
+
}
|
|
2088
3559
|
interface GenerateReferringCustomerForContactResponse {
|
|
2089
3560
|
/** The created ReferringCustomer. */
|
|
2090
3561
|
referringCustomer?: ReferringCustomer;
|
|
2091
3562
|
}
|
|
3563
|
+
interface GetReferringCustomerRequest {
|
|
3564
|
+
/** Id of the ReferringCustomer to retrieve. */
|
|
3565
|
+
referringCustomerId: string;
|
|
3566
|
+
}
|
|
3567
|
+
interface GetReferringCustomerResponse {
|
|
3568
|
+
/** The retrieved ReferringCustomer. */
|
|
3569
|
+
referringCustomer?: ReferringCustomer;
|
|
3570
|
+
}
|
|
3571
|
+
interface GetReferringCustomerByReferralCodeRequest {
|
|
3572
|
+
/** Referral Code of the ReferringCustomer to retrieve. */
|
|
3573
|
+
referralCode: string;
|
|
3574
|
+
}
|
|
2092
3575
|
interface GetReferringCustomerByReferralCodeResponse {
|
|
2093
3576
|
/** The retrieved ReferringCustomer. */
|
|
2094
3577
|
referringCustomer?: ReferringCustomer;
|
|
2095
3578
|
}
|
|
3579
|
+
interface QueryReferringCustomersRequest {
|
|
3580
|
+
/** Query options. */
|
|
3581
|
+
query: CursorQuery;
|
|
3582
|
+
}
|
|
3583
|
+
interface CursorQuery extends CursorQueryPagingMethodOneOf {
|
|
3584
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
3585
|
+
cursorPaging?: CursorPaging;
|
|
3586
|
+
/**
|
|
3587
|
+
* Filter object in the following format:
|
|
3588
|
+
* `"filter" : {
|
|
3589
|
+
* "fieldName1": "value1",
|
|
3590
|
+
* "fieldName2":{"$operator":"value2"}
|
|
3591
|
+
* }`
|
|
3592
|
+
* Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
|
|
3593
|
+
*/
|
|
3594
|
+
filter?: Record<string, any> | null;
|
|
3595
|
+
/**
|
|
3596
|
+
* Sort object in the following format:
|
|
3597
|
+
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
3598
|
+
*/
|
|
3599
|
+
sort?: Sorting[];
|
|
3600
|
+
}
|
|
3601
|
+
/** @oneof */
|
|
3602
|
+
interface CursorQueryPagingMethodOneOf {
|
|
3603
|
+
/** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
|
|
3604
|
+
cursorPaging?: CursorPaging;
|
|
3605
|
+
}
|
|
3606
|
+
interface Sorting {
|
|
3607
|
+
/** Name of the field to sort by. */
|
|
3608
|
+
fieldName?: string;
|
|
3609
|
+
/** Sort order. */
|
|
3610
|
+
order?: SortOrder;
|
|
3611
|
+
}
|
|
3612
|
+
declare enum SortOrder {
|
|
3613
|
+
ASC = "ASC",
|
|
3614
|
+
DESC = "DESC"
|
|
3615
|
+
}
|
|
3616
|
+
interface CursorPaging {
|
|
3617
|
+
/** Maximum number of items to return in the results. */
|
|
3618
|
+
limit?: number | null;
|
|
3619
|
+
/**
|
|
3620
|
+
* Pointer to the next or previous page in the list of results.
|
|
3621
|
+
*
|
|
3622
|
+
* Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
|
|
3623
|
+
* Not relevant for the first request.
|
|
3624
|
+
*/
|
|
3625
|
+
cursor?: string | null;
|
|
3626
|
+
}
|
|
3627
|
+
interface QueryReferringCustomersResponse {
|
|
3628
|
+
/** The retrieved ReferringCustomers. */
|
|
3629
|
+
referringCustomers?: ReferringCustomer[];
|
|
3630
|
+
/** Paging metadata. */
|
|
3631
|
+
metadata?: CursorPagingMetadata;
|
|
3632
|
+
}
|
|
3633
|
+
interface CursorPagingMetadata {
|
|
3634
|
+
/** Number of items returned in the response. */
|
|
3635
|
+
count?: number | null;
|
|
3636
|
+
/** Cursor strings that point to the next page, previous page, or both. */
|
|
3637
|
+
cursors?: Cursors;
|
|
3638
|
+
/**
|
|
3639
|
+
* Whether there are more pages to retrieve following the current page.
|
|
3640
|
+
*
|
|
3641
|
+
* + `true`: Another page of results can be retrieved.
|
|
3642
|
+
* + `false`: This is the last page.
|
|
3643
|
+
*/
|
|
3644
|
+
hasNext?: boolean | null;
|
|
3645
|
+
}
|
|
2096
3646
|
interface Cursors {
|
|
2097
3647
|
/** Cursor string pointing to the next page in the list of results. */
|
|
2098
3648
|
next?: string | null;
|
|
2099
3649
|
/** Cursor pointing to the previous page in the list of results. */
|
|
2100
3650
|
prev?: string | null;
|
|
2101
3651
|
}
|
|
3652
|
+
interface DeleteReferringCustomerRequest {
|
|
3653
|
+
/** Id of the ReferringCustomer to delete. */
|
|
3654
|
+
referringCustomerId: string;
|
|
3655
|
+
/** The revision of the ReferringCustomer. */
|
|
3656
|
+
revision?: string;
|
|
3657
|
+
}
|
|
3658
|
+
interface DeleteReferringCustomerResponse {
|
|
3659
|
+
}
|
|
3660
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
3661
|
+
createdEvent?: EntityCreatedEvent;
|
|
3662
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
3663
|
+
deletedEvent?: EntityDeletedEvent;
|
|
3664
|
+
actionEvent?: ActionEvent;
|
|
3665
|
+
/**
|
|
3666
|
+
* Unique event ID.
|
|
3667
|
+
* Allows clients to ignore duplicate webhooks.
|
|
3668
|
+
*/
|
|
3669
|
+
_id?: string;
|
|
3670
|
+
/**
|
|
3671
|
+
* Assumes actions are also always typed to an entity_type
|
|
3672
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
3673
|
+
*/
|
|
3674
|
+
entityFqdn?: string;
|
|
3675
|
+
/**
|
|
3676
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
3677
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
3678
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
3679
|
+
*/
|
|
3680
|
+
slug?: string;
|
|
3681
|
+
/** ID of the entity associated with the event. */
|
|
3682
|
+
entityId?: string;
|
|
3683
|
+
/** Event timestamp. */
|
|
3684
|
+
eventTime?: Date;
|
|
3685
|
+
/**
|
|
3686
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
3687
|
+
* (for example, GDPR).
|
|
3688
|
+
*/
|
|
3689
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
3690
|
+
/** If present, indicates the action that triggered the event. */
|
|
3691
|
+
originatedFrom?: string | null;
|
|
3692
|
+
/**
|
|
3693
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
3694
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
3695
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
3696
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
3697
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
3698
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
3699
|
+
*/
|
|
3700
|
+
entityEventSequence?: string | null;
|
|
3701
|
+
}
|
|
3702
|
+
/** @oneof */
|
|
3703
|
+
interface DomainEventBodyOneOf {
|
|
3704
|
+
createdEvent?: EntityCreatedEvent;
|
|
3705
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
3706
|
+
deletedEvent?: EntityDeletedEvent;
|
|
3707
|
+
actionEvent?: ActionEvent;
|
|
3708
|
+
}
|
|
3709
|
+
interface EntityCreatedEvent {
|
|
3710
|
+
entity?: string;
|
|
3711
|
+
}
|
|
3712
|
+
interface UndeleteInfo {
|
|
3713
|
+
deletedDate?: Date;
|
|
3714
|
+
}
|
|
3715
|
+
interface EntityUpdatedEvent {
|
|
3716
|
+
/**
|
|
3717
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
3718
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
3719
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
3720
|
+
*/
|
|
3721
|
+
currentEntity?: string;
|
|
3722
|
+
}
|
|
3723
|
+
interface EntityDeletedEvent {
|
|
3724
|
+
/** Entity that was deleted */
|
|
3725
|
+
deletedEntity?: string | null;
|
|
3726
|
+
}
|
|
3727
|
+
interface ActionEvent {
|
|
3728
|
+
body?: string;
|
|
3729
|
+
}
|
|
3730
|
+
interface MessageEnvelope {
|
|
3731
|
+
/** App instance ID. */
|
|
3732
|
+
instanceId?: string | null;
|
|
3733
|
+
/** Event type. */
|
|
3734
|
+
eventType?: string;
|
|
3735
|
+
/** The identification type and identity data. */
|
|
3736
|
+
identity?: IdentificationData;
|
|
3737
|
+
/** Stringify payload. */
|
|
3738
|
+
data?: string;
|
|
3739
|
+
}
|
|
2102
3740
|
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
2103
3741
|
/** ID of a site visitor that has not logged in to the site. */
|
|
2104
3742
|
anonymousVisitorId?: string;
|
|
@@ -2129,19 +3767,22 @@ declare enum WebhookIdentityType {
|
|
|
2129
3767
|
WIX_USER = "WIX_USER",
|
|
2130
3768
|
APP = "APP"
|
|
2131
3769
|
}
|
|
3770
|
+
interface ReferringCustomerNonNullableFields {
|
|
3771
|
+
_id: string;
|
|
3772
|
+
contactId: string;
|
|
3773
|
+
referralCode: string;
|
|
3774
|
+
}
|
|
2132
3775
|
interface GenerateReferringCustomerForContactResponseNonNullableFields {
|
|
2133
|
-
referringCustomer?:
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
};
|
|
3776
|
+
referringCustomer?: ReferringCustomerNonNullableFields;
|
|
3777
|
+
}
|
|
3778
|
+
interface GetReferringCustomerResponseNonNullableFields {
|
|
3779
|
+
referringCustomer?: ReferringCustomerNonNullableFields;
|
|
2138
3780
|
}
|
|
2139
3781
|
interface GetReferringCustomerByReferralCodeResponseNonNullableFields {
|
|
2140
|
-
referringCustomer?:
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
};
|
|
3782
|
+
referringCustomer?: ReferringCustomerNonNullableFields;
|
|
3783
|
+
}
|
|
3784
|
+
interface QueryReferringCustomersResponseNonNullableFields {
|
|
3785
|
+
referringCustomers: ReferringCustomerNonNullableFields[];
|
|
2145
3786
|
}
|
|
2146
3787
|
interface BaseEventMetadata {
|
|
2147
3788
|
/** App instance ID. */
|
|
@@ -2278,69 +3919,61 @@ interface DeleteReferringCustomerOptions {
|
|
|
2278
3919
|
revision?: string;
|
|
2279
3920
|
}
|
|
2280
3921
|
|
|
2281
|
-
|
|
2282
|
-
interface HttpClient {
|
|
2283
|
-
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
2284
|
-
fetchWithAuth: (url: string | URL, init?: RequestInit) => Promise<Response>;
|
|
2285
|
-
}
|
|
2286
|
-
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
2287
|
-
type HttpResponse<T = any> = {
|
|
2288
|
-
data: T;
|
|
2289
|
-
status: number;
|
|
2290
|
-
statusText: string;
|
|
2291
|
-
headers: any;
|
|
2292
|
-
request?: any;
|
|
2293
|
-
};
|
|
2294
|
-
type RequestOptions<_TResponse = any, Data = any> = {
|
|
2295
|
-
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
2296
|
-
url: string;
|
|
2297
|
-
data?: Data;
|
|
2298
|
-
params?: URLSearchParams;
|
|
2299
|
-
} & APIMetadata;
|
|
2300
|
-
type APIMetadata = {
|
|
2301
|
-
methodFqn?: string;
|
|
2302
|
-
entityFqdn?: string;
|
|
2303
|
-
packageName?: string;
|
|
2304
|
-
};
|
|
2305
|
-
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
2306
|
-
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
2307
|
-
__type: 'event-definition';
|
|
2308
|
-
type: Type;
|
|
2309
|
-
isDomainEvent?: boolean;
|
|
2310
|
-
transformations?: (envelope: unknown) => Payload;
|
|
2311
|
-
__payload: Payload;
|
|
2312
|
-
};
|
|
2313
|
-
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
2314
|
-
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
2315
|
-
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
3922
|
+
declare function createRESTModule<T extends RESTFunctionDescriptor>(descriptor: T, elevated?: boolean): BuildRESTFunction<T> & T;
|
|
2316
3923
|
|
|
2317
|
-
declare
|
|
2318
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
2319
|
-
interface SymbolConstructor {
|
|
2320
|
-
readonly observable: symbol;
|
|
2321
|
-
}
|
|
2322
|
-
}
|
|
2323
|
-
|
|
2324
|
-
declare function generateReferringCustomerForContact$1(httpClient: HttpClient): (contactId: string) => Promise<GenerateReferringCustomerForContactResponse & GenerateReferringCustomerForContactResponseNonNullableFields>;
|
|
2325
|
-
declare function getReferringCustomer$1(httpClient: HttpClient): (referringCustomerId: string) => Promise<ReferringCustomer & {
|
|
2326
|
-
_id: string;
|
|
2327
|
-
contactId: string;
|
|
2328
|
-
referralCode: string;
|
|
2329
|
-
}>;
|
|
2330
|
-
declare function getReferringCustomerByReferralCode$1(httpClient: HttpClient): (referralCode: string) => Promise<GetReferringCustomerByReferralCodeResponse & GetReferringCustomerByReferralCodeResponseNonNullableFields>;
|
|
2331
|
-
declare function queryReferringCustomers$1(httpClient: HttpClient): () => ReferringCustomersQueryBuilder;
|
|
2332
|
-
declare function deleteReferringCustomer$1(httpClient: HttpClient): (referringCustomerId: string, options?: DeleteReferringCustomerOptions) => Promise<void>;
|
|
2333
|
-
declare const onReferringCustomerCreated$1: EventDefinition<ReferringCustomerCreatedEnvelope, "wix.loyalty.referral.v1.referring_customer_created">;
|
|
2334
|
-
declare const onReferringCustomerDeleted$1: EventDefinition<ReferringCustomerDeletedEnvelope, "wix.loyalty.referral.v1.referring_customer_deleted">;
|
|
3924
|
+
declare function createEventModule<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
2335
3925
|
|
|
2336
|
-
declare const generateReferringCustomerForContact:
|
|
2337
|
-
declare const getReferringCustomer:
|
|
2338
|
-
declare const getReferringCustomerByReferralCode:
|
|
2339
|
-
declare const queryReferringCustomers:
|
|
2340
|
-
declare const deleteReferringCustomer:
|
|
2341
|
-
declare const onReferringCustomerCreated:
|
|
2342
|
-
declare const onReferringCustomerDeleted:
|
|
3926
|
+
declare const generateReferringCustomerForContact: ReturnType<typeof createRESTModule<typeof publicGenerateReferringCustomerForContact>>;
|
|
3927
|
+
declare const getReferringCustomer: ReturnType<typeof createRESTModule<typeof publicGetReferringCustomer>>;
|
|
3928
|
+
declare const getReferringCustomerByReferralCode: ReturnType<typeof createRESTModule<typeof publicGetReferringCustomerByReferralCode>>;
|
|
3929
|
+
declare const queryReferringCustomers: ReturnType<typeof createRESTModule<typeof publicQueryReferringCustomers>>;
|
|
3930
|
+
declare const deleteReferringCustomer: ReturnType<typeof createRESTModule<typeof publicDeleteReferringCustomer>>;
|
|
3931
|
+
declare const onReferringCustomerCreated: ReturnType<typeof createEventModule<typeof publicOnReferringCustomerCreated>>;
|
|
3932
|
+
declare const onReferringCustomerDeleted: ReturnType<typeof createEventModule<typeof publicOnReferringCustomerDeleted>>;
|
|
2343
3933
|
|
|
3934
|
+
type context_ActionEvent = ActionEvent;
|
|
3935
|
+
type context_BaseEventMetadata = BaseEventMetadata;
|
|
3936
|
+
type context_CursorPaging = CursorPaging;
|
|
3937
|
+
type context_CursorPagingMetadata = CursorPagingMetadata;
|
|
3938
|
+
type context_CursorQuery = CursorQuery;
|
|
3939
|
+
type context_CursorQueryPagingMethodOneOf = CursorQueryPagingMethodOneOf;
|
|
3940
|
+
type context_Cursors = Cursors;
|
|
3941
|
+
type context_DeleteReferringCustomerOptions = DeleteReferringCustomerOptions;
|
|
3942
|
+
type context_DeleteReferringCustomerRequest = DeleteReferringCustomerRequest;
|
|
3943
|
+
type context_DeleteReferringCustomerResponse = DeleteReferringCustomerResponse;
|
|
3944
|
+
type context_DomainEvent = DomainEvent;
|
|
3945
|
+
type context_DomainEventBodyOneOf = DomainEventBodyOneOf;
|
|
3946
|
+
type context_EntityCreatedEvent = EntityCreatedEvent;
|
|
3947
|
+
type context_EntityDeletedEvent = EntityDeletedEvent;
|
|
3948
|
+
type context_EntityUpdatedEvent = EntityUpdatedEvent;
|
|
3949
|
+
type context_EventMetadata = EventMetadata;
|
|
3950
|
+
type context_GenerateReferringCustomerForContactRequest = GenerateReferringCustomerForContactRequest;
|
|
3951
|
+
type context_GenerateReferringCustomerForContactResponse = GenerateReferringCustomerForContactResponse;
|
|
3952
|
+
type context_GenerateReferringCustomerForContactResponseNonNullableFields = GenerateReferringCustomerForContactResponseNonNullableFields;
|
|
3953
|
+
type context_GetReferringCustomerByReferralCodeRequest = GetReferringCustomerByReferralCodeRequest;
|
|
3954
|
+
type context_GetReferringCustomerByReferralCodeResponse = GetReferringCustomerByReferralCodeResponse;
|
|
3955
|
+
type context_GetReferringCustomerByReferralCodeResponseNonNullableFields = GetReferringCustomerByReferralCodeResponseNonNullableFields;
|
|
3956
|
+
type context_GetReferringCustomerRequest = GetReferringCustomerRequest;
|
|
3957
|
+
type context_GetReferringCustomerResponse = GetReferringCustomerResponse;
|
|
3958
|
+
type context_GetReferringCustomerResponseNonNullableFields = GetReferringCustomerResponseNonNullableFields;
|
|
3959
|
+
type context_IdentificationData = IdentificationData;
|
|
3960
|
+
type context_IdentificationDataIdOneOf = IdentificationDataIdOneOf;
|
|
3961
|
+
type context_MessageEnvelope = MessageEnvelope;
|
|
3962
|
+
type context_QueryReferringCustomersRequest = QueryReferringCustomersRequest;
|
|
3963
|
+
type context_QueryReferringCustomersResponse = QueryReferringCustomersResponse;
|
|
3964
|
+
type context_QueryReferringCustomersResponseNonNullableFields = QueryReferringCustomersResponseNonNullableFields;
|
|
3965
|
+
type context_ReferringCustomer = ReferringCustomer;
|
|
3966
|
+
type context_ReferringCustomerCreatedEnvelope = ReferringCustomerCreatedEnvelope;
|
|
3967
|
+
type context_ReferringCustomerDeletedEnvelope = ReferringCustomerDeletedEnvelope;
|
|
3968
|
+
type context_ReferringCustomerNonNullableFields = ReferringCustomerNonNullableFields;
|
|
3969
|
+
type context_ReferringCustomersQueryBuilder = ReferringCustomersQueryBuilder;
|
|
3970
|
+
type context_ReferringCustomersQueryResult = ReferringCustomersQueryResult;
|
|
3971
|
+
type context_SortOrder = SortOrder;
|
|
3972
|
+
declare const context_SortOrder: typeof SortOrder;
|
|
3973
|
+
type context_Sorting = Sorting;
|
|
3974
|
+
type context_UndeleteInfo = UndeleteInfo;
|
|
3975
|
+
type context_WebhookIdentityType = WebhookIdentityType;
|
|
3976
|
+
declare const context_WebhookIdentityType: typeof WebhookIdentityType;
|
|
2344
3977
|
declare const context_deleteReferringCustomer: typeof deleteReferringCustomer;
|
|
2345
3978
|
declare const context_generateReferringCustomerForContact: typeof generateReferringCustomerForContact;
|
|
2346
3979
|
declare const context_getReferringCustomer: typeof getReferringCustomer;
|
|
@@ -2349,7 +3982,7 @@ declare const context_onReferringCustomerCreated: typeof onReferringCustomerCrea
|
|
|
2349
3982
|
declare const context_onReferringCustomerDeleted: typeof onReferringCustomerDeleted;
|
|
2350
3983
|
declare const context_queryReferringCustomers: typeof queryReferringCustomers;
|
|
2351
3984
|
declare namespace context {
|
|
2352
|
-
export { context_deleteReferringCustomer as deleteReferringCustomer, context_generateReferringCustomerForContact as generateReferringCustomerForContact, context_getReferringCustomer as getReferringCustomer, context_getReferringCustomerByReferralCode as getReferringCustomerByReferralCode, context_onReferringCustomerCreated as onReferringCustomerCreated, context_onReferringCustomerDeleted as onReferringCustomerDeleted, context_queryReferringCustomers as queryReferringCustomers };
|
|
3985
|
+
export { type context_ActionEvent as ActionEvent, type context_BaseEventMetadata as BaseEventMetadata, type context_CursorPaging as CursorPaging, type context_CursorPagingMetadata as CursorPagingMetadata, type context_CursorQuery as CursorQuery, type context_CursorQueryPagingMethodOneOf as CursorQueryPagingMethodOneOf, type context_Cursors as Cursors, type context_DeleteReferringCustomerOptions as DeleteReferringCustomerOptions, type context_DeleteReferringCustomerRequest as DeleteReferringCustomerRequest, type context_DeleteReferringCustomerResponse as DeleteReferringCustomerResponse, type context_DomainEvent as DomainEvent, type context_DomainEventBodyOneOf as DomainEventBodyOneOf, type context_EntityCreatedEvent as EntityCreatedEvent, type context_EntityDeletedEvent as EntityDeletedEvent, type context_EntityUpdatedEvent as EntityUpdatedEvent, type context_EventMetadata as EventMetadata, type context_GenerateReferringCustomerForContactRequest as GenerateReferringCustomerForContactRequest, type context_GenerateReferringCustomerForContactResponse as GenerateReferringCustomerForContactResponse, type context_GenerateReferringCustomerForContactResponseNonNullableFields as GenerateReferringCustomerForContactResponseNonNullableFields, type context_GetReferringCustomerByReferralCodeRequest as GetReferringCustomerByReferralCodeRequest, type context_GetReferringCustomerByReferralCodeResponse as GetReferringCustomerByReferralCodeResponse, type context_GetReferringCustomerByReferralCodeResponseNonNullableFields as GetReferringCustomerByReferralCodeResponseNonNullableFields, type context_GetReferringCustomerRequest as GetReferringCustomerRequest, type context_GetReferringCustomerResponse as GetReferringCustomerResponse, type context_GetReferringCustomerResponseNonNullableFields as GetReferringCustomerResponseNonNullableFields, type context_IdentificationData as IdentificationData, type context_IdentificationDataIdOneOf as IdentificationDataIdOneOf, type context_MessageEnvelope as MessageEnvelope, type context_QueryReferringCustomersRequest as QueryReferringCustomersRequest, type context_QueryReferringCustomersResponse as QueryReferringCustomersResponse, type context_QueryReferringCustomersResponseNonNullableFields as QueryReferringCustomersResponseNonNullableFields, type context_ReferringCustomer as ReferringCustomer, type context_ReferringCustomerCreatedEnvelope as ReferringCustomerCreatedEnvelope, type context_ReferringCustomerDeletedEnvelope as ReferringCustomerDeletedEnvelope, type context_ReferringCustomerNonNullableFields as ReferringCustomerNonNullableFields, type context_ReferringCustomersQueryBuilder as ReferringCustomersQueryBuilder, type context_ReferringCustomersQueryResult as ReferringCustomersQueryResult, context_SortOrder as SortOrder, type context_Sorting as Sorting, type context_UndeleteInfo as UndeleteInfo, context_WebhookIdentityType as WebhookIdentityType, context_deleteReferringCustomer as deleteReferringCustomer, context_generateReferringCustomerForContact as generateReferringCustomerForContact, context_getReferringCustomer as getReferringCustomer, context_getReferringCustomerByReferralCode as getReferringCustomerByReferralCode, context_onReferringCustomerCreated as onReferringCustomerCreated, context_onReferringCustomerDeleted as onReferringCustomerDeleted, context_queryReferringCustomers as queryReferringCustomers };
|
|
2353
3986
|
}
|
|
2354
3987
|
|
|
2355
3988
|
export { context as customers, context$1 as friends, context$4 as programs, context$2 as rewards, context$3 as tracker };
|