@wix/auto_sdk_automations_activations 1.0.0
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/cjs/index.d.ts +1 -0
- package/build/cjs/index.js +18 -0
- package/build/cjs/index.js.map +1 -0
- package/build/cjs/index.typings.d.ts +1 -0
- package/build/cjs/index.typings.js +18 -0
- package/build/cjs/index.typings.js.map +1 -0
- package/build/cjs/meta.d.ts +1 -0
- package/build/cjs/meta.js +18 -0
- package/build/cjs/meta.js.map +1 -0
- package/build/cjs/src/automations-v2-activation-activations.context.d.ts +14 -0
- package/build/cjs/src/automations-v2-activation-activations.context.js +35 -0
- package/build/cjs/src/automations-v2-activation-activations.context.js.map +1 -0
- package/build/cjs/src/automations-v2-activation-activations.http.d.ts +31 -0
- package/build/cjs/src/automations-v2-activation-activations.http.js +143 -0
- package/build/cjs/src/automations-v2-activation-activations.http.js.map +1 -0
- package/build/cjs/src/automations-v2-activation-activations.meta.d.ts +16 -0
- package/build/cjs/src/automations-v2-activation-activations.meta.js +104 -0
- package/build/cjs/src/automations-v2-activation-activations.meta.js.map +1 -0
- package/build/cjs/src/automations-v2-activation-activations.public.d.ts +74 -0
- package/build/cjs/src/automations-v2-activation-activations.public.js +66 -0
- package/build/cjs/src/automations-v2-activation-activations.public.js.map +1 -0
- package/build/cjs/src/automations-v2-activation-activations.types.d.ts +1592 -0
- package/build/cjs/src/automations-v2-activation-activations.types.js +195 -0
- package/build/cjs/src/automations-v2-activation-activations.types.js.map +1 -0
- package/build/cjs/src/automations-v2-activation-activations.universal.d.ts +1775 -0
- package/build/cjs/src/automations-v2-activation-activations.universal.js +423 -0
- package/build/cjs/src/automations-v2-activation-activations.universal.js.map +1 -0
- package/build/es/index.d.ts +1 -0
- package/build/es/index.js +2 -0
- package/build/es/index.js.map +1 -0
- package/build/es/index.typings.d.ts +1 -0
- package/build/es/index.typings.js +2 -0
- package/build/es/index.typings.js.map +1 -0
- package/build/es/meta.d.ts +1 -0
- package/build/es/meta.js +2 -0
- package/build/es/meta.js.map +1 -0
- package/build/es/package.json +3 -0
- package/build/es/src/automations-v2-activation-activations.context.d.ts +14 -0
- package/build/es/src/automations-v2-activation-activations.context.js +14 -0
- package/build/es/src/automations-v2-activation-activations.context.js.map +1 -0
- package/build/es/src/automations-v2-activation-activations.http.d.ts +31 -0
- package/build/es/src/automations-v2-activation-activations.http.js +136 -0
- package/build/es/src/automations-v2-activation-activations.http.js.map +1 -0
- package/build/es/src/automations-v2-activation-activations.meta.d.ts +16 -0
- package/build/es/src/automations-v2-activation-activations.meta.js +74 -0
- package/build/es/src/automations-v2-activation-activations.meta.js.map +1 -0
- package/build/es/src/automations-v2-activation-activations.public.d.ts +74 -0
- package/build/es/src/automations-v2-activation-activations.public.js +41 -0
- package/build/es/src/automations-v2-activation-activations.public.js.map +1 -0
- package/build/es/src/automations-v2-activation-activations.types.d.ts +1592 -0
- package/build/es/src/automations-v2-activation-activations.types.js +192 -0
- package/build/es/src/automations-v2-activation-activations.types.js.map +1 -0
- package/build/es/src/automations-v2-activation-activations.universal.d.ts +1775 -0
- package/build/es/src/automations-v2-activation-activations.universal.js +393 -0
- package/build/es/src/automations-v2-activation-activations.universal.js.map +1 -0
- package/build/internal/cjs/index.d.ts +1 -0
- package/build/internal/cjs/index.js +18 -0
- package/build/internal/cjs/index.js.map +1 -0
- package/build/internal/cjs/index.typings.d.ts +1 -0
- package/build/internal/cjs/index.typings.js +18 -0
- package/build/internal/cjs/index.typings.js.map +1 -0
- package/build/internal/cjs/meta.d.ts +1 -0
- package/build/internal/cjs/meta.js +18 -0
- package/build/internal/cjs/meta.js.map +1 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.context.d.ts +14 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.context.js +35 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.context.js.map +1 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.http.d.ts +31 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.http.js +143 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.http.js.map +1 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.meta.d.ts +16 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.meta.js +104 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.meta.js.map +1 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.public.d.ts +74 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.public.js +66 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.public.js.map +1 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.types.d.ts +1592 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.types.js +195 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.types.js.map +1 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.universal.d.ts +1775 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.universal.js +423 -0
- package/build/internal/cjs/src/automations-v2-activation-activations.universal.js.map +1 -0
- package/build/internal/es/index.d.ts +1 -0
- package/build/internal/es/index.js +2 -0
- package/build/internal/es/index.js.map +1 -0
- package/build/internal/es/index.typings.d.ts +1 -0
- package/build/internal/es/index.typings.js +2 -0
- package/build/internal/es/index.typings.js.map +1 -0
- package/build/internal/es/meta.d.ts +1 -0
- package/build/internal/es/meta.js +2 -0
- package/build/internal/es/meta.js.map +1 -0
- package/build/internal/es/src/automations-v2-activation-activations.context.d.ts +14 -0
- package/build/internal/es/src/automations-v2-activation-activations.context.js +14 -0
- package/build/internal/es/src/automations-v2-activation-activations.context.js.map +1 -0
- package/build/internal/es/src/automations-v2-activation-activations.http.d.ts +31 -0
- package/build/internal/es/src/automations-v2-activation-activations.http.js +136 -0
- package/build/internal/es/src/automations-v2-activation-activations.http.js.map +1 -0
- package/build/internal/es/src/automations-v2-activation-activations.meta.d.ts +16 -0
- package/build/internal/es/src/automations-v2-activation-activations.meta.js +74 -0
- package/build/internal/es/src/automations-v2-activation-activations.meta.js.map +1 -0
- package/build/internal/es/src/automations-v2-activation-activations.public.d.ts +74 -0
- package/build/internal/es/src/automations-v2-activation-activations.public.js +41 -0
- package/build/internal/es/src/automations-v2-activation-activations.public.js.map +1 -0
- package/build/internal/es/src/automations-v2-activation-activations.types.d.ts +1592 -0
- package/build/internal/es/src/automations-v2-activation-activations.types.js +192 -0
- package/build/internal/es/src/automations-v2-activation-activations.types.js.map +1 -0
- package/build/internal/es/src/automations-v2-activation-activations.universal.d.ts +1775 -0
- package/build/internal/es/src/automations-v2-activation-activations.universal.js +393 -0
- package/build/internal/es/src/automations-v2-activation-activations.universal.js.map +1 -0
- package/meta/package.json +3 -0
- package/package.json +52 -0
|
@@ -0,0 +1,423 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.cancelEvent = exports.bulkCancelEvent = exports.bulkReportEvent = exports.reportEvent = exports.IdentifierType = exports.ActivationActionStatusChangedStatus = exports.BlockType = exports.WebhookIdentityType = exports.ScheduleStatus = exports.Units = exports.ActivationStatusChangedStatus = exports.SkipReason = exports.ErrorReason = exports.CancellationReason = exports.Target = exports.Status = exports.Origin = exports.AutomationConfigurationStatus = exports.Type = exports.Operator = exports.TimeUnit = exports.Domain = void 0;
|
|
27
|
+
const transform_error_1 = require("@wix/sdk-runtime/transform-error");
|
|
28
|
+
const rename_all_nested_keys_1 = require("@wix/sdk-runtime/rename-all-nested-keys");
|
|
29
|
+
const ambassadorWixAutomationsV2Activation = __importStar(require("./automations-v2-activation-activations.http.js"));
|
|
30
|
+
var Domain;
|
|
31
|
+
(function (Domain) {
|
|
32
|
+
/** User domain (default). */
|
|
33
|
+
Domain["USER"] = "USER";
|
|
34
|
+
/** Wix domain. */
|
|
35
|
+
Domain["WIX"] = "WIX";
|
|
36
|
+
})(Domain || (exports.Domain = Domain = {}));
|
|
37
|
+
var TimeUnit;
|
|
38
|
+
(function (TimeUnit) {
|
|
39
|
+
TimeUnit["UNKNOWN_TIME_UNIT"] = "UNKNOWN_TIME_UNIT";
|
|
40
|
+
TimeUnit["MINUTES"] = "MINUTES";
|
|
41
|
+
TimeUnit["HOURS"] = "HOURS";
|
|
42
|
+
TimeUnit["DAYS"] = "DAYS";
|
|
43
|
+
TimeUnit["WEEKS"] = "WEEKS";
|
|
44
|
+
TimeUnit["MONTHS"] = "MONTHS";
|
|
45
|
+
})(TimeUnit || (exports.TimeUnit = TimeUnit = {}));
|
|
46
|
+
var Operator;
|
|
47
|
+
(function (Operator) {
|
|
48
|
+
Operator["UNKNOWN_OPERATOR"] = "UNKNOWN_OPERATOR";
|
|
49
|
+
Operator["OR"] = "OR";
|
|
50
|
+
Operator["AND"] = "AND";
|
|
51
|
+
})(Operator || (exports.Operator = Operator = {}));
|
|
52
|
+
var Type;
|
|
53
|
+
(function (Type) {
|
|
54
|
+
/** Automation will be triggered according to the trigger configuration. */
|
|
55
|
+
Type["UNKNOWN_ACTION_TYPE"] = "UNKNOWN_ACTION_TYPE";
|
|
56
|
+
/** App defined Action. */
|
|
57
|
+
Type["APP_DEFINED"] = "APP_DEFINED";
|
|
58
|
+
/** Condition Action. */
|
|
59
|
+
Type["CONDITION"] = "CONDITION";
|
|
60
|
+
/** Delay Action. */
|
|
61
|
+
Type["DELAY"] = "DELAY";
|
|
62
|
+
/** RateLimit Action. */
|
|
63
|
+
Type["RATE_LIMIT"] = "RATE_LIMIT";
|
|
64
|
+
/** Set Variables Action. */
|
|
65
|
+
Type["SET_VARIABLES"] = "SET_VARIABLES";
|
|
66
|
+
/** Output Action. */
|
|
67
|
+
Type["OUTPUT"] = "OUTPUT";
|
|
68
|
+
})(Type || (exports.Type = Type = {}));
|
|
69
|
+
var AutomationConfigurationStatus;
|
|
70
|
+
(function (AutomationConfigurationStatus) {
|
|
71
|
+
/** unused */
|
|
72
|
+
AutomationConfigurationStatus["UNKNOWN_STATUS"] = "UNKNOWN_STATUS";
|
|
73
|
+
/** Automation will be triggered according to the trigger configuration */
|
|
74
|
+
AutomationConfigurationStatus["ACTIVE"] = "ACTIVE";
|
|
75
|
+
/** Automation will not be triggered */
|
|
76
|
+
AutomationConfigurationStatus["INACTIVE"] = "INACTIVE";
|
|
77
|
+
})(AutomationConfigurationStatus || (exports.AutomationConfigurationStatus = AutomationConfigurationStatus = {}));
|
|
78
|
+
var Origin;
|
|
79
|
+
(function (Origin) {
|
|
80
|
+
/** Default value. This is unused. */
|
|
81
|
+
Origin["UNKNOWN_ORIGIN"] = "UNKNOWN_ORIGIN";
|
|
82
|
+
/** User created automation. */
|
|
83
|
+
Origin["USER"] = "USER";
|
|
84
|
+
/** Automation created by application (site specific). */
|
|
85
|
+
Origin["APPLICATION"] = "APPLICATION";
|
|
86
|
+
/** Preinstalled application automation. */
|
|
87
|
+
Origin["PREINSTALLED"] = "PREINSTALLED";
|
|
88
|
+
/** Automation created from a recipe. */
|
|
89
|
+
Origin["RECIPE"] = "RECIPE";
|
|
90
|
+
})(Origin || (exports.Origin = Origin = {}));
|
|
91
|
+
var Status;
|
|
92
|
+
(function (Status) {
|
|
93
|
+
Status["UNKNOWN_STATUS"] = "UNKNOWN_STATUS";
|
|
94
|
+
Status["STARTED"] = "STARTED";
|
|
95
|
+
Status["ENDED"] = "ENDED";
|
|
96
|
+
Status["ERROR"] = "ERROR";
|
|
97
|
+
Status["SCHEDULED"] = "SCHEDULED";
|
|
98
|
+
Status["FROM_SCHEDULER"] = "FROM_SCHEDULER";
|
|
99
|
+
Status["RETRY"] = "RETRY";
|
|
100
|
+
Status["RESUMED"] = "RESUMED";
|
|
101
|
+
Status["PAUSED"] = "PAUSED";
|
|
102
|
+
Status["ACTION_SKIPPED"] = "ACTION_SKIPPED";
|
|
103
|
+
})(Status || (exports.Status = Status = {}));
|
|
104
|
+
var Target;
|
|
105
|
+
(function (Target) {
|
|
106
|
+
Target["UNKNOWN_TARGET"] = "UNKNOWN_TARGET";
|
|
107
|
+
Target["SCHEDULE"] = "SCHEDULE";
|
|
108
|
+
Target["IMMEDIATE"] = "IMMEDIATE";
|
|
109
|
+
})(Target || (exports.Target = Target = {}));
|
|
110
|
+
var CancellationReason;
|
|
111
|
+
(function (CancellationReason) {
|
|
112
|
+
CancellationReason["UNKNOWN_CANCELLATION_REASON"] = "UNKNOWN_CANCELLATION_REASON";
|
|
113
|
+
/** Indicates that the activation was cancelled directly. */
|
|
114
|
+
CancellationReason["EVENT_CANCELLED"] = "EVENT_CANCELLED";
|
|
115
|
+
/** Indicates that the activation was cancelled because the automation was deactivated. */
|
|
116
|
+
CancellationReason["AUTOMATION_DEACTIVATED"] = "AUTOMATION_DEACTIVATED";
|
|
117
|
+
/** Indicates that the activation was cancelled because the automation was deleted. */
|
|
118
|
+
CancellationReason["AUTOMATION_DELETED"] = "AUTOMATION_DELETED";
|
|
119
|
+
/** Indicates that the activation was cancelled after the automation schedule time was reached. */
|
|
120
|
+
CancellationReason["CANCELLED_BY_REFRESH_PAYLOAD"] = "CANCELLED_BY_REFRESH_PAYLOAD";
|
|
121
|
+
/** Indicates that the activation was cancelled due to a UoU GDPR "Right to be Forgotten" request. */
|
|
122
|
+
CancellationReason["CANCELLED_BY_GDPR_REQUEST"] = "CANCELLED_BY_GDPR_REQUEST";
|
|
123
|
+
})(CancellationReason || (exports.CancellationReason = CancellationReason = {}));
|
|
124
|
+
var ErrorReason;
|
|
125
|
+
(function (ErrorReason) {
|
|
126
|
+
/** Unexpected error reason */
|
|
127
|
+
ErrorReason["UNEXPECTED_ERROR_REASON"] = "UNEXPECTED_ERROR_REASON";
|
|
128
|
+
/** Failed to evaluate the schedule date expression */
|
|
129
|
+
ErrorReason["SCHEDULE_DATE_EVALUATION_FAILED"] = "SCHEDULE_DATE_EVALUATION_FAILED";
|
|
130
|
+
})(ErrorReason || (exports.ErrorReason = ErrorReason = {}));
|
|
131
|
+
var SkipReason;
|
|
132
|
+
(function (SkipReason) {
|
|
133
|
+
SkipReason["UNKNOWN_SKIP_REASON"] = "UNKNOWN_SKIP_REASON";
|
|
134
|
+
/** Activation was skipped because the scheduled execution time had already passed at the time of execution. */
|
|
135
|
+
SkipReason["SCHEDULE_DATE_EXPIRED"] = "SCHEDULE_DATE_EXPIRED";
|
|
136
|
+
/** Activation was skipped because the trigger filters defined in the automation did not match the payload. */
|
|
137
|
+
SkipReason["TRIGGER_FILTERS_NOT_PASSED"] = "TRIGGER_FILTERS_NOT_PASSED";
|
|
138
|
+
})(SkipReason || (exports.SkipReason = SkipReason = {}));
|
|
139
|
+
var ActivationStatusChangedStatus;
|
|
140
|
+
(function (ActivationStatusChangedStatus) {
|
|
141
|
+
ActivationStatusChangedStatus["UNKNOWN_STATUS"] = "UNKNOWN_STATUS";
|
|
142
|
+
/** Indicates that activation has not started yet and no actions have been executed. */
|
|
143
|
+
ActivationStatusChangedStatus["INITIATED"] = "INITIATED";
|
|
144
|
+
/** Activation is in scheduled status when the automation has a future date or debounce defined and we're in the waiting stage and no actions have been executed. */
|
|
145
|
+
ActivationStatusChangedStatus["SCHEDULED"] = "SCHEDULED";
|
|
146
|
+
/** Indicates the automation activation has started and is currently in progress. */
|
|
147
|
+
ActivationStatusChangedStatus["STARTED"] = "STARTED";
|
|
148
|
+
/** Indicates all the automation actions were handled either by invoking them, skipping them, etc. */
|
|
149
|
+
ActivationStatusChangedStatus["ENDED"] = "ENDED";
|
|
150
|
+
/** Indicates the activation was cancelled. */
|
|
151
|
+
ActivationStatusChangedStatus["CANCELLED"] = "CANCELLED";
|
|
152
|
+
/**
|
|
153
|
+
* Indicates the activation failed to start.
|
|
154
|
+
* Note that failure in the activation of a single action will not result in a failure in activation of the entire automation.
|
|
155
|
+
*/
|
|
156
|
+
ActivationStatusChangedStatus["FAILED"] = "FAILED";
|
|
157
|
+
/**
|
|
158
|
+
* Indicates that the automation activation was skipped without executing any actions.
|
|
159
|
+
* Note that an activation will either be skipped immediately or move to INITIATED state.
|
|
160
|
+
*/
|
|
161
|
+
ActivationStatusChangedStatus["SKIPPED"] = "SKIPPED";
|
|
162
|
+
})(ActivationStatusChangedStatus || (exports.ActivationStatusChangedStatus = ActivationStatusChangedStatus = {}));
|
|
163
|
+
var Units;
|
|
164
|
+
(function (Units) {
|
|
165
|
+
Units["UNKNOWN"] = "UNKNOWN";
|
|
166
|
+
Units["MINUTES"] = "MINUTES";
|
|
167
|
+
Units["HOURS"] = "HOURS";
|
|
168
|
+
Units["DAYS"] = "DAYS";
|
|
169
|
+
})(Units || (exports.Units = Units = {}));
|
|
170
|
+
var ScheduleStatus;
|
|
171
|
+
(function (ScheduleStatus) {
|
|
172
|
+
ScheduleStatus["UNKNOWN_SCHEDULE_STATUS"] = "UNKNOWN_SCHEDULE_STATUS";
|
|
173
|
+
ScheduleStatus["PENDING"] = "PENDING";
|
|
174
|
+
ScheduleStatus["CANCELLED"] = "CANCELLED";
|
|
175
|
+
ScheduleStatus["DONE"] = "DONE";
|
|
176
|
+
})(ScheduleStatus || (exports.ScheduleStatus = ScheduleStatus = {}));
|
|
177
|
+
var WebhookIdentityType;
|
|
178
|
+
(function (WebhookIdentityType) {
|
|
179
|
+
WebhookIdentityType["UNKNOWN"] = "UNKNOWN";
|
|
180
|
+
WebhookIdentityType["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
|
181
|
+
WebhookIdentityType["MEMBER"] = "MEMBER";
|
|
182
|
+
WebhookIdentityType["WIX_USER"] = "WIX_USER";
|
|
183
|
+
WebhookIdentityType["APP"] = "APP";
|
|
184
|
+
})(WebhookIdentityType || (exports.WebhookIdentityType = WebhookIdentityType = {}));
|
|
185
|
+
var BlockType;
|
|
186
|
+
(function (BlockType) {
|
|
187
|
+
BlockType["UNKNOWN"] = "UNKNOWN";
|
|
188
|
+
BlockType["OR"] = "OR";
|
|
189
|
+
BlockType["AND"] = "AND";
|
|
190
|
+
})(BlockType || (exports.BlockType = BlockType = {}));
|
|
191
|
+
var ActivationActionStatusChangedStatus;
|
|
192
|
+
(function (ActivationActionStatusChangedStatus) {
|
|
193
|
+
ActivationActionStatusChangedStatus["UNKNOWN_ACTION_ACTIVATION_STATUS"] = "UNKNOWN_ACTION_ACTIVATION_STATUS";
|
|
194
|
+
/**
|
|
195
|
+
* Indicates that action activation has started and is in progress.
|
|
196
|
+
* Relevant to action types: APP_DEFINED, DELAY.
|
|
197
|
+
*/
|
|
198
|
+
ActivationActionStatusChangedStatus["STARTED"] = "STARTED";
|
|
199
|
+
/**
|
|
200
|
+
* Indicates that the action activation was completed without errors.
|
|
201
|
+
* Relevant to action types: APP_DEFINED, DELAY, CONDITION, RATE_LIMIT.
|
|
202
|
+
*/
|
|
203
|
+
ActivationActionStatusChangedStatus["ENDED"] = "ENDED";
|
|
204
|
+
/**
|
|
205
|
+
* Indicates that the action was skipped and post actions won't start.
|
|
206
|
+
* Relevant to action types: APP_DEFINED.
|
|
207
|
+
*/
|
|
208
|
+
ActivationActionStatusChangedStatus["SKIPPED"] = "SKIPPED";
|
|
209
|
+
/**
|
|
210
|
+
* Indicates that the action failed.
|
|
211
|
+
* Relevant to action types: APP_DEFINED, DELAY, RATE_LIMIT.
|
|
212
|
+
*/
|
|
213
|
+
ActivationActionStatusChangedStatus["FAILED"] = "FAILED";
|
|
214
|
+
})(ActivationActionStatusChangedStatus || (exports.ActivationActionStatusChangedStatus = ActivationActionStatusChangedStatus = {}));
|
|
215
|
+
var IdentifierType;
|
|
216
|
+
(function (IdentifierType) {
|
|
217
|
+
IdentifierType["UNKNOWN_IDENTIFIER"] = "UNKNOWN_IDENTIFIER";
|
|
218
|
+
IdentifierType["PREINSTALLED"] = "PREINSTALLED";
|
|
219
|
+
IdentifierType["AUTOMATION"] = "AUTOMATION";
|
|
220
|
+
})(IdentifierType || (exports.IdentifierType = IdentifierType = {}));
|
|
221
|
+
/**
|
|
222
|
+
* Reports an event and activates site automations with the specified trigger key.
|
|
223
|
+
*
|
|
224
|
+
*
|
|
225
|
+
* Only the app that created a trigger can report events for it.
|
|
226
|
+
* This means other apps can't report events for your triggers,
|
|
227
|
+
* and you can't report events for another app's triggers.
|
|
228
|
+
*
|
|
229
|
+
* If your app supports canceling events,
|
|
230
|
+
* `externalEntityId` must be provided.
|
|
231
|
+
* `externalEntityId` is required when calling [cancelEvent()](#cancel-event).
|
|
232
|
+
* @param triggerKey - Trigger key as defined in your app's trigger configuration
|
|
233
|
+
* in the app dashboard.
|
|
234
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
235
|
+
* @public
|
|
236
|
+
* @requiredField triggerKey
|
|
237
|
+
* @permissionId AUTOMATIONS.REPORT_EVENT
|
|
238
|
+
* @permissionScope Manage Your App
|
|
239
|
+
* @permissionScopeId SCOPE.DC.MANAGE-YOUR-APP
|
|
240
|
+
* @permissionScope Read site, business, and email details
|
|
241
|
+
* @permissionScopeId SCOPE.DEV_CENTER.APP-INSTANCE-READ-BASIC-INFO
|
|
242
|
+
* @applicableIdentity APP
|
|
243
|
+
* @fqn wix.automations.esb.resolver.v1.EsbConfigResolver.ReportEvent
|
|
244
|
+
*/
|
|
245
|
+
async function reportEvent(triggerKey, options) {
|
|
246
|
+
// @ts-ignore
|
|
247
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
248
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
249
|
+
triggerKey: triggerKey,
|
|
250
|
+
payload: options?.payload,
|
|
251
|
+
externalEntityId: options?.externalEntityId,
|
|
252
|
+
idempotency: options?.idempotency,
|
|
253
|
+
});
|
|
254
|
+
const reqOpts = ambassadorWixAutomationsV2Activation.reportEvent(payload);
|
|
255
|
+
sideEffects?.onSiteCall?.();
|
|
256
|
+
try {
|
|
257
|
+
const result = await httpClient.request(reqOpts);
|
|
258
|
+
sideEffects?.onSuccess?.(result);
|
|
259
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
260
|
+
}
|
|
261
|
+
catch (err) {
|
|
262
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
263
|
+
spreadPathsToArguments: {},
|
|
264
|
+
explicitPathsToArguments: {
|
|
265
|
+
triggerKey: '$[0]',
|
|
266
|
+
payload: '$[1].payload',
|
|
267
|
+
externalEntityId: '$[1].externalEntityId',
|
|
268
|
+
idempotency: '$[1].idempotency',
|
|
269
|
+
},
|
|
270
|
+
singleArgumentUnchanged: false,
|
|
271
|
+
}, ['triggerKey', 'options']);
|
|
272
|
+
sideEffects?.onError?.(err);
|
|
273
|
+
throw transformedError;
|
|
274
|
+
}
|
|
275
|
+
}
|
|
276
|
+
exports.reportEvent = reportEvent;
|
|
277
|
+
/**
|
|
278
|
+
* Bulk reports events and activates site automations with the specified trigger key.
|
|
279
|
+
* @param triggerKey - Trigger key as defined in your app's trigger configuration
|
|
280
|
+
* in the app dashboard.
|
|
281
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
282
|
+
* @param eventsInfo - Repeated list of event details for bulk reporting.
|
|
283
|
+
* @public
|
|
284
|
+
* @requiredField eventsInfo
|
|
285
|
+
* @requiredField triggerKey
|
|
286
|
+
* @permissionId AUTOMATIONS.REPORT_EVENT
|
|
287
|
+
* @permissionScope Manage Your App
|
|
288
|
+
* @permissionScopeId SCOPE.DC.MANAGE-YOUR-APP
|
|
289
|
+
* @permissionScope Read site, business, and email details
|
|
290
|
+
* @permissionScopeId SCOPE.DEV_CENTER.APP-INSTANCE-READ-BASIC-INFO
|
|
291
|
+
* @applicableIdentity APP
|
|
292
|
+
* @fqn wix.automations.esb.resolver.v1.EsbConfigResolver.BulkReportEvent
|
|
293
|
+
*/
|
|
294
|
+
async function bulkReportEvent(triggerKey, eventsInfo) {
|
|
295
|
+
// @ts-ignore
|
|
296
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
297
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
298
|
+
triggerKey: triggerKey,
|
|
299
|
+
eventsInfo: eventsInfo,
|
|
300
|
+
});
|
|
301
|
+
const reqOpts = ambassadorWixAutomationsV2Activation.bulkReportEvent(payload);
|
|
302
|
+
sideEffects?.onSiteCall?.();
|
|
303
|
+
try {
|
|
304
|
+
const result = await httpClient.request(reqOpts);
|
|
305
|
+
sideEffects?.onSuccess?.(result);
|
|
306
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
307
|
+
}
|
|
308
|
+
catch (err) {
|
|
309
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
310
|
+
spreadPathsToArguments: {},
|
|
311
|
+
explicitPathsToArguments: { triggerKey: '$[0]', eventsInfo: '$[1]' },
|
|
312
|
+
singleArgumentUnchanged: false,
|
|
313
|
+
}, ['triggerKey', 'eventsInfo']);
|
|
314
|
+
sideEffects?.onError?.(err);
|
|
315
|
+
throw transformedError;
|
|
316
|
+
}
|
|
317
|
+
}
|
|
318
|
+
exports.bulkReportEvent = bulkReportEvent;
|
|
319
|
+
/**
|
|
320
|
+
* Bulk cancels any remaining actions for a trigger and external entities.
|
|
321
|
+
* @param triggerKey - Trigger key whose events you want to cancel.
|
|
322
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
323
|
+
* @param externalEntityIds - Repeated list of external_entity_id, representing the related resources' IDs.
|
|
324
|
+
* @public
|
|
325
|
+
* @requiredField externalEntityIds
|
|
326
|
+
* @requiredField triggerKey
|
|
327
|
+
* @permissionId AUTOMATIONS.CANCEL_EVENT
|
|
328
|
+
* @permissionScope Manage Your App
|
|
329
|
+
* @permissionScopeId SCOPE.DC.MANAGE-YOUR-APP
|
|
330
|
+
* @permissionScope Read site, business, and email details
|
|
331
|
+
* @permissionScopeId SCOPE.DEV_CENTER.APP-INSTANCE-READ-BASIC-INFO
|
|
332
|
+
* @applicableIdentity APP
|
|
333
|
+
* @fqn wix.automations.esb.resolver.v1.EsbConfigResolver.BulkCancelEvent
|
|
334
|
+
*/
|
|
335
|
+
async function bulkCancelEvent(triggerKey, externalEntityIds) {
|
|
336
|
+
// @ts-ignore
|
|
337
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
338
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
339
|
+
triggerKey: triggerKey,
|
|
340
|
+
externalEntityIds: externalEntityIds,
|
|
341
|
+
});
|
|
342
|
+
const reqOpts = ambassadorWixAutomationsV2Activation.bulkCancelEvent(payload);
|
|
343
|
+
sideEffects?.onSiteCall?.();
|
|
344
|
+
try {
|
|
345
|
+
const result = await httpClient.request(reqOpts);
|
|
346
|
+
sideEffects?.onSuccess?.(result);
|
|
347
|
+
return (0, rename_all_nested_keys_1.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
348
|
+
}
|
|
349
|
+
catch (err) {
|
|
350
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
351
|
+
spreadPathsToArguments: {},
|
|
352
|
+
explicitPathsToArguments: {
|
|
353
|
+
triggerKey: '$[0]',
|
|
354
|
+
externalEntityIds: '$[1]',
|
|
355
|
+
},
|
|
356
|
+
singleArgumentUnchanged: false,
|
|
357
|
+
}, ['triggerKey', 'externalEntityIds']);
|
|
358
|
+
sideEffects?.onError?.(err);
|
|
359
|
+
throw transformedError;
|
|
360
|
+
}
|
|
361
|
+
}
|
|
362
|
+
exports.bulkCancelEvent = bulkCancelEvent;
|
|
363
|
+
/**
|
|
364
|
+
* Cancels any remaining actions for a trigger and external entity.
|
|
365
|
+
*
|
|
366
|
+
*
|
|
367
|
+
* Events are not cancelable by default.
|
|
368
|
+
* To make an event cancelable,
|
|
369
|
+
* you must first pass an `externalEntityId`
|
|
370
|
+
* and the applicable `triggerKey` to [reportEvent()](#report-event).
|
|
371
|
+
* When you call cancelEvent() with the same `externalEntityId` and `triggerKey`,
|
|
372
|
+
* the event is canceled,
|
|
373
|
+
* as are all other events that share the `externalEntityId` and `triggerKey`.
|
|
374
|
+
* @param triggerKey - Trigger key whose event you want to cancel.
|
|
375
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
376
|
+
* @param externalEntityId - ID of the related resource in GUID format.
|
|
377
|
+
* For example, `fc81a355-3429-50fc-a4c7-def486e828f3`.
|
|
378
|
+
*
|
|
379
|
+
* Typically, this ID is defined in your system,
|
|
380
|
+
* but you can also use any Wix resource GUID,
|
|
381
|
+
* such as contact ID, member ID, or invoice ID.
|
|
382
|
+
* See
|
|
383
|
+
* [Choose the right `externalEntityId`](https://dev.wix.com/docs/rest/business-management/automations/triggered-events/reporting-and-canceling-events#choose-the-right-externalentityid)
|
|
384
|
+
* for more information.
|
|
385
|
+
* @public
|
|
386
|
+
* @requiredField externalEntityId
|
|
387
|
+
* @requiredField triggerKey
|
|
388
|
+
* @permissionId AUTOMATIONS.CANCEL_EVENT
|
|
389
|
+
* @permissionScope Manage Your App
|
|
390
|
+
* @permissionScopeId SCOPE.DC.MANAGE-YOUR-APP
|
|
391
|
+
* @permissionScope Read site, business, and email details
|
|
392
|
+
* @permissionScopeId SCOPE.DEV_CENTER.APP-INSTANCE-READ-BASIC-INFO
|
|
393
|
+
* @applicableIdentity APP
|
|
394
|
+
* @fqn wix.automations.esb.resolver.v1.EsbConfigResolver.CancelEvent
|
|
395
|
+
*/
|
|
396
|
+
async function cancelEvent(triggerKey, externalEntityId) {
|
|
397
|
+
// @ts-ignore
|
|
398
|
+
const { httpClient, sideEffects } = arguments[2];
|
|
399
|
+
const payload = (0, rename_all_nested_keys_1.renameKeysFromSDKRequestToRESTRequest)({
|
|
400
|
+
triggerKey: triggerKey,
|
|
401
|
+
externalEntityId: externalEntityId,
|
|
402
|
+
});
|
|
403
|
+
const reqOpts = ambassadorWixAutomationsV2Activation.cancelEvent(payload);
|
|
404
|
+
sideEffects?.onSiteCall?.();
|
|
405
|
+
try {
|
|
406
|
+
const result = await httpClient.request(reqOpts);
|
|
407
|
+
sideEffects?.onSuccess?.(result);
|
|
408
|
+
}
|
|
409
|
+
catch (err) {
|
|
410
|
+
const transformedError = (0, transform_error_1.transformError)(err, {
|
|
411
|
+
spreadPathsToArguments: {},
|
|
412
|
+
explicitPathsToArguments: {
|
|
413
|
+
triggerKey: '$[0]',
|
|
414
|
+
externalEntityId: '$[1]',
|
|
415
|
+
},
|
|
416
|
+
singleArgumentUnchanged: false,
|
|
417
|
+
}, ['triggerKey', 'externalEntityId']);
|
|
418
|
+
sideEffects?.onError?.(err);
|
|
419
|
+
throw transformedError;
|
|
420
|
+
}
|
|
421
|
+
}
|
|
422
|
+
exports.cancelEvent = cancelEvent;
|
|
423
|
+
//# sourceMappingURL=automations-v2-activation-activations.universal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"automations-v2-activation-activations.universal.js","sourceRoot":"","sources":["../../../src/automations-v2-activation-activations.universal.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,sEAAuF;AACvF,oFAGiD;AAE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C,CAAC;QACjD,WAAW,EAAE,SAAS,EAAE,CAAC,MAAM,CAAC,CAAC;IACnC,CAAC;IAAC,OAAO,GAAQ,EAAE,CAAC;QAClB,MAAM,gBAAgB,GAAG,IAAA,gCAAiB,EACxC,GAAG,EACH;YACE,sBAAsB,EAAE,EAAE;YAC1B,wBAAwB,EAAE;gBACxB,UAAU,EAAE,MAAM;gBAClB,gBAAgB,EAAE,MAAM;aACzB;YACD,uBAAuB,EAAE,KAAK;SAC/B,EACD,CAAC,YAAY,EAAE,kBAAkB,CAAC,CACnC,CAAC;QACF,WAAW,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAAC;QAE5B,MAAM,gBAAgB,CAAC;IACzB,CAAC;AACH,CAAC;AAtCD,kCAsCC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './src/automations-v2-activation-activations.context.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../index.ts"],"names":[],"mappings":"AAAA,cAAc,wDAAwD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './src/automations-v2-activation-activations.universal.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.typings.js","sourceRoot":"","sources":["../../index.typings.ts"],"names":[],"mappings":"AAAA,cAAc,0DAA0D,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './src/automations-v2-activation-activations.meta.js';
|
package/build/es/meta.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"meta.js","sourceRoot":"","sources":["../../meta.ts"],"names":[],"mappings":"AAAA,cAAc,qDAAqD,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { reportEvent as publicReportEvent, bulkReportEvent as publicBulkReportEvent, bulkCancelEvent as publicBulkCancelEvent, cancelEvent as publicCancelEvent } from './automations-v2-activation-activations.public.js';
|
|
2
|
+
import { createEventModule } from '@wix/sdk-runtime/event-definition-modules';
|
|
3
|
+
import { BuildRESTFunction, MaybeContext } from '@wix/sdk-types';
|
|
4
|
+
import { onActivationStatusChanged as publicOnActivationStatusChanged } from './automations-v2-activation-activations.public.js';
|
|
5
|
+
export declare const reportEvent: MaybeContext<BuildRESTFunction<typeof publicReportEvent> & typeof publicReportEvent>;
|
|
6
|
+
export declare const bulkReportEvent: MaybeContext<BuildRESTFunction<typeof publicBulkReportEvent> & typeof publicBulkReportEvent>;
|
|
7
|
+
export declare const bulkCancelEvent: MaybeContext<BuildRESTFunction<typeof publicBulkCancelEvent> & typeof publicBulkCancelEvent>;
|
|
8
|
+
export declare const cancelEvent: MaybeContext<BuildRESTFunction<typeof publicCancelEvent> & typeof publicCancelEvent>;
|
|
9
|
+
/**
|
|
10
|
+
* activation status changed message
|
|
11
|
+
*/
|
|
12
|
+
export declare const onActivationStatusChanged: ReturnType<typeof createEventModule<typeof publicOnActivationStatusChanged>>;
|
|
13
|
+
export { Domain, TimeUnit, Operator, Type, AutomationConfigurationStatus, Origin, Status, Target, CancellationReason, ErrorReason, SkipReason, ActivationStatusChangedStatus, Units, ScheduleStatus, WebhookIdentityType, BlockType, ActivationActionStatusChangedStatus, IdentifierType, } from './automations-v2-activation-activations.universal.js';
|
|
14
|
+
export { Activation, Automation, AutomationOriginInfoOneOf, ActionSettings, Enrichment, AuditInfo, AuditInfoIdOneOf, AutomationConfiguration, Filter, FutureDateActivationOffset, RateLimit, ConditionExpressionGroup, AppDefinedAction, ConditionAction, DelayAction, RateLimitAction, SetVariablesAction, OutputAction, Trigger, AutomationConfigurationAction, AutomationConfigurationActionInfoOneOf, ApplicationOrigin, PreinstalledOrigin, AutomationSettings, DraftInfo, Enrichments, ExtendedFields, ActivationStatus, ActivationStatusChanged, ActivationStatusChangedStatusInfoOneOf, Identity, InitiatedStatusInfo, ActivationStatusChangedStartedStatusInfo, ScheduledStatusInfo, CancelledStatusInfo, ActivationStatusChangedFailedStatusInfo, SkippedStatusInfo, ScheduleRequest, Schedule, ScheduledAction, Delay, DelayOfOneOf, SimpleDelay, TriggerInfo, ScheduleResponse, CancelPendingScheduleRequest, CancelPendingScheduleRequestByOneOf, CancelPendingScheduleResponse, UpdatePendingSchedulesPayloadRequest, UpdatePendingSchedulesPayloadResponse, DomainEvent, DomainEventBodyOneOf, EntityCreatedEvent, RestoreInfo, EntityUpdatedEvent, EntityDeletedEvent, ActionEvent, MessageEnvelope, IdentificationData, IdentificationDataIdOneOf, ActivationRequest, Runtime, Scheduler, AsyncAction, ActionData, Action, ActionActionOneOf, ServiceMapping, IfFilter, SwitchFilter, Case, DelayHelper, RateLimiting, ConditionFilter, ConditionBlock, Output, SetVariables, Service, SystemHelper, SystemHelperHelperOneOf, SpiAction, ActivationSource, ActivationSourceOfOneOf, ActionsData, ActionStatus, BatchActivationRequest, Empty, ActivationActionStatusChanged, ActivationActionStatusChangedInfoOneOf, ActivationActionStatusChangedStatusInfoOneOf, StartedStatusInfoAppDefinedActionInfo, StartedStatusInfoDelayActionInfo, ExpressionEvaluationResult, EndedStatusInfoAppDefinedActionInfo, ConditionActionInfo, RateLimitActionInfo, DelayActionInfo, SetVariablesActionInfo, AutomationInfo, AutomationInfoOriginInfoOneOf, AutomationInfoTriggerInfo, AppDefinedActionInfo, StartedStatusInfo, StartedStatusInfoTypeInfoOneOf, EndedStatusInfo, EndedStatusInfoTypeInfoOneOf, FailedStatusInfo, ActivationResumeAfterDelay, ActionCompletedRequest, RefreshPayloadRequest, RefreshPayloadResponse, RunAutomationRequest, RunAutomationResponse, ActivationScheduleRequested, ScheduleActivationRequested, ActivationContinuedAfterSchedule, ReportEventRequest, Idempotency, ReportEventResponse, BulkReportEventRequest, EventInfo, BulkReportEventResponse, BulkReportEventResult, ItemMetadata, ApplicationError, BulkActionMetadata, BulkCancelEventRequest, BulkCancelEventResponse, BulkCancelEventResult, CancelEventRequest, CancelEventResponse, V1RunAutomationRequest, V1RunAutomationRequestIdentifierOneOf, PreinstalledIdentifier, AutomationIdentifier, V1RunAutomationResponse, ReportDomainEventRequest, ReportDomainEventResponse, ExecuteFromActionRequest, ExecuteFromActionResponse, ActivationScheduleCompleted, ReportEventResponseNonNullableFields, BulkReportEventResponseNonNullableFields, BulkCancelEventResponseNonNullableFields, BaseEventMetadata, EventMetadata, ActivationStatusChangedEnvelope, ReportEventOptions, } from './automations-v2-activation-activations.universal.js';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { reportEvent as publicReportEvent, bulkReportEvent as publicBulkReportEvent, bulkCancelEvent as publicBulkCancelEvent, cancelEvent as publicCancelEvent, } from './automations-v2-activation-activations.public.js';
|
|
2
|
+
import { createRESTModule } from '@wix/sdk-runtime/rest-modules';
|
|
3
|
+
import { createEventModule } from '@wix/sdk-runtime/event-definition-modules';
|
|
4
|
+
import { onActivationStatusChanged as publicOnActivationStatusChanged } from './automations-v2-activation-activations.public.js';
|
|
5
|
+
export const reportEvent = /*#__PURE__*/ createRESTModule(publicReportEvent);
|
|
6
|
+
export const bulkReportEvent = /*#__PURE__*/ createRESTModule(publicBulkReportEvent);
|
|
7
|
+
export const bulkCancelEvent = /*#__PURE__*/ createRESTModule(publicBulkCancelEvent);
|
|
8
|
+
export const cancelEvent = /*#__PURE__*/ createRESTModule(publicCancelEvent);
|
|
9
|
+
/**
|
|
10
|
+
* activation status changed message
|
|
11
|
+
*/
|
|
12
|
+
export const onActivationStatusChanged = createEventModule(publicOnActivationStatusChanged);
|
|
13
|
+
export { Domain, TimeUnit, Operator, Type, AutomationConfigurationStatus, Origin, Status, Target, CancellationReason, ErrorReason, SkipReason, ActivationStatusChangedStatus, Units, ScheduleStatus, WebhookIdentityType, BlockType, ActivationActionStatusChangedStatus, IdentifierType, } from './automations-v2-activation-activations.universal.js';
|
|
14
|
+
//# sourceMappingURL=automations-v2-activation-activations.context.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"automations-v2-activation-activations.context.js","sourceRoot":"","sources":["../../../src/automations-v2-activation-activations.context.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,IAAI,iBAAiB,EAChC,eAAe,IAAI,qBAAqB,EACxC,eAAe,IAAI,qBAAqB,EACxC,WAAW,IAAI,iBAAiB,GACjC,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,+BAA+B,CAAC;AACjE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAC;AAE9E,OAAO,EAAE,yBAAyB,IAAI,+BAA+B,EAAE,MAAM,mDAAmD,CAAC;AAEjI,MAAM,CAAC,MAAM,WAAW,GAEpB,aAAa,CAAC,gBAAgB,CAAC,iBAAiB,CAAC,CAAC;AACtD,MAAM,CAAC,MAAM,eAAe,GAExB,aAAa,CAAC,gBAAgB,CAAC,qBAAqB,CAAC,CAAC;AAC1D,MAAM,CAAC,MAAM,eAAe,GAExB,aAAa,CAAC,gBAAgB,CAAC,qBAAqB,CAAC,CAAC;AAC1D,MAAM,CAAC,MAAM,WAAW,GAEpB,aAAa,CAAC,gBAAgB,CAAC,iBAAiB,CAAC,CAAC;AACtD;;GAEG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAElC,iBAAiB,CAAC,+BAA+B,CAAC,CAAC;AAEvD,OAAO,EACL,MAAM,EACN,QAAQ,EACR,QAAQ,EACR,IAAI,EACJ,6BAA6B,EAC7B,MAAM,EACN,MAAM,EACN,MAAM,EACN,kBAAkB,EAClB,WAAW,EACX,UAAU,EACV,6BAA6B,EAC7B,KAAK,EACL,cAAc,EACd,mBAAmB,EACnB,SAAS,EACT,mCAAmC,EACnC,cAAc,GACf,MAAM,sDAAsD,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { RequestOptionsFactory } from '@wix/sdk-types';
|
|
2
|
+
/**
|
|
3
|
+
* Reports an event and activates site automations with the specified trigger key.
|
|
4
|
+
*
|
|
5
|
+
*
|
|
6
|
+
* Only the app that created a trigger can report events for it.
|
|
7
|
+
* This means other apps can't report events for your triggers,
|
|
8
|
+
* and you can't report events for another app's triggers.
|
|
9
|
+
*
|
|
10
|
+
* If your app supports canceling events,
|
|
11
|
+
* `externalEntityId` must be provided.
|
|
12
|
+
* `externalEntityId` is required when calling [cancelEvent()](#cancel-event).
|
|
13
|
+
*/
|
|
14
|
+
export declare function reportEvent(payload: object): RequestOptionsFactory<any>;
|
|
15
|
+
/** Bulk reports events and activates site automations with the specified trigger key. */
|
|
16
|
+
export declare function bulkReportEvent(payload: object): RequestOptionsFactory<any>;
|
|
17
|
+
/** Bulk cancels any remaining actions for a trigger and external entities. */
|
|
18
|
+
export declare function bulkCancelEvent(payload: object): RequestOptionsFactory<any>;
|
|
19
|
+
/**
|
|
20
|
+
* Cancels any remaining actions for a trigger and external entity.
|
|
21
|
+
*
|
|
22
|
+
*
|
|
23
|
+
* Events are not cancelable by default.
|
|
24
|
+
* To make an event cancelable,
|
|
25
|
+
* you must first pass an `externalEntityId`
|
|
26
|
+
* and the applicable `triggerKey` to [reportEvent()](#report-event).
|
|
27
|
+
* When you call cancelEvent() with the same `externalEntityId` and `triggerKey`,
|
|
28
|
+
* the event is canceled,
|
|
29
|
+
* as are all other events that share the `externalEntityId` and `triggerKey`.
|
|
30
|
+
*/
|
|
31
|
+
export declare function cancelEvent(payload: object): RequestOptionsFactory<any>;
|