@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,41 @@ 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
|
+
/**
|
|
150
|
+
* Information about the type of custom earning rule.
|
|
151
|
+
* @internal
|
|
152
|
+
*/
|
|
153
|
+
ruleTypeTag?: LoyaltyEarningRuleTypeTag;
|
|
149
154
|
}
|
|
150
|
-
|
|
155
|
+
interface LoyaltyEarningRuleTypeTag {
|
|
151
156
|
/** Type of custom earning rule. */
|
|
152
157
|
ruleType?: LoyaltyEarningRuleTypeTagTypeWithLiterals;
|
|
153
158
|
}
|
|
154
|
-
|
|
159
|
+
declare enum LoyaltyEarningRuleTypeTagType {
|
|
155
160
|
/** Type is unknown or not specified. */
|
|
156
161
|
UNKNOWN_TYPE = "UNKNOWN_TYPE",
|
|
157
162
|
/** Earning rule for a customer's birthday. */
|
|
158
163
|
BIRTHDAY = "BIRTHDAY"
|
|
159
164
|
}
|
|
160
165
|
/** @enumType */
|
|
161
|
-
|
|
162
|
-
|
|
166
|
+
type LoyaltyEarningRuleTypeTagTypeWithLiterals = LoyaltyEarningRuleTypeTagType | 'UNKNOWN_TYPE' | 'BIRTHDAY';
|
|
167
|
+
interface CacheInvalidated {
|
|
163
168
|
}
|
|
164
|
-
|
|
169
|
+
interface EarningRuleDisabled {
|
|
165
170
|
}
|
|
166
|
-
|
|
171
|
+
interface CreateLoyaltyEarningRuleRequest {
|
|
167
172
|
/** Earning rule to create. */
|
|
168
173
|
earningRule: LoyaltyEarningRule;
|
|
169
174
|
}
|
|
170
|
-
|
|
175
|
+
interface CreateLoyaltyEarningRuleResponse {
|
|
171
176
|
/** Created earning rule. */
|
|
172
177
|
earningRule?: LoyaltyEarningRule;
|
|
173
178
|
}
|
|
174
|
-
|
|
179
|
+
interface BulkCreateLoyaltyEarningRulesRequest {
|
|
175
180
|
/**
|
|
176
181
|
* Earning rules to create.
|
|
177
182
|
* @minSize 1
|
|
@@ -179,21 +184,21 @@ export interface BulkCreateLoyaltyEarningRulesRequest {
|
|
|
179
184
|
*/
|
|
180
185
|
earningRules: LoyaltyEarningRule[];
|
|
181
186
|
}
|
|
182
|
-
|
|
187
|
+
interface BulkCreateLoyaltyEarningRulesResponse {
|
|
183
188
|
/** Created earning rules. */
|
|
184
189
|
results?: BulkLoyaltyEarningRuleResult[];
|
|
185
190
|
/** Additional metadata for the created earning rules. */
|
|
186
191
|
bulkActionMetadata?: BulkActionMetadata;
|
|
187
192
|
}
|
|
188
|
-
|
|
193
|
+
interface BulkLoyaltyEarningRuleResult {
|
|
189
194
|
/** Additional metadata for the created earning rules. */
|
|
190
195
|
itemMetadata?: ItemMetadata;
|
|
191
196
|
/** Created earning rule. */
|
|
192
197
|
item?: LoyaltyEarningRule;
|
|
193
198
|
}
|
|
194
|
-
|
|
199
|
+
interface ItemMetadata {
|
|
195
200
|
/** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
|
|
196
|
-
|
|
201
|
+
_id?: string | null;
|
|
197
202
|
/** Index of the item within the request array. Allows for correlation between request and response items. */
|
|
198
203
|
originalIndex?: number;
|
|
199
204
|
/** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
|
|
@@ -201,7 +206,7 @@ export interface ItemMetadata {
|
|
|
201
206
|
/** Details about the error in case of failure. */
|
|
202
207
|
error?: ApplicationError;
|
|
203
208
|
}
|
|
204
|
-
|
|
209
|
+
interface ApplicationError {
|
|
205
210
|
/** Error code. */
|
|
206
211
|
code?: string;
|
|
207
212
|
/** Description of the error. */
|
|
@@ -209,7 +214,7 @@ export interface ApplicationError {
|
|
|
209
214
|
/** Data related to the error. */
|
|
210
215
|
data?: Record<string, any> | null;
|
|
211
216
|
}
|
|
212
|
-
|
|
217
|
+
interface BulkActionMetadata {
|
|
213
218
|
/** Number of items that were successfully processed. */
|
|
214
219
|
totalSuccesses?: number;
|
|
215
220
|
/** Number of items that couldn't be processed. */
|
|
@@ -217,13 +222,13 @@ export interface BulkActionMetadata {
|
|
|
217
222
|
/** Number of failures without details because detailed failure threshold was exceeded. */
|
|
218
223
|
undetailedFailures?: number;
|
|
219
224
|
}
|
|
220
|
-
|
|
225
|
+
interface CreateCustomLoyaltyEarningRuleRequest {
|
|
221
226
|
/** Type of the custom earning rule. */
|
|
222
227
|
type: TypeWithLiterals;
|
|
223
228
|
/** Custom earning rule to create. */
|
|
224
229
|
earningRule?: CustomLoyaltyEarningRule;
|
|
225
230
|
}
|
|
226
|
-
|
|
231
|
+
declare enum Type {
|
|
227
232
|
/** Unknown type. This value is not used. */
|
|
228
233
|
UNKNOWN_TYPE = "UNKNOWN_TYPE",
|
|
229
234
|
/** Earning rule for social media. */
|
|
@@ -232,9 +237,9 @@ export declare enum Type {
|
|
|
232
237
|
BIRTHDAY = "BIRTHDAY"
|
|
233
238
|
}
|
|
234
239
|
/** @enumType */
|
|
235
|
-
|
|
240
|
+
type TypeWithLiterals = Type | 'UNKNOWN_TYPE' | 'SOCIAL_MEDIA' | 'BIRTHDAY';
|
|
236
241
|
/** Used in CreateCustomLoyaltyEarningRuleRequest */
|
|
237
|
-
|
|
242
|
+
interface CustomLoyaltyEarningRule extends CustomLoyaltyEarningRuleTypeOneOf {
|
|
238
243
|
/** Fixed amount of points awarded for each qualifying activity. */
|
|
239
244
|
fixedAmount?: FixedAmount;
|
|
240
245
|
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
@@ -247,69 +252,69 @@ export interface CustomLoyaltyEarningRule extends CustomLoyaltyEarningRuleTypeOn
|
|
|
247
252
|
title?: string;
|
|
248
253
|
}
|
|
249
254
|
/** @oneof */
|
|
250
|
-
|
|
255
|
+
interface CustomLoyaltyEarningRuleTypeOneOf {
|
|
251
256
|
/** Fixed amount of points awarded for each qualifying activity. */
|
|
252
257
|
fixedAmount?: FixedAmount;
|
|
253
258
|
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
254
259
|
conversionRate?: ConversionRate;
|
|
255
260
|
}
|
|
256
|
-
|
|
261
|
+
interface CreateCustomLoyaltyEarningRuleResponse {
|
|
257
262
|
/** Created earning rule. */
|
|
258
263
|
earningRule?: LoyaltyEarningRule;
|
|
259
264
|
}
|
|
260
|
-
|
|
265
|
+
interface GetLoyaltyEarningRuleRequest {
|
|
261
266
|
/**
|
|
262
267
|
* ID of the earning rule to retrieve.
|
|
263
268
|
* @format GUID
|
|
264
269
|
*/
|
|
265
|
-
|
|
270
|
+
_id: string;
|
|
266
271
|
}
|
|
267
|
-
|
|
272
|
+
interface GetLoyaltyEarningRuleResponse {
|
|
268
273
|
/** Retrieved earning rule. */
|
|
269
274
|
earningRule?: LoyaltyEarningRule;
|
|
270
275
|
}
|
|
271
|
-
|
|
276
|
+
interface UpdateLoyaltyEarningRuleRequest {
|
|
272
277
|
/** Earning rule to update. */
|
|
273
278
|
earningRule: LoyaltyEarningRule;
|
|
274
279
|
}
|
|
275
|
-
|
|
280
|
+
interface UpdateLoyaltyEarningRuleResponse {
|
|
276
281
|
/** The updated earning rule. */
|
|
277
282
|
earningRule?: LoyaltyEarningRule;
|
|
278
283
|
}
|
|
279
|
-
|
|
284
|
+
interface DeleteLoyaltyEarningRuleRequest {
|
|
280
285
|
/**
|
|
281
286
|
* ID of the earning rule to delete.
|
|
282
287
|
* @format GUID
|
|
283
288
|
*/
|
|
284
|
-
|
|
289
|
+
_id: string;
|
|
285
290
|
/**
|
|
286
291
|
* Revision of the earning rule. Incremented by 1 each time the earning rule is updated.
|
|
287
292
|
* Pass the latest revision when updating to prevent conflicting changes.
|
|
288
293
|
*/
|
|
289
294
|
revision?: string;
|
|
290
295
|
}
|
|
291
|
-
|
|
296
|
+
interface DeleteLoyaltyEarningRuleResponse {
|
|
292
297
|
}
|
|
293
|
-
|
|
298
|
+
interface DeleteAutomationEarningRuleRequest {
|
|
294
299
|
/**
|
|
295
300
|
* ID of the earning rule to delete.
|
|
296
301
|
* @format GUID
|
|
297
302
|
*/
|
|
298
|
-
|
|
303
|
+
_id: string;
|
|
299
304
|
}
|
|
300
|
-
|
|
305
|
+
interface DeleteAutomationEarningRuleResponse {
|
|
301
306
|
}
|
|
302
|
-
|
|
307
|
+
interface ListEarningRulesRequest {
|
|
303
308
|
/** App ID that triggers the point assignment. For example, `9a5d83fd-8570-482e-81ab-cfa88942ee60`. */
|
|
304
309
|
triggerAppId?: string | null;
|
|
305
310
|
/** Type of activity that triggers the point assignment. For example, `restaurants-order-is-pending`. */
|
|
306
311
|
triggerActivityType?: string | null;
|
|
307
312
|
}
|
|
308
|
-
|
|
313
|
+
interface ListEarningRulesResponse {
|
|
309
314
|
/** Retrieved earning rules. */
|
|
310
315
|
earningRules?: LoyaltyEarningRule[];
|
|
311
316
|
}
|
|
312
|
-
|
|
317
|
+
interface ListEarningRulesInTierRequest {
|
|
313
318
|
/**
|
|
314
319
|
* ID of the tier for which the earning rules will be returned.
|
|
315
320
|
* @format GUID
|
|
@@ -318,7 +323,7 @@ export interface ListEarningRulesInTierRequest {
|
|
|
318
323
|
/** Pagination options. */
|
|
319
324
|
paging?: CursorPaging;
|
|
320
325
|
}
|
|
321
|
-
|
|
326
|
+
interface CursorPaging {
|
|
322
327
|
/**
|
|
323
328
|
* Maximum number of items to return in the results.
|
|
324
329
|
* @max 100
|
|
@@ -333,13 +338,13 @@ export interface CursorPaging {
|
|
|
333
338
|
*/
|
|
334
339
|
cursor?: string | null;
|
|
335
340
|
}
|
|
336
|
-
|
|
341
|
+
interface ListEarningRulesInTierResponse {
|
|
337
342
|
/** Retrieved earning rules. */
|
|
338
343
|
earningRules?: LoyaltyEarningRule[];
|
|
339
344
|
/** Details on the paged set of results returned. */
|
|
340
345
|
pagingMetadata?: PagingMetadataV2;
|
|
341
346
|
}
|
|
342
|
-
|
|
347
|
+
interface PagingMetadataV2 {
|
|
343
348
|
/** Number of items returned in the response. */
|
|
344
349
|
count?: number | null;
|
|
345
350
|
/** Offset that was requested. */
|
|
@@ -351,7 +356,7 @@ export interface PagingMetadataV2 {
|
|
|
351
356
|
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
|
352
357
|
cursors?: Cursors;
|
|
353
358
|
}
|
|
354
|
-
|
|
359
|
+
interface Cursors {
|
|
355
360
|
/**
|
|
356
361
|
* Cursor string pointing to the next page in the list of results.
|
|
357
362
|
* @maxLength 16000
|
|
@@ -363,13 +368,13 @@ export interface Cursors {
|
|
|
363
368
|
*/
|
|
364
369
|
prev?: string | null;
|
|
365
370
|
}
|
|
366
|
-
|
|
371
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
367
372
|
createdEvent?: EntityCreatedEvent;
|
|
368
373
|
updatedEvent?: EntityUpdatedEvent;
|
|
369
374
|
deletedEvent?: EntityDeletedEvent;
|
|
370
375
|
actionEvent?: ActionEvent;
|
|
371
376
|
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
372
|
-
|
|
377
|
+
_id?: string;
|
|
373
378
|
/**
|
|
374
379
|
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
375
380
|
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
@@ -398,42 +403,40 @@ export interface DomainEvent extends DomainEventBodyOneOf {
|
|
|
398
403
|
entityEventSequence?: string | null;
|
|
399
404
|
}
|
|
400
405
|
/** @oneof */
|
|
401
|
-
|
|
406
|
+
interface DomainEventBodyOneOf {
|
|
402
407
|
createdEvent?: EntityCreatedEvent;
|
|
403
408
|
updatedEvent?: EntityUpdatedEvent;
|
|
404
409
|
deletedEvent?: EntityDeletedEvent;
|
|
405
410
|
actionEvent?: ActionEvent;
|
|
406
411
|
}
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
/** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
|
|
410
|
-
restoreInfo?: RestoreInfo;
|
|
412
|
+
interface EntityCreatedEvent {
|
|
413
|
+
entity?: string;
|
|
411
414
|
}
|
|
412
|
-
|
|
415
|
+
interface RestoreInfo {
|
|
413
416
|
deletedDate?: Date | null;
|
|
414
417
|
}
|
|
415
|
-
|
|
418
|
+
interface EntityUpdatedEvent {
|
|
416
419
|
/**
|
|
417
420
|
* 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
421
|
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
419
422
|
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
420
423
|
*/
|
|
421
|
-
|
|
424
|
+
currentEntity?: string;
|
|
422
425
|
}
|
|
423
|
-
|
|
426
|
+
interface EntityDeletedEvent {
|
|
424
427
|
/** Entity that was deleted. */
|
|
425
|
-
|
|
428
|
+
deletedEntity?: string | null;
|
|
426
429
|
}
|
|
427
|
-
|
|
428
|
-
|
|
430
|
+
interface ActionEvent {
|
|
431
|
+
body?: string;
|
|
429
432
|
}
|
|
430
|
-
|
|
433
|
+
interface Empty {
|
|
431
434
|
}
|
|
432
|
-
|
|
435
|
+
interface InvalidateEarningRuleCacheRequest {
|
|
433
436
|
}
|
|
434
|
-
|
|
437
|
+
interface InvalidateEarningRuleCacheResponse {
|
|
435
438
|
}
|
|
436
|
-
|
|
439
|
+
interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf {
|
|
437
440
|
/** Emitted on a meta site creation. */
|
|
438
441
|
siteCreated?: SiteCreated;
|
|
439
442
|
/** Emitted on a meta site transfer completion. */
|
|
@@ -499,7 +502,7 @@ export interface MetaSiteSpecialEvent extends MetaSiteSpecialEventPayloadOneOf {
|
|
|
499
502
|
assets?: Asset[];
|
|
500
503
|
}
|
|
501
504
|
/** @oneof */
|
|
502
|
-
|
|
505
|
+
interface MetaSiteSpecialEventPayloadOneOf {
|
|
503
506
|
/** Emitted on a meta site creation. */
|
|
504
507
|
siteCreated?: SiteCreated;
|
|
505
508
|
/** Emitted on a meta site transfer completion. */
|
|
@@ -549,7 +552,7 @@ export interface MetaSiteSpecialEventPayloadOneOf {
|
|
|
549
552
|
/** Emitted when Picasso is detached. */
|
|
550
553
|
picassoUnassigned?: PicassoUnassigned;
|
|
551
554
|
}
|
|
552
|
-
|
|
555
|
+
interface Asset {
|
|
553
556
|
/**
|
|
554
557
|
* An application definition id (app_id in dev-center). For legacy reasons may be UUID or a string (from Java Enum).
|
|
555
558
|
* @maxLength 36
|
|
@@ -563,7 +566,7 @@ export interface Asset {
|
|
|
563
566
|
/** An application state. */
|
|
564
567
|
state?: StateWithLiterals;
|
|
565
568
|
}
|
|
566
|
-
|
|
569
|
+
declare enum State {
|
|
567
570
|
UNKNOWN = "UNKNOWN",
|
|
568
571
|
ENABLED = "ENABLED",
|
|
569
572
|
DISABLED = "DISABLED",
|
|
@@ -571,8 +574,8 @@ export declare enum State {
|
|
|
571
574
|
DEMO = "DEMO"
|
|
572
575
|
}
|
|
573
576
|
/** @enumType */
|
|
574
|
-
|
|
575
|
-
|
|
577
|
+
type StateWithLiterals = State | 'UNKNOWN' | 'ENABLED' | 'DISABLED' | 'PENDING' | 'DEMO';
|
|
578
|
+
interface SiteCreated {
|
|
576
579
|
/**
|
|
577
580
|
* A template identifier (empty if not created from a template).
|
|
578
581
|
* @maxLength 36
|
|
@@ -601,7 +604,7 @@ export interface SiteCreated {
|
|
|
601
604
|
/** A namespace. */
|
|
602
605
|
namespace?: NamespaceWithLiterals;
|
|
603
606
|
}
|
|
604
|
-
|
|
607
|
+
declare enum SiteCreatedContext {
|
|
605
608
|
/** A valid option, we don't expose all reasons why site might be created. */
|
|
606
609
|
OTHER = "OTHER",
|
|
607
610
|
/** A meta site was created from template. */
|
|
@@ -616,8 +619,8 @@ export declare enum SiteCreatedContext {
|
|
|
616
619
|
FLASH = "FLASH"
|
|
617
620
|
}
|
|
618
621
|
/** @enumType */
|
|
619
|
-
|
|
620
|
-
|
|
622
|
+
type SiteCreatedContextWithLiterals = SiteCreatedContext | 'OTHER' | 'FROM_TEMPLATE' | 'DUPLICATE_BY_SITE_TRANSFER' | 'DUPLICATE' | 'OLD_SITE_TRANSFER' | 'FLASH';
|
|
623
|
+
declare enum Namespace {
|
|
621
624
|
UNKNOWN_NAMESPACE = "UNKNOWN_NAMESPACE",
|
|
622
625
|
/** Default namespace for UGC sites. MetaSites with this namespace will be shown in a user's site list by default. */
|
|
623
626
|
WIX = "WIX",
|
|
@@ -700,9 +703,9 @@ export declare enum Namespace {
|
|
|
700
703
|
MIMIR = "MIMIR"
|
|
701
704
|
}
|
|
702
705
|
/** @enumType */
|
|
703
|
-
|
|
706
|
+
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
707
|
/** Site transferred to another user. */
|
|
705
|
-
|
|
708
|
+
interface SiteTransferred {
|
|
706
709
|
/**
|
|
707
710
|
* A previous owner id (user that transfers meta site).
|
|
708
711
|
* @format GUID
|
|
@@ -715,11 +718,11 @@ export interface SiteTransferred {
|
|
|
715
718
|
newOwnerId?: string;
|
|
716
719
|
}
|
|
717
720
|
/** Soft deletion of the meta site. Could be restored. */
|
|
718
|
-
|
|
721
|
+
interface SiteDeleted {
|
|
719
722
|
/** A deletion context. */
|
|
720
723
|
deleteContext?: DeleteContext;
|
|
721
724
|
}
|
|
722
|
-
|
|
725
|
+
interface DeleteContext {
|
|
723
726
|
/** When the meta site was deleted. */
|
|
724
727
|
dateDeleted?: Date | null;
|
|
725
728
|
/** A status. */
|
|
@@ -735,7 +738,7 @@ export interface DeleteContext {
|
|
|
735
738
|
*/
|
|
736
739
|
initiatorId?: string | null;
|
|
737
740
|
}
|
|
738
|
-
|
|
741
|
+
declare enum DeleteStatus {
|
|
739
742
|
UNKNOWN = "UNKNOWN",
|
|
740
743
|
TRASH = "TRASH",
|
|
741
744
|
DELETED = "DELETED",
|
|
@@ -743,14 +746,14 @@ export declare enum DeleteStatus {
|
|
|
743
746
|
PURGED_EXTERNALLY = "PURGED_EXTERNALLY"
|
|
744
747
|
}
|
|
745
748
|
/** @enumType */
|
|
746
|
-
|
|
749
|
+
type DeleteStatusWithLiterals = DeleteStatus | 'UNKNOWN' | 'TRASH' | 'DELETED' | 'PENDING_PURGE' | 'PURGED_EXTERNALLY';
|
|
747
750
|
/** Restoration of the meta site. */
|
|
748
|
-
|
|
751
|
+
interface SiteUndeleted {
|
|
749
752
|
}
|
|
750
753
|
/** First publish of a meta site. Or subsequent publish after unpublish. */
|
|
751
|
-
|
|
754
|
+
interface SitePublished {
|
|
752
755
|
}
|
|
753
|
-
|
|
756
|
+
interface SiteUnpublished {
|
|
754
757
|
/**
|
|
755
758
|
* A list of URLs previously associated with the meta site.
|
|
756
759
|
* @maxLength 4000
|
|
@@ -758,9 +761,9 @@ export interface SiteUnpublished {
|
|
|
758
761
|
*/
|
|
759
762
|
urls?: string[];
|
|
760
763
|
}
|
|
761
|
-
|
|
764
|
+
interface SiteMarkedAsTemplate {
|
|
762
765
|
}
|
|
763
|
-
|
|
766
|
+
interface SiteMarkedAsWixSite {
|
|
764
767
|
}
|
|
765
768
|
/**
|
|
766
769
|
* Represents a service provisioned a site.
|
|
@@ -777,7 +780,7 @@ export interface SiteMarkedAsWixSite {
|
|
|
777
780
|
* changes made to the original template afterward.
|
|
778
781
|
* To ensure this, the TPA on the template gets a new instance_id.
|
|
779
782
|
*/
|
|
780
|
-
|
|
783
|
+
interface ServiceProvisioned {
|
|
781
784
|
/**
|
|
782
785
|
* Either UUID or EmbeddedServiceType.
|
|
783
786
|
* @maxLength 36
|
|
@@ -804,7 +807,7 @@ export interface ServiceProvisioned {
|
|
|
804
807
|
*/
|
|
805
808
|
originMetaSiteId?: string | null;
|
|
806
809
|
}
|
|
807
|
-
|
|
810
|
+
interface ServiceRemoved {
|
|
808
811
|
/**
|
|
809
812
|
* Either UUID or EmbeddedServiceType.
|
|
810
813
|
* @maxLength 36
|
|
@@ -822,7 +825,7 @@ export interface ServiceRemoved {
|
|
|
822
825
|
version?: string | null;
|
|
823
826
|
}
|
|
824
827
|
/** Rename of the site. Meaning, free public url has been changed as well. */
|
|
825
|
-
|
|
828
|
+
interface SiteRenamed {
|
|
826
829
|
/**
|
|
827
830
|
* A new meta site name (URL slug).
|
|
828
831
|
* @maxLength 20
|
|
@@ -839,21 +842,21 @@ export interface SiteRenamed {
|
|
|
839
842
|
*
|
|
840
843
|
* Could not be restored. Therefore it's desirable to cleanup data.
|
|
841
844
|
*/
|
|
842
|
-
|
|
845
|
+
interface SiteHardDeleted {
|
|
843
846
|
/** A deletion context. */
|
|
844
847
|
deleteContext?: DeleteContext;
|
|
845
848
|
}
|
|
846
|
-
|
|
849
|
+
interface NamespaceChanged {
|
|
847
850
|
/** A previous namespace. */
|
|
848
851
|
oldNamespace?: NamespaceWithLiterals;
|
|
849
852
|
/** A new namespace. */
|
|
850
853
|
newNamespace?: NamespaceWithLiterals;
|
|
851
854
|
}
|
|
852
855
|
/** Assigned Studio editor */
|
|
853
|
-
|
|
856
|
+
interface StudioAssigned {
|
|
854
857
|
}
|
|
855
858
|
/** Unassigned Studio editor */
|
|
856
|
-
|
|
859
|
+
interface StudioUnassigned {
|
|
857
860
|
}
|
|
858
861
|
/**
|
|
859
862
|
* Fired in case site URLs were changed in any way: new secondary domain, published, account slug rename, site rename etc.
|
|
@@ -863,13 +866,13 @@ export interface StudioUnassigned {
|
|
|
863
866
|
*
|
|
864
867
|
* https://bo.wix.com/wix-docs/rest/meta-site/meta-site---urls-service
|
|
865
868
|
*/
|
|
866
|
-
|
|
869
|
+
interface SiteUrlChanged {
|
|
867
870
|
}
|
|
868
871
|
/**
|
|
869
872
|
* Used at the end of the deletion flow for both draft sites and when a user deletes a site.
|
|
870
873
|
* Consumed by other teams to remove relevant data.
|
|
871
874
|
*/
|
|
872
|
-
|
|
875
|
+
interface SitePurgedExternally {
|
|
873
876
|
/**
|
|
874
877
|
* @maxLength 2048
|
|
875
878
|
* @maxSize 100
|
|
@@ -879,18 +882,18 @@ export interface SitePurgedExternally {
|
|
|
879
882
|
appDefId?: string[];
|
|
880
883
|
}
|
|
881
884
|
/** Assigned Odeditor */
|
|
882
|
-
|
|
885
|
+
interface OdeditorAssigned {
|
|
883
886
|
}
|
|
884
887
|
/** Unassigned Odeditor */
|
|
885
|
-
|
|
888
|
+
interface OdeditorUnassigned {
|
|
886
889
|
}
|
|
887
890
|
/** Assigned Picasso editor */
|
|
888
|
-
|
|
891
|
+
interface PicassoAssigned {
|
|
889
892
|
}
|
|
890
893
|
/** Unassigned Picasso */
|
|
891
|
-
|
|
894
|
+
interface PicassoUnassigned {
|
|
892
895
|
}
|
|
893
|
-
|
|
896
|
+
interface MessageEnvelope {
|
|
894
897
|
/**
|
|
895
898
|
* App instance ID.
|
|
896
899
|
* @format GUID
|
|
@@ -906,7 +909,7 @@ export interface MessageEnvelope {
|
|
|
906
909
|
/** Stringify payload. */
|
|
907
910
|
data?: string;
|
|
908
911
|
}
|
|
909
|
-
|
|
912
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
910
913
|
/**
|
|
911
914
|
* ID of a site visitor that has not logged in to the site.
|
|
912
915
|
* @format GUID
|
|
@@ -931,7 +934,7 @@ export interface IdentificationData extends IdentificationDataIdOneOf {
|
|
|
931
934
|
identityType?: WebhookIdentityTypeWithLiterals;
|
|
932
935
|
}
|
|
933
936
|
/** @oneof */
|
|
934
|
-
|
|
937
|
+
interface IdentificationDataIdOneOf {
|
|
935
938
|
/**
|
|
936
939
|
* ID of a site visitor that has not logged in to the site.
|
|
937
940
|
* @format GUID
|
|
@@ -953,7 +956,7 @@ export interface IdentificationDataIdOneOf {
|
|
|
953
956
|
*/
|
|
954
957
|
appId?: string;
|
|
955
958
|
}
|
|
956
|
-
|
|
959
|
+
declare enum WebhookIdentityType {
|
|
957
960
|
UNKNOWN = "UNKNOWN",
|
|
958
961
|
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
959
962
|
MEMBER = "MEMBER",
|
|
@@ -961,4 +964,135 @@ export declare enum WebhookIdentityType {
|
|
|
961
964
|
APP = "APP"
|
|
962
965
|
}
|
|
963
966
|
/** @enumType */
|
|
964
|
-
|
|
967
|
+
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
968
|
+
interface BaseEventMetadata {
|
|
969
|
+
/**
|
|
970
|
+
* App instance ID.
|
|
971
|
+
* @format GUID
|
|
972
|
+
*/
|
|
973
|
+
instanceId?: string | null;
|
|
974
|
+
/**
|
|
975
|
+
* Event type.
|
|
976
|
+
* @maxLength 150
|
|
977
|
+
*/
|
|
978
|
+
eventType?: string;
|
|
979
|
+
/** The identification type and identity data. */
|
|
980
|
+
identity?: IdentificationData;
|
|
981
|
+
}
|
|
982
|
+
interface EventMetadata extends BaseEventMetadata {
|
|
983
|
+
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
984
|
+
_id?: string;
|
|
985
|
+
/**
|
|
986
|
+
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
987
|
+
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
988
|
+
*/
|
|
989
|
+
entityFqdn?: string;
|
|
990
|
+
/**
|
|
991
|
+
* Event action name, placed at the top level to make it easier for users to dispatch messages.
|
|
992
|
+
* For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
|
|
993
|
+
*/
|
|
994
|
+
slug?: string;
|
|
995
|
+
/** ID of the entity associated with the event. */
|
|
996
|
+
entityId?: string;
|
|
997
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
|
|
998
|
+
eventTime?: Date | null;
|
|
999
|
+
/**
|
|
1000
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
1001
|
+
* (for example, GDPR).
|
|
1002
|
+
*/
|
|
1003
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
1004
|
+
/** If present, indicates the action that triggered the event. */
|
|
1005
|
+
originatedFrom?: string | null;
|
|
1006
|
+
/**
|
|
1007
|
+
* 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.
|
|
1008
|
+
* 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.
|
|
1009
|
+
*/
|
|
1010
|
+
entityEventSequence?: string | null;
|
|
1011
|
+
}
|
|
1012
|
+
interface LoyaltyEarningRuleCreatedEnvelope {
|
|
1013
|
+
entity: LoyaltyEarningRule;
|
|
1014
|
+
metadata: EventMetadata;
|
|
1015
|
+
}
|
|
1016
|
+
interface LoyaltyEarningRuleDeletedEnvelope {
|
|
1017
|
+
metadata: EventMetadata;
|
|
1018
|
+
}
|
|
1019
|
+
interface LoyaltyEarningRuleUpdatedEnvelope {
|
|
1020
|
+
entity: LoyaltyEarningRule;
|
|
1021
|
+
metadata: EventMetadata;
|
|
1022
|
+
}
|
|
1023
|
+
interface CreateCustomLoyaltyEarningRuleOptions {
|
|
1024
|
+
/** Custom earning rule to create. */
|
|
1025
|
+
earningRule?: CustomLoyaltyEarningRule;
|
|
1026
|
+
}
|
|
1027
|
+
interface UpdateLoyaltyEarningRule {
|
|
1028
|
+
/** Fixed amount of points awarded for each qualifying activity. */
|
|
1029
|
+
fixedAmount?: FixedAmount;
|
|
1030
|
+
/** Points awarded based on a conversion rate formula: `(amount spent) / (money_amount * points)`. */
|
|
1031
|
+
conversionRate?: ConversionRate;
|
|
1032
|
+
/**
|
|
1033
|
+
* Loyalty earning rule ID.
|
|
1034
|
+
* @format GUID
|
|
1035
|
+
* @readonly
|
|
1036
|
+
*/
|
|
1037
|
+
_id?: string | null;
|
|
1038
|
+
/**
|
|
1039
|
+
* ID of the app managing the earning rule. Can be a loyalty app ID or a Wix automations app ID.
|
|
1040
|
+
* @format GUID
|
|
1041
|
+
*/
|
|
1042
|
+
sourceAppId?: string;
|
|
1043
|
+
/**
|
|
1044
|
+
* ID of the app that triggers point assignment. Examples: Wix Stores, Wix Bookings, Wix Events.
|
|
1045
|
+
* @minLength 1
|
|
1046
|
+
* @maxLength 80
|
|
1047
|
+
*/
|
|
1048
|
+
triggerAppId?: string;
|
|
1049
|
+
/**
|
|
1050
|
+
* Type of activity that triggers point assignment. For example, `wix-restaurants/orderSubmitted` or `birthday`.
|
|
1051
|
+
* @minLength 1
|
|
1052
|
+
* @maxLength 80
|
|
1053
|
+
*/
|
|
1054
|
+
triggerActivityType?: string;
|
|
1055
|
+
/**
|
|
1056
|
+
* Name of the earning rule.
|
|
1057
|
+
* @minLength 1
|
|
1058
|
+
* @maxLength 50
|
|
1059
|
+
*/
|
|
1060
|
+
title?: string;
|
|
1061
|
+
/** Current status of the earning rule. */
|
|
1062
|
+
status?: StatusWithLiterals;
|
|
1063
|
+
/**
|
|
1064
|
+
* Revision number, incremented by 1 each time the earning rule is updated.
|
|
1065
|
+
* Pass the latest revision when updating to prevent conflicting changes.
|
|
1066
|
+
*/
|
|
1067
|
+
revision?: string | null;
|
|
1068
|
+
/**
|
|
1069
|
+
* Date and time the earning rule was created.
|
|
1070
|
+
* @readonly
|
|
1071
|
+
*/
|
|
1072
|
+
_createdDate?: Date | null;
|
|
1073
|
+
/**
|
|
1074
|
+
* Date and time the earning rule was last updated.
|
|
1075
|
+
* @readonly
|
|
1076
|
+
*/
|
|
1077
|
+
_updatedDate?: Date | null;
|
|
1078
|
+
/**
|
|
1079
|
+
* Additional metadata about the earning rule.
|
|
1080
|
+
* @readonly
|
|
1081
|
+
*/
|
|
1082
|
+
metadata?: Metadata;
|
|
1083
|
+
}
|
|
1084
|
+
interface DeleteLoyaltyEarningRuleOptions {
|
|
1085
|
+
/**
|
|
1086
|
+
* Revision of the earning rule. Incremented by 1 each time the earning rule is updated.
|
|
1087
|
+
* Pass the latest revision when updating to prevent conflicting changes.
|
|
1088
|
+
*/
|
|
1089
|
+
revision?: string;
|
|
1090
|
+
}
|
|
1091
|
+
interface ListEarningRulesOptions {
|
|
1092
|
+
/** App ID that triggers the point assignment. For example, `9a5d83fd-8570-482e-81ab-cfa88942ee60`. */
|
|
1093
|
+
triggerAppId?: string | null;
|
|
1094
|
+
/** Type of activity that triggers the point assignment. For example, `restaurants-order-is-pending`. */
|
|
1095
|
+
triggerActivityType?: string | null;
|
|
1096
|
+
}
|
|
1097
|
+
|
|
1098
|
+
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 };
|