@wix/auto_sdk_loyalty_earning-rules 1.0.11 → 1.0.12
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/build/index.d.mts +114 -0
- package/build/index.d.ts +114 -0
- package/build/index.js +798 -0
- package/build/index.js.map +1 -0
- package/build/index.mjs +756 -0
- package/build/index.mjs.map +1 -0
- package/build/internal/index.d.mts +114 -0
- package/build/internal/index.d.ts +114 -0
- package/build/internal/index.js +798 -0
- package/build/internal/index.js.map +1 -0
- package/build/internal/index.mjs +756 -0
- package/build/internal/index.mjs.map +1 -0
- package/build/internal/{es/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.d.ts → loyalty-v1-loyalty-earning-rule-earning-rules.universal-B7haYXGy.d.mts} +239 -105
- package/build/{es/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.d.ts → internal/loyalty-v1-loyalty-earning-rule-earning-rules.universal-B7haYXGy.d.ts} +239 -105
- package/build/internal/meta.d.mts +326 -0
- package/build/internal/meta.d.ts +326 -0
- package/build/internal/meta.js +500 -0
- package/build/internal/meta.js.map +1 -0
- package/build/internal/meta.mjs +466 -0
- package/build/internal/meta.mjs.map +1 -0
- package/build/{cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.d.ts → loyalty-v1-loyalty-earning-rule-earning-rules.universal-C7uemg2R.d.mts} +234 -105
- package/build/{internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.d.ts → loyalty-v1-loyalty-earning-rule-earning-rules.universal-C7uemg2R.d.ts} +234 -105
- package/build/meta.d.mts +326 -0
- package/build/meta.d.ts +326 -0
- package/build/meta.js +500 -0
- package/build/meta.js.map +1 -0
- package/build/meta.mjs +466 -0
- package/build/meta.mjs.map +1 -0
- package/package.json +13 -12
- package/build/cjs/index.d.ts +0 -1
- package/build/cjs/index.js +0 -18
- package/build/cjs/index.js.map +0 -1
- package/build/cjs/index.typings.d.ts +0 -1
- package/build/cjs/index.typings.js +0 -18
- package/build/cjs/index.typings.js.map +0 -1
- package/build/cjs/meta.d.ts +0 -1
- package/build/cjs/meta.js +0 -18
- package/build/cjs/meta.js.map +0 -1
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.d.ts +0 -28
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js +0 -39
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js.map +0 -1
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.d.ts +0 -48
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js +0 -353
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js.map +0 -1
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.d.ts +0 -28
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js +0 -180
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js.map +0 -1
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.d.ts +0 -93
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js +0 -97
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js.map +0 -1
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js +0 -151
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js.map +0 -1
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.d.ts +0 -1294
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js +0 -514
- package/build/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js.map +0 -1
- package/build/es/index.d.ts +0 -1
- package/build/es/index.js +0 -2
- package/build/es/index.js.map +0 -1
- package/build/es/index.typings.d.ts +0 -1
- package/build/es/index.typings.js +0 -2
- package/build/es/index.typings.js.map +0 -1
- package/build/es/meta.d.ts +0 -1
- package/build/es/meta.js +0 -2
- package/build/es/meta.js.map +0 -1
- package/build/es/package.json +0 -3
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.d.ts +0 -28
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js +0 -28
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js.map +0 -1
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.d.ts +0 -48
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js +0 -342
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js.map +0 -1
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.d.ts +0 -28
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js +0 -146
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js.map +0 -1
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.d.ts +0 -93
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js +0 -78
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js.map +0 -1
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js +0 -148
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js.map +0 -1
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.d.ts +0 -1294
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js +0 -480
- package/build/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js.map +0 -1
- package/build/internal/cjs/index.d.ts +0 -1
- package/build/internal/cjs/index.js +0 -18
- package/build/internal/cjs/index.js.map +0 -1
- package/build/internal/cjs/index.typings.d.ts +0 -1
- package/build/internal/cjs/index.typings.js +0 -18
- package/build/internal/cjs/index.typings.js.map +0 -1
- package/build/internal/cjs/meta.d.ts +0 -1
- package/build/internal/cjs/meta.js +0 -18
- package/build/internal/cjs/meta.js.map +0 -1
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.d.ts +0 -28
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js +0 -39
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js.map +0 -1
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.d.ts +0 -48
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js +0 -353
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js.map +0 -1
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.d.ts +0 -28
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js +0 -180
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js.map +0 -1
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.d.ts +0 -93
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js +0 -97
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js.map +0 -1
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js +0 -151
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js.map +0 -1
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.d.ts +0 -1299
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js +0 -514
- package/build/internal/cjs/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js.map +0 -1
- package/build/internal/es/index.d.ts +0 -1
- package/build/internal/es/index.js +0 -2
- package/build/internal/es/index.js.map +0 -1
- package/build/internal/es/index.typings.d.ts +0 -1
- package/build/internal/es/index.typings.js +0 -2
- package/build/internal/es/index.typings.js.map +0 -1
- package/build/internal/es/meta.d.ts +0 -1
- package/build/internal/es/meta.js +0 -2
- package/build/internal/es/meta.js.map +0 -1
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.d.ts +0 -28
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js +0 -28
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.context.js.map +0 -1
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.d.ts +0 -48
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js +0 -342
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.http.js.map +0 -1
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.d.ts +0 -28
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js +0 -146
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.meta.js.map +0 -1
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.d.ts +0 -93
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js +0 -78
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.public.js.map +0 -1
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js +0 -148
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.types.js.map +0 -1
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.d.ts +0 -1299
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js +0 -480
- package/build/internal/es/src/loyalty-v1-loyalty-earning-rule-earning-rules.universal.js.map +0 -1
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* A loyalty earning rule defines how customers earn points in a loyalty program.
|
|
3
3
|
* You can create rules for different activities, such as making purchases.
|
|
4
4
|
*/
|
|
5
|
-
|
|
5
|
+
interface LoyaltyEarningRule extends LoyaltyEarningRuleTypeOneOf {
|
|
6
6
|
/** Fixed amount of points awarded for each qualifying activity. */
|
|
7
7
|
fixedAmount?: FixedAmount;
|
|
8
8
|
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
@@ -12,7 +12,7 @@ export interface LoyaltyEarningRule extends LoyaltyEarningRuleTypeOneOf {
|
|
|
12
12
|
* @format GUID
|
|
13
13
|
* @readonly
|
|
14
14
|
*/
|
|
15
|
-
|
|
15
|
+
_id?: string | null;
|
|
16
16
|
/**
|
|
17
17
|
* ID of the app managing the earning rule. Can be a loyalty app ID or a Wix automations app ID.
|
|
18
18
|
* @format GUID
|
|
@@ -47,12 +47,12 @@ export interface LoyaltyEarningRule extends LoyaltyEarningRuleTypeOneOf {
|
|
|
47
47
|
* Date and time the earning rule was created.
|
|
48
48
|
* @readonly
|
|
49
49
|
*/
|
|
50
|
-
|
|
50
|
+
_createdDate?: Date | null;
|
|
51
51
|
/**
|
|
52
52
|
* Date and time the earning rule was last updated.
|
|
53
53
|
* @readonly
|
|
54
54
|
*/
|
|
55
|
-
|
|
55
|
+
_updatedDate?: Date | null;
|
|
56
56
|
/**
|
|
57
57
|
* Additional metadata about the earning rule.
|
|
58
58
|
* @readonly
|
|
@@ -60,21 +60,21 @@ export interface LoyaltyEarningRule extends LoyaltyEarningRuleTypeOneOf {
|
|
|
60
60
|
metadata?: Metadata;
|
|
61
61
|
}
|
|
62
62
|
/** @oneof */
|
|
63
|
-
|
|
63
|
+
interface LoyaltyEarningRuleTypeOneOf {
|
|
64
64
|
/** Fixed amount of points awarded for each qualifying activity. */
|
|
65
65
|
fixedAmount?: FixedAmount;
|
|
66
66
|
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
67
67
|
conversionRate?: ConversionRate;
|
|
68
68
|
}
|
|
69
69
|
/** Fixed amount type of earning rule. */
|
|
70
|
-
|
|
70
|
+
interface FixedAmount {
|
|
71
71
|
/**
|
|
72
72
|
* Fixed amount configurations for each tier.
|
|
73
73
|
* @maxSize 21
|
|
74
74
|
*/
|
|
75
75
|
configs?: FixedAmountConfig[];
|
|
76
76
|
}
|
|
77
|
-
|
|
77
|
+
interface FixedAmountConfig {
|
|
78
78
|
/**
|
|
79
79
|
* Tier ID. If empty, the [base tier](https://dev.wix.com/docs/rest/crm/loyalty-program/tiers/introduction#terminology) is used.
|
|
80
80
|
* @format GUID
|
|
@@ -89,7 +89,7 @@ export interface FixedAmountConfig {
|
|
|
89
89
|
* Customers earn points based on the amount spent.
|
|
90
90
|
* For example, for every $10 spent, a customer might earn 1 point.
|
|
91
91
|
*/
|
|
92
|
-
|
|
92
|
+
interface ConversionRate {
|
|
93
93
|
/**
|
|
94
94
|
* Conversion rate configurations for each tier.
|
|
95
95
|
*
|
|
@@ -106,7 +106,7 @@ export interface ConversionRate {
|
|
|
106
106
|
*/
|
|
107
107
|
field?: string | null;
|
|
108
108
|
}
|
|
109
|
-
|
|
109
|
+
interface ConversionRateConfig {
|
|
110
110
|
/**
|
|
111
111
|
* Tier ID. If empty, the [base tier](https://dev.wix.com/docs/rest/crm/loyalty-program/tiers/introduction) is used.
|
|
112
112
|
* @format GUID
|
|
@@ -133,7 +133,7 @@ export interface ConversionRateConfig {
|
|
|
133
133
|
*/
|
|
134
134
|
points?: number;
|
|
135
135
|
}
|
|
136
|
-
|
|
136
|
+
declare enum Status {
|
|
137
137
|
/** Status is unknown or not specified. */
|
|
138
138
|
UNKNOWN = "UNKNOWN",
|
|
139
139
|
/** Earning rule is active and can assign points. */
|
|
@@ -142,36 +142,36 @@ export declare enum Status {
|
|
|
142
142
|
PAUSED = "PAUSED"
|
|
143
143
|
}
|
|
144
144
|
/** @enumType */
|
|
145
|
-
|
|
146
|
-
|
|
145
|
+
type StatusWithLiterals = Status | 'UNKNOWN' | 'ACTIVE' | 'PAUSED';
|
|
146
|
+
interface Metadata {
|
|
147
147
|
/** Whether the earning rule can be deleted. */
|
|
148
148
|
canBeDeleted?: boolean;
|
|
149
149
|
}
|
|
150
|
-
|
|
150
|
+
interface LoyaltyEarningRuleTypeTag {
|
|
151
151
|
/** Type of custom earning rule. */
|
|
152
152
|
ruleType?: LoyaltyEarningRuleTypeTagTypeWithLiterals;
|
|
153
153
|
}
|
|
154
|
-
|
|
154
|
+
declare enum LoyaltyEarningRuleTypeTagType {
|
|
155
155
|
/** Type is unknown or not specified. */
|
|
156
156
|
UNKNOWN_TYPE = "UNKNOWN_TYPE",
|
|
157
157
|
/** Earning rule for a customer's birthday. */
|
|
158
158
|
BIRTHDAY = "BIRTHDAY"
|
|
159
159
|
}
|
|
160
160
|
/** @enumType */
|
|
161
|
-
|
|
162
|
-
|
|
161
|
+
type LoyaltyEarningRuleTypeTagTypeWithLiterals = LoyaltyEarningRuleTypeTagType | 'UNKNOWN_TYPE' | 'BIRTHDAY';
|
|
162
|
+
interface CacheInvalidated {
|
|
163
163
|
}
|
|
164
|
-
|
|
164
|
+
interface EarningRuleDisabled {
|
|
165
165
|
}
|
|
166
|
-
|
|
166
|
+
interface CreateLoyaltyEarningRuleRequest {
|
|
167
167
|
/** Earning rule to create. */
|
|
168
168
|
earningRule: LoyaltyEarningRule;
|
|
169
169
|
}
|
|
170
|
-
|
|
170
|
+
interface CreateLoyaltyEarningRuleResponse {
|
|
171
171
|
/** Created earning rule. */
|
|
172
172
|
earningRule?: LoyaltyEarningRule;
|
|
173
173
|
}
|
|
174
|
-
|
|
174
|
+
interface BulkCreateLoyaltyEarningRulesRequest {
|
|
175
175
|
/**
|
|
176
176
|
* Earning rules to create.
|
|
177
177
|
* @minSize 1
|
|
@@ -179,21 +179,21 @@ export interface BulkCreateLoyaltyEarningRulesRequest {
|
|
|
179
179
|
*/
|
|
180
180
|
earningRules: LoyaltyEarningRule[];
|
|
181
181
|
}
|
|
182
|
-
|
|
182
|
+
interface BulkCreateLoyaltyEarningRulesResponse {
|
|
183
183
|
/** Created earning rules. */
|
|
184
184
|
results?: BulkLoyaltyEarningRuleResult[];
|
|
185
185
|
/** Additional metadata for the created earning rules. */
|
|
186
186
|
bulkActionMetadata?: BulkActionMetadata;
|
|
187
187
|
}
|
|
188
|
-
|
|
188
|
+
interface BulkLoyaltyEarningRuleResult {
|
|
189
189
|
/** Additional metadata for the created earning rules. */
|
|
190
190
|
itemMetadata?: ItemMetadata;
|
|
191
191
|
/** Created earning rule. */
|
|
192
192
|
item?: LoyaltyEarningRule;
|
|
193
193
|
}
|
|
194
|
-
|
|
194
|
+
interface ItemMetadata {
|
|
195
195
|
/** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
|
|
196
|
-
|
|
196
|
+
_id?: string | null;
|
|
197
197
|
/** Index of the item within the request array. Allows for correlation between request and response items. */
|
|
198
198
|
originalIndex?: number;
|
|
199
199
|
/** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
|
|
@@ -201,7 +201,7 @@ export interface ItemMetadata {
|
|
|
201
201
|
/** Details about the error in case of failure. */
|
|
202
202
|
error?: ApplicationError;
|
|
203
203
|
}
|
|
204
|
-
|
|
204
|
+
interface ApplicationError {
|
|
205
205
|
/** Error code. */
|
|
206
206
|
code?: string;
|
|
207
207
|
/** Description of the error. */
|
|
@@ -209,7 +209,7 @@ export interface ApplicationError {
|
|
|
209
209
|
/** Data related to the error. */
|
|
210
210
|
data?: Record<string, any> | null;
|
|
211
211
|
}
|
|
212
|
-
|
|
212
|
+
interface BulkActionMetadata {
|
|
213
213
|
/** Number of items that were successfully processed. */
|
|
214
214
|
totalSuccesses?: number;
|
|
215
215
|
/** Number of items that couldn't be processed. */
|
|
@@ -217,13 +217,13 @@ export interface BulkActionMetadata {
|
|
|
217
217
|
/** Number of failures without details because detailed failure threshold was exceeded. */
|
|
218
218
|
undetailedFailures?: number;
|
|
219
219
|
}
|
|
220
|
-
|
|
220
|
+
interface CreateCustomLoyaltyEarningRuleRequest {
|
|
221
221
|
/** Type of the custom earning rule. */
|
|
222
222
|
type: TypeWithLiterals;
|
|
223
223
|
/** Custom earning rule to create. */
|
|
224
224
|
earningRule?: CustomLoyaltyEarningRule;
|
|
225
225
|
}
|
|
226
|
-
|
|
226
|
+
declare enum Type {
|
|
227
227
|
/** Unknown type. This value is not used. */
|
|
228
228
|
UNKNOWN_TYPE = "UNKNOWN_TYPE",
|
|
229
229
|
/** Earning rule for social media. */
|
|
@@ -232,9 +232,9 @@ export declare enum Type {
|
|
|
232
232
|
BIRTHDAY = "BIRTHDAY"
|
|
233
233
|
}
|
|
234
234
|
/** @enumType */
|
|
235
|
-
|
|
235
|
+
type TypeWithLiterals = Type | 'UNKNOWN_TYPE' | 'SOCIAL_MEDIA' | 'BIRTHDAY';
|
|
236
236
|
/** Used in CreateCustomLoyaltyEarningRuleRequest */
|
|
237
|
-
|
|
237
|
+
interface CustomLoyaltyEarningRule extends CustomLoyaltyEarningRuleTypeOneOf {
|
|
238
238
|
/** Fixed amount of points awarded for each qualifying activity. */
|
|
239
239
|
fixedAmount?: FixedAmount;
|
|
240
240
|
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
@@ -247,69 +247,69 @@ export interface CustomLoyaltyEarningRule extends CustomLoyaltyEarningRuleTypeOn
|
|
|
247
247
|
title?: string;
|
|
248
248
|
}
|
|
249
249
|
/** @oneof */
|
|
250
|
-
|
|
250
|
+
interface CustomLoyaltyEarningRuleTypeOneOf {
|
|
251
251
|
/** Fixed amount of points awarded for each qualifying activity. */
|
|
252
252
|
fixedAmount?: FixedAmount;
|
|
253
253
|
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
254
254
|
conversionRate?: ConversionRate;
|
|
255
255
|
}
|
|
256
|
-
|
|
256
|
+
interface CreateCustomLoyaltyEarningRuleResponse {
|
|
257
257
|
/** Created earning rule. */
|
|
258
258
|
earningRule?: LoyaltyEarningRule;
|
|
259
259
|
}
|
|
260
|
-
|
|
260
|
+
interface GetLoyaltyEarningRuleRequest {
|
|
261
261
|
/**
|
|
262
262
|
* ID of the earning rule to retrieve.
|
|
263
263
|
* @format GUID
|
|
264
264
|
*/
|
|
265
|
-
|
|
265
|
+
_id: string;
|
|
266
266
|
}
|
|
267
|
-
|
|
267
|
+
interface GetLoyaltyEarningRuleResponse {
|
|
268
268
|
/** Retrieved earning rule. */
|
|
269
269
|
earningRule?: LoyaltyEarningRule;
|
|
270
270
|
}
|
|
271
|
-
|
|
271
|
+
interface UpdateLoyaltyEarningRuleRequest {
|
|
272
272
|
/** Earning rule to update. */
|
|
273
273
|
earningRule: LoyaltyEarningRule;
|
|
274
274
|
}
|
|
275
|
-
|
|
275
|
+
interface UpdateLoyaltyEarningRuleResponse {
|
|
276
276
|
/** The updated earning rule. */
|
|
277
277
|
earningRule?: LoyaltyEarningRule;
|
|
278
278
|
}
|
|
279
|
-
|
|
279
|
+
interface DeleteLoyaltyEarningRuleRequest {
|
|
280
280
|
/**
|
|
281
281
|
* ID of the earning rule to delete.
|
|
282
282
|
* @format GUID
|
|
283
283
|
*/
|
|
284
|
-
|
|
284
|
+
_id: string;
|
|
285
285
|
/**
|
|
286
286
|
* Revision of the earning rule. Incremented by 1 each time the earning rule is updated.
|
|
287
287
|
* Pass the latest revision when updating to prevent conflicting changes.
|
|
288
288
|
*/
|
|
289
289
|
revision?: string;
|
|
290
290
|
}
|
|
291
|
-
|
|
291
|
+
interface DeleteLoyaltyEarningRuleResponse {
|
|
292
292
|
}
|
|
293
|
-
|
|
293
|
+
interface DeleteAutomationEarningRuleRequest {
|
|
294
294
|
/**
|
|
295
295
|
* ID of the earning rule to delete.
|
|
296
296
|
* @format GUID
|
|
297
297
|
*/
|
|
298
|
-
|
|
298
|
+
_id: string;
|
|
299
299
|
}
|
|
300
|
-
|
|
300
|
+
interface DeleteAutomationEarningRuleResponse {
|
|
301
301
|
}
|
|
302
|
-
|
|
302
|
+
interface ListEarningRulesRequest {
|
|
303
303
|
/** App ID that triggers the point assignment. For example, `9a5d83fd-8570-482e-81ab-cfa88942ee60`. */
|
|
304
304
|
triggerAppId?: string | null;
|
|
305
305
|
/** Type of activity that triggers the point assignment. For example, `restaurants-order-is-pending`. */
|
|
306
306
|
triggerActivityType?: string | null;
|
|
307
307
|
}
|
|
308
|
-
|
|
308
|
+
interface ListEarningRulesResponse {
|
|
309
309
|
/** Retrieved earning rules. */
|
|
310
310
|
earningRules?: LoyaltyEarningRule[];
|
|
311
311
|
}
|
|
312
|
-
|
|
312
|
+
interface ListEarningRulesInTierRequest {
|
|
313
313
|
/**
|
|
314
314
|
* ID of the tier for which the earning rules will be returned.
|
|
315
315
|
* @format GUID
|
|
@@ -318,7 +318,7 @@ export interface ListEarningRulesInTierRequest {
|
|
|
318
318
|
/** Pagination options. */
|
|
319
319
|
paging?: CursorPaging;
|
|
320
320
|
}
|
|
321
|
-
|
|
321
|
+
interface CursorPaging {
|
|
322
322
|
/**
|
|
323
323
|
* Maximum number of items to return in the results.
|
|
324
324
|
* @max 100
|
|
@@ -333,13 +333,13 @@ export interface CursorPaging {
|
|
|
333
333
|
*/
|
|
334
334
|
cursor?: string | null;
|
|
335
335
|
}
|
|
336
|
-
|
|
336
|
+
interface ListEarningRulesInTierResponse {
|
|
337
337
|
/** Retrieved earning rules. */
|
|
338
338
|
earningRules?: LoyaltyEarningRule[];
|
|
339
339
|
/** Details on the paged set of results returned. */
|
|
340
340
|
pagingMetadata?: PagingMetadataV2;
|
|
341
341
|
}
|
|
342
|
-
|
|
342
|
+
interface PagingMetadataV2 {
|
|
343
343
|
/** Number of items returned in the response. */
|
|
344
344
|
count?: number | null;
|
|
345
345
|
/** Offset that was requested. */
|
|
@@ -351,7 +351,7 @@ export interface PagingMetadataV2 {
|
|
|
351
351
|
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
|
352
352
|
cursors?: Cursors;
|
|
353
353
|
}
|
|
354
|
-
|
|
354
|
+
interface Cursors {
|
|
355
355
|
/**
|
|
356
356
|
* Cursor string pointing to the next page in the list of results.
|
|
357
357
|
* @maxLength 16000
|
|
@@ -363,13 +363,13 @@ export interface Cursors {
|
|
|
363
363
|
*/
|
|
364
364
|
prev?: string | null;
|
|
365
365
|
}
|
|
366
|
-
|
|
366
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
367
367
|
createdEvent?: EntityCreatedEvent;
|
|
368
368
|
updatedEvent?: EntityUpdatedEvent;
|
|
369
369
|
deletedEvent?: EntityDeletedEvent;
|
|
370
370
|
actionEvent?: ActionEvent;
|
|
371
371
|
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
372
|
-
|
|
372
|
+
_id?: string;
|
|
373
373
|
/**
|
|
374
374
|
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
375
375
|
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
@@ -398,42 +398,40 @@ export interface DomainEvent extends DomainEventBodyOneOf {
|
|
|
398
398
|
entityEventSequence?: string | null;
|
|
399
399
|
}
|
|
400
400
|
/** @oneof */
|
|
401
|
-
|
|
401
|
+
interface DomainEventBodyOneOf {
|
|
402
402
|
createdEvent?: EntityCreatedEvent;
|
|
403
403
|
updatedEvent?: EntityUpdatedEvent;
|
|
404
404
|
deletedEvent?: EntityDeletedEvent;
|
|
405
405
|
actionEvent?: ActionEvent;
|
|
406
406
|
}
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
/** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
|
|
410
|
-
restoreInfo?: RestoreInfo;
|
|
407
|
+
interface EntityCreatedEvent {
|
|
408
|
+
entity?: string;
|
|
411
409
|
}
|
|
412
|
-
|
|
410
|
+
interface RestoreInfo {
|
|
413
411
|
deletedDate?: Date | null;
|
|
414
412
|
}
|
|
415
|
-
|
|
413
|
+
interface EntityUpdatedEvent {
|
|
416
414
|
/**
|
|
417
415
|
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
418
416
|
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
419
417
|
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
420
418
|
*/
|
|
421
|
-
|
|
419
|
+
currentEntity?: string;
|
|
422
420
|
}
|
|
423
|
-
|
|
421
|
+
interface EntityDeletedEvent {
|
|
424
422
|
/** Entity that was deleted. */
|
|
425
|
-
|
|
423
|
+
deletedEntity?: string | null;
|
|
426
424
|
}
|
|
427
|
-
|
|
428
|
-
|
|
425
|
+
interface ActionEvent {
|
|
426
|
+
body?: string;
|
|
429
427
|
}
|
|
430
|
-
|
|
428
|
+
interface Empty {
|
|
431
429
|
}
|
|
432
|
-
|
|
430
|
+
interface InvalidateEarningRuleCacheRequest {
|
|
433
431
|
}
|
|
434
|
-
|
|
432
|
+
interface InvalidateEarningRuleCacheResponse {
|
|
435
433
|
}
|
|
436
|
-
|
|
434
|
+
interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf {
|
|
437
435
|
/** Emitted on a meta site creation. */
|
|
438
436
|
siteCreated?: SiteCreated;
|
|
439
437
|
/** Emitted on a meta site transfer completion. */
|
|
@@ -499,7 +497,7 @@ export interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf {
|
|
|
499
497
|
assets?: Asset[];
|
|
500
498
|
}
|
|
501
499
|
/** @oneof */
|
|
502
|
-
|
|
500
|
+
interface MetaSiteSpecialEventPayloadOneOf {
|
|
503
501
|
/** Emitted on a meta site creation. */
|
|
504
502
|
siteCreated?: SiteCreated;
|
|
505
503
|
/** Emitted on a meta site transfer completion. */
|
|
@@ -549,7 +547,7 @@ export interface MetaSiteSpecialEventPayloadOneOf {
|
|
|
549
547
|
/** Emitted when Picasso is detached. */
|
|
550
548
|
picassoUnassigned?: PicassoUnassigned;
|
|
551
549
|
}
|
|
552
|
-
|
|
550
|
+
interface Asset {
|
|
553
551
|
/**
|
|
554
552
|
* An application definition id (app_id in dev-center). For legacy reasons may be UUID or a string (from Java Enum).
|
|
555
553
|
* @maxLength 36
|
|
@@ -563,7 +561,7 @@ export interface Asset {
|
|
|
563
561
|
/** An application state. */
|
|
564
562
|
state?: StateWithLiterals;
|
|
565
563
|
}
|
|
566
|
-
|
|
564
|
+
declare enum State {
|
|
567
565
|
UNKNOWN = "UNKNOWN",
|
|
568
566
|
ENABLED = "ENABLED",
|
|
569
567
|
DISABLED = "DISABLED",
|
|
@@ -571,8 +569,8 @@ export declare enum State {
|
|
|
571
569
|
DEMO = "DEMO"
|
|
572
570
|
}
|
|
573
571
|
/** @enumType */
|
|
574
|
-
|
|
575
|
-
|
|
572
|
+
type StateWithLiterals = State | 'UNKNOWN' | 'ENABLED' | 'DISABLED' | 'PENDING' | 'DEMO';
|
|
573
|
+
interface SiteCreated {
|
|
576
574
|
/**
|
|
577
575
|
* A template identifier (empty if not created from a template).
|
|
578
576
|
* @maxLength 36
|
|
@@ -601,7 +599,7 @@ export interface SiteCreated {
|
|
|
601
599
|
/** A namespace. */
|
|
602
600
|
namespace?: NamespaceWithLiterals;
|
|
603
601
|
}
|
|
604
|
-
|
|
602
|
+
declare enum SiteCreatedContext {
|
|
605
603
|
/** A valid option, we don't expose all reasons why site might be created. */
|
|
606
604
|
OTHER = "OTHER",
|
|
607
605
|
/** A meta site was created from template. */
|
|
@@ -616,8 +614,8 @@ export declare enum SiteCreatedContext {
|
|
|
616
614
|
FLASH = "FLASH"
|
|
617
615
|
}
|
|
618
616
|
/** @enumType */
|
|
619
|
-
|
|
620
|
-
|
|
617
|
+
type SiteCreatedContextWithLiterals = SiteCreatedContext | 'OTHER' | 'FROM_TEMPLATE' | 'DUPLICATE_BY_SITE_TRANSFER' | 'DUPLICATE' | 'OLD_SITE_TRANSFER' | 'FLASH';
|
|
618
|
+
declare enum Namespace {
|
|
621
619
|
UNKNOWN_NAMESPACE = "UNKNOWN_NAMESPACE",
|
|
622
620
|
/** Default namespace for UGC sites. MetaSites with this namespace will be shown in a user's site list by default. */
|
|
623
621
|
WIX = "WIX",
|
|
@@ -700,9 +698,9 @@ export declare enum Namespace {
|
|
|
700
698
|
MIMIR = "MIMIR"
|
|
701
699
|
}
|
|
702
700
|
/** @enumType */
|
|
703
|
-
|
|
701
|
+
type NamespaceWithLiterals = Namespace | 'UNKNOWN_NAMESPACE' | 'WIX' | 'SHOUT_OUT' | 'ALBUMS' | 'WIX_STORES_TEST_DRIVE' | 'HOTELS' | 'CLUBS' | 'ONBOARDING_DRAFT' | 'DEV_SITE' | 'LOGOS' | 'VIDEO_MAKER' | 'PARTNER_DASHBOARD' | 'DEV_CENTER_COMPANY' | 'HTML_DRAFT' | 'SITELESS_BUSINESS' | 'CREATOR_ECONOMY' | 'DASHBOARD_FIRST' | 'ANYWHERE' | 'HEADLESS' | 'ACCOUNT_MASTER_CMS' | 'RISE' | 'BRANDED_FIRST' | 'NOWNIA' | 'UGC_TEMPLATE' | 'CODUX' | 'MEDIA_DESIGN_CREATOR' | 'SHARED_BLOG_ENTERPRISE' | 'STANDALONE_FORMS' | 'STANDALONE_EVENTS' | 'MIMIR';
|
|
704
702
|
/** Site transferred to another user. */
|
|
705
|
-
|
|
703
|
+
interface SiteTransferred {
|
|
706
704
|
/**
|
|
707
705
|
* A previous owner id (user that transfers meta site).
|
|
708
706
|
* @format GUID
|
|
@@ -715,11 +713,11 @@ export interface SiteTransferred {
|
|
|
715
713
|
newOwnerId?: string;
|
|
716
714
|
}
|
|
717
715
|
/** Soft deletion of the meta site. Could be restored. */
|
|
718
|
-
|
|
716
|
+
interface SiteDeleted {
|
|
719
717
|
/** A deletion context. */
|
|
720
718
|
deleteContext?: DeleteContext;
|
|
721
719
|
}
|
|
722
|
-
|
|
720
|
+
interface DeleteContext {
|
|
723
721
|
/** When the meta site was deleted. */
|
|
724
722
|
dateDeleted?: Date | null;
|
|
725
723
|
/** A status. */
|
|
@@ -735,7 +733,7 @@ export interface DeleteContext {
|
|
|
735
733
|
*/
|
|
736
734
|
initiatorId?: string | null;
|
|
737
735
|
}
|
|
738
|
-
|
|
736
|
+
declare enum DeleteStatus {
|
|
739
737
|
UNKNOWN = "UNKNOWN",
|
|
740
738
|
TRASH = "TRASH",
|
|
741
739
|
DELETED = "DELETED",
|
|
@@ -743,14 +741,14 @@ export declare enum DeleteStatus {
|
|
|
743
741
|
PURGED_EXTERNALLY = "PURGED_EXTERNALLY"
|
|
744
742
|
}
|
|
745
743
|
/** @enumType */
|
|
746
|
-
|
|
744
|
+
type DeleteStatusWithLiterals = DeleteStatus | 'UNKNOWN' | 'TRASH' | 'DELETED' | 'PENDING_PURGE' | 'PURGED_EXTERNALLY';
|
|
747
745
|
/** Restoration of the meta site. */
|
|
748
|
-
|
|
746
|
+
interface SiteUndeleted {
|
|
749
747
|
}
|
|
750
748
|
/** First publish of a meta site. Or subsequent publish after unpublish. */
|
|
751
|
-
|
|
749
|
+
interface SitePublished {
|
|
752
750
|
}
|
|
753
|
-
|
|
751
|
+
interface SiteUnpublished {
|
|
754
752
|
/**
|
|
755
753
|
* A list of URLs previously associated with the meta site.
|
|
756
754
|
* @maxLength 4000
|
|
@@ -758,9 +756,9 @@ export interface SiteUnpublished {
|
|
|
758
756
|
*/
|
|
759
757
|
urls?: string[];
|
|
760
758
|
}
|
|
761
|
-
|
|
759
|
+
interface SiteMarkedAsTemplate {
|
|
762
760
|
}
|
|
763
|
-
|
|
761
|
+
interface SiteMarkedAsWixSite {
|
|
764
762
|
}
|
|
765
763
|
/**
|
|
766
764
|
* Represents a service provisioned a site.
|
|
@@ -777,7 +775,7 @@ export interface SiteMarkedAsWixSite {
|
|
|
777
775
|
* changes made to the original template afterward.
|
|
778
776
|
* To ensure this, the TPA on the template gets a new instance_id.
|
|
779
777
|
*/
|
|
780
|
-
|
|
778
|
+
interface ServiceProvisioned {
|
|
781
779
|
/**
|
|
782
780
|
* Either UUID or EmbeddedServiceType.
|
|
783
781
|
* @maxLength 36
|
|
@@ -804,7 +802,7 @@ export interface ServiceProvisioned {
|
|
|
804
802
|
*/
|
|
805
803
|
originMetaSiteId?: string | null;
|
|
806
804
|
}
|
|
807
|
-
|
|
805
|
+
interface ServiceRemoved {
|
|
808
806
|
/**
|
|
809
807
|
* Either UUID or EmbeddedServiceType.
|
|
810
808
|
* @maxLength 36
|
|
@@ -822,7 +820,7 @@ export interface ServiceRemoved {
|
|
|
822
820
|
version?: string | null;
|
|
823
821
|
}
|
|
824
822
|
/** Rename of the site. Meaning, free public url has been changed as well. */
|
|
825
|
-
|
|
823
|
+
interface SiteRenamed {
|
|
826
824
|
/**
|
|
827
825
|
* A new meta site name (URL slug).
|
|
828
826
|
* @maxLength 20
|
|
@@ -839,21 +837,21 @@ export interface SiteRenamed {
|
|
|
839
837
|
*
|
|
840
838
|
* Could not be restored. Therefore it's desirable to cleanup data.
|
|
841
839
|
*/
|
|
842
|
-
|
|
840
|
+
interface SiteHardDeleted {
|
|
843
841
|
/** A deletion context. */
|
|
844
842
|
deleteContext?: DeleteContext;
|
|
845
843
|
}
|
|
846
|
-
|
|
844
|
+
interface NamespaceChanged {
|
|
847
845
|
/** A previous namespace. */
|
|
848
846
|
oldNamespace?: NamespaceWithLiterals;
|
|
849
847
|
/** A new namespace. */
|
|
850
848
|
newNamespace?: NamespaceWithLiterals;
|
|
851
849
|
}
|
|
852
850
|
/** Assigned Studio editor */
|
|
853
|
-
|
|
851
|
+
interface StudioAssigned {
|
|
854
852
|
}
|
|
855
853
|
/** Unassigned Studio editor */
|
|
856
|
-
|
|
854
|
+
interface StudioUnassigned {
|
|
857
855
|
}
|
|
858
856
|
/**
|
|
859
857
|
* Fired in case site URLs were changed in any way: new secondary domain, published, account slug rename, site rename etc.
|
|
@@ -863,13 +861,13 @@ export interface StudioUnassigned {
|
|
|
863
861
|
*
|
|
864
862
|
* https://bo.wix.com/wix-docs/rest/meta-site/meta-site---urls-service
|
|
865
863
|
*/
|
|
866
|
-
|
|
864
|
+
interface SiteUrlChanged {
|
|
867
865
|
}
|
|
868
866
|
/**
|
|
869
867
|
* Used at the end of the deletion flow for both draft sites and when a user deletes a site.
|
|
870
868
|
* Consumed by other teams to remove relevant data.
|
|
871
869
|
*/
|
|
872
|
-
|
|
870
|
+
interface SitePurgedExternally {
|
|
873
871
|
/**
|
|
874
872
|
* @maxLength 2048
|
|
875
873
|
* @maxSize 100
|
|
@@ -879,18 +877,18 @@ export interface SitePurgedExternally {
|
|
|
879
877
|
appDefId?: string[];
|
|
880
878
|
}
|
|
881
879
|
/** Assigned Odeditor */
|
|
882
|
-
|
|
880
|
+
interface OdeditorAssigned {
|
|
883
881
|
}
|
|
884
882
|
/** Unassigned Odeditor */
|
|
885
|
-
|
|
883
|
+
interface OdeditorUnassigned {
|
|
886
884
|
}
|
|
887
885
|
/** Assigned Picasso editor */
|
|
888
|
-
|
|
886
|
+
interface PicassoAssigned {
|
|
889
887
|
}
|
|
890
888
|
/** Unassigned Picasso */
|
|
891
|
-
|
|
889
|
+
interface PicassoUnassigned {
|
|
892
890
|
}
|
|
893
|
-
|
|
891
|
+
interface MessageEnvelope {
|
|
894
892
|
/**
|
|
895
893
|
* App instance ID.
|
|
896
894
|
* @format GUID
|
|
@@ -906,7 +904,7 @@ export interface MessageEnvelope {
|
|
|
906
904
|
/** Stringify payload. */
|
|
907
905
|
data?: string;
|
|
908
906
|
}
|
|
909
|
-
|
|
907
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
910
908
|
/**
|
|
911
909
|
* ID of a site visitor that has not logged in to the site.
|
|
912
910
|
* @format GUID
|
|
@@ -931,7 +929,7 @@ export interface IdentificationData extends IdentificationDataIdOneOf {
|
|
|
931
929
|
identityType?: WebhookIdentityTypeWithLiterals;
|
|
932
930
|
}
|
|
933
931
|
/** @oneof */
|
|
934
|
-
|
|
932
|
+
interface IdentificationDataIdOneOf {
|
|
935
933
|
/**
|
|
936
934
|
* ID of a site visitor that has not logged in to the site.
|
|
937
935
|
* @format GUID
|
|
@@ -953,7 +951,7 @@ export interface IdentificationDataIdOneOf {
|
|
|
953
951
|
*/
|
|
954
952
|
appId?: string;
|
|
955
953
|
}
|
|
956
|
-
|
|
954
|
+
declare enum WebhookIdentityType {
|
|
957
955
|
UNKNOWN = "UNKNOWN",
|
|
958
956
|
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
959
957
|
MEMBER = "MEMBER",
|
|
@@ -961,4 +959,135 @@ export declare enum WebhookIdentityType {
|
|
|
961
959
|
APP = "APP"
|
|
962
960
|
}
|
|
963
961
|
/** @enumType */
|
|
964
|
-
|
|
962
|
+
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
963
|
+
interface BaseEventMetadata {
|
|
964
|
+
/**
|
|
965
|
+
* App instance ID.
|
|
966
|
+
* @format GUID
|
|
967
|
+
*/
|
|
968
|
+
instanceId?: string | null;
|
|
969
|
+
/**
|
|
970
|
+
* Event type.
|
|
971
|
+
* @maxLength 150
|
|
972
|
+
*/
|
|
973
|
+
eventType?: string;
|
|
974
|
+
/** The identification type and identity data. */
|
|
975
|
+
identity?: IdentificationData;
|
|
976
|
+
}
|
|
977
|
+
interface EventMetadata extends BaseEventMetadata {
|
|
978
|
+
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
979
|
+
_id?: string;
|
|
980
|
+
/**
|
|
981
|
+
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
982
|
+
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
983
|
+
*/
|
|
984
|
+
entityFqdn?: string;
|
|
985
|
+
/**
|
|
986
|
+
* Event action name, placed at the top level to make it easier for users to dispatch messages.
|
|
987
|
+
* For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
|
|
988
|
+
*/
|
|
989
|
+
slug?: string;
|
|
990
|
+
/** ID of the entity associated with the event. */
|
|
991
|
+
entityId?: string;
|
|
992
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
|
|
993
|
+
eventTime?: Date | null;
|
|
994
|
+
/**
|
|
995
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
996
|
+
* (for example, GDPR).
|
|
997
|
+
*/
|
|
998
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
999
|
+
/** If present, indicates the action that triggered the event. */
|
|
1000
|
+
originatedFrom?: string | null;
|
|
1001
|
+
/**
|
|
1002
|
+
* A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.
|
|
1003
|
+
* You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
|
|
1004
|
+
*/
|
|
1005
|
+
entityEventSequence?: string | null;
|
|
1006
|
+
}
|
|
1007
|
+
interface LoyaltyEarningRuleCreatedEnvelope {
|
|
1008
|
+
entity: LoyaltyEarningRule;
|
|
1009
|
+
metadata: EventMetadata;
|
|
1010
|
+
}
|
|
1011
|
+
interface LoyaltyEarningRuleDeletedEnvelope {
|
|
1012
|
+
metadata: EventMetadata;
|
|
1013
|
+
}
|
|
1014
|
+
interface LoyaltyEarningRuleUpdatedEnvelope {
|
|
1015
|
+
entity: LoyaltyEarningRule;
|
|
1016
|
+
metadata: EventMetadata;
|
|
1017
|
+
}
|
|
1018
|
+
interface CreateCustomLoyaltyEarningRuleOptions {
|
|
1019
|
+
/** Custom earning rule to create. */
|
|
1020
|
+
earningRule?: CustomLoyaltyEarningRule;
|
|
1021
|
+
}
|
|
1022
|
+
interface UpdateLoyaltyEarningRule {
|
|
1023
|
+
/** Fixed amount of points awarded for each qualifying activity. */
|
|
1024
|
+
fixedAmount?: FixedAmount;
|
|
1025
|
+
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
1026
|
+
conversionRate?: ConversionRate;
|
|
1027
|
+
/**
|
|
1028
|
+
* Loyalty earning rule ID.
|
|
1029
|
+
* @format GUID
|
|
1030
|
+
* @readonly
|
|
1031
|
+
*/
|
|
1032
|
+
_id?: string | null;
|
|
1033
|
+
/**
|
|
1034
|
+
* ID of the app managing the earning rule. Can be a loyalty app ID or a Wix automations app ID.
|
|
1035
|
+
* @format GUID
|
|
1036
|
+
*/
|
|
1037
|
+
sourceAppId?: string;
|
|
1038
|
+
/**
|
|
1039
|
+
* ID of the app that triggers point assignment. Examples: Wix Stores, Wix Bookings, Wix Events.
|
|
1040
|
+
* @minLength 1
|
|
1041
|
+
* @maxLength 80
|
|
1042
|
+
*/
|
|
1043
|
+
triggerAppId?: string;
|
|
1044
|
+
/**
|
|
1045
|
+
* Type of activity that triggers point assignment. For example, `wix-restaurants/orderSubmitted` or `birthday`.
|
|
1046
|
+
* @minLength 1
|
|
1047
|
+
* @maxLength 80
|
|
1048
|
+
*/
|
|
1049
|
+
triggerActivityType?: string;
|
|
1050
|
+
/**
|
|
1051
|
+
* Name of the earning rule.
|
|
1052
|
+
* @minLength 1
|
|
1053
|
+
* @maxLength 50
|
|
1054
|
+
*/
|
|
1055
|
+
title?: string;
|
|
1056
|
+
/** Current status of the earning rule. */
|
|
1057
|
+
status?: StatusWithLiterals;
|
|
1058
|
+
/**
|
|
1059
|
+
* Revision number, incremented by 1 each time the earning rule is updated.
|
|
1060
|
+
* Pass the latest revision when updating to prevent conflicting changes.
|
|
1061
|
+
*/
|
|
1062
|
+
revision?: string | null;
|
|
1063
|
+
/**
|
|
1064
|
+
* Date and time the earning rule was created.
|
|
1065
|
+
* @readonly
|
|
1066
|
+
*/
|
|
1067
|
+
_createdDate?: Date | null;
|
|
1068
|
+
/**
|
|
1069
|
+
* Date and time the earning rule was last updated.
|
|
1070
|
+
* @readonly
|
|
1071
|
+
*/
|
|
1072
|
+
_updatedDate?: Date | null;
|
|
1073
|
+
/**
|
|
1074
|
+
* Additional metadata about the earning rule.
|
|
1075
|
+
* @readonly
|
|
1076
|
+
*/
|
|
1077
|
+
metadata?: Metadata;
|
|
1078
|
+
}
|
|
1079
|
+
interface DeleteLoyaltyEarningRuleOptions {
|
|
1080
|
+
/**
|
|
1081
|
+
* Revision of the earning rule. Incremented by 1 each time the earning rule is updated.
|
|
1082
|
+
* Pass the latest revision when updating to prevent conflicting changes.
|
|
1083
|
+
*/
|
|
1084
|
+
revision?: string;
|
|
1085
|
+
}
|
|
1086
|
+
interface ListEarningRulesOptions {
|
|
1087
|
+
/** App ID that triggers the point assignment. For example, `9a5d83fd-8570-482e-81ab-cfa88942ee60`. */
|
|
1088
|
+
triggerAppId?: string | null;
|
|
1089
|
+
/** Type of activity that triggers the point assignment. For example, `restaurants-order-is-pending`. */
|
|
1090
|
+
triggerActivityType?: string | null;
|
|
1091
|
+
}
|
|
1092
|
+
|
|
1093
|
+
export { type DomainEvent as $, type ApplicationError as A, type BulkCreateLoyaltyEarningRulesResponse as B, type CreateCustomLoyaltyEarningRuleOptions as C, type DeleteLoyaltyEarningRuleOptions as D, type EarningRuleDisabled as E, type FixedAmount as F, type GetLoyaltyEarningRuleRequest as G, type GetLoyaltyEarningRuleResponse as H, type ItemMetadata as I, type UpdateLoyaltyEarningRuleRequest as J, type DeleteLoyaltyEarningRuleRequest as K, type LoyaltyEarningRule as L, type Metadata as M, Namespace as N, type DeleteLoyaltyEarningRuleResponse as O, type DeleteAutomationEarningRuleRequest as P, type DeleteAutomationEarningRuleResponse as Q, type ListEarningRulesRequest as R, Status as S, type TypeWithLiterals as T, type UpdateLoyaltyEarningRule as U, type ListEarningRulesInTierRequest as V, WebhookIdentityType as W, type CursorPaging as X, type ListEarningRulesInTierResponse as Y, type PagingMetadataV2 as Z, type Cursors as _, type CreateCustomLoyaltyEarningRuleResponse as a, type DomainEventBodyOneOf as a0, type EntityCreatedEvent as a1, type RestoreInfo as a2, type EntityUpdatedEvent as a3, type EntityDeletedEvent as a4, type ActionEvent as a5, type Empty as a6, type InvalidateEarningRuleCacheRequest as a7, type InvalidateEarningRuleCacheResponse as a8, type MetaSiteSpecialEvent as a9, type IdentificationDataIdOneOf as aA, type BaseEventMetadata as aB, type EventMetadata as aC, type MetaSiteSpecialEventPayloadOneOf as aa, type Asset as ab, type SiteCreated as ac, type SiteTransferred as ad, type SiteDeleted as ae, type DeleteContext as af, type SiteUndeleted as ag, type SitePublished as ah, type SiteUnpublished as ai, type SiteMarkedAsTemplate as aj, type SiteMarkedAsWixSite as ak, type ServiceProvisioned as al, type ServiceRemoved as am, type SiteRenamed as an, type SiteHardDeleted as ao, type NamespaceChanged as ap, type StudioAssigned as aq, type StudioUnassigned as ar, type SiteUrlChanged as as, type SitePurgedExternally as at, type OdeditorAssigned as au, type OdeditorUnassigned as av, type PicassoAssigned as aw, type PicassoUnassigned as ax, type MessageEnvelope as ay, type IdentificationData as az, type UpdateLoyaltyEarningRuleResponse as b, type ListEarningRulesOptions as c, type ListEarningRulesResponse as d, type LoyaltyEarningRuleCreatedEnvelope as e, type LoyaltyEarningRuleDeletedEnvelope as f, type LoyaltyEarningRuleUpdatedEnvelope as g, LoyaltyEarningRuleTypeTagType as h, Type as i, State as j, SiteCreatedContext as k, DeleteStatus as l, type LoyaltyEarningRuleTypeOneOf as m, type FixedAmountConfig as n, type ConversionRate as o, type ConversionRateConfig as p, type LoyaltyEarningRuleTypeTag as q, type CacheInvalidated as r, type CreateLoyaltyEarningRuleRequest as s, type CreateLoyaltyEarningRuleResponse as t, type BulkCreateLoyaltyEarningRulesRequest as u, type BulkLoyaltyEarningRuleResult as v, type BulkActionMetadata as w, type CreateCustomLoyaltyEarningRuleRequest as x, type CustomLoyaltyEarningRule as y, type CustomLoyaltyEarningRuleTypeOneOf as z };
|