@wix/automations 1.0.40 → 1.0.42
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/context.js +1 -0
- package/build/cjs/context.js.map +1 -0
- package/build/cjs/index.js +1 -0
- package/build/cjs/index.js.map +1 -0
- package/build/cjs/meta.js +1 -0
- package/build/cjs/meta.js.map +1 -0
- package/package.json +5 -5
- package/type-bundles/context.bundle.d.ts +1368 -80
- package/type-bundles/index.bundle.d.ts +1368 -80
- package/type-bundles/meta.bundle.d.ts +82 -0
|
@@ -1,39 +1,127 @@
|
|
|
1
|
-
type
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
type HostModule$2<T, H extends Host$2> = {
|
|
2
|
+
__type: 'host';
|
|
3
|
+
create(host: H): T;
|
|
4
|
+
};
|
|
5
|
+
type HostModuleAPI$2<T extends HostModule$2<any, any>> = T extends HostModule$2<infer U, any> ? U : never;
|
|
6
|
+
type Host$2<Environment = unknown> = {
|
|
7
|
+
channel: {
|
|
8
|
+
observeState(callback: (props: unknown, environment: Environment) => unknown): {
|
|
9
|
+
disconnect: () => void;
|
|
10
|
+
} | Promise<{
|
|
11
|
+
disconnect: () => void;
|
|
12
|
+
}>;
|
|
13
|
+
};
|
|
14
|
+
environment?: Environment;
|
|
15
|
+
/**
|
|
16
|
+
* Optional bast url to use for API requests, for example `www.wixapis.com`
|
|
17
|
+
*/
|
|
18
|
+
apiBaseUrl?: string;
|
|
19
|
+
/**
|
|
20
|
+
* Possible data to be provided by every host, for cross cutting concerns
|
|
21
|
+
* like internationalization, billing, etc.
|
|
22
|
+
*/
|
|
23
|
+
essentials?: {
|
|
24
|
+
/**
|
|
25
|
+
* The language of the currently viewed session
|
|
26
|
+
*/
|
|
27
|
+
language?: string;
|
|
28
|
+
/**
|
|
29
|
+
* The locale of the currently viewed session
|
|
30
|
+
*/
|
|
31
|
+
locale?: string;
|
|
32
|
+
/**
|
|
33
|
+
* Any headers that should be passed through to the API requests
|
|
34
|
+
*/
|
|
35
|
+
passThroughHeaders?: Record<string, string>;
|
|
36
|
+
};
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
type RESTFunctionDescriptor$2<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$2) => T;
|
|
40
|
+
interface HttpClient$2 {
|
|
41
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory$2<TResponse, TData>): Promise<HttpResponse$2<TResponse>>;
|
|
4
42
|
fetchWithAuth: typeof fetch;
|
|
5
43
|
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
44
|
+
getActiveToken?: () => string | undefined;
|
|
6
45
|
}
|
|
7
|
-
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
8
|
-
type HttpResponse<T = any> = {
|
|
46
|
+
type RequestOptionsFactory$2<TResponse = any, TData = any> = (context: any) => RequestOptions$2<TResponse, TData>;
|
|
47
|
+
type HttpResponse$2<T = any> = {
|
|
9
48
|
data: T;
|
|
10
49
|
status: number;
|
|
11
50
|
statusText: string;
|
|
12
51
|
headers: any;
|
|
13
52
|
request?: any;
|
|
14
53
|
};
|
|
15
|
-
type RequestOptions<_TResponse = any, Data = any> = {
|
|
54
|
+
type RequestOptions$2<_TResponse = any, Data = any> = {
|
|
16
55
|
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
17
56
|
url: string;
|
|
18
57
|
data?: Data;
|
|
19
58
|
params?: URLSearchParams;
|
|
20
|
-
} & APIMetadata;
|
|
21
|
-
type APIMetadata = {
|
|
59
|
+
} & APIMetadata$2;
|
|
60
|
+
type APIMetadata$2 = {
|
|
22
61
|
methodFqn?: string;
|
|
23
62
|
entityFqdn?: string;
|
|
24
63
|
packageName?: string;
|
|
25
64
|
};
|
|
26
|
-
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
27
|
-
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
65
|
+
type BuildRESTFunction$2<T extends RESTFunctionDescriptor$2> = T extends RESTFunctionDescriptor$2<infer U> ? U : never;
|
|
66
|
+
type EventDefinition$5<Payload = unknown, Type extends string = string> = {
|
|
28
67
|
__type: 'event-definition';
|
|
29
68
|
type: Type;
|
|
30
69
|
isDomainEvent?: boolean;
|
|
31
70
|
transformations?: (envelope: unknown) => Payload;
|
|
32
71
|
__payload: Payload;
|
|
33
72
|
};
|
|
34
|
-
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
35
|
-
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
36
|
-
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
73
|
+
declare function EventDefinition$5<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$5<Payload, Type>;
|
|
74
|
+
type EventHandler$5<T extends EventDefinition$5> = (payload: T['__payload']) => void | Promise<void>;
|
|
75
|
+
type BuildEventDefinition$5<T extends EventDefinition$5<any, string>> = (handler: EventHandler$5<T>) => void;
|
|
76
|
+
|
|
77
|
+
type ServicePluginMethodInput$2 = {
|
|
78
|
+
request: any;
|
|
79
|
+
metadata: any;
|
|
80
|
+
};
|
|
81
|
+
type ServicePluginContract$2 = Record<string, (payload: ServicePluginMethodInput$2) => unknown | Promise<unknown>>;
|
|
82
|
+
type ServicePluginMethodMetadata$2 = {
|
|
83
|
+
name: string;
|
|
84
|
+
primaryHttpMappingPath: string;
|
|
85
|
+
transformations: {
|
|
86
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput$2;
|
|
87
|
+
toREST: (...args: unknown[]) => unknown;
|
|
88
|
+
};
|
|
89
|
+
};
|
|
90
|
+
type ServicePluginDefinition$2<Contract extends ServicePluginContract$2> = {
|
|
91
|
+
__type: 'service-plugin-definition';
|
|
92
|
+
componentType: string;
|
|
93
|
+
methods: ServicePluginMethodMetadata$2[];
|
|
94
|
+
__contract: Contract;
|
|
95
|
+
};
|
|
96
|
+
declare function ServicePluginDefinition$2<Contract extends ServicePluginContract$2>(componentType: string, methods: ServicePluginMethodMetadata$2[]): ServicePluginDefinition$2<Contract>;
|
|
97
|
+
type BuildServicePluginDefinition$2<T extends ServicePluginDefinition$2<any>> = (implementation: T['__contract']) => void;
|
|
98
|
+
declare const SERVICE_PLUGIN_ERROR_TYPE$2 = "wix_spi_error";
|
|
99
|
+
|
|
100
|
+
type RequestContext$2 = {
|
|
101
|
+
isSSR: boolean;
|
|
102
|
+
host: string;
|
|
103
|
+
protocol?: string;
|
|
104
|
+
};
|
|
105
|
+
type ResponseTransformer$2 = (data: any, headers?: any) => any;
|
|
106
|
+
/**
|
|
107
|
+
* Ambassador request options types are copied mostly from AxiosRequestConfig.
|
|
108
|
+
* They are copied and not imported to reduce the amount of dependencies (to reduce install time).
|
|
109
|
+
* https://github.com/axios/axios/blob/3f53eb6960f05a1f88409c4b731a40de595cb825/index.d.ts#L307-L315
|
|
110
|
+
*/
|
|
111
|
+
type Method$2 = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
112
|
+
type AmbassadorRequestOptions$2<T = any> = {
|
|
113
|
+
_?: T;
|
|
114
|
+
url?: string;
|
|
115
|
+
method?: Method$2;
|
|
116
|
+
params?: any;
|
|
117
|
+
data?: any;
|
|
118
|
+
transformResponse?: ResponseTransformer$2 | ResponseTransformer$2[];
|
|
119
|
+
};
|
|
120
|
+
type AmbassadorFactory$2<Request, Response> = (payload: Request) => ((context: RequestContext$2) => AmbassadorRequestOptions$2<Response>) & {
|
|
121
|
+
__isAmbassador: boolean;
|
|
122
|
+
};
|
|
123
|
+
type AmbassadorFunctionDescriptor$2<Request = any, Response = any> = AmbassadorFactory$2<Request, Response>;
|
|
124
|
+
type BuildAmbassadorFunction$2<T extends AmbassadorFunctionDescriptor$2> = T extends AmbassadorFunctionDescriptor$2<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
37
125
|
|
|
38
126
|
declare global {
|
|
39
127
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -42,6 +130,284 @@ declare global {
|
|
|
42
130
|
}
|
|
43
131
|
}
|
|
44
132
|
|
|
133
|
+
declare const emptyObjectSymbol$2: unique symbol;
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
Represents a strictly empty plain object, the `{}` value.
|
|
137
|
+
|
|
138
|
+
When you annotate something as the type `{}`, it can be anything except `null` and `undefined`. This means that you cannot use `{}` to represent an empty plain object ([read more](https://stackoverflow.com/questions/47339869/typescript-empty-object-and-any-difference/52193484#52193484)).
|
|
139
|
+
|
|
140
|
+
@example
|
|
141
|
+
```
|
|
142
|
+
import type {EmptyObject} from 'type-fest';
|
|
143
|
+
|
|
144
|
+
// The following illustrates the problem with `{}`.
|
|
145
|
+
const foo1: {} = {}; // Pass
|
|
146
|
+
const foo2: {} = []; // Pass
|
|
147
|
+
const foo3: {} = 42; // Pass
|
|
148
|
+
const foo4: {} = {a: 1}; // Pass
|
|
149
|
+
|
|
150
|
+
// With `EmptyObject` only the first case is valid.
|
|
151
|
+
const bar1: EmptyObject = {}; // Pass
|
|
152
|
+
const bar2: EmptyObject = 42; // Fail
|
|
153
|
+
const bar3: EmptyObject = []; // Fail
|
|
154
|
+
const bar4: EmptyObject = {a: 1}; // Fail
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
Unfortunately, `Record<string, never>`, `Record<keyof any, never>` and `Record<never, never>` do not work. See {@link https://github.com/sindresorhus/type-fest/issues/395 #395}.
|
|
158
|
+
|
|
159
|
+
@category Object
|
|
160
|
+
*/
|
|
161
|
+
type EmptyObject$2 = {[emptyObjectSymbol$2]?: never};
|
|
162
|
+
|
|
163
|
+
/**
|
|
164
|
+
Returns a boolean for whether the two given types are equal.
|
|
165
|
+
|
|
166
|
+
@link https://github.com/microsoft/TypeScript/issues/27024#issuecomment-421529650
|
|
167
|
+
@link https://stackoverflow.com/questions/68961864/how-does-the-equals-work-in-typescript/68963796#68963796
|
|
168
|
+
|
|
169
|
+
Use-cases:
|
|
170
|
+
- If you want to make a conditional branch based on the result of a comparison of two types.
|
|
171
|
+
|
|
172
|
+
@example
|
|
173
|
+
```
|
|
174
|
+
import type {IsEqual} from 'type-fest';
|
|
175
|
+
|
|
176
|
+
// This type returns a boolean for whether the given array includes the given item.
|
|
177
|
+
// `IsEqual` is used to compare the given array at position 0 and the given item and then return true if they are equal.
|
|
178
|
+
type Includes<Value extends readonly any[], Item> =
|
|
179
|
+
Value extends readonly [Value[0], ...infer rest]
|
|
180
|
+
? IsEqual<Value[0], Item> extends true
|
|
181
|
+
? true
|
|
182
|
+
: Includes<rest, Item>
|
|
183
|
+
: false;
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+
@category Type Guard
|
|
187
|
+
@category Utilities
|
|
188
|
+
*/
|
|
189
|
+
type IsEqual$2<A, B> =
|
|
190
|
+
(<G>() => G extends A ? 1 : 2) extends
|
|
191
|
+
(<G>() => G extends B ? 1 : 2)
|
|
192
|
+
? true
|
|
193
|
+
: false;
|
|
194
|
+
|
|
195
|
+
/**
|
|
196
|
+
Filter out keys from an object.
|
|
197
|
+
|
|
198
|
+
Returns `never` if `Exclude` is strictly equal to `Key`.
|
|
199
|
+
Returns `never` if `Key` extends `Exclude`.
|
|
200
|
+
Returns `Key` otherwise.
|
|
201
|
+
|
|
202
|
+
@example
|
|
203
|
+
```
|
|
204
|
+
type Filtered = Filter<'foo', 'foo'>;
|
|
205
|
+
//=> never
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
@example
|
|
209
|
+
```
|
|
210
|
+
type Filtered = Filter<'bar', string>;
|
|
211
|
+
//=> never
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
@example
|
|
215
|
+
```
|
|
216
|
+
type Filtered = Filter<'bar', 'foo'>;
|
|
217
|
+
//=> 'bar'
|
|
218
|
+
```
|
|
219
|
+
|
|
220
|
+
@see {Except}
|
|
221
|
+
*/
|
|
222
|
+
type Filter$5<KeyType, ExcludeType> = IsEqual$2<KeyType, ExcludeType> extends true ? never : (KeyType extends ExcludeType ? never : KeyType);
|
|
223
|
+
|
|
224
|
+
type ExceptOptions$2 = {
|
|
225
|
+
/**
|
|
226
|
+
Disallow assigning non-specified properties.
|
|
227
|
+
|
|
228
|
+
Note that any omitted properties in the resulting type will be present in autocomplete as `undefined`.
|
|
229
|
+
|
|
230
|
+
@default false
|
|
231
|
+
*/
|
|
232
|
+
requireExactProps?: boolean;
|
|
233
|
+
};
|
|
234
|
+
|
|
235
|
+
/**
|
|
236
|
+
Create a type from an object type without certain keys.
|
|
237
|
+
|
|
238
|
+
We recommend setting the `requireExactProps` option to `true`.
|
|
239
|
+
|
|
240
|
+
This type is a stricter version of [`Omit`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-5.html#the-omit-helper-type). The `Omit` type does not restrict the omitted keys to be keys present on the given type, while `Except` does. The benefits of a stricter type are avoiding typos and allowing the compiler to pick up on rename refactors automatically.
|
|
241
|
+
|
|
242
|
+
This type was proposed to the TypeScript team, which declined it, saying they prefer that libraries implement stricter versions of the built-in types ([microsoft/TypeScript#30825](https://github.com/microsoft/TypeScript/issues/30825#issuecomment-523668235)).
|
|
243
|
+
|
|
244
|
+
@example
|
|
245
|
+
```
|
|
246
|
+
import type {Except} from 'type-fest';
|
|
247
|
+
|
|
248
|
+
type Foo = {
|
|
249
|
+
a: number;
|
|
250
|
+
b: string;
|
|
251
|
+
};
|
|
252
|
+
|
|
253
|
+
type FooWithoutA = Except<Foo, 'a'>;
|
|
254
|
+
//=> {b: string}
|
|
255
|
+
|
|
256
|
+
const fooWithoutA: FooWithoutA = {a: 1, b: '2'};
|
|
257
|
+
//=> errors: 'a' does not exist in type '{ b: string; }'
|
|
258
|
+
|
|
259
|
+
type FooWithoutB = Except<Foo, 'b', {requireExactProps: true}>;
|
|
260
|
+
//=> {a: number} & Partial<Record<"b", never>>
|
|
261
|
+
|
|
262
|
+
const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
|
|
263
|
+
//=> errors at 'b': Type 'string' is not assignable to type 'undefined'.
|
|
264
|
+
```
|
|
265
|
+
|
|
266
|
+
@category Object
|
|
267
|
+
*/
|
|
268
|
+
type Except$2<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions$2 = {requireExactProps: false}> = {
|
|
269
|
+
[KeyType in keyof ObjectType as Filter$5<KeyType, KeysType>]: ObjectType[KeyType];
|
|
270
|
+
} & (Options['requireExactProps'] extends true
|
|
271
|
+
? Partial<Record<KeysType, never>>
|
|
272
|
+
: {});
|
|
273
|
+
|
|
274
|
+
/**
|
|
275
|
+
Extract the keys from a type where the value type of the key extends the given `Condition`.
|
|
276
|
+
|
|
277
|
+
Internally this is used for the `ConditionalPick` and `ConditionalExcept` types.
|
|
278
|
+
|
|
279
|
+
@example
|
|
280
|
+
```
|
|
281
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
282
|
+
|
|
283
|
+
interface Example {
|
|
284
|
+
a: string;
|
|
285
|
+
b: string | number;
|
|
286
|
+
c?: string;
|
|
287
|
+
d: {};
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
type StringKeysOnly = ConditionalKeys<Example, string>;
|
|
291
|
+
//=> 'a'
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
To support partial types, make sure your `Condition` is a union of undefined (for example, `string | undefined`) as demonstrated below.
|
|
295
|
+
|
|
296
|
+
@example
|
|
297
|
+
```
|
|
298
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
299
|
+
|
|
300
|
+
type StringKeysAndUndefined = ConditionalKeys<Example, string | undefined>;
|
|
301
|
+
//=> 'a' | 'c'
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
@category Object
|
|
305
|
+
*/
|
|
306
|
+
type ConditionalKeys$2<Base, Condition> = NonNullable<
|
|
307
|
+
// Wrap in `NonNullable` to strip away the `undefined` type from the produced union.
|
|
308
|
+
{
|
|
309
|
+
// Map through all the keys of the given base type.
|
|
310
|
+
[Key in keyof Base]:
|
|
311
|
+
// Pick only keys with types extending the given `Condition` type.
|
|
312
|
+
Base[Key] extends Condition
|
|
313
|
+
// Retain this key since the condition passes.
|
|
314
|
+
? Key
|
|
315
|
+
// Discard this key since the condition fails.
|
|
316
|
+
: never;
|
|
317
|
+
|
|
318
|
+
// Convert the produced object into a union type of the keys which passed the conditional test.
|
|
319
|
+
}[keyof Base]
|
|
320
|
+
>;
|
|
321
|
+
|
|
322
|
+
/**
|
|
323
|
+
Exclude keys from a shape that matches the given `Condition`.
|
|
324
|
+
|
|
325
|
+
This is useful when you want to create a new type with a specific set of keys from a shape. For example, you might want to exclude all the primitive properties from a class and form a new shape containing everything but the primitive properties.
|
|
326
|
+
|
|
327
|
+
@example
|
|
328
|
+
```
|
|
329
|
+
import type {Primitive, ConditionalExcept} from 'type-fest';
|
|
330
|
+
|
|
331
|
+
class Awesome {
|
|
332
|
+
name: string;
|
|
333
|
+
successes: number;
|
|
334
|
+
failures: bigint;
|
|
335
|
+
|
|
336
|
+
run() {}
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
type ExceptPrimitivesFromAwesome = ConditionalExcept<Awesome, Primitive>;
|
|
340
|
+
//=> {run: () => void}
|
|
341
|
+
```
|
|
342
|
+
|
|
343
|
+
@example
|
|
344
|
+
```
|
|
345
|
+
import type {ConditionalExcept} from 'type-fest';
|
|
346
|
+
|
|
347
|
+
interface Example {
|
|
348
|
+
a: string;
|
|
349
|
+
b: string | number;
|
|
350
|
+
c: () => void;
|
|
351
|
+
d: {};
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
type NonStringKeysOnly = ConditionalExcept<Example, string>;
|
|
355
|
+
//=> {b: string | number; c: () => void; d: {}}
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
@category Object
|
|
359
|
+
*/
|
|
360
|
+
type ConditionalExcept$2<Base, Condition> = Except$2<
|
|
361
|
+
Base,
|
|
362
|
+
ConditionalKeys$2<Base, Condition>
|
|
363
|
+
>;
|
|
364
|
+
|
|
365
|
+
/**
|
|
366
|
+
* Descriptors are objects that describe the API of a module, and the module
|
|
367
|
+
* can either be a REST module or a host module.
|
|
368
|
+
* This type is recursive, so it can describe nested modules.
|
|
369
|
+
*/
|
|
370
|
+
type Descriptors$2 = RESTFunctionDescriptor$2 | AmbassadorFunctionDescriptor$2 | HostModule$2<any, any> | EventDefinition$5<any> | ServicePluginDefinition$2<any> | {
|
|
371
|
+
[key: string]: Descriptors$2 | PublicMetadata$2 | any;
|
|
372
|
+
};
|
|
373
|
+
/**
|
|
374
|
+
* This type takes in a descriptors object of a certain Host (including an `unknown` host)
|
|
375
|
+
* and returns an object with the same structure, but with all descriptors replaced with their API.
|
|
376
|
+
* Any non-descriptor properties are removed from the returned object, including descriptors that
|
|
377
|
+
* do not match the given host (as they will not work with the given host).
|
|
378
|
+
*/
|
|
379
|
+
type BuildDescriptors$2<T extends Descriptors$2, H extends Host$2<any> | undefined, Depth extends number = 5> = {
|
|
380
|
+
done: T;
|
|
381
|
+
recurse: T extends {
|
|
382
|
+
__type: typeof SERVICE_PLUGIN_ERROR_TYPE$2;
|
|
383
|
+
} ? never : T extends AmbassadorFunctionDescriptor$2 ? BuildAmbassadorFunction$2<T> : T extends RESTFunctionDescriptor$2 ? BuildRESTFunction$2<T> : T extends EventDefinition$5<any> ? BuildEventDefinition$5<T> : T extends ServicePluginDefinition$2<any> ? BuildServicePluginDefinition$2<T> : T extends HostModule$2<any, any> ? HostModuleAPI$2<T> : ConditionalExcept$2<{
|
|
384
|
+
[Key in keyof T]: T[Key] extends Descriptors$2 ? BuildDescriptors$2<T[Key], H, [
|
|
385
|
+
-1,
|
|
386
|
+
0,
|
|
387
|
+
1,
|
|
388
|
+
2,
|
|
389
|
+
3,
|
|
390
|
+
4,
|
|
391
|
+
5
|
|
392
|
+
][Depth]> : never;
|
|
393
|
+
}, EmptyObject$2>;
|
|
394
|
+
}[Depth extends -1 ? 'done' : 'recurse'];
|
|
395
|
+
type PublicMetadata$2 = {
|
|
396
|
+
PACKAGE_NAME?: string;
|
|
397
|
+
};
|
|
398
|
+
|
|
399
|
+
declare global {
|
|
400
|
+
interface ContextualClient {
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
/**
|
|
404
|
+
* A type used to create concerete types from SDK descriptors in
|
|
405
|
+
* case a contextual client is available.
|
|
406
|
+
*/
|
|
407
|
+
type MaybeContext$2<T extends Descriptors$2> = globalThis.ContextualClient extends {
|
|
408
|
+
host: Host$2;
|
|
409
|
+
} ? BuildDescriptors$2<T, globalThis.ContextualClient['host']> : T;
|
|
410
|
+
|
|
45
411
|
/** Automation */
|
|
46
412
|
interface Automation$2 {
|
|
47
413
|
/**
|
|
@@ -120,7 +486,7 @@ interface Trigger$2 {
|
|
|
120
486
|
/** Identifier for this trigger - human readable action key */
|
|
121
487
|
triggerKey?: string;
|
|
122
488
|
/** optional list of filters on schema fields */
|
|
123
|
-
filters?: Filter$
|
|
489
|
+
filters?: Filter$4[];
|
|
124
490
|
/**
|
|
125
491
|
* optional - allows to define a trigger whose following actions will be executed only if the same event for the same resource has not in the last X seconds.
|
|
126
492
|
* for example, if the trigger is "session booked", the resource is a contact and the timeframe is 3600 seconds (contact hasn't booked another session in the last hour),
|
|
@@ -128,7 +494,7 @@ interface Trigger$2 {
|
|
|
128
494
|
*/
|
|
129
495
|
debounce?: Debounce;
|
|
130
496
|
}
|
|
131
|
-
interface Filter$
|
|
497
|
+
interface Filter$4 {
|
|
132
498
|
/** the filter identifier */
|
|
133
499
|
_id?: string | null;
|
|
134
500
|
/** the field key from the schema, for example "formId" */
|
|
@@ -1608,7 +1974,7 @@ interface GenerateActionInputMappingFromTemplateOptions {
|
|
|
1608
1974
|
actionInputMappingTemplate: Record<string, any> | null;
|
|
1609
1975
|
}
|
|
1610
1976
|
|
|
1611
|
-
declare function createAutomation$3(httpClient: HttpClient): CreateAutomationSignature$1;
|
|
1977
|
+
declare function createAutomation$3(httpClient: HttpClient$2): CreateAutomationSignature$1;
|
|
1612
1978
|
interface CreateAutomationSignature$1 {
|
|
1613
1979
|
/**
|
|
1614
1980
|
* Creates a new Automation
|
|
@@ -1617,7 +1983,7 @@ interface CreateAutomationSignature$1 {
|
|
|
1617
1983
|
*/
|
|
1618
1984
|
(automation: Automation$2): Promise<Automation$2 & AutomationNonNullableFields$1>;
|
|
1619
1985
|
}
|
|
1620
|
-
declare function getAutomation$3(httpClient: HttpClient): GetAutomationSignature$1;
|
|
1986
|
+
declare function getAutomation$3(httpClient: HttpClient$2): GetAutomationSignature$1;
|
|
1621
1987
|
interface GetAutomationSignature$1 {
|
|
1622
1988
|
/**
|
|
1623
1989
|
* Get a Automation by id
|
|
@@ -1626,7 +1992,7 @@ interface GetAutomationSignature$1 {
|
|
|
1626
1992
|
*/
|
|
1627
1993
|
(automationId: string, options?: GetAutomationOptions$1 | undefined): Promise<Automation$2 & AutomationNonNullableFields$1>;
|
|
1628
1994
|
}
|
|
1629
|
-
declare function updateAutomation$3(httpClient: HttpClient): UpdateAutomationSignature$1;
|
|
1995
|
+
declare function updateAutomation$3(httpClient: HttpClient$2): UpdateAutomationSignature$1;
|
|
1630
1996
|
interface UpdateAutomationSignature$1 {
|
|
1631
1997
|
/**
|
|
1632
1998
|
* Update a Automation, supports partial update
|
|
@@ -1636,7 +2002,7 @@ interface UpdateAutomationSignature$1 {
|
|
|
1636
2002
|
*/
|
|
1637
2003
|
(_id: string | null, automation: UpdateAutomation$1): Promise<Automation$2 & AutomationNonNullableFields$1>;
|
|
1638
2004
|
}
|
|
1639
|
-
declare function deleteAutomation$3(httpClient: HttpClient): DeleteAutomationSignature$1;
|
|
2005
|
+
declare function deleteAutomation$3(httpClient: HttpClient$2): DeleteAutomationSignature$1;
|
|
1640
2006
|
interface DeleteAutomationSignature$1 {
|
|
1641
2007
|
/**
|
|
1642
2008
|
* Delete an Automation
|
|
@@ -1644,14 +2010,14 @@ interface DeleteAutomationSignature$1 {
|
|
|
1644
2010
|
*/
|
|
1645
2011
|
(automationId: string, options?: DeleteAutomationOptions | undefined): Promise<void>;
|
|
1646
2012
|
}
|
|
1647
|
-
declare function queryAutomations$3(httpClient: HttpClient): QueryAutomationsSignature$1;
|
|
2013
|
+
declare function queryAutomations$3(httpClient: HttpClient$2): QueryAutomationsSignature$1;
|
|
1648
2014
|
interface QueryAutomationsSignature$1 {
|
|
1649
2015
|
/**
|
|
1650
2016
|
* Query Automations using [WQL - Wix Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language)
|
|
1651
2017
|
*/
|
|
1652
2018
|
(options?: QueryAutomationsOptions | undefined): AutomationsQueryBuilder$1;
|
|
1653
2019
|
}
|
|
1654
|
-
declare function overrideApplicationAutomation$1(httpClient: HttpClient): OverrideApplicationAutomationSignature;
|
|
2020
|
+
declare function overrideApplicationAutomation$1(httpClient: HttpClient$2): OverrideApplicationAutomationSignature;
|
|
1655
2021
|
interface OverrideApplicationAutomationSignature {
|
|
1656
2022
|
/**
|
|
1657
2023
|
* Creates a new Automation
|
|
@@ -1659,7 +2025,7 @@ interface OverrideApplicationAutomationSignature {
|
|
|
1659
2025
|
*/
|
|
1660
2026
|
(automation: Automation$2): Promise<OverrideApplicationAutomationResponse & OverrideApplicationAutomationResponseNonNullableFields>;
|
|
1661
2027
|
}
|
|
1662
|
-
declare function validateAutomationById$1(httpClient: HttpClient): ValidateAutomationByIdSignature;
|
|
2028
|
+
declare function validateAutomationById$1(httpClient: HttpClient$2): ValidateAutomationByIdSignature;
|
|
1663
2029
|
interface ValidateAutomationByIdSignature {
|
|
1664
2030
|
/**
|
|
1665
2031
|
* Validate Automation by Id
|
|
@@ -1667,7 +2033,7 @@ interface ValidateAutomationByIdSignature {
|
|
|
1667
2033
|
*/
|
|
1668
2034
|
(automationId: string, options?: ValidateAutomationByIdOptions | undefined): Promise<ValidateAutomationByIdResponse & ValidateAutomationByIdResponseNonNullableFields>;
|
|
1669
2035
|
}
|
|
1670
|
-
declare function validateAutomation$3(httpClient: HttpClient): ValidateAutomationSignature$1;
|
|
2036
|
+
declare function validateAutomation$3(httpClient: HttpClient$2): ValidateAutomationSignature$1;
|
|
1671
2037
|
interface ValidateAutomationSignature$1 {
|
|
1672
2038
|
/**
|
|
1673
2039
|
* Validate Automation
|
|
@@ -1675,19 +2041,19 @@ interface ValidateAutomationSignature$1 {
|
|
|
1675
2041
|
*/
|
|
1676
2042
|
(automation: Automation$2): Promise<ValidateAutomationResponse$1 & ValidateAutomationResponseNonNullableFields$1>;
|
|
1677
2043
|
}
|
|
1678
|
-
declare function getAutomationActivationStats$1(httpClient: HttpClient): GetAutomationActivationStatsSignature;
|
|
2044
|
+
declare function getAutomationActivationStats$1(httpClient: HttpClient$2): GetAutomationActivationStatsSignature;
|
|
1679
2045
|
interface GetAutomationActivationStatsSignature {
|
|
1680
2046
|
/** @param - Automation ID */
|
|
1681
2047
|
(automationId: string, options?: GetAutomationActivationStatsOptions | undefined): Promise<GetAutomationActivationReportsResponse & GetAutomationActivationReportsResponseNonNullableFields>;
|
|
1682
2048
|
}
|
|
1683
|
-
declare function getActionsQuotaInfo$3(httpClient: HttpClient): GetActionsQuotaInfoSignature$1;
|
|
2049
|
+
declare function getActionsQuotaInfo$3(httpClient: HttpClient$2): GetActionsQuotaInfoSignature$1;
|
|
1684
2050
|
interface GetActionsQuotaInfoSignature$1 {
|
|
1685
2051
|
/**
|
|
1686
2052
|
* Get actions quota information
|
|
1687
2053
|
*/
|
|
1688
2054
|
(): Promise<GetActionsQuotaInfoResponse$1 & GetActionsQuotaInfoResponseNonNullableFields$1>;
|
|
1689
2055
|
}
|
|
1690
|
-
declare function generateActionInputMappingFromTemplate$1(httpClient: HttpClient): GenerateActionInputMappingFromTemplateSignature;
|
|
2056
|
+
declare function generateActionInputMappingFromTemplate$1(httpClient: HttpClient$2): GenerateActionInputMappingFromTemplateSignature;
|
|
1691
2057
|
interface GenerateActionInputMappingFromTemplateSignature {
|
|
1692
2058
|
/**
|
|
1693
2059
|
* Generate action input mapping from a template
|
|
@@ -1695,25 +2061,43 @@ interface GenerateActionInputMappingFromTemplateSignature {
|
|
|
1695
2061
|
*/
|
|
1696
2062
|
(appId: string, options: GenerateActionInputMappingFromTemplateOptions): Promise<GenerateActionInputMappingFromTemplateResponse>;
|
|
1697
2063
|
}
|
|
1698
|
-
declare const onAutomationCreated$3: EventDefinition<AutomationCreatedEnvelope$1, "wix.automations.v1.automation_created">;
|
|
1699
|
-
declare const onAutomationUpdated$3: EventDefinition<AutomationUpdatedEnvelope$1, "wix.automations.v1.automation_updated">;
|
|
1700
|
-
declare const onAutomationDeleted$3: EventDefinition<AutomationDeletedEnvelope$1, "wix.automations.v1.automation_deleted">;
|
|
1701
|
-
declare const onAutomationUpdatedWithPreviousEntity$3: EventDefinition<AutomationUpdatedWithPreviousEntityEnvelope$1, "wix.automations.v1.automation_updated_with_previous_entity">;
|
|
1702
|
-
declare const onAutomationDeletedWithEntity$3: EventDefinition<AutomationDeletedWithEntityEnvelope$1, "wix.automations.v1.automation_deleted_with_entity">;
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
declare
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
declare
|
|
1716
|
-
|
|
2064
|
+
declare const onAutomationCreated$3: EventDefinition$5<AutomationCreatedEnvelope$1, "wix.automations.v1.automation_created">;
|
|
2065
|
+
declare const onAutomationUpdated$3: EventDefinition$5<AutomationUpdatedEnvelope$1, "wix.automations.v1.automation_updated">;
|
|
2066
|
+
declare const onAutomationDeleted$3: EventDefinition$5<AutomationDeletedEnvelope$1, "wix.automations.v1.automation_deleted">;
|
|
2067
|
+
declare const onAutomationUpdatedWithPreviousEntity$3: EventDefinition$5<AutomationUpdatedWithPreviousEntityEnvelope$1, "wix.automations.v1.automation_updated_with_previous_entity">;
|
|
2068
|
+
declare const onAutomationDeletedWithEntity$3: EventDefinition$5<AutomationDeletedWithEntityEnvelope$1, "wix.automations.v1.automation_deleted_with_entity">;
|
|
2069
|
+
|
|
2070
|
+
type EventDefinition$4<Payload = unknown, Type extends string = string> = {
|
|
2071
|
+
__type: 'event-definition';
|
|
2072
|
+
type: Type;
|
|
2073
|
+
isDomainEvent?: boolean;
|
|
2074
|
+
transformations?: (envelope: unknown) => Payload;
|
|
2075
|
+
__payload: Payload;
|
|
2076
|
+
};
|
|
2077
|
+
declare function EventDefinition$4<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$4<Payload, Type>;
|
|
2078
|
+
type EventHandler$4<T extends EventDefinition$4> = (payload: T['__payload']) => void | Promise<void>;
|
|
2079
|
+
type BuildEventDefinition$4<T extends EventDefinition$4<any, string>> = (handler: EventHandler$4<T>) => void;
|
|
2080
|
+
|
|
2081
|
+
declare global {
|
|
2082
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
2083
|
+
interface SymbolConstructor {
|
|
2084
|
+
readonly observable: symbol;
|
|
2085
|
+
}
|
|
2086
|
+
}
|
|
2087
|
+
|
|
2088
|
+
declare function createEventModule$2<T extends EventDefinition$4<any, string>>(eventDefinition: T): BuildEventDefinition$4<T> & T;
|
|
2089
|
+
|
|
2090
|
+
declare const createAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof createAutomation$3> & typeof createAutomation$3>;
|
|
2091
|
+
declare const getAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof getAutomation$3> & typeof getAutomation$3>;
|
|
2092
|
+
declare const updateAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof updateAutomation$3> & typeof updateAutomation$3>;
|
|
2093
|
+
declare const deleteAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof deleteAutomation$3> & typeof deleteAutomation$3>;
|
|
2094
|
+
declare const queryAutomations$2: MaybeContext$2<BuildRESTFunction$2<typeof queryAutomations$3> & typeof queryAutomations$3>;
|
|
2095
|
+
declare const overrideApplicationAutomation: MaybeContext$2<BuildRESTFunction$2<typeof overrideApplicationAutomation$1> & typeof overrideApplicationAutomation$1>;
|
|
2096
|
+
declare const validateAutomationById: MaybeContext$2<BuildRESTFunction$2<typeof validateAutomationById$1> & typeof validateAutomationById$1>;
|
|
2097
|
+
declare const validateAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof validateAutomation$3> & typeof validateAutomation$3>;
|
|
2098
|
+
declare const getAutomationActivationStats: MaybeContext$2<BuildRESTFunction$2<typeof getAutomationActivationStats$1> & typeof getAutomationActivationStats$1>;
|
|
2099
|
+
declare const getActionsQuotaInfo$2: MaybeContext$2<BuildRESTFunction$2<typeof getActionsQuotaInfo$3> & typeof getActionsQuotaInfo$3>;
|
|
2100
|
+
declare const generateActionInputMappingFromTemplate: MaybeContext$2<BuildRESTFunction$2<typeof generateActionInputMappingFromTemplate$1> & typeof generateActionInputMappingFromTemplate$1>;
|
|
1717
2101
|
|
|
1718
2102
|
type _publicOnAutomationCreatedType$1 = typeof onAutomationCreated$3;
|
|
1719
2103
|
/** */
|
|
@@ -1793,8 +2177,418 @@ declare const context$2_getAutomationActivationStats: typeof getAutomationActiva
|
|
|
1793
2177
|
declare const context$2_overrideApplicationAutomation: typeof overrideApplicationAutomation;
|
|
1794
2178
|
declare const context$2_validateAutomationById: typeof validateAutomationById;
|
|
1795
2179
|
declare namespace context$2 {
|
|
1796
|
-
export { type Action$2 as Action, type ActionConfigurationError$1 as ActionConfigurationError, ActionErrorType$1 as ActionErrorType, type ActionEvent$2 as ActionEvent, type ActionProviderQuotaInfo$1 as ActionProviderQuotaInfo, type ActionQuotaInfo$1 as ActionQuotaInfo, type ActionValidationError$1 as ActionValidationError, type ActionValidationErrorErrorOneOf$1 as ActionValidationErrorErrorOneOf, type ActionValidationInfo$1 as ActionValidationInfo, type context$2_ActivationReport as ActivationReport, ActivationStatus$1 as ActivationStatus, type AdditionalInfo$1 as AdditionalInfo, type ApplicationError$2 as ApplicationError, type Asset$1 as Asset, type Automation$2 as Automation, type AutomationCreatedEnvelope$1 as AutomationCreatedEnvelope, type AutomationDeletedEnvelope$1 as AutomationDeletedEnvelope, type AutomationDeletedWithEntityEnvelope$1 as AutomationDeletedWithEntityEnvelope, type context$2_AutomationMetadata as AutomationMetadata, type AutomationNonNullableFields$1 as AutomationNonNullableFields, type AutomationUpdatedEnvelope$1 as AutomationUpdatedEnvelope, type AutomationUpdatedWithPreviousEntityEnvelope$1 as AutomationUpdatedWithPreviousEntityEnvelope, type AutomationsQueryBuilder$1 as AutomationsQueryBuilder, type AutomationsQueryResult$1 as AutomationsQueryResult, type BaseEventMetadata$2 as BaseEventMetadata, BlockType$1 as BlockType, type BulkActionMetadata$2 as BulkActionMetadata, type context$2_BulkCreateApplicationAutomationRequest as BulkCreateApplicationAutomationRequest, type context$2_BulkCreateApplicationAutomationResponse as BulkCreateApplicationAutomationResponse, type BulkDeleteAutomationsRequest$1 as BulkDeleteAutomationsRequest, type BulkDeleteAutomationsResponse$1 as BulkDeleteAutomationsResponse, type CTA$1 as CTA, type context$2_Condition as Condition, type ConditionBlock$1 as ConditionBlock, type context$2_Conditions as Conditions, type CreateAutomationRequest$1 as CreateAutomationRequest, type CreateAutomationResponse$1 as CreateAutomationResponse, type CreateAutomationResponseNonNullableFields$1 as CreateAutomationResponseNonNullableFields, type CursorPaging$1 as CursorPaging, type Cursors$1 as Cursors, type context$2_Debounce as Debounce, type Delay$1 as Delay, type context$2_DelayTypeOneOf as DelayTypeOneOf, type context$2_DeleteAutomationOptions as DeleteAutomationOptions, type DeleteAutomationRequest$1 as DeleteAutomationRequest, type DeleteAutomationResponse$1 as DeleteAutomationResponse, type DeleteContext$1 as DeleteContext, DeleteStatus$1 as DeleteStatus, type DeletedWithEntity$1 as DeletedWithEntity, type DomainEvent$2 as DomainEvent, type DomainEventBodyOneOf$2 as DomainEventBodyOneOf, type Empty$2 as Empty, type EntityCreatedEvent$2 as EntityCreatedEvent, type EntityDeletedEvent$2 as EntityDeletedEvent, type EntityUpdatedEvent$2 as EntityUpdatedEvent, type EventMetadata$2 as EventMetadata, type context$2_ExtendedFields as ExtendedFields, type Filter$2 as Filter, type context$2_GenerateActionInputMappingFromTemplateOptions as GenerateActionInputMappingFromTemplateOptions, type context$2_GenerateActionInputMappingFromTemplateRequest as GenerateActionInputMappingFromTemplateRequest, type context$2_GenerateActionInputMappingFromTemplateResponse as GenerateActionInputMappingFromTemplateResponse, type context$2_GenerateApplicationAutomationFromCustomRequest as GenerateApplicationAutomationFromCustomRequest, type context$2_GenerateApplicationAutomationFromCustomResponse as GenerateApplicationAutomationFromCustomResponse, type GetActionsQuotaInfoRequest$1 as GetActionsQuotaInfoRequest, type GetActionsQuotaInfoResponse$1 as GetActionsQuotaInfoResponse, type GetActionsQuotaInfoResponseNonNullableFields$1 as GetActionsQuotaInfoResponseNonNullableFields, type context$2_GetApplicationAutomationRequest as GetApplicationAutomationRequest, type context$2_GetApplicationAutomationResponse as GetApplicationAutomationResponse, type GetAutomationActionSchemaRequest$1 as GetAutomationActionSchemaRequest, type GetAutomationActionSchemaResponse$1 as GetAutomationActionSchemaResponse, type context$2_GetAutomationActivationReportsRequest as GetAutomationActivationReportsRequest, type context$2_GetAutomationActivationReportsResponse as GetAutomationActivationReportsResponse, type context$2_GetAutomationActivationReportsResponseNonNullableFields as GetAutomationActivationReportsResponseNonNullableFields, type context$2_GetAutomationActivationStatsOptions as GetAutomationActivationStatsOptions, type GetAutomationOptions$1 as GetAutomationOptions, type GetAutomationRequest$1 as GetAutomationRequest, type GetAutomationResponse$1 as GetAutomationResponse, type GetAutomationResponseNonNullableFields$1 as GetAutomationResponseNonNullableFields, type IdentificationData$2 as IdentificationData, type IdentificationDataIdOneOf$2 as IdentificationDataIdOneOf, type ItemMetadata$2 as ItemMetadata, type MessageEnvelope$2 as MessageEnvelope, type MetaSiteSpecialEvent$1 as MetaSiteSpecialEvent, type MetaSiteSpecialEventPayloadOneOf$1 as MetaSiteSpecialEventPayloadOneOf, type context$2_MigrationBulkCreateAutomations as MigrationBulkCreateAutomations, type context$2_MigrationBulkCreateAutomationsRequest as MigrationBulkCreateAutomationsRequest, type context$2_MigrationBulkCreateAutomationsResponse as MigrationBulkCreateAutomationsResponse, type context$2_MigrationUpdateMigratedToV3AutomationRequest as MigrationUpdateMigratedToV3AutomationRequest, type context$2_MigrationUpdateMigratedToV3AutomationResponse as MigrationUpdateMigratedToV3AutomationResponse, Namespace$1 as Namespace, type NamespaceChanged$1 as NamespaceChanged, type context$2_Offset as Offset, type context$2_OffsetValueOneOf as OffsetValueOneOf, type context$2_OverrideApplicationAutomationRequest as OverrideApplicationAutomationRequest, type context$2_OverrideApplicationAutomationResponse as OverrideApplicationAutomationResponse, type context$2_OverrideApplicationAutomationResponseNonNullableFields as OverrideApplicationAutomationResponseNonNullableFields, type context$2_Paging as Paging, type context$2_PagingMetadata as PagingMetadata, type context$2_PagingMetadataV2 as PagingMetadataV2, type Plan$1 as Plan, type ProviderConfigurationError$1 as ProviderConfigurationError, type context$2_QueryApplicationAutomationsRequest as QueryApplicationAutomationsRequest, type context$2_QueryApplicationAutomationsResponse as QueryApplicationAutomationsResponse, type context$2_QueryAutomationsOptions as QueryAutomationsOptions, type QueryAutomationsRequest$1 as QueryAutomationsRequest, type QueryAutomationsResponse$1 as QueryAutomationsResponse, type QueryAutomationsResponseNonNullableFields$1 as QueryAutomationsResponseNonNullableFields, type context$2_QueryV2 as QueryV2, type context$2_QueryV2PagingMethodOneOf as QueryV2PagingMethodOneOf, type Quota$1 as Quota, type QuotaInfo$1 as QuotaInfo, type RateLimit$2 as RateLimit, type RestoreInfo$2 as RestoreInfo, type context$2_Rule as Rule, type ServiceProvisioned$1 as ServiceProvisioned, type ServiceRemoved$1 as ServiceRemoved, type SiteCreated$1 as SiteCreated, SiteCreatedContext$1 as SiteCreatedContext, type SiteDeleted$1 as SiteDeleted, type SiteHardDeleted$1 as SiteHardDeleted, type SiteMarkedAsTemplate$1 as SiteMarkedAsTemplate, type SiteMarkedAsWixSite$1 as SiteMarkedAsWixSite, type SitePublished$1 as SitePublished, type SiteRenamed$1 as SiteRenamed, type SiteTransferred$1 as SiteTransferred, type SiteUndeleted$1 as SiteUndeleted, type SiteUnpublished$1 as SiteUnpublished, SortOrder$1 as SortOrder, type Sorting$1 as Sorting, type context$2_Source as Source, State$1 as State, Status$2 as Status, type StudioAssigned$1 as StudioAssigned, type StudioUnassigned$1 as StudioUnassigned, type context$2_SyncApplicationAutomationsRequest as SyncApplicationAutomationsRequest, type context$2_SyncApplicationAutomationsResponse as SyncApplicationAutomationsResponse, type Trigger$2 as Trigger, type TriggerConfigurationError$1 as TriggerConfigurationError, TriggerErrorType$1 as TriggerErrorType, type TriggerValidationError$1 as TriggerValidationError, type TriggerValidationErrorErrorOneOf$1 as TriggerValidationErrorErrorOneOf, TriggerValidationErrorValidationErrorType$1 as TriggerValidationErrorValidationErrorType, Type$2 as Type, type context$2_Until as Until, type context$2_UpdateApplicationAutomationConfigurationIdRequest as UpdateApplicationAutomationConfigurationIdRequest, type context$2_UpdateApplicationAutomationConfigurationIdResponse as UpdateApplicationAutomationConfigurationIdResponse, type context$2_UpdateApplicationAutomationToMigratedFromV1Request as UpdateApplicationAutomationToMigratedFromV1Request, type context$2_UpdateApplicationAutomationToMigratedFromV1Response as UpdateApplicationAutomationToMigratedFromV1Response, type UpdateAutomation$1 as UpdateAutomation, type UpdateAutomationRequest$1 as UpdateAutomationRequest, type UpdateAutomationResponse$1 as UpdateAutomationResponse, type UpdateAutomationResponseNonNullableFields$1 as UpdateAutomationResponseNonNullableFields, type context$2_UpdatedAutomationsWithEsb as UpdatedAutomationsWithEsb, type UpdatedWithPreviousEntity$1 as UpdatedWithPreviousEntity, type UpgradeCTA$1 as UpgradeCTA, type context$2_ValidateAutomationByIdOptions as ValidateAutomationByIdOptions, type context$2_ValidateAutomationByIdRequest as ValidateAutomationByIdRequest, type context$2_ValidateAutomationByIdResponse as ValidateAutomationByIdResponse, type context$2_ValidateAutomationByIdResponseNonNullableFields as ValidateAutomationByIdResponseNonNullableFields, type ValidateAutomationRequest$1 as ValidateAutomationRequest, type ValidateAutomationResponse$1 as ValidateAutomationResponse, type ValidateAutomationResponseNonNullableFields$1 as ValidateAutomationResponseNonNullableFields, ValidationErrorType$1 as ValidationErrorType, WebhookIdentityType$2 as WebhookIdentityType, type _publicOnAutomationCreatedType$1 as _publicOnAutomationCreatedType, type _publicOnAutomationDeletedType$1 as _publicOnAutomationDeletedType, type _publicOnAutomationDeletedWithEntityType$1 as _publicOnAutomationDeletedWithEntityType, type _publicOnAutomationUpdatedType$1 as _publicOnAutomationUpdatedType, type _publicOnAutomationUpdatedWithPreviousEntityType$1 as _publicOnAutomationUpdatedWithPreviousEntityType, createAutomation$2 as createAutomation, deleteAutomation$2 as deleteAutomation, context$2_generateActionInputMappingFromTemplate as generateActionInputMappingFromTemplate, getActionsQuotaInfo$2 as getActionsQuotaInfo, getAutomation$2 as getAutomation, context$2_getAutomationActivationStats as getAutomationActivationStats, onAutomationCreated$2 as onAutomationCreated, onAutomationDeleted$2 as onAutomationDeleted, onAutomationDeletedWithEntity$2 as onAutomationDeletedWithEntity, onAutomationUpdated$2 as onAutomationUpdated, onAutomationUpdatedWithPreviousEntity$2 as onAutomationUpdatedWithPreviousEntity, context$2_overrideApplicationAutomation as overrideApplicationAutomation, onAutomationCreated$3 as publicOnAutomationCreated, onAutomationDeleted$3 as publicOnAutomationDeleted, onAutomationDeletedWithEntity$3 as publicOnAutomationDeletedWithEntity, onAutomationUpdated$3 as publicOnAutomationUpdated, onAutomationUpdatedWithPreviousEntity$3 as publicOnAutomationUpdatedWithPreviousEntity, queryAutomations$2 as queryAutomations, updateAutomation$2 as updateAutomation, validateAutomation$2 as validateAutomation, context$2_validateAutomationById as validateAutomationById };
|
|
2180
|
+
export { type Action$2 as Action, type ActionConfigurationError$1 as ActionConfigurationError, ActionErrorType$1 as ActionErrorType, type ActionEvent$2 as ActionEvent, type ActionProviderQuotaInfo$1 as ActionProviderQuotaInfo, type ActionQuotaInfo$1 as ActionQuotaInfo, type ActionValidationError$1 as ActionValidationError, type ActionValidationErrorErrorOneOf$1 as ActionValidationErrorErrorOneOf, type ActionValidationInfo$1 as ActionValidationInfo, type context$2_ActivationReport as ActivationReport, ActivationStatus$1 as ActivationStatus, type AdditionalInfo$1 as AdditionalInfo, type ApplicationError$2 as ApplicationError, type Asset$1 as Asset, type Automation$2 as Automation, type AutomationCreatedEnvelope$1 as AutomationCreatedEnvelope, type AutomationDeletedEnvelope$1 as AutomationDeletedEnvelope, type AutomationDeletedWithEntityEnvelope$1 as AutomationDeletedWithEntityEnvelope, type context$2_AutomationMetadata as AutomationMetadata, type AutomationNonNullableFields$1 as AutomationNonNullableFields, type AutomationUpdatedEnvelope$1 as AutomationUpdatedEnvelope, type AutomationUpdatedWithPreviousEntityEnvelope$1 as AutomationUpdatedWithPreviousEntityEnvelope, type AutomationsQueryBuilder$1 as AutomationsQueryBuilder, type AutomationsQueryResult$1 as AutomationsQueryResult, type BaseEventMetadata$2 as BaseEventMetadata, BlockType$1 as BlockType, type BulkActionMetadata$2 as BulkActionMetadata, type context$2_BulkCreateApplicationAutomationRequest as BulkCreateApplicationAutomationRequest, type context$2_BulkCreateApplicationAutomationResponse as BulkCreateApplicationAutomationResponse, type BulkDeleteAutomationsRequest$1 as BulkDeleteAutomationsRequest, type BulkDeleteAutomationsResponse$1 as BulkDeleteAutomationsResponse, type CTA$1 as CTA, type context$2_Condition as Condition, type ConditionBlock$1 as ConditionBlock, type context$2_Conditions as Conditions, type CreateAutomationRequest$1 as CreateAutomationRequest, type CreateAutomationResponse$1 as CreateAutomationResponse, type CreateAutomationResponseNonNullableFields$1 as CreateAutomationResponseNonNullableFields, type CursorPaging$1 as CursorPaging, type Cursors$1 as Cursors, type context$2_Debounce as Debounce, type Delay$1 as Delay, type context$2_DelayTypeOneOf as DelayTypeOneOf, type context$2_DeleteAutomationOptions as DeleteAutomationOptions, type DeleteAutomationRequest$1 as DeleteAutomationRequest, type DeleteAutomationResponse$1 as DeleteAutomationResponse, type DeleteContext$1 as DeleteContext, DeleteStatus$1 as DeleteStatus, type DeletedWithEntity$1 as DeletedWithEntity, type DomainEvent$2 as DomainEvent, type DomainEventBodyOneOf$2 as DomainEventBodyOneOf, type Empty$2 as Empty, type EntityCreatedEvent$2 as EntityCreatedEvent, type EntityDeletedEvent$2 as EntityDeletedEvent, type EntityUpdatedEvent$2 as EntityUpdatedEvent, type EventMetadata$2 as EventMetadata, type context$2_ExtendedFields as ExtendedFields, type Filter$4 as Filter, type context$2_GenerateActionInputMappingFromTemplateOptions as GenerateActionInputMappingFromTemplateOptions, type context$2_GenerateActionInputMappingFromTemplateRequest as GenerateActionInputMappingFromTemplateRequest, type context$2_GenerateActionInputMappingFromTemplateResponse as GenerateActionInputMappingFromTemplateResponse, type context$2_GenerateApplicationAutomationFromCustomRequest as GenerateApplicationAutomationFromCustomRequest, type context$2_GenerateApplicationAutomationFromCustomResponse as GenerateApplicationAutomationFromCustomResponse, type GetActionsQuotaInfoRequest$1 as GetActionsQuotaInfoRequest, type GetActionsQuotaInfoResponse$1 as GetActionsQuotaInfoResponse, type GetActionsQuotaInfoResponseNonNullableFields$1 as GetActionsQuotaInfoResponseNonNullableFields, type context$2_GetApplicationAutomationRequest as GetApplicationAutomationRequest, type context$2_GetApplicationAutomationResponse as GetApplicationAutomationResponse, type GetAutomationActionSchemaRequest$1 as GetAutomationActionSchemaRequest, type GetAutomationActionSchemaResponse$1 as GetAutomationActionSchemaResponse, type context$2_GetAutomationActivationReportsRequest as GetAutomationActivationReportsRequest, type context$2_GetAutomationActivationReportsResponse as GetAutomationActivationReportsResponse, type context$2_GetAutomationActivationReportsResponseNonNullableFields as GetAutomationActivationReportsResponseNonNullableFields, type context$2_GetAutomationActivationStatsOptions as GetAutomationActivationStatsOptions, type GetAutomationOptions$1 as GetAutomationOptions, type GetAutomationRequest$1 as GetAutomationRequest, type GetAutomationResponse$1 as GetAutomationResponse, type GetAutomationResponseNonNullableFields$1 as GetAutomationResponseNonNullableFields, type IdentificationData$2 as IdentificationData, type IdentificationDataIdOneOf$2 as IdentificationDataIdOneOf, type ItemMetadata$2 as ItemMetadata, type MessageEnvelope$2 as MessageEnvelope, type MetaSiteSpecialEvent$1 as MetaSiteSpecialEvent, type MetaSiteSpecialEventPayloadOneOf$1 as MetaSiteSpecialEventPayloadOneOf, type context$2_MigrationBulkCreateAutomations as MigrationBulkCreateAutomations, type context$2_MigrationBulkCreateAutomationsRequest as MigrationBulkCreateAutomationsRequest, type context$2_MigrationBulkCreateAutomationsResponse as MigrationBulkCreateAutomationsResponse, type context$2_MigrationUpdateMigratedToV3AutomationRequest as MigrationUpdateMigratedToV3AutomationRequest, type context$2_MigrationUpdateMigratedToV3AutomationResponse as MigrationUpdateMigratedToV3AutomationResponse, Namespace$1 as Namespace, type NamespaceChanged$1 as NamespaceChanged, type context$2_Offset as Offset, type context$2_OffsetValueOneOf as OffsetValueOneOf, type context$2_OverrideApplicationAutomationRequest as OverrideApplicationAutomationRequest, type context$2_OverrideApplicationAutomationResponse as OverrideApplicationAutomationResponse, type context$2_OverrideApplicationAutomationResponseNonNullableFields as OverrideApplicationAutomationResponseNonNullableFields, type context$2_Paging as Paging, type context$2_PagingMetadata as PagingMetadata, type context$2_PagingMetadataV2 as PagingMetadataV2, type Plan$1 as Plan, type ProviderConfigurationError$1 as ProviderConfigurationError, type context$2_QueryApplicationAutomationsRequest as QueryApplicationAutomationsRequest, type context$2_QueryApplicationAutomationsResponse as QueryApplicationAutomationsResponse, type context$2_QueryAutomationsOptions as QueryAutomationsOptions, type QueryAutomationsRequest$1 as QueryAutomationsRequest, type QueryAutomationsResponse$1 as QueryAutomationsResponse, type QueryAutomationsResponseNonNullableFields$1 as QueryAutomationsResponseNonNullableFields, type context$2_QueryV2 as QueryV2, type context$2_QueryV2PagingMethodOneOf as QueryV2PagingMethodOneOf, type Quota$1 as Quota, type QuotaInfo$1 as QuotaInfo, type RateLimit$2 as RateLimit, type RestoreInfo$2 as RestoreInfo, type context$2_Rule as Rule, type ServiceProvisioned$1 as ServiceProvisioned, type ServiceRemoved$1 as ServiceRemoved, type SiteCreated$1 as SiteCreated, SiteCreatedContext$1 as SiteCreatedContext, type SiteDeleted$1 as SiteDeleted, type SiteHardDeleted$1 as SiteHardDeleted, type SiteMarkedAsTemplate$1 as SiteMarkedAsTemplate, type SiteMarkedAsWixSite$1 as SiteMarkedAsWixSite, type SitePublished$1 as SitePublished, type SiteRenamed$1 as SiteRenamed, type SiteTransferred$1 as SiteTransferred, type SiteUndeleted$1 as SiteUndeleted, type SiteUnpublished$1 as SiteUnpublished, SortOrder$1 as SortOrder, type Sorting$1 as Sorting, type context$2_Source as Source, State$1 as State, Status$2 as Status, type StudioAssigned$1 as StudioAssigned, type StudioUnassigned$1 as StudioUnassigned, type context$2_SyncApplicationAutomationsRequest as SyncApplicationAutomationsRequest, type context$2_SyncApplicationAutomationsResponse as SyncApplicationAutomationsResponse, type Trigger$2 as Trigger, type TriggerConfigurationError$1 as TriggerConfigurationError, TriggerErrorType$1 as TriggerErrorType, type TriggerValidationError$1 as TriggerValidationError, type TriggerValidationErrorErrorOneOf$1 as TriggerValidationErrorErrorOneOf, TriggerValidationErrorValidationErrorType$1 as TriggerValidationErrorValidationErrorType, Type$2 as Type, type context$2_Until as Until, type context$2_UpdateApplicationAutomationConfigurationIdRequest as UpdateApplicationAutomationConfigurationIdRequest, type context$2_UpdateApplicationAutomationConfigurationIdResponse as UpdateApplicationAutomationConfigurationIdResponse, type context$2_UpdateApplicationAutomationToMigratedFromV1Request as UpdateApplicationAutomationToMigratedFromV1Request, type context$2_UpdateApplicationAutomationToMigratedFromV1Response as UpdateApplicationAutomationToMigratedFromV1Response, type UpdateAutomation$1 as UpdateAutomation, type UpdateAutomationRequest$1 as UpdateAutomationRequest, type UpdateAutomationResponse$1 as UpdateAutomationResponse, type UpdateAutomationResponseNonNullableFields$1 as UpdateAutomationResponseNonNullableFields, type context$2_UpdatedAutomationsWithEsb as UpdatedAutomationsWithEsb, type UpdatedWithPreviousEntity$1 as UpdatedWithPreviousEntity, type UpgradeCTA$1 as UpgradeCTA, type context$2_ValidateAutomationByIdOptions as ValidateAutomationByIdOptions, type context$2_ValidateAutomationByIdRequest as ValidateAutomationByIdRequest, type context$2_ValidateAutomationByIdResponse as ValidateAutomationByIdResponse, type context$2_ValidateAutomationByIdResponseNonNullableFields as ValidateAutomationByIdResponseNonNullableFields, type ValidateAutomationRequest$1 as ValidateAutomationRequest, type ValidateAutomationResponse$1 as ValidateAutomationResponse, type ValidateAutomationResponseNonNullableFields$1 as ValidateAutomationResponseNonNullableFields, ValidationErrorType$1 as ValidationErrorType, WebhookIdentityType$2 as WebhookIdentityType, type _publicOnAutomationCreatedType$1 as _publicOnAutomationCreatedType, type _publicOnAutomationDeletedType$1 as _publicOnAutomationDeletedType, type _publicOnAutomationDeletedWithEntityType$1 as _publicOnAutomationDeletedWithEntityType, type _publicOnAutomationUpdatedType$1 as _publicOnAutomationUpdatedType, type _publicOnAutomationUpdatedWithPreviousEntityType$1 as _publicOnAutomationUpdatedWithPreviousEntityType, createAutomation$2 as createAutomation, deleteAutomation$2 as deleteAutomation, context$2_generateActionInputMappingFromTemplate as generateActionInputMappingFromTemplate, getActionsQuotaInfo$2 as getActionsQuotaInfo, getAutomation$2 as getAutomation, context$2_getAutomationActivationStats as getAutomationActivationStats, onAutomationCreated$2 as onAutomationCreated, onAutomationDeleted$2 as onAutomationDeleted, onAutomationDeletedWithEntity$2 as onAutomationDeletedWithEntity, onAutomationUpdated$2 as onAutomationUpdated, onAutomationUpdatedWithPreviousEntity$2 as onAutomationUpdatedWithPreviousEntity, context$2_overrideApplicationAutomation as overrideApplicationAutomation, onAutomationCreated$3 as publicOnAutomationCreated, onAutomationDeleted$3 as publicOnAutomationDeleted, onAutomationDeletedWithEntity$3 as publicOnAutomationDeletedWithEntity, onAutomationUpdated$3 as publicOnAutomationUpdated, onAutomationUpdatedWithPreviousEntity$3 as publicOnAutomationUpdatedWithPreviousEntity, queryAutomations$2 as queryAutomations, updateAutomation$2 as updateAutomation, validateAutomation$2 as validateAutomation, context$2_validateAutomationById as validateAutomationById };
|
|
2181
|
+
}
|
|
2182
|
+
|
|
2183
|
+
type HostModule$1<T, H extends Host$1> = {
|
|
2184
|
+
__type: 'host';
|
|
2185
|
+
create(host: H): T;
|
|
2186
|
+
};
|
|
2187
|
+
type HostModuleAPI$1<T extends HostModule$1<any, any>> = T extends HostModule$1<infer U, any> ? U : never;
|
|
2188
|
+
type Host$1<Environment = unknown> = {
|
|
2189
|
+
channel: {
|
|
2190
|
+
observeState(callback: (props: unknown, environment: Environment) => unknown): {
|
|
2191
|
+
disconnect: () => void;
|
|
2192
|
+
} | Promise<{
|
|
2193
|
+
disconnect: () => void;
|
|
2194
|
+
}>;
|
|
2195
|
+
};
|
|
2196
|
+
environment?: Environment;
|
|
2197
|
+
/**
|
|
2198
|
+
* Optional bast url to use for API requests, for example `www.wixapis.com`
|
|
2199
|
+
*/
|
|
2200
|
+
apiBaseUrl?: string;
|
|
2201
|
+
/**
|
|
2202
|
+
* Possible data to be provided by every host, for cross cutting concerns
|
|
2203
|
+
* like internationalization, billing, etc.
|
|
2204
|
+
*/
|
|
2205
|
+
essentials?: {
|
|
2206
|
+
/**
|
|
2207
|
+
* The language of the currently viewed session
|
|
2208
|
+
*/
|
|
2209
|
+
language?: string;
|
|
2210
|
+
/**
|
|
2211
|
+
* The locale of the currently viewed session
|
|
2212
|
+
*/
|
|
2213
|
+
locale?: string;
|
|
2214
|
+
/**
|
|
2215
|
+
* Any headers that should be passed through to the API requests
|
|
2216
|
+
*/
|
|
2217
|
+
passThroughHeaders?: Record<string, string>;
|
|
2218
|
+
};
|
|
2219
|
+
};
|
|
2220
|
+
|
|
2221
|
+
type RESTFunctionDescriptor$1<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$1) => T;
|
|
2222
|
+
interface HttpClient$1 {
|
|
2223
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
|
|
2224
|
+
fetchWithAuth: typeof fetch;
|
|
2225
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
2226
|
+
getActiveToken?: () => string | undefined;
|
|
2227
|
+
}
|
|
2228
|
+
type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
|
|
2229
|
+
type HttpResponse$1<T = any> = {
|
|
2230
|
+
data: T;
|
|
2231
|
+
status: number;
|
|
2232
|
+
statusText: string;
|
|
2233
|
+
headers: any;
|
|
2234
|
+
request?: any;
|
|
2235
|
+
};
|
|
2236
|
+
type RequestOptions$1<_TResponse = any, Data = any> = {
|
|
2237
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
2238
|
+
url: string;
|
|
2239
|
+
data?: Data;
|
|
2240
|
+
params?: URLSearchParams;
|
|
2241
|
+
} & APIMetadata$1;
|
|
2242
|
+
type APIMetadata$1 = {
|
|
2243
|
+
methodFqn?: string;
|
|
2244
|
+
entityFqdn?: string;
|
|
2245
|
+
packageName?: string;
|
|
2246
|
+
};
|
|
2247
|
+
type BuildRESTFunction$1<T extends RESTFunctionDescriptor$1> = T extends RESTFunctionDescriptor$1<infer U> ? U : never;
|
|
2248
|
+
type EventDefinition$3<Payload = unknown, Type extends string = string> = {
|
|
2249
|
+
__type: 'event-definition';
|
|
2250
|
+
type: Type;
|
|
2251
|
+
isDomainEvent?: boolean;
|
|
2252
|
+
transformations?: (envelope: unknown) => Payload;
|
|
2253
|
+
__payload: Payload;
|
|
2254
|
+
};
|
|
2255
|
+
declare function EventDefinition$3<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$3<Payload, Type>;
|
|
2256
|
+
type EventHandler$3<T extends EventDefinition$3> = (payload: T['__payload']) => void | Promise<void>;
|
|
2257
|
+
type BuildEventDefinition$3<T extends EventDefinition$3<any, string>> = (handler: EventHandler$3<T>) => void;
|
|
2258
|
+
|
|
2259
|
+
type ServicePluginMethodInput$1 = {
|
|
2260
|
+
request: any;
|
|
2261
|
+
metadata: any;
|
|
2262
|
+
};
|
|
2263
|
+
type ServicePluginContract$1 = Record<string, (payload: ServicePluginMethodInput$1) => unknown | Promise<unknown>>;
|
|
2264
|
+
type ServicePluginMethodMetadata$1 = {
|
|
2265
|
+
name: string;
|
|
2266
|
+
primaryHttpMappingPath: string;
|
|
2267
|
+
transformations: {
|
|
2268
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput$1;
|
|
2269
|
+
toREST: (...args: unknown[]) => unknown;
|
|
2270
|
+
};
|
|
2271
|
+
};
|
|
2272
|
+
type ServicePluginDefinition$1<Contract extends ServicePluginContract$1> = {
|
|
2273
|
+
__type: 'service-plugin-definition';
|
|
2274
|
+
componentType: string;
|
|
2275
|
+
methods: ServicePluginMethodMetadata$1[];
|
|
2276
|
+
__contract: Contract;
|
|
2277
|
+
};
|
|
2278
|
+
declare function ServicePluginDefinition$1<Contract extends ServicePluginContract$1>(componentType: string, methods: ServicePluginMethodMetadata$1[]): ServicePluginDefinition$1<Contract>;
|
|
2279
|
+
type BuildServicePluginDefinition$1<T extends ServicePluginDefinition$1<any>> = (implementation: T['__contract']) => void;
|
|
2280
|
+
declare const SERVICE_PLUGIN_ERROR_TYPE$1 = "wix_spi_error";
|
|
2281
|
+
|
|
2282
|
+
type RequestContext$1 = {
|
|
2283
|
+
isSSR: boolean;
|
|
2284
|
+
host: string;
|
|
2285
|
+
protocol?: string;
|
|
2286
|
+
};
|
|
2287
|
+
type ResponseTransformer$1 = (data: any, headers?: any) => any;
|
|
2288
|
+
/**
|
|
2289
|
+
* Ambassador request options types are copied mostly from AxiosRequestConfig.
|
|
2290
|
+
* They are copied and not imported to reduce the amount of dependencies (to reduce install time).
|
|
2291
|
+
* https://github.com/axios/axios/blob/3f53eb6960f05a1f88409c4b731a40de595cb825/index.d.ts#L307-L315
|
|
2292
|
+
*/
|
|
2293
|
+
type Method$1 = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
2294
|
+
type AmbassadorRequestOptions$1<T = any> = {
|
|
2295
|
+
_?: T;
|
|
2296
|
+
url?: string;
|
|
2297
|
+
method?: Method$1;
|
|
2298
|
+
params?: any;
|
|
2299
|
+
data?: any;
|
|
2300
|
+
transformResponse?: ResponseTransformer$1 | ResponseTransformer$1[];
|
|
2301
|
+
};
|
|
2302
|
+
type AmbassadorFactory$1<Request, Response> = (payload: Request) => ((context: RequestContext$1) => AmbassadorRequestOptions$1<Response>) & {
|
|
2303
|
+
__isAmbassador: boolean;
|
|
2304
|
+
};
|
|
2305
|
+
type AmbassadorFunctionDescriptor$1<Request = any, Response = any> = AmbassadorFactory$1<Request, Response>;
|
|
2306
|
+
type BuildAmbassadorFunction$1<T extends AmbassadorFunctionDescriptor$1> = T extends AmbassadorFunctionDescriptor$1<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
2307
|
+
|
|
2308
|
+
declare global {
|
|
2309
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
2310
|
+
interface SymbolConstructor {
|
|
2311
|
+
readonly observable: symbol;
|
|
2312
|
+
}
|
|
2313
|
+
}
|
|
2314
|
+
|
|
2315
|
+
declare const emptyObjectSymbol$1: unique symbol;
|
|
2316
|
+
|
|
2317
|
+
/**
|
|
2318
|
+
Represents a strictly empty plain object, the `{}` value.
|
|
2319
|
+
|
|
2320
|
+
When you annotate something as the type `{}`, it can be anything except `null` and `undefined`. This means that you cannot use `{}` to represent an empty plain object ([read more](https://stackoverflow.com/questions/47339869/typescript-empty-object-and-any-difference/52193484#52193484)).
|
|
2321
|
+
|
|
2322
|
+
@example
|
|
2323
|
+
```
|
|
2324
|
+
import type {EmptyObject} from 'type-fest';
|
|
2325
|
+
|
|
2326
|
+
// The following illustrates the problem with `{}`.
|
|
2327
|
+
const foo1: {} = {}; // Pass
|
|
2328
|
+
const foo2: {} = []; // Pass
|
|
2329
|
+
const foo3: {} = 42; // Pass
|
|
2330
|
+
const foo4: {} = {a: 1}; // Pass
|
|
2331
|
+
|
|
2332
|
+
// With `EmptyObject` only the first case is valid.
|
|
2333
|
+
const bar1: EmptyObject = {}; // Pass
|
|
2334
|
+
const bar2: EmptyObject = 42; // Fail
|
|
2335
|
+
const bar3: EmptyObject = []; // Fail
|
|
2336
|
+
const bar4: EmptyObject = {a: 1}; // Fail
|
|
2337
|
+
```
|
|
2338
|
+
|
|
2339
|
+
Unfortunately, `Record<string, never>`, `Record<keyof any, never>` and `Record<never, never>` do not work. See {@link https://github.com/sindresorhus/type-fest/issues/395 #395}.
|
|
2340
|
+
|
|
2341
|
+
@category Object
|
|
2342
|
+
*/
|
|
2343
|
+
type EmptyObject$1 = {[emptyObjectSymbol$1]?: never};
|
|
2344
|
+
|
|
2345
|
+
/**
|
|
2346
|
+
Returns a boolean for whether the two given types are equal.
|
|
2347
|
+
|
|
2348
|
+
@link https://github.com/microsoft/TypeScript/issues/27024#issuecomment-421529650
|
|
2349
|
+
@link https://stackoverflow.com/questions/68961864/how-does-the-equals-work-in-typescript/68963796#68963796
|
|
2350
|
+
|
|
2351
|
+
Use-cases:
|
|
2352
|
+
- If you want to make a conditional branch based on the result of a comparison of two types.
|
|
2353
|
+
|
|
2354
|
+
@example
|
|
2355
|
+
```
|
|
2356
|
+
import type {IsEqual} from 'type-fest';
|
|
2357
|
+
|
|
2358
|
+
// This type returns a boolean for whether the given array includes the given item.
|
|
2359
|
+
// `IsEqual` is used to compare the given array at position 0 and the given item and then return true if they are equal.
|
|
2360
|
+
type Includes<Value extends readonly any[], Item> =
|
|
2361
|
+
Value extends readonly [Value[0], ...infer rest]
|
|
2362
|
+
? IsEqual<Value[0], Item> extends true
|
|
2363
|
+
? true
|
|
2364
|
+
: Includes<rest, Item>
|
|
2365
|
+
: false;
|
|
2366
|
+
```
|
|
2367
|
+
|
|
2368
|
+
@category Type Guard
|
|
2369
|
+
@category Utilities
|
|
2370
|
+
*/
|
|
2371
|
+
type IsEqual$1<A, B> =
|
|
2372
|
+
(<G>() => G extends A ? 1 : 2) extends
|
|
2373
|
+
(<G>() => G extends B ? 1 : 2)
|
|
2374
|
+
? true
|
|
2375
|
+
: false;
|
|
2376
|
+
|
|
2377
|
+
/**
|
|
2378
|
+
Filter out keys from an object.
|
|
2379
|
+
|
|
2380
|
+
Returns `never` if `Exclude` is strictly equal to `Key`.
|
|
2381
|
+
Returns `never` if `Key` extends `Exclude`.
|
|
2382
|
+
Returns `Key` otherwise.
|
|
2383
|
+
|
|
2384
|
+
@example
|
|
2385
|
+
```
|
|
2386
|
+
type Filtered = Filter<'foo', 'foo'>;
|
|
2387
|
+
//=> never
|
|
2388
|
+
```
|
|
2389
|
+
|
|
2390
|
+
@example
|
|
2391
|
+
```
|
|
2392
|
+
type Filtered = Filter<'bar', string>;
|
|
2393
|
+
//=> never
|
|
2394
|
+
```
|
|
2395
|
+
|
|
2396
|
+
@example
|
|
2397
|
+
```
|
|
2398
|
+
type Filtered = Filter<'bar', 'foo'>;
|
|
2399
|
+
//=> 'bar'
|
|
2400
|
+
```
|
|
2401
|
+
|
|
2402
|
+
@see {Except}
|
|
2403
|
+
*/
|
|
2404
|
+
type Filter$3<KeyType, ExcludeType> = IsEqual$1<KeyType, ExcludeType> extends true ? never : (KeyType extends ExcludeType ? never : KeyType);
|
|
2405
|
+
|
|
2406
|
+
type ExceptOptions$1 = {
|
|
2407
|
+
/**
|
|
2408
|
+
Disallow assigning non-specified properties.
|
|
2409
|
+
|
|
2410
|
+
Note that any omitted properties in the resulting type will be present in autocomplete as `undefined`.
|
|
2411
|
+
|
|
2412
|
+
@default false
|
|
2413
|
+
*/
|
|
2414
|
+
requireExactProps?: boolean;
|
|
2415
|
+
};
|
|
2416
|
+
|
|
2417
|
+
/**
|
|
2418
|
+
Create a type from an object type without certain keys.
|
|
2419
|
+
|
|
2420
|
+
We recommend setting the `requireExactProps` option to `true`.
|
|
2421
|
+
|
|
2422
|
+
This type is a stricter version of [`Omit`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-5.html#the-omit-helper-type). The `Omit` type does not restrict the omitted keys to be keys present on the given type, while `Except` does. The benefits of a stricter type are avoiding typos and allowing the compiler to pick up on rename refactors automatically.
|
|
2423
|
+
|
|
2424
|
+
This type was proposed to the TypeScript team, which declined it, saying they prefer that libraries implement stricter versions of the built-in types ([microsoft/TypeScript#30825](https://github.com/microsoft/TypeScript/issues/30825#issuecomment-523668235)).
|
|
2425
|
+
|
|
2426
|
+
@example
|
|
2427
|
+
```
|
|
2428
|
+
import type {Except} from 'type-fest';
|
|
2429
|
+
|
|
2430
|
+
type Foo = {
|
|
2431
|
+
a: number;
|
|
2432
|
+
b: string;
|
|
2433
|
+
};
|
|
2434
|
+
|
|
2435
|
+
type FooWithoutA = Except<Foo, 'a'>;
|
|
2436
|
+
//=> {b: string}
|
|
2437
|
+
|
|
2438
|
+
const fooWithoutA: FooWithoutA = {a: 1, b: '2'};
|
|
2439
|
+
//=> errors: 'a' does not exist in type '{ b: string; }'
|
|
2440
|
+
|
|
2441
|
+
type FooWithoutB = Except<Foo, 'b', {requireExactProps: true}>;
|
|
2442
|
+
//=> {a: number} & Partial<Record<"b", never>>
|
|
2443
|
+
|
|
2444
|
+
const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
|
|
2445
|
+
//=> errors at 'b': Type 'string' is not assignable to type 'undefined'.
|
|
2446
|
+
```
|
|
2447
|
+
|
|
2448
|
+
@category Object
|
|
2449
|
+
*/
|
|
2450
|
+
type Except$1<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions$1 = {requireExactProps: false}> = {
|
|
2451
|
+
[KeyType in keyof ObjectType as Filter$3<KeyType, KeysType>]: ObjectType[KeyType];
|
|
2452
|
+
} & (Options['requireExactProps'] extends true
|
|
2453
|
+
? Partial<Record<KeysType, never>>
|
|
2454
|
+
: {});
|
|
2455
|
+
|
|
2456
|
+
/**
|
|
2457
|
+
Extract the keys from a type where the value type of the key extends the given `Condition`.
|
|
2458
|
+
|
|
2459
|
+
Internally this is used for the `ConditionalPick` and `ConditionalExcept` types.
|
|
2460
|
+
|
|
2461
|
+
@example
|
|
2462
|
+
```
|
|
2463
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
2464
|
+
|
|
2465
|
+
interface Example {
|
|
2466
|
+
a: string;
|
|
2467
|
+
b: string | number;
|
|
2468
|
+
c?: string;
|
|
2469
|
+
d: {};
|
|
2470
|
+
}
|
|
2471
|
+
|
|
2472
|
+
type StringKeysOnly = ConditionalKeys<Example, string>;
|
|
2473
|
+
//=> 'a'
|
|
2474
|
+
```
|
|
2475
|
+
|
|
2476
|
+
To support partial types, make sure your `Condition` is a union of undefined (for example, `string | undefined`) as demonstrated below.
|
|
2477
|
+
|
|
2478
|
+
@example
|
|
2479
|
+
```
|
|
2480
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
2481
|
+
|
|
2482
|
+
type StringKeysAndUndefined = ConditionalKeys<Example, string | undefined>;
|
|
2483
|
+
//=> 'a' | 'c'
|
|
2484
|
+
```
|
|
2485
|
+
|
|
2486
|
+
@category Object
|
|
2487
|
+
*/
|
|
2488
|
+
type ConditionalKeys$1<Base, Condition> = NonNullable<
|
|
2489
|
+
// Wrap in `NonNullable` to strip away the `undefined` type from the produced union.
|
|
2490
|
+
{
|
|
2491
|
+
// Map through all the keys of the given base type.
|
|
2492
|
+
[Key in keyof Base]:
|
|
2493
|
+
// Pick only keys with types extending the given `Condition` type.
|
|
2494
|
+
Base[Key] extends Condition
|
|
2495
|
+
// Retain this key since the condition passes.
|
|
2496
|
+
? Key
|
|
2497
|
+
// Discard this key since the condition fails.
|
|
2498
|
+
: never;
|
|
2499
|
+
|
|
2500
|
+
// Convert the produced object into a union type of the keys which passed the conditional test.
|
|
2501
|
+
}[keyof Base]
|
|
2502
|
+
>;
|
|
2503
|
+
|
|
2504
|
+
/**
|
|
2505
|
+
Exclude keys from a shape that matches the given `Condition`.
|
|
2506
|
+
|
|
2507
|
+
This is useful when you want to create a new type with a specific set of keys from a shape. For example, you might want to exclude all the primitive properties from a class and form a new shape containing everything but the primitive properties.
|
|
2508
|
+
|
|
2509
|
+
@example
|
|
2510
|
+
```
|
|
2511
|
+
import type {Primitive, ConditionalExcept} from 'type-fest';
|
|
2512
|
+
|
|
2513
|
+
class Awesome {
|
|
2514
|
+
name: string;
|
|
2515
|
+
successes: number;
|
|
2516
|
+
failures: bigint;
|
|
2517
|
+
|
|
2518
|
+
run() {}
|
|
2519
|
+
}
|
|
2520
|
+
|
|
2521
|
+
type ExceptPrimitivesFromAwesome = ConditionalExcept<Awesome, Primitive>;
|
|
2522
|
+
//=> {run: () => void}
|
|
2523
|
+
```
|
|
2524
|
+
|
|
2525
|
+
@example
|
|
2526
|
+
```
|
|
2527
|
+
import type {ConditionalExcept} from 'type-fest';
|
|
2528
|
+
|
|
2529
|
+
interface Example {
|
|
2530
|
+
a: string;
|
|
2531
|
+
b: string | number;
|
|
2532
|
+
c: () => void;
|
|
2533
|
+
d: {};
|
|
2534
|
+
}
|
|
2535
|
+
|
|
2536
|
+
type NonStringKeysOnly = ConditionalExcept<Example, string>;
|
|
2537
|
+
//=> {b: string | number; c: () => void; d: {}}
|
|
2538
|
+
```
|
|
2539
|
+
|
|
2540
|
+
@category Object
|
|
2541
|
+
*/
|
|
2542
|
+
type ConditionalExcept$1<Base, Condition> = Except$1<
|
|
2543
|
+
Base,
|
|
2544
|
+
ConditionalKeys$1<Base, Condition>
|
|
2545
|
+
>;
|
|
2546
|
+
|
|
2547
|
+
/**
|
|
2548
|
+
* Descriptors are objects that describe the API of a module, and the module
|
|
2549
|
+
* can either be a REST module or a host module.
|
|
2550
|
+
* This type is recursive, so it can describe nested modules.
|
|
2551
|
+
*/
|
|
2552
|
+
type Descriptors$1 = RESTFunctionDescriptor$1 | AmbassadorFunctionDescriptor$1 | HostModule$1<any, any> | EventDefinition$3<any> | ServicePluginDefinition$1<any> | {
|
|
2553
|
+
[key: string]: Descriptors$1 | PublicMetadata$1 | any;
|
|
2554
|
+
};
|
|
2555
|
+
/**
|
|
2556
|
+
* This type takes in a descriptors object of a certain Host (including an `unknown` host)
|
|
2557
|
+
* and returns an object with the same structure, but with all descriptors replaced with their API.
|
|
2558
|
+
* Any non-descriptor properties are removed from the returned object, including descriptors that
|
|
2559
|
+
* do not match the given host (as they will not work with the given host).
|
|
2560
|
+
*/
|
|
2561
|
+
type BuildDescriptors$1<T extends Descriptors$1, H extends Host$1<any> | undefined, Depth extends number = 5> = {
|
|
2562
|
+
done: T;
|
|
2563
|
+
recurse: T extends {
|
|
2564
|
+
__type: typeof SERVICE_PLUGIN_ERROR_TYPE$1;
|
|
2565
|
+
} ? never : T extends AmbassadorFunctionDescriptor$1 ? BuildAmbassadorFunction$1<T> : T extends RESTFunctionDescriptor$1 ? BuildRESTFunction$1<T> : T extends EventDefinition$3<any> ? BuildEventDefinition$3<T> : T extends ServicePluginDefinition$1<any> ? BuildServicePluginDefinition$1<T> : T extends HostModule$1<any, any> ? HostModuleAPI$1<T> : ConditionalExcept$1<{
|
|
2566
|
+
[Key in keyof T]: T[Key] extends Descriptors$1 ? BuildDescriptors$1<T[Key], H, [
|
|
2567
|
+
-1,
|
|
2568
|
+
0,
|
|
2569
|
+
1,
|
|
2570
|
+
2,
|
|
2571
|
+
3,
|
|
2572
|
+
4,
|
|
2573
|
+
5
|
|
2574
|
+
][Depth]> : never;
|
|
2575
|
+
}, EmptyObject$1>;
|
|
2576
|
+
}[Depth extends -1 ? 'done' : 'recurse'];
|
|
2577
|
+
type PublicMetadata$1 = {
|
|
2578
|
+
PACKAGE_NAME?: string;
|
|
2579
|
+
};
|
|
2580
|
+
|
|
2581
|
+
declare global {
|
|
2582
|
+
interface ContextualClient {
|
|
2583
|
+
}
|
|
1797
2584
|
}
|
|
2585
|
+
/**
|
|
2586
|
+
* A type used to create concerete types from SDK descriptors in
|
|
2587
|
+
* case a contextual client is available.
|
|
2588
|
+
*/
|
|
2589
|
+
type MaybeContext$1<T extends Descriptors$1> = globalThis.ContextualClient extends {
|
|
2590
|
+
host: Host$1;
|
|
2591
|
+
} ? BuildDescriptors$1<T, globalThis.ContextualClient['host']> : T;
|
|
1798
2592
|
|
|
1799
2593
|
interface Activation {
|
|
1800
2594
|
/** Activation ID */
|
|
@@ -1917,7 +2711,7 @@ declare enum TimeUnit$1 {
|
|
|
1917
2711
|
WEEKS = "WEEKS",
|
|
1918
2712
|
MONTHS = "MONTHS"
|
|
1919
2713
|
}
|
|
1920
|
-
interface Filter$
|
|
2714
|
+
interface Filter$2 {
|
|
1921
2715
|
/** Filter ID. */
|
|
1922
2716
|
_id?: string;
|
|
1923
2717
|
/** Field key from the payload schema, for example "formId". */
|
|
@@ -2043,7 +2837,7 @@ interface Trigger$1 {
|
|
|
2043
2837
|
* List of filters on schema fields.
|
|
2044
2838
|
* In order for the automation to run, all filter expressions must evaluate to `true` for a given payload.
|
|
2045
2839
|
*/
|
|
2046
|
-
filters?: Filter$
|
|
2840
|
+
filters?: Filter$2[];
|
|
2047
2841
|
/** Defines the time offset between the trigger date and when the automation runs. */
|
|
2048
2842
|
scheduledEventOffset?: FutureDateActivationOffset$1;
|
|
2049
2843
|
/** Limits the number of times an automation can be triggered. */
|
|
@@ -3298,7 +4092,7 @@ interface ReportEventOptions {
|
|
|
3298
4092
|
idempotency?: Idempotency;
|
|
3299
4093
|
}
|
|
3300
4094
|
|
|
3301
|
-
declare function reportEvent$1(httpClient: HttpClient): ReportEventSignature;
|
|
4095
|
+
declare function reportEvent$1(httpClient: HttpClient$1): ReportEventSignature;
|
|
3302
4096
|
interface ReportEventSignature {
|
|
3303
4097
|
/**
|
|
3304
4098
|
* Reports an event and activates site automations with the specified trigger key.
|
|
@@ -3317,7 +4111,7 @@ interface ReportEventSignature {
|
|
|
3317
4111
|
*/
|
|
3318
4112
|
(triggerKey: string, options?: ReportEventOptions | undefined): Promise<ReportEventResponse & ReportEventResponseNonNullableFields>;
|
|
3319
4113
|
}
|
|
3320
|
-
declare function bulkReportEvent$1(httpClient: HttpClient): BulkReportEventSignature;
|
|
4114
|
+
declare function bulkReportEvent$1(httpClient: HttpClient$1): BulkReportEventSignature;
|
|
3321
4115
|
interface BulkReportEventSignature {
|
|
3322
4116
|
/**
|
|
3323
4117
|
* Bulk reports events and activates site automations with the specified trigger key.
|
|
@@ -3328,7 +4122,7 @@ interface BulkReportEventSignature {
|
|
|
3328
4122
|
*/
|
|
3329
4123
|
(triggerKey: string, eventsInfo: EventInfo[]): Promise<BulkReportEventResponse & BulkReportEventResponseNonNullableFields>;
|
|
3330
4124
|
}
|
|
3331
|
-
declare function bulkCancelEvent$1(httpClient: HttpClient): BulkCancelEventSignature;
|
|
4125
|
+
declare function bulkCancelEvent$1(httpClient: HttpClient$1): BulkCancelEventSignature;
|
|
3332
4126
|
interface BulkCancelEventSignature {
|
|
3333
4127
|
/**
|
|
3334
4128
|
* Bulk cancels any remaining actions for a trigger and external entities.
|
|
@@ -3338,7 +4132,7 @@ interface BulkCancelEventSignature {
|
|
|
3338
4132
|
*/
|
|
3339
4133
|
(triggerKey: string, externalEntityIds: string[]): Promise<BulkCancelEventResponse & BulkCancelEventResponseNonNullableFields>;
|
|
3340
4134
|
}
|
|
3341
|
-
declare function cancelEvent$1(httpClient: HttpClient): CancelEventSignature;
|
|
4135
|
+
declare function cancelEvent$1(httpClient: HttpClient$1): CancelEventSignature;
|
|
3342
4136
|
interface CancelEventSignature {
|
|
3343
4137
|
/**
|
|
3344
4138
|
* Cancels any remaining actions for a trigger and external entity.
|
|
@@ -3365,14 +4159,32 @@ interface CancelEventSignature {
|
|
|
3365
4159
|
*/
|
|
3366
4160
|
(triggerKey: string, externalEntityId: string): Promise<void>;
|
|
3367
4161
|
}
|
|
3368
|
-
declare const onActivationStatusChanged$1: EventDefinition<ActivationStatusChangedEnvelope, "wix.automations.v2.activation_activation_status_changed">;
|
|
4162
|
+
declare const onActivationStatusChanged$1: EventDefinition$3<ActivationStatusChangedEnvelope, "wix.automations.v2.activation_activation_status_changed">;
|
|
3369
4163
|
|
|
3370
|
-
|
|
4164
|
+
type EventDefinition$2<Payload = unknown, Type extends string = string> = {
|
|
4165
|
+
__type: 'event-definition';
|
|
4166
|
+
type: Type;
|
|
4167
|
+
isDomainEvent?: boolean;
|
|
4168
|
+
transformations?: (envelope: unknown) => Payload;
|
|
4169
|
+
__payload: Payload;
|
|
4170
|
+
};
|
|
4171
|
+
declare function EventDefinition$2<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$2<Payload, Type>;
|
|
4172
|
+
type EventHandler$2<T extends EventDefinition$2> = (payload: T['__payload']) => void | Promise<void>;
|
|
4173
|
+
type BuildEventDefinition$2<T extends EventDefinition$2<any, string>> = (handler: EventHandler$2<T>) => void;
|
|
3371
4174
|
|
|
3372
|
-
declare
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
4175
|
+
declare global {
|
|
4176
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
4177
|
+
interface SymbolConstructor {
|
|
4178
|
+
readonly observable: symbol;
|
|
4179
|
+
}
|
|
4180
|
+
}
|
|
4181
|
+
|
|
4182
|
+
declare function createEventModule$1<T extends EventDefinition$2<any, string>>(eventDefinition: T): BuildEventDefinition$2<T> & T;
|
|
4183
|
+
|
|
4184
|
+
declare const reportEvent: MaybeContext$1<BuildRESTFunction$1<typeof reportEvent$1> & typeof reportEvent$1>;
|
|
4185
|
+
declare const bulkReportEvent: MaybeContext$1<BuildRESTFunction$1<typeof bulkReportEvent$1> & typeof bulkReportEvent$1>;
|
|
4186
|
+
declare const bulkCancelEvent: MaybeContext$1<BuildRESTFunction$1<typeof bulkCancelEvent$1> & typeof bulkCancelEvent$1>;
|
|
4187
|
+
declare const cancelEvent: MaybeContext$1<BuildRESTFunction$1<typeof cancelEvent$1> & typeof cancelEvent$1>;
|
|
3376
4188
|
|
|
3377
4189
|
type _publicOnActivationStatusChangedType = typeof onActivationStatusChanged$1;
|
|
3378
4190
|
/**
|
|
@@ -3503,9 +4315,419 @@ declare const context$1_cancelEvent: typeof cancelEvent;
|
|
|
3503
4315
|
declare const context$1_onActivationStatusChanged: typeof onActivationStatusChanged;
|
|
3504
4316
|
declare const context$1_reportEvent: typeof reportEvent;
|
|
3505
4317
|
declare namespace context$1 {
|
|
3506
|
-
export { type Action$1 as Action, type context$1_ActionActionOneOf as ActionActionOneOf, type context$1_ActionCompletedRequest as ActionCompletedRequest, type context$1_ActionData as ActionData, type ActionEvent$1 as ActionEvent, type ActionSettings$1 as ActionSettings, type context$1_ActionStatus as ActionStatus, type context$1_ActionsData as ActionsData, type context$1_Activation as Activation, type context$1_ActivationActionStatusChanged as ActivationActionStatusChanged, context$1_ActivationActionStatusChangedStatus as ActivationActionStatusChangedStatus, type context$1_ActivationActionStatusChangedStatusInfoOneOf as ActivationActionStatusChangedStatusInfoOneOf, type context$1_ActivationContinuedAfterSchedule as ActivationContinuedAfterSchedule, type context$1_ActivationRequest as ActivationRequest, type context$1_ActivationResumeAfterDelay as ActivationResumeAfterDelay, type context$1_ActivationScheduleCompleted as ActivationScheduleCompleted, type context$1_ActivationScheduleRequested as ActivationScheduleRequested, type context$1_ActivationSource as ActivationSource, type context$1_ActivationSourceOfOneOf as ActivationSourceOfOneOf, type context$1_ActivationStatus as ActivationStatus, type context$1_ActivationStatusChanged as ActivationStatusChanged, type context$1_ActivationStatusChangedEnvelope as ActivationStatusChangedEnvelope, type context$1_ActivationStatusChangedFailedStatusInfo as ActivationStatusChangedFailedStatusInfo, context$1_ActivationStatusChangedStatus as ActivationStatusChangedStatus, type context$1_ActivationStatusChangedStatusInfoOneOf as ActivationStatusChangedStatusInfoOneOf, type AppDefinedAction$1 as AppDefinedAction, type context$1_AppDefinedActionInfo as AppDefinedActionInfo, type ApplicationError$1 as ApplicationError, type ApplicationOrigin$1 as ApplicationOrigin, type context$1_AsyncAction as AsyncAction, type AuditInfo$1 as AuditInfo, type AuditInfoIdOneOf$1 as AuditInfoIdOneOf, type Automation$1 as Automation, type AutomationConfiguration$1 as AutomationConfiguration, type context$1_AutomationConfigurationAction as AutomationConfigurationAction, type context$1_AutomationConfigurationActionInfoOneOf as AutomationConfigurationActionInfoOneOf, context$1_AutomationConfigurationStatus as AutomationConfigurationStatus, type context$1_AutomationIdentifier as AutomationIdentifier, type context$1_AutomationInfo as AutomationInfo, type context$1_AutomationInfoOriginInfoOneOf as AutomationInfoOriginInfoOneOf, type AutomationOriginInfoOneOf$1 as AutomationOriginInfoOneOf, type AutomationSettings$1 as AutomationSettings, type BaseEventMetadata$1 as BaseEventMetadata, type context$1_BatchActivationRequest as BatchActivationRequest, context$1_BlockType as BlockType, type BulkActionMetadata$1 as BulkActionMetadata, type context$1_BulkCancelEventRequest as BulkCancelEventRequest, type context$1_BulkCancelEventResponse as BulkCancelEventResponse, type context$1_BulkCancelEventResponseNonNullableFields as BulkCancelEventResponseNonNullableFields, type context$1_BulkCancelEventResult as BulkCancelEventResult, type context$1_BulkReportEventRequest as BulkReportEventRequest, type context$1_BulkReportEventResponse as BulkReportEventResponse, type context$1_BulkReportEventResponseNonNullableFields as BulkReportEventResponseNonNullableFields, type context$1_BulkReportEventResult as BulkReportEventResult, type context$1_CancelEventRequest as CancelEventRequest, type context$1_CancelEventResponse as CancelEventResponse, type context$1_CancelPendingScheduleRequest as CancelPendingScheduleRequest, type context$1_CancelPendingScheduleRequestByOneOf as CancelPendingScheduleRequestByOneOf, type context$1_CancelPendingScheduleResponse as CancelPendingScheduleResponse, context$1_CancellationReason as CancellationReason, type context$1_CancelledStatusInfo as CancelledStatusInfo, type context$1_Case as Case, type ConditionAction$1 as ConditionAction, type context$1_ConditionActionInfo as ConditionActionInfo, type context$1_ConditionBlock as ConditionBlock, type ConditionExpressionGroup$1 as ConditionExpressionGroup, type context$1_ConditionFilter as ConditionFilter, type context$1_Delay as Delay, type DelayAction$1 as DelayAction, type context$1_DelayActionInfo as DelayActionInfo, type context$1_DelayHelper as DelayHelper, type context$1_DelayOfOneOf as DelayOfOneOf, type DomainEvent$1 as DomainEvent, type DomainEventBodyOneOf$1 as DomainEventBodyOneOf, type DraftInfo$1 as DraftInfo, type Empty$1 as Empty, type context$1_EndedStatusInfo as EndedStatusInfo, type context$1_EndedStatusInfoTypeInfoOneOf as EndedStatusInfoTypeInfoOneOf, type EntityCreatedEvent$1 as EntityCreatedEvent, type EntityDeletedEvent$1 as EntityDeletedEvent, type EntityUpdatedEvent$1 as EntityUpdatedEvent, type context$1_EventInfo as EventInfo, type EventMetadata$1 as EventMetadata, type context$1_ExecuteFromActionRequest as ExecuteFromActionRequest, type context$1_ExecuteFromActionResponse as ExecuteFromActionResponse, type context$1_ExpressionEvaluationResult as ExpressionEvaluationResult, type context$1_FailedStatusInfo as FailedStatusInfo, type Filter$
|
|
4318
|
+
export { type Action$1 as Action, type context$1_ActionActionOneOf as ActionActionOneOf, type context$1_ActionCompletedRequest as ActionCompletedRequest, type context$1_ActionData as ActionData, type ActionEvent$1 as ActionEvent, type ActionSettings$1 as ActionSettings, type context$1_ActionStatus as ActionStatus, type context$1_ActionsData as ActionsData, type context$1_Activation as Activation, type context$1_ActivationActionStatusChanged as ActivationActionStatusChanged, context$1_ActivationActionStatusChangedStatus as ActivationActionStatusChangedStatus, type context$1_ActivationActionStatusChangedStatusInfoOneOf as ActivationActionStatusChangedStatusInfoOneOf, type context$1_ActivationContinuedAfterSchedule as ActivationContinuedAfterSchedule, type context$1_ActivationRequest as ActivationRequest, type context$1_ActivationResumeAfterDelay as ActivationResumeAfterDelay, type context$1_ActivationScheduleCompleted as ActivationScheduleCompleted, type context$1_ActivationScheduleRequested as ActivationScheduleRequested, type context$1_ActivationSource as ActivationSource, type context$1_ActivationSourceOfOneOf as ActivationSourceOfOneOf, type context$1_ActivationStatus as ActivationStatus, type context$1_ActivationStatusChanged as ActivationStatusChanged, type context$1_ActivationStatusChangedEnvelope as ActivationStatusChangedEnvelope, type context$1_ActivationStatusChangedFailedStatusInfo as ActivationStatusChangedFailedStatusInfo, context$1_ActivationStatusChangedStatus as ActivationStatusChangedStatus, type context$1_ActivationStatusChangedStatusInfoOneOf as ActivationStatusChangedStatusInfoOneOf, type AppDefinedAction$1 as AppDefinedAction, type context$1_AppDefinedActionInfo as AppDefinedActionInfo, type ApplicationError$1 as ApplicationError, type ApplicationOrigin$1 as ApplicationOrigin, type context$1_AsyncAction as AsyncAction, type AuditInfo$1 as AuditInfo, type AuditInfoIdOneOf$1 as AuditInfoIdOneOf, type Automation$1 as Automation, type AutomationConfiguration$1 as AutomationConfiguration, type context$1_AutomationConfigurationAction as AutomationConfigurationAction, type context$1_AutomationConfigurationActionInfoOneOf as AutomationConfigurationActionInfoOneOf, context$1_AutomationConfigurationStatus as AutomationConfigurationStatus, type context$1_AutomationIdentifier as AutomationIdentifier, type context$1_AutomationInfo as AutomationInfo, type context$1_AutomationInfoOriginInfoOneOf as AutomationInfoOriginInfoOneOf, type AutomationOriginInfoOneOf$1 as AutomationOriginInfoOneOf, type AutomationSettings$1 as AutomationSettings, type BaseEventMetadata$1 as BaseEventMetadata, type context$1_BatchActivationRequest as BatchActivationRequest, context$1_BlockType as BlockType, type BulkActionMetadata$1 as BulkActionMetadata, type context$1_BulkCancelEventRequest as BulkCancelEventRequest, type context$1_BulkCancelEventResponse as BulkCancelEventResponse, type context$1_BulkCancelEventResponseNonNullableFields as BulkCancelEventResponseNonNullableFields, type context$1_BulkCancelEventResult as BulkCancelEventResult, type context$1_BulkReportEventRequest as BulkReportEventRequest, type context$1_BulkReportEventResponse as BulkReportEventResponse, type context$1_BulkReportEventResponseNonNullableFields as BulkReportEventResponseNonNullableFields, type context$1_BulkReportEventResult as BulkReportEventResult, type context$1_CancelEventRequest as CancelEventRequest, type context$1_CancelEventResponse as CancelEventResponse, type context$1_CancelPendingScheduleRequest as CancelPendingScheduleRequest, type context$1_CancelPendingScheduleRequestByOneOf as CancelPendingScheduleRequestByOneOf, type context$1_CancelPendingScheduleResponse as CancelPendingScheduleResponse, context$1_CancellationReason as CancellationReason, type context$1_CancelledStatusInfo as CancelledStatusInfo, type context$1_Case as Case, type ConditionAction$1 as ConditionAction, type context$1_ConditionActionInfo as ConditionActionInfo, type context$1_ConditionBlock as ConditionBlock, type ConditionExpressionGroup$1 as ConditionExpressionGroup, type context$1_ConditionFilter as ConditionFilter, type context$1_Delay as Delay, type DelayAction$1 as DelayAction, type context$1_DelayActionInfo as DelayActionInfo, type context$1_DelayHelper as DelayHelper, type context$1_DelayOfOneOf as DelayOfOneOf, type DomainEvent$1 as DomainEvent, type DomainEventBodyOneOf$1 as DomainEventBodyOneOf, type DraftInfo$1 as DraftInfo, type Empty$1 as Empty, type context$1_EndedStatusInfo as EndedStatusInfo, type context$1_EndedStatusInfoTypeInfoOneOf as EndedStatusInfoTypeInfoOneOf, type EntityCreatedEvent$1 as EntityCreatedEvent, type EntityDeletedEvent$1 as EntityDeletedEvent, type EntityUpdatedEvent$1 as EntityUpdatedEvent, type context$1_EventInfo as EventInfo, type EventMetadata$1 as EventMetadata, type context$1_ExecuteFromActionRequest as ExecuteFromActionRequest, type context$1_ExecuteFromActionResponse as ExecuteFromActionResponse, type context$1_ExpressionEvaluationResult as ExpressionEvaluationResult, type context$1_FailedStatusInfo as FailedStatusInfo, type Filter$2 as Filter, type FutureDateActivationOffset$1 as FutureDateActivationOffset, type context$1_Idempotency as Idempotency, type IdentificationData$1 as IdentificationData, type IdentificationDataIdOneOf$1 as IdentificationDataIdOneOf, context$1_IdentifierType as IdentifierType, type context$1_Identity as Identity, type context$1_IfFilter as IfFilter, type context$1_InitiatedStatusInfo as InitiatedStatusInfo, type ItemMetadata$1 as ItemMetadata, type MessageEnvelope$1 as MessageEnvelope, Operator$1 as Operator, Origin$1 as Origin, type context$1_Output as Output, type OutputAction$1 as OutputAction, type context$1_PreinstalledIdentifier as PreinstalledIdentifier, type PreinstalledOrigin$1 as PreinstalledOrigin, type RateLimit$1 as RateLimit, type RateLimitAction$1 as RateLimitAction, type context$1_RateLimitActionInfo as RateLimitActionInfo, type context$1_RateLimiting as RateLimiting, type context$1_RefreshPayloadRequest as RefreshPayloadRequest, type context$1_RefreshPayloadResponse as RefreshPayloadResponse, type context$1_ReportDomainEventRequest as ReportDomainEventRequest, type context$1_ReportDomainEventResponse as ReportDomainEventResponse, type context$1_ReportEventOptions as ReportEventOptions, type context$1_ReportEventRequest as ReportEventRequest, type context$1_ReportEventResponse as ReportEventResponse, type context$1_ReportEventResponseNonNullableFields as ReportEventResponseNonNullableFields, type RestoreInfo$1 as RestoreInfo, type context$1_RunAutomationRequest as RunAutomationRequest, type context$1_RunAutomationResponse as RunAutomationResponse, type context$1_Runtime as Runtime, type context$1_Schedule as Schedule, type context$1_ScheduleRequest as ScheduleRequest, type context$1_ScheduleResponse as ScheduleResponse, context$1_ScheduleStatus as ScheduleStatus, type context$1_ScheduledAction as ScheduledAction, type context$1_ScheduledStatusInfo as ScheduledStatusInfo, type context$1_Scheduler as Scheduler, type context$1_Service as Service, type context$1_ServiceMapping as ServiceMapping, type context$1_SimpleDelay as SimpleDelay, type context$1_SpiAction as SpiAction, type context$1_StartedStatusInfo as StartedStatusInfo, type context$1_StartedStatusInfoAppDefinedActionInfo as StartedStatusInfoAppDefinedActionInfo, type context$1_StartedStatusInfoTypeInfoOneOf as StartedStatusInfoTypeInfoOneOf, Status$1 as Status, type context$1_SwitchFilter as SwitchFilter, type context$1_SystemHelper as SystemHelper, type context$1_SystemHelperHelperOneOf as SystemHelperHelperOneOf, context$1_Target as Target, TimeUnit$1 as TimeUnit, type Trigger$1 as Trigger, type context$1_TriggerInfo as TriggerInfo, Type$1 as Type, context$1_Units as Units, type context$1_UpdatePendingSchedulesPayloadRequest as UpdatePendingSchedulesPayloadRequest, type context$1_UpdatePendingSchedulesPayloadResponse as UpdatePendingSchedulesPayloadResponse, type context$1_V1RunAutomationRequest as V1RunAutomationRequest, type context$1_V1RunAutomationRequestIdentifierOneOf as V1RunAutomationRequestIdentifierOneOf, type context$1_V1RunAutomationResponse as V1RunAutomationResponse, WebhookIdentityType$1 as WebhookIdentityType, type context$1__publicOnActivationStatusChangedType as _publicOnActivationStatusChangedType, context$1_bulkCancelEvent as bulkCancelEvent, context$1_bulkReportEvent as bulkReportEvent, context$1_cancelEvent as cancelEvent, context$1_onActivationStatusChanged as onActivationStatusChanged, onActivationStatusChanged$1 as publicOnActivationStatusChanged, context$1_reportEvent as reportEvent };
|
|
4319
|
+
}
|
|
4320
|
+
|
|
4321
|
+
type HostModule<T, H extends Host> = {
|
|
4322
|
+
__type: 'host';
|
|
4323
|
+
create(host: H): T;
|
|
4324
|
+
};
|
|
4325
|
+
type HostModuleAPI<T extends HostModule<any, any>> = T extends HostModule<infer U, any> ? U : never;
|
|
4326
|
+
type Host<Environment = unknown> = {
|
|
4327
|
+
channel: {
|
|
4328
|
+
observeState(callback: (props: unknown, environment: Environment) => unknown): {
|
|
4329
|
+
disconnect: () => void;
|
|
4330
|
+
} | Promise<{
|
|
4331
|
+
disconnect: () => void;
|
|
4332
|
+
}>;
|
|
4333
|
+
};
|
|
4334
|
+
environment?: Environment;
|
|
4335
|
+
/**
|
|
4336
|
+
* Optional bast url to use for API requests, for example `www.wixapis.com`
|
|
4337
|
+
*/
|
|
4338
|
+
apiBaseUrl?: string;
|
|
4339
|
+
/**
|
|
4340
|
+
* Possible data to be provided by every host, for cross cutting concerns
|
|
4341
|
+
* like internationalization, billing, etc.
|
|
4342
|
+
*/
|
|
4343
|
+
essentials?: {
|
|
4344
|
+
/**
|
|
4345
|
+
* The language of the currently viewed session
|
|
4346
|
+
*/
|
|
4347
|
+
language?: string;
|
|
4348
|
+
/**
|
|
4349
|
+
* The locale of the currently viewed session
|
|
4350
|
+
*/
|
|
4351
|
+
locale?: string;
|
|
4352
|
+
/**
|
|
4353
|
+
* Any headers that should be passed through to the API requests
|
|
4354
|
+
*/
|
|
4355
|
+
passThroughHeaders?: Record<string, string>;
|
|
4356
|
+
};
|
|
4357
|
+
};
|
|
4358
|
+
|
|
4359
|
+
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
4360
|
+
interface HttpClient {
|
|
4361
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
4362
|
+
fetchWithAuth: typeof fetch;
|
|
4363
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
4364
|
+
getActiveToken?: () => string | undefined;
|
|
4365
|
+
}
|
|
4366
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
4367
|
+
type HttpResponse<T = any> = {
|
|
4368
|
+
data: T;
|
|
4369
|
+
status: number;
|
|
4370
|
+
statusText: string;
|
|
4371
|
+
headers: any;
|
|
4372
|
+
request?: any;
|
|
4373
|
+
};
|
|
4374
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
|
4375
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
4376
|
+
url: string;
|
|
4377
|
+
data?: Data;
|
|
4378
|
+
params?: URLSearchParams;
|
|
4379
|
+
} & APIMetadata;
|
|
4380
|
+
type APIMetadata = {
|
|
4381
|
+
methodFqn?: string;
|
|
4382
|
+
entityFqdn?: string;
|
|
4383
|
+
packageName?: string;
|
|
4384
|
+
};
|
|
4385
|
+
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
4386
|
+
type EventDefinition$1<Payload = unknown, Type extends string = string> = {
|
|
4387
|
+
__type: 'event-definition';
|
|
4388
|
+
type: Type;
|
|
4389
|
+
isDomainEvent?: boolean;
|
|
4390
|
+
transformations?: (envelope: unknown) => Payload;
|
|
4391
|
+
__payload: Payload;
|
|
4392
|
+
};
|
|
4393
|
+
declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
|
|
4394
|
+
type EventHandler$1<T extends EventDefinition$1> = (payload: T['__payload']) => void | Promise<void>;
|
|
4395
|
+
type BuildEventDefinition$1<T extends EventDefinition$1<any, string>> = (handler: EventHandler$1<T>) => void;
|
|
4396
|
+
|
|
4397
|
+
type ServicePluginMethodInput = {
|
|
4398
|
+
request: any;
|
|
4399
|
+
metadata: any;
|
|
4400
|
+
};
|
|
4401
|
+
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
4402
|
+
type ServicePluginMethodMetadata = {
|
|
4403
|
+
name: string;
|
|
4404
|
+
primaryHttpMappingPath: string;
|
|
4405
|
+
transformations: {
|
|
4406
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
4407
|
+
toREST: (...args: unknown[]) => unknown;
|
|
4408
|
+
};
|
|
4409
|
+
};
|
|
4410
|
+
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
4411
|
+
__type: 'service-plugin-definition';
|
|
4412
|
+
componentType: string;
|
|
4413
|
+
methods: ServicePluginMethodMetadata[];
|
|
4414
|
+
__contract: Contract;
|
|
4415
|
+
};
|
|
4416
|
+
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
4417
|
+
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
4418
|
+
declare const SERVICE_PLUGIN_ERROR_TYPE = "wix_spi_error";
|
|
4419
|
+
|
|
4420
|
+
type RequestContext = {
|
|
4421
|
+
isSSR: boolean;
|
|
4422
|
+
host: string;
|
|
4423
|
+
protocol?: string;
|
|
4424
|
+
};
|
|
4425
|
+
type ResponseTransformer = (data: any, headers?: any) => any;
|
|
4426
|
+
/**
|
|
4427
|
+
* Ambassador request options types are copied mostly from AxiosRequestConfig.
|
|
4428
|
+
* They are copied and not imported to reduce the amount of dependencies (to reduce install time).
|
|
4429
|
+
* https://github.com/axios/axios/blob/3f53eb6960f05a1f88409c4b731a40de595cb825/index.d.ts#L307-L315
|
|
4430
|
+
*/
|
|
4431
|
+
type Method = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
4432
|
+
type AmbassadorRequestOptions<T = any> = {
|
|
4433
|
+
_?: T;
|
|
4434
|
+
url?: string;
|
|
4435
|
+
method?: Method;
|
|
4436
|
+
params?: any;
|
|
4437
|
+
data?: any;
|
|
4438
|
+
transformResponse?: ResponseTransformer | ResponseTransformer[];
|
|
4439
|
+
};
|
|
4440
|
+
type AmbassadorFactory<Request, Response> = (payload: Request) => ((context: RequestContext) => AmbassadorRequestOptions<Response>) & {
|
|
4441
|
+
__isAmbassador: boolean;
|
|
4442
|
+
};
|
|
4443
|
+
type AmbassadorFunctionDescriptor<Request = any, Response = any> = AmbassadorFactory<Request, Response>;
|
|
4444
|
+
type BuildAmbassadorFunction<T extends AmbassadorFunctionDescriptor> = T extends AmbassadorFunctionDescriptor<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
4445
|
+
|
|
4446
|
+
declare global {
|
|
4447
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
4448
|
+
interface SymbolConstructor {
|
|
4449
|
+
readonly observable: symbol;
|
|
4450
|
+
}
|
|
4451
|
+
}
|
|
4452
|
+
|
|
4453
|
+
declare const emptyObjectSymbol: unique symbol;
|
|
4454
|
+
|
|
4455
|
+
/**
|
|
4456
|
+
Represents a strictly empty plain object, the `{}` value.
|
|
4457
|
+
|
|
4458
|
+
When you annotate something as the type `{}`, it can be anything except `null` and `undefined`. This means that you cannot use `{}` to represent an empty plain object ([read more](https://stackoverflow.com/questions/47339869/typescript-empty-object-and-any-difference/52193484#52193484)).
|
|
4459
|
+
|
|
4460
|
+
@example
|
|
4461
|
+
```
|
|
4462
|
+
import type {EmptyObject} from 'type-fest';
|
|
4463
|
+
|
|
4464
|
+
// The following illustrates the problem with `{}`.
|
|
4465
|
+
const foo1: {} = {}; // Pass
|
|
4466
|
+
const foo2: {} = []; // Pass
|
|
4467
|
+
const foo3: {} = 42; // Pass
|
|
4468
|
+
const foo4: {} = {a: 1}; // Pass
|
|
4469
|
+
|
|
4470
|
+
// With `EmptyObject` only the first case is valid.
|
|
4471
|
+
const bar1: EmptyObject = {}; // Pass
|
|
4472
|
+
const bar2: EmptyObject = 42; // Fail
|
|
4473
|
+
const bar3: EmptyObject = []; // Fail
|
|
4474
|
+
const bar4: EmptyObject = {a: 1}; // Fail
|
|
4475
|
+
```
|
|
4476
|
+
|
|
4477
|
+
Unfortunately, `Record<string, never>`, `Record<keyof any, never>` and `Record<never, never>` do not work. See {@link https://github.com/sindresorhus/type-fest/issues/395 #395}.
|
|
4478
|
+
|
|
4479
|
+
@category Object
|
|
4480
|
+
*/
|
|
4481
|
+
type EmptyObject = {[emptyObjectSymbol]?: never};
|
|
4482
|
+
|
|
4483
|
+
/**
|
|
4484
|
+
Returns a boolean for whether the two given types are equal.
|
|
4485
|
+
|
|
4486
|
+
@link https://github.com/microsoft/TypeScript/issues/27024#issuecomment-421529650
|
|
4487
|
+
@link https://stackoverflow.com/questions/68961864/how-does-the-equals-work-in-typescript/68963796#68963796
|
|
4488
|
+
|
|
4489
|
+
Use-cases:
|
|
4490
|
+
- If you want to make a conditional branch based on the result of a comparison of two types.
|
|
4491
|
+
|
|
4492
|
+
@example
|
|
4493
|
+
```
|
|
4494
|
+
import type {IsEqual} from 'type-fest';
|
|
4495
|
+
|
|
4496
|
+
// This type returns a boolean for whether the given array includes the given item.
|
|
4497
|
+
// `IsEqual` is used to compare the given array at position 0 and the given item and then return true if they are equal.
|
|
4498
|
+
type Includes<Value extends readonly any[], Item> =
|
|
4499
|
+
Value extends readonly [Value[0], ...infer rest]
|
|
4500
|
+
? IsEqual<Value[0], Item> extends true
|
|
4501
|
+
? true
|
|
4502
|
+
: Includes<rest, Item>
|
|
4503
|
+
: false;
|
|
4504
|
+
```
|
|
4505
|
+
|
|
4506
|
+
@category Type Guard
|
|
4507
|
+
@category Utilities
|
|
4508
|
+
*/
|
|
4509
|
+
type IsEqual<A, B> =
|
|
4510
|
+
(<G>() => G extends A ? 1 : 2) extends
|
|
4511
|
+
(<G>() => G extends B ? 1 : 2)
|
|
4512
|
+
? true
|
|
4513
|
+
: false;
|
|
4514
|
+
|
|
4515
|
+
/**
|
|
4516
|
+
Filter out keys from an object.
|
|
4517
|
+
|
|
4518
|
+
Returns `never` if `Exclude` is strictly equal to `Key`.
|
|
4519
|
+
Returns `never` if `Key` extends `Exclude`.
|
|
4520
|
+
Returns `Key` otherwise.
|
|
4521
|
+
|
|
4522
|
+
@example
|
|
4523
|
+
```
|
|
4524
|
+
type Filtered = Filter<'foo', 'foo'>;
|
|
4525
|
+
//=> never
|
|
4526
|
+
```
|
|
4527
|
+
|
|
4528
|
+
@example
|
|
4529
|
+
```
|
|
4530
|
+
type Filtered = Filter<'bar', string>;
|
|
4531
|
+
//=> never
|
|
4532
|
+
```
|
|
4533
|
+
|
|
4534
|
+
@example
|
|
4535
|
+
```
|
|
4536
|
+
type Filtered = Filter<'bar', 'foo'>;
|
|
4537
|
+
//=> 'bar'
|
|
4538
|
+
```
|
|
4539
|
+
|
|
4540
|
+
@see {Except}
|
|
4541
|
+
*/
|
|
4542
|
+
type Filter$1<KeyType, ExcludeType> = IsEqual<KeyType, ExcludeType> extends true ? never : (KeyType extends ExcludeType ? never : KeyType);
|
|
4543
|
+
|
|
4544
|
+
type ExceptOptions = {
|
|
4545
|
+
/**
|
|
4546
|
+
Disallow assigning non-specified properties.
|
|
4547
|
+
|
|
4548
|
+
Note that any omitted properties in the resulting type will be present in autocomplete as `undefined`.
|
|
4549
|
+
|
|
4550
|
+
@default false
|
|
4551
|
+
*/
|
|
4552
|
+
requireExactProps?: boolean;
|
|
4553
|
+
};
|
|
4554
|
+
|
|
4555
|
+
/**
|
|
4556
|
+
Create a type from an object type without certain keys.
|
|
4557
|
+
|
|
4558
|
+
We recommend setting the `requireExactProps` option to `true`.
|
|
4559
|
+
|
|
4560
|
+
This type is a stricter version of [`Omit`](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-5.html#the-omit-helper-type). The `Omit` type does not restrict the omitted keys to be keys present on the given type, while `Except` does. The benefits of a stricter type are avoiding typos and allowing the compiler to pick up on rename refactors automatically.
|
|
4561
|
+
|
|
4562
|
+
This type was proposed to the TypeScript team, which declined it, saying they prefer that libraries implement stricter versions of the built-in types ([microsoft/TypeScript#30825](https://github.com/microsoft/TypeScript/issues/30825#issuecomment-523668235)).
|
|
4563
|
+
|
|
4564
|
+
@example
|
|
4565
|
+
```
|
|
4566
|
+
import type {Except} from 'type-fest';
|
|
4567
|
+
|
|
4568
|
+
type Foo = {
|
|
4569
|
+
a: number;
|
|
4570
|
+
b: string;
|
|
4571
|
+
};
|
|
4572
|
+
|
|
4573
|
+
type FooWithoutA = Except<Foo, 'a'>;
|
|
4574
|
+
//=> {b: string}
|
|
4575
|
+
|
|
4576
|
+
const fooWithoutA: FooWithoutA = {a: 1, b: '2'};
|
|
4577
|
+
//=> errors: 'a' does not exist in type '{ b: string; }'
|
|
4578
|
+
|
|
4579
|
+
type FooWithoutB = Except<Foo, 'b', {requireExactProps: true}>;
|
|
4580
|
+
//=> {a: number} & Partial<Record<"b", never>>
|
|
4581
|
+
|
|
4582
|
+
const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
|
|
4583
|
+
//=> errors at 'b': Type 'string' is not assignable to type 'undefined'.
|
|
4584
|
+
```
|
|
4585
|
+
|
|
4586
|
+
@category Object
|
|
4587
|
+
*/
|
|
4588
|
+
type Except<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions = {requireExactProps: false}> = {
|
|
4589
|
+
[KeyType in keyof ObjectType as Filter$1<KeyType, KeysType>]: ObjectType[KeyType];
|
|
4590
|
+
} & (Options['requireExactProps'] extends true
|
|
4591
|
+
? Partial<Record<KeysType, never>>
|
|
4592
|
+
: {});
|
|
4593
|
+
|
|
4594
|
+
/**
|
|
4595
|
+
Extract the keys from a type where the value type of the key extends the given `Condition`.
|
|
4596
|
+
|
|
4597
|
+
Internally this is used for the `ConditionalPick` and `ConditionalExcept` types.
|
|
4598
|
+
|
|
4599
|
+
@example
|
|
4600
|
+
```
|
|
4601
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
4602
|
+
|
|
4603
|
+
interface Example {
|
|
4604
|
+
a: string;
|
|
4605
|
+
b: string | number;
|
|
4606
|
+
c?: string;
|
|
4607
|
+
d: {};
|
|
4608
|
+
}
|
|
4609
|
+
|
|
4610
|
+
type StringKeysOnly = ConditionalKeys<Example, string>;
|
|
4611
|
+
//=> 'a'
|
|
4612
|
+
```
|
|
4613
|
+
|
|
4614
|
+
To support partial types, make sure your `Condition` is a union of undefined (for example, `string | undefined`) as demonstrated below.
|
|
4615
|
+
|
|
4616
|
+
@example
|
|
4617
|
+
```
|
|
4618
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
4619
|
+
|
|
4620
|
+
type StringKeysAndUndefined = ConditionalKeys<Example, string | undefined>;
|
|
4621
|
+
//=> 'a' | 'c'
|
|
4622
|
+
```
|
|
4623
|
+
|
|
4624
|
+
@category Object
|
|
4625
|
+
*/
|
|
4626
|
+
type ConditionalKeys<Base, Condition> = NonNullable<
|
|
4627
|
+
// Wrap in `NonNullable` to strip away the `undefined` type from the produced union.
|
|
4628
|
+
{
|
|
4629
|
+
// Map through all the keys of the given base type.
|
|
4630
|
+
[Key in keyof Base]:
|
|
4631
|
+
// Pick only keys with types extending the given `Condition` type.
|
|
4632
|
+
Base[Key] extends Condition
|
|
4633
|
+
// Retain this key since the condition passes.
|
|
4634
|
+
? Key
|
|
4635
|
+
// Discard this key since the condition fails.
|
|
4636
|
+
: never;
|
|
4637
|
+
|
|
4638
|
+
// Convert the produced object into a union type of the keys which passed the conditional test.
|
|
4639
|
+
}[keyof Base]
|
|
4640
|
+
>;
|
|
4641
|
+
|
|
4642
|
+
/**
|
|
4643
|
+
Exclude keys from a shape that matches the given `Condition`.
|
|
4644
|
+
|
|
4645
|
+
This is useful when you want to create a new type with a specific set of keys from a shape. For example, you might want to exclude all the primitive properties from a class and form a new shape containing everything but the primitive properties.
|
|
4646
|
+
|
|
4647
|
+
@example
|
|
4648
|
+
```
|
|
4649
|
+
import type {Primitive, ConditionalExcept} from 'type-fest';
|
|
4650
|
+
|
|
4651
|
+
class Awesome {
|
|
4652
|
+
name: string;
|
|
4653
|
+
successes: number;
|
|
4654
|
+
failures: bigint;
|
|
4655
|
+
|
|
4656
|
+
run() {}
|
|
4657
|
+
}
|
|
4658
|
+
|
|
4659
|
+
type ExceptPrimitivesFromAwesome = ConditionalExcept<Awesome, Primitive>;
|
|
4660
|
+
//=> {run: () => void}
|
|
4661
|
+
```
|
|
4662
|
+
|
|
4663
|
+
@example
|
|
4664
|
+
```
|
|
4665
|
+
import type {ConditionalExcept} from 'type-fest';
|
|
4666
|
+
|
|
4667
|
+
interface Example {
|
|
4668
|
+
a: string;
|
|
4669
|
+
b: string | number;
|
|
4670
|
+
c: () => void;
|
|
4671
|
+
d: {};
|
|
3507
4672
|
}
|
|
3508
4673
|
|
|
4674
|
+
type NonStringKeysOnly = ConditionalExcept<Example, string>;
|
|
4675
|
+
//=> {b: string | number; c: () => void; d: {}}
|
|
4676
|
+
```
|
|
4677
|
+
|
|
4678
|
+
@category Object
|
|
4679
|
+
*/
|
|
4680
|
+
type ConditionalExcept<Base, Condition> = Except<
|
|
4681
|
+
Base,
|
|
4682
|
+
ConditionalKeys<Base, Condition>
|
|
4683
|
+
>;
|
|
4684
|
+
|
|
4685
|
+
/**
|
|
4686
|
+
* Descriptors are objects that describe the API of a module, and the module
|
|
4687
|
+
* can either be a REST module or a host module.
|
|
4688
|
+
* This type is recursive, so it can describe nested modules.
|
|
4689
|
+
*/
|
|
4690
|
+
type Descriptors = RESTFunctionDescriptor | AmbassadorFunctionDescriptor | HostModule<any, any> | EventDefinition$1<any> | ServicePluginDefinition<any> | {
|
|
4691
|
+
[key: string]: Descriptors | PublicMetadata | any;
|
|
4692
|
+
};
|
|
4693
|
+
/**
|
|
4694
|
+
* This type takes in a descriptors object of a certain Host (including an `unknown` host)
|
|
4695
|
+
* and returns an object with the same structure, but with all descriptors replaced with their API.
|
|
4696
|
+
* Any non-descriptor properties are removed from the returned object, including descriptors that
|
|
4697
|
+
* do not match the given host (as they will not work with the given host).
|
|
4698
|
+
*/
|
|
4699
|
+
type BuildDescriptors<T extends Descriptors, H extends Host<any> | undefined, Depth extends number = 5> = {
|
|
4700
|
+
done: T;
|
|
4701
|
+
recurse: T extends {
|
|
4702
|
+
__type: typeof SERVICE_PLUGIN_ERROR_TYPE;
|
|
4703
|
+
} ? never : T extends AmbassadorFunctionDescriptor ? BuildAmbassadorFunction<T> : T extends RESTFunctionDescriptor ? BuildRESTFunction<T> : T extends EventDefinition$1<any> ? BuildEventDefinition$1<T> : T extends ServicePluginDefinition<any> ? BuildServicePluginDefinition<T> : T extends HostModule<any, any> ? HostModuleAPI<T> : ConditionalExcept<{
|
|
4704
|
+
[Key in keyof T]: T[Key] extends Descriptors ? BuildDescriptors<T[Key], H, [
|
|
4705
|
+
-1,
|
|
4706
|
+
0,
|
|
4707
|
+
1,
|
|
4708
|
+
2,
|
|
4709
|
+
3,
|
|
4710
|
+
4,
|
|
4711
|
+
5
|
|
4712
|
+
][Depth]> : never;
|
|
4713
|
+
}, EmptyObject>;
|
|
4714
|
+
}[Depth extends -1 ? 'done' : 'recurse'];
|
|
4715
|
+
type PublicMetadata = {
|
|
4716
|
+
PACKAGE_NAME?: string;
|
|
4717
|
+
};
|
|
4718
|
+
|
|
4719
|
+
declare global {
|
|
4720
|
+
interface ContextualClient {
|
|
4721
|
+
}
|
|
4722
|
+
}
|
|
4723
|
+
/**
|
|
4724
|
+
* A type used to create concerete types from SDK descriptors in
|
|
4725
|
+
* case a contextual client is available.
|
|
4726
|
+
*/
|
|
4727
|
+
type MaybeContext<T extends Descriptors> = globalThis.ContextualClient extends {
|
|
4728
|
+
host: Host;
|
|
4729
|
+
} ? BuildDescriptors<T, globalThis.ContextualClient['host']> : T;
|
|
4730
|
+
|
|
3509
4731
|
interface Automation extends AutomationOriginInfoOneOf {
|
|
3510
4732
|
/** Application info */
|
|
3511
4733
|
applicationInfo?: ApplicationOrigin;
|
|
@@ -4637,6 +5859,8 @@ interface ValidateAutomationResponse {
|
|
|
4637
5859
|
triggerValidationErrors?: TriggerValidationError[];
|
|
4638
5860
|
/** List of validation information for the automation actions. */
|
|
4639
5861
|
actionValidationInfo?: ActionValidationInfo[];
|
|
5862
|
+
/** List of additional validation errors for the automation */
|
|
5863
|
+
automationValidationErrors?: AutomationValidationError[];
|
|
4640
5864
|
}
|
|
4641
5865
|
interface TriggerValidationError extends TriggerValidationErrorErrorOneOf {
|
|
4642
5866
|
/** Trigger configuration error. */
|
|
@@ -4744,6 +5968,35 @@ declare enum ActionErrorType {
|
|
|
4744
5968
|
MAPPING_SCHEMA_MISMATCH = "MAPPING_SCHEMA_MISMATCH",
|
|
4745
5969
|
MAPPING_VARIABLE_MISSING_FROM_SCHEMA = "MAPPING_VARIABLE_MISSING_FROM_SCHEMA"
|
|
4746
5970
|
}
|
|
5971
|
+
interface AutomationValidationError extends AutomationValidationErrorErrorOneOf {
|
|
5972
|
+
/** Automation configuration error. */
|
|
5973
|
+
configurationError?: AutomationConfigurationError;
|
|
5974
|
+
/** Provider configuration error. */
|
|
5975
|
+
providerConfigurationError?: ProviderConfigurationError;
|
|
5976
|
+
/** Validation error type. */
|
|
5977
|
+
errorType?: AutomationValidationErrorValidationErrorType;
|
|
5978
|
+
/** Validation error severity */
|
|
5979
|
+
severity?: ValidationErrorSeverity;
|
|
5980
|
+
}
|
|
5981
|
+
/** @oneof */
|
|
5982
|
+
interface AutomationValidationErrorErrorOneOf {
|
|
5983
|
+
/** Automation configuration error. */
|
|
5984
|
+
configurationError?: AutomationConfigurationError;
|
|
5985
|
+
/** Provider configuration error. */
|
|
5986
|
+
providerConfigurationError?: ProviderConfigurationError;
|
|
5987
|
+
}
|
|
5988
|
+
declare enum AutomationValidationErrorValidationErrorType {
|
|
5989
|
+
UNKNOWN_VALIDATION_ERROR_TYPE = "UNKNOWN_VALIDATION_ERROR_TYPE",
|
|
5990
|
+
CONFIGURATION_ERROR = "CONFIGURATION_ERROR",
|
|
5991
|
+
PROVIDER_ERROR = "PROVIDER_ERROR"
|
|
5992
|
+
}
|
|
5993
|
+
interface AutomationConfigurationError {
|
|
5994
|
+
/** Automation error type. */
|
|
5995
|
+
errorType?: AutomationErrorType;
|
|
5996
|
+
}
|
|
5997
|
+
declare enum AutomationErrorType {
|
|
5998
|
+
UNKNOWN_AUTOMATION_ERROR_TYPE = "UNKNOWN_AUTOMATION_ERROR_TYPE"
|
|
5999
|
+
}
|
|
4747
6000
|
interface GetAutomationActionSchemaRequest {
|
|
4748
6001
|
/** Automation ID */
|
|
4749
6002
|
automationId: string;
|
|
@@ -4973,10 +6226,20 @@ interface ActionValidationInfoNonNullableFields {
|
|
|
4973
6226
|
actionKey: string;
|
|
4974
6227
|
validationErrors: ActionValidationErrorNonNullableFields[];
|
|
4975
6228
|
}
|
|
6229
|
+
interface AutomationConfigurationErrorNonNullableFields {
|
|
6230
|
+
errorType: AutomationErrorType;
|
|
6231
|
+
}
|
|
6232
|
+
interface AutomationValidationErrorNonNullableFields {
|
|
6233
|
+
configurationError?: AutomationConfigurationErrorNonNullableFields;
|
|
6234
|
+
providerConfigurationError?: ProviderConfigurationErrorNonNullableFields;
|
|
6235
|
+
errorType: AutomationValidationErrorValidationErrorType;
|
|
6236
|
+
severity: ValidationErrorSeverity;
|
|
6237
|
+
}
|
|
4976
6238
|
interface ValidateAutomationResponseNonNullableFields {
|
|
4977
6239
|
valid: boolean;
|
|
4978
6240
|
triggerValidationErrors: TriggerValidationErrorNonNullableFields[];
|
|
4979
6241
|
actionValidationInfo: ActionValidationInfoNonNullableFields[];
|
|
6242
|
+
automationValidationErrors: AutomationValidationErrorNonNullableFields[];
|
|
4980
6243
|
}
|
|
4981
6244
|
interface PlanNonNullableFields {
|
|
4982
6245
|
_id: string;
|
|
@@ -5434,29 +6697,47 @@ interface GetActionsQuotaInfoSignature {
|
|
|
5434
6697
|
*/
|
|
5435
6698
|
(): Promise<GetActionsQuotaInfoResponse & GetActionsQuotaInfoResponseNonNullableFields>;
|
|
5436
6699
|
}
|
|
5437
|
-
declare const onAutomationCreated$1: EventDefinition<AutomationCreatedEnvelope, "wix.automations.v2.automation_created">;
|
|
5438
|
-
declare const onAutomationUpdated$1: EventDefinition<AutomationUpdatedEnvelope, "wix.automations.v2.automation_updated">;
|
|
5439
|
-
declare const onAutomationDeleted$1: EventDefinition<AutomationDeletedEnvelope, "wix.automations.v2.automation_deleted">;
|
|
5440
|
-
declare const onAutomationUpdatedWithPreviousEntity$1: EventDefinition<AutomationUpdatedWithPreviousEntityEnvelope, "wix.automations.v2.automation_updated_with_previous_entity">;
|
|
5441
|
-
declare const onAutomationDeletedWithEntity$1: EventDefinition<AutomationDeletedWithEntityEnvelope, "wix.automations.v2.automation_deleted_with_entity">;
|
|
6700
|
+
declare const onAutomationCreated$1: EventDefinition$1<AutomationCreatedEnvelope, "wix.automations.v2.automation_created">;
|
|
6701
|
+
declare const onAutomationUpdated$1: EventDefinition$1<AutomationUpdatedEnvelope, "wix.automations.v2.automation_updated">;
|
|
6702
|
+
declare const onAutomationDeleted$1: EventDefinition$1<AutomationDeletedEnvelope, "wix.automations.v2.automation_deleted">;
|
|
6703
|
+
declare const onAutomationUpdatedWithPreviousEntity$1: EventDefinition$1<AutomationUpdatedWithPreviousEntityEnvelope, "wix.automations.v2.automation_updated_with_previous_entity">;
|
|
6704
|
+
declare const onAutomationDeletedWithEntity$1: EventDefinition$1<AutomationDeletedWithEntityEnvelope, "wix.automations.v2.automation_deleted_with_entity">;
|
|
6705
|
+
|
|
6706
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
6707
|
+
__type: 'event-definition';
|
|
6708
|
+
type: Type;
|
|
6709
|
+
isDomainEvent?: boolean;
|
|
6710
|
+
transformations?: (envelope: unknown) => Payload;
|
|
6711
|
+
__payload: Payload;
|
|
6712
|
+
};
|
|
6713
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
6714
|
+
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
6715
|
+
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
6716
|
+
|
|
6717
|
+
declare global {
|
|
6718
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
6719
|
+
interface SymbolConstructor {
|
|
6720
|
+
readonly observable: symbol;
|
|
6721
|
+
}
|
|
6722
|
+
}
|
|
5442
6723
|
|
|
5443
6724
|
declare function createEventModule<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
5444
6725
|
|
|
5445
|
-
declare const createAutomation: BuildRESTFunction<typeof createAutomation$1> & typeof createAutomation$1
|
|
5446
|
-
declare const getAutomation: BuildRESTFunction<typeof getAutomation$1> & typeof getAutomation$1
|
|
5447
|
-
declare const updateAutomation: BuildRESTFunction<typeof updateAutomation$1> & typeof updateAutomation$1
|
|
5448
|
-
declare const deleteAutomation: BuildRESTFunction<typeof deleteAutomation$1> & typeof deleteAutomation$1
|
|
5449
|
-
declare const bulkDeleteAutomations: BuildRESTFunction<typeof bulkDeleteAutomations$1> & typeof bulkDeleteAutomations$1
|
|
5450
|
-
declare const queryAutomations: BuildRESTFunction<typeof queryAutomations$1> & typeof queryAutomations$1
|
|
5451
|
-
declare const copyAutomation: BuildRESTFunction<typeof copyAutomation$1> & typeof copyAutomation$1
|
|
5452
|
-
declare const createDraftAutomation: BuildRESTFunction<typeof createDraftAutomation$1> & typeof createDraftAutomation$1
|
|
5453
|
-
declare const getOrCreateDraftAutomation: BuildRESTFunction<typeof getOrCreateDraftAutomation$1> & typeof getOrCreateDraftAutomation$1
|
|
5454
|
-
declare const updateDraftAutomation: BuildRESTFunction<typeof updateDraftAutomation$1> & typeof updateDraftAutomation$1
|
|
5455
|
-
declare const queryAutomationsWithDrafts: BuildRESTFunction<typeof queryAutomationsWithDrafts$1> & typeof queryAutomationsWithDrafts$1
|
|
5456
|
-
declare const deleteDraftAutomation: BuildRESTFunction<typeof deleteDraftAutomation$1> & typeof deleteDraftAutomation$1
|
|
5457
|
-
declare const validateAutomation: BuildRESTFunction<typeof validateAutomation$1> & typeof validateAutomation$1
|
|
5458
|
-
declare const getAutomationActionSchema: BuildRESTFunction<typeof getAutomationActionSchema$1> & typeof getAutomationActionSchema$1
|
|
5459
|
-
declare const getActionsQuotaInfo: BuildRESTFunction<typeof getActionsQuotaInfo$1> & typeof getActionsQuotaInfo$1
|
|
6726
|
+
declare const createAutomation: MaybeContext<BuildRESTFunction<typeof createAutomation$1> & typeof createAutomation$1>;
|
|
6727
|
+
declare const getAutomation: MaybeContext<BuildRESTFunction<typeof getAutomation$1> & typeof getAutomation$1>;
|
|
6728
|
+
declare const updateAutomation: MaybeContext<BuildRESTFunction<typeof updateAutomation$1> & typeof updateAutomation$1>;
|
|
6729
|
+
declare const deleteAutomation: MaybeContext<BuildRESTFunction<typeof deleteAutomation$1> & typeof deleteAutomation$1>;
|
|
6730
|
+
declare const bulkDeleteAutomations: MaybeContext<BuildRESTFunction<typeof bulkDeleteAutomations$1> & typeof bulkDeleteAutomations$1>;
|
|
6731
|
+
declare const queryAutomations: MaybeContext<BuildRESTFunction<typeof queryAutomations$1> & typeof queryAutomations$1>;
|
|
6732
|
+
declare const copyAutomation: MaybeContext<BuildRESTFunction<typeof copyAutomation$1> & typeof copyAutomation$1>;
|
|
6733
|
+
declare const createDraftAutomation: MaybeContext<BuildRESTFunction<typeof createDraftAutomation$1> & typeof createDraftAutomation$1>;
|
|
6734
|
+
declare const getOrCreateDraftAutomation: MaybeContext<BuildRESTFunction<typeof getOrCreateDraftAutomation$1> & typeof getOrCreateDraftAutomation$1>;
|
|
6735
|
+
declare const updateDraftAutomation: MaybeContext<BuildRESTFunction<typeof updateDraftAutomation$1> & typeof updateDraftAutomation$1>;
|
|
6736
|
+
declare const queryAutomationsWithDrafts: MaybeContext<BuildRESTFunction<typeof queryAutomationsWithDrafts$1> & typeof queryAutomationsWithDrafts$1>;
|
|
6737
|
+
declare const deleteDraftAutomation: MaybeContext<BuildRESTFunction<typeof deleteDraftAutomation$1> & typeof deleteDraftAutomation$1>;
|
|
6738
|
+
declare const validateAutomation: MaybeContext<BuildRESTFunction<typeof validateAutomation$1> & typeof validateAutomation$1>;
|
|
6739
|
+
declare const getAutomationActionSchema: MaybeContext<BuildRESTFunction<typeof getAutomationActionSchema$1> & typeof getAutomationActionSchema$1>;
|
|
6740
|
+
declare const getActionsQuotaInfo: MaybeContext<BuildRESTFunction<typeof getActionsQuotaInfo$1> & typeof getActionsQuotaInfo$1>;
|
|
5460
6741
|
|
|
5461
6742
|
type _publicOnAutomationCreatedType = typeof onAutomationCreated$1;
|
|
5462
6743
|
/** */
|
|
@@ -5499,14 +6780,21 @@ type context_AuditInfo = AuditInfo;
|
|
|
5499
6780
|
type context_AuditInfoIdOneOf = AuditInfoIdOneOf;
|
|
5500
6781
|
type context_Automation = Automation;
|
|
5501
6782
|
type context_AutomationConfiguration = AutomationConfiguration;
|
|
6783
|
+
type context_AutomationConfigurationError = AutomationConfigurationError;
|
|
5502
6784
|
type context_AutomationCreatedEnvelope = AutomationCreatedEnvelope;
|
|
5503
6785
|
type context_AutomationDeletedEnvelope = AutomationDeletedEnvelope;
|
|
5504
6786
|
type context_AutomationDeletedWithEntityEnvelope = AutomationDeletedWithEntityEnvelope;
|
|
6787
|
+
type context_AutomationErrorType = AutomationErrorType;
|
|
6788
|
+
declare const context_AutomationErrorType: typeof AutomationErrorType;
|
|
5505
6789
|
type context_AutomationNonNullableFields = AutomationNonNullableFields;
|
|
5506
6790
|
type context_AutomationOriginInfoOneOf = AutomationOriginInfoOneOf;
|
|
5507
6791
|
type context_AutomationSettings = AutomationSettings;
|
|
5508
6792
|
type context_AutomationUpdatedEnvelope = AutomationUpdatedEnvelope;
|
|
5509
6793
|
type context_AutomationUpdatedWithPreviousEntityEnvelope = AutomationUpdatedWithPreviousEntityEnvelope;
|
|
6794
|
+
type context_AutomationValidationError = AutomationValidationError;
|
|
6795
|
+
type context_AutomationValidationErrorErrorOneOf = AutomationValidationErrorErrorOneOf;
|
|
6796
|
+
type context_AutomationValidationErrorValidationErrorType = AutomationValidationErrorValidationErrorType;
|
|
6797
|
+
declare const context_AutomationValidationErrorValidationErrorType: typeof AutomationValidationErrorValidationErrorType;
|
|
5510
6798
|
type context_AutomationsQueryBuilder = AutomationsQueryBuilder;
|
|
5511
6799
|
type context_AutomationsQueryResult = AutomationsQueryResult;
|
|
5512
6800
|
type context_BaseEventMetadata = BaseEventMetadata;
|
|
@@ -5700,7 +6988,7 @@ declare const context_updateAutomation: typeof updateAutomation;
|
|
|
5700
6988
|
declare const context_updateDraftAutomation: typeof updateDraftAutomation;
|
|
5701
6989
|
declare const context_validateAutomation: typeof validateAutomation;
|
|
5702
6990
|
declare namespace context {
|
|
5703
|
-
export { type context_Action as Action, type context_ActionConfigurationError as ActionConfigurationError, context_ActionErrorType as ActionErrorType, type context_ActionEvent as ActionEvent, type context_ActionInfoOneOf as ActionInfoOneOf, type context_ActionProviderQuotaInfo as ActionProviderQuotaInfo, type context_ActionQuotaInfo as ActionQuotaInfo, type context_ActionSettings as ActionSettings, type context_ActionValidationError as ActionValidationError, type context_ActionValidationErrorErrorOneOf as ActionValidationErrorErrorOneOf, type context_ActionValidationInfo as ActionValidationInfo, type context_AdditionalInfo as AdditionalInfo, type context_AppDefinedAction as AppDefinedAction, type context_ApplicationError as ApplicationError, type context_ApplicationOrigin as ApplicationOrigin, type context_Asset as Asset, type context_AuditInfo as AuditInfo, type context_AuditInfoIdOneOf as AuditInfoIdOneOf, type context_Automation as Automation, type context_AutomationConfiguration as AutomationConfiguration, type context_AutomationCreatedEnvelope as AutomationCreatedEnvelope, type context_AutomationDeletedEnvelope as AutomationDeletedEnvelope, type context_AutomationDeletedWithEntityEnvelope as AutomationDeletedWithEntityEnvelope, type context_AutomationNonNullableFields as AutomationNonNullableFields, type context_AutomationOriginInfoOneOf as AutomationOriginInfoOneOf, type context_AutomationSettings as AutomationSettings, type context_AutomationUpdatedEnvelope as AutomationUpdatedEnvelope, type context_AutomationUpdatedWithPreviousEntityEnvelope as AutomationUpdatedWithPreviousEntityEnvelope, type context_AutomationsQueryBuilder as AutomationsQueryBuilder, type context_AutomationsQueryResult as AutomationsQueryResult, type context_BaseEventMetadata as BaseEventMetadata, type context_BulkActionMetadata as BulkActionMetadata, type context_BulkDeleteAutomationsRequest as BulkDeleteAutomationsRequest, type context_BulkDeleteAutomationsResponse as BulkDeleteAutomationsResponse, type context_BulkDeleteAutomationsResponseNonNullableFields as BulkDeleteAutomationsResponseNonNullableFields, type context_BulkDeleteResult as BulkDeleteResult, type context_CTA as CTA, type context_CommonCursorPaging as CommonCursorPaging, type context_CommonCursorPagingMetadata as CommonCursorPagingMetadata, type context_CommonCursorQuery as CommonCursorQuery, type context_CommonCursorQueryPagingMethodOneOf as CommonCursorQueryPagingMethodOneOf, type context_CommonCursors as CommonCursors, context_CommonSortOrder as CommonSortOrder, type context_CommonSorting as CommonSorting, type context_ConditionAction as ConditionAction, type context_ConditionExpressionGroup as ConditionExpressionGroup, type context_CopyAutomationOptions as CopyAutomationOptions, type context_CopyAutomationRequest as CopyAutomationRequest, type context_CopyAutomationResponse as CopyAutomationResponse, type context_CopyAutomationResponseNonNullableFields as CopyAutomationResponseNonNullableFields, type context_CreateAutomationRequest as CreateAutomationRequest, type context_CreateAutomationResponse as CreateAutomationResponse, type context_CreateAutomationResponseNonNullableFields as CreateAutomationResponseNonNullableFields, type context_CreateDraftAutomationOptions as CreateDraftAutomationOptions, type context_CreateDraftAutomationRequest as CreateDraftAutomationRequest, type context_CreateDraftAutomationResponse as CreateDraftAutomationResponse, type context_CreateDraftAutomationResponseNonNullableFields as CreateDraftAutomationResponseNonNullableFields, type context_CreatePreinstalledAutomationRequest as CreatePreinstalledAutomationRequest, type context_CreatePreinstalledAutomationResponse as CreatePreinstalledAutomationResponse, type context_CursorPaging as CursorPaging, type context_CursorPagingMetadata as CursorPagingMetadata, type context_CursorQuery as CursorQuery, type context_CursorQueryPagingMethodOneOf as CursorQueryPagingMethodOneOf, type context_Cursors as Cursors, type context_DelayAction as DelayAction, type context_DeleteAutomationRequest as DeleteAutomationRequest, type context_DeleteAutomationResponse as DeleteAutomationResponse, type context_DeleteContext as DeleteContext, type context_DeleteDraftAutomationRequest as DeleteDraftAutomationRequest, type context_DeleteDraftAutomationResponse as DeleteDraftAutomationResponse, type context_DeletePreinstalledAutomationRequest as DeletePreinstalledAutomationRequest, type context_DeletePreinstalledAutomationResponse as DeletePreinstalledAutomationResponse, context_DeleteStatus as DeleteStatus, type context_DeletedWithEntity as DeletedWithEntity, type context_DomainEvent as DomainEvent, type context_DomainEventBodyOneOf as DomainEventBodyOneOf, type context_DraftInfo as DraftInfo, type context_DraftsInfo as DraftsInfo, type context_Empty as Empty, type context_EntityCreatedEvent as EntityCreatedEvent, type context_EntityDeletedEvent as EntityDeletedEvent, type context_EntityUpdatedEvent as EntityUpdatedEvent, type context_EventMetadata as EventMetadata, type context_Filter as Filter, type context_FutureDateActivationOffset as FutureDateActivationOffset, type context_GetActionsQuotaInfoRequest as GetActionsQuotaInfoRequest, type context_GetActionsQuotaInfoResponse as GetActionsQuotaInfoResponse, type context_GetActionsQuotaInfoResponseNonNullableFields as GetActionsQuotaInfoResponseNonNullableFields, type context_GetAutomationActionSchemaIdentifiers as GetAutomationActionSchemaIdentifiers, type context_GetAutomationActionSchemaRequest as GetAutomationActionSchemaRequest, type context_GetAutomationActionSchemaResponse as GetAutomationActionSchemaResponse, type context_GetAutomationOptions as GetAutomationOptions, type context_GetAutomationRequest as GetAutomationRequest, type context_GetAutomationResponse as GetAutomationResponse, type context_GetAutomationResponseNonNullableFields as GetAutomationResponseNonNullableFields, type context_GetAutomationRevisionRequest as GetAutomationRevisionRequest, type context_GetAutomationRevisionResponse as GetAutomationRevisionResponse, type context_GetOrCreateDraftAutomationRequest as GetOrCreateDraftAutomationRequest, type context_GetOrCreateDraftAutomationResponse as GetOrCreateDraftAutomationResponse, type context_GetOrCreateDraftAutomationResponseNonNullableFields as GetOrCreateDraftAutomationResponseNonNullableFields, type context_IdentificationData as IdentificationData, type context_IdentificationDataIdOneOf as IdentificationDataIdOneOf, type context_ItemMetadata as ItemMetadata, type context_MessageEnvelope as MessageEnvelope, type context_MetaSiteSpecialEvent as MetaSiteSpecialEvent, type context_MetaSiteSpecialEventPayloadOneOf as MetaSiteSpecialEventPayloadOneOf, context_Namespace as Namespace, type context_NamespaceChanged as NamespaceChanged, context_Operator as Operator, context_Origin as Origin, type context_OriginAutomationInfo as OriginAutomationInfo, type context_OutputAction as OutputAction, type context_Plan as Plan, type context_PreinstalledAutomationSpecInfo as PreinstalledAutomationSpecInfo, type context_PreinstalledOrigin as PreinstalledOrigin, type context_ProviderConfigurationError as ProviderConfigurationError, type context_PublishDraftAutomationRequest as PublishDraftAutomationRequest, type context_PublishDraftAutomationResponse as PublishDraftAutomationResponse, type context_QueryAutomationsRequest as QueryAutomationsRequest, type context_QueryAutomationsResponse as QueryAutomationsResponse, type context_QueryAutomationsResponseNonNullableFields as QueryAutomationsResponseNonNullableFields, type context_QueryAutomationsWithDraftsOptions as QueryAutomationsWithDraftsOptions, type context_QueryAutomationsWithDraftsRequest as QueryAutomationsWithDraftsRequest, type context_QueryAutomationsWithDraftsResponse as QueryAutomationsWithDraftsResponse, type context_QueryAutomationsWithDraftsResponseNonNullableFields as QueryAutomationsWithDraftsResponseNonNullableFields, type context_QueryPreinstalledAutomationsForAppRequest as QueryPreinstalledAutomationsForAppRequest, type context_QueryPreinstalledAutomationsForAppResponse as QueryPreinstalledAutomationsForAppResponse, type context_Quota as Quota, type context_QuotaInfo as QuotaInfo, type context_RateLimit as RateLimit, type context_RateLimitAction as RateLimitAction, type context_RestoreInfo as RestoreInfo, type context_ServiceProvisioned as ServiceProvisioned, type context_ServiceRemoved as ServiceRemoved, type context_SiteCreated as SiteCreated, context_SiteCreatedContext as SiteCreatedContext, type context_SiteDeleted as SiteDeleted, type context_SiteHardDeleted as SiteHardDeleted, type context_SiteMarkedAsTemplate as SiteMarkedAsTemplate, type context_SiteMarkedAsWixSite as SiteMarkedAsWixSite, type context_SitePublished as SitePublished, type context_SiteRenamed as SiteRenamed, type context_SiteTransferred as SiteTransferred, type context_SiteUndeleted as SiteUndeleted, type context_SiteUnpublished as SiteUnpublished, context_SortOrder as SortOrder, type context_Sorting as Sorting, context_State as State, context_Status as Status, type context_StudioAssigned as StudioAssigned, type context_StudioUnassigned as StudioUnassigned, context_TimeUnit as TimeUnit, type context_Trigger as Trigger, type context_TriggerConfigurationError as TriggerConfigurationError, context_TriggerErrorType as TriggerErrorType, type context_TriggerValidationError as TriggerValidationError, type context_TriggerValidationErrorErrorOneOf as TriggerValidationErrorErrorOneOf, context_TriggerValidationErrorValidationErrorType as TriggerValidationErrorValidationErrorType, context_Type as Type, type context_UpdateAutomation as UpdateAutomation, type context_UpdateAutomationRequest as UpdateAutomationRequest, type context_UpdateAutomationResponse as UpdateAutomationResponse, type context_UpdateAutomationResponseNonNullableFields as UpdateAutomationResponseNonNullableFields, type context_UpdateDraftAutomation as UpdateDraftAutomation, type context_UpdateDraftAutomationRequest as UpdateDraftAutomationRequest, type context_UpdateDraftAutomationResponse as UpdateDraftAutomationResponse, type context_UpdateDraftAutomationResponseNonNullableFields as UpdateDraftAutomationResponseNonNullableFields, type context_UpdatePreinstalledAutomationRequest as UpdatePreinstalledAutomationRequest, type context_UpdatePreinstalledAutomationResponse as UpdatePreinstalledAutomationResponse, type context_UpdatedWithPreviousEntity as UpdatedWithPreviousEntity, type context_UpgradeCTA as UpgradeCTA, type context_ValidateAutomationOptions as ValidateAutomationOptions, type context_ValidateAutomationRequest as ValidateAutomationRequest, type context_ValidateAutomationResponse as ValidateAutomationResponse, type context_ValidateAutomationResponseNonNullableFields as ValidateAutomationResponseNonNullableFields, context_ValidationErrorSeverity as ValidationErrorSeverity, context_ValidationErrorType as ValidationErrorType, type context_ValidationSettings as ValidationSettings, context_WebhookIdentityType as WebhookIdentityType, type context__publicOnAutomationCreatedType as _publicOnAutomationCreatedType, type context__publicOnAutomationDeletedType as _publicOnAutomationDeletedType, type context__publicOnAutomationDeletedWithEntityType as _publicOnAutomationDeletedWithEntityType, type context__publicOnAutomationUpdatedType as _publicOnAutomationUpdatedType, type context__publicOnAutomationUpdatedWithPreviousEntityType as _publicOnAutomationUpdatedWithPreviousEntityType, context_bulkDeleteAutomations as bulkDeleteAutomations, context_copyAutomation as copyAutomation, context_createAutomation as createAutomation, context_createDraftAutomation as createDraftAutomation, context_deleteAutomation as deleteAutomation, context_deleteDraftAutomation as deleteDraftAutomation, context_getActionsQuotaInfo as getActionsQuotaInfo, context_getAutomation as getAutomation, context_getAutomationActionSchema as getAutomationActionSchema, context_getOrCreateDraftAutomation as getOrCreateDraftAutomation, context_onAutomationCreated as onAutomationCreated, context_onAutomationDeleted as onAutomationDeleted, context_onAutomationDeletedWithEntity as onAutomationDeletedWithEntity, context_onAutomationUpdated as onAutomationUpdated, context_onAutomationUpdatedWithPreviousEntity as onAutomationUpdatedWithPreviousEntity, onAutomationCreated$1 as publicOnAutomationCreated, onAutomationDeleted$1 as publicOnAutomationDeleted, onAutomationDeletedWithEntity$1 as publicOnAutomationDeletedWithEntity, onAutomationUpdated$1 as publicOnAutomationUpdated, onAutomationUpdatedWithPreviousEntity$1 as publicOnAutomationUpdatedWithPreviousEntity, context_queryAutomations as queryAutomations, context_queryAutomationsWithDrafts as queryAutomationsWithDrafts, context_updateAutomation as updateAutomation, context_updateDraftAutomation as updateDraftAutomation, context_validateAutomation as validateAutomation };
|
|
6991
|
+
export { type context_Action as Action, type context_ActionConfigurationError as ActionConfigurationError, context_ActionErrorType as ActionErrorType, type context_ActionEvent as ActionEvent, type context_ActionInfoOneOf as ActionInfoOneOf, type context_ActionProviderQuotaInfo as ActionProviderQuotaInfo, type context_ActionQuotaInfo as ActionQuotaInfo, type context_ActionSettings as ActionSettings, type context_ActionValidationError as ActionValidationError, type context_ActionValidationErrorErrorOneOf as ActionValidationErrorErrorOneOf, type context_ActionValidationInfo as ActionValidationInfo, type context_AdditionalInfo as AdditionalInfo, type context_AppDefinedAction as AppDefinedAction, type context_ApplicationError as ApplicationError, type context_ApplicationOrigin as ApplicationOrigin, type context_Asset as Asset, type context_AuditInfo as AuditInfo, type context_AuditInfoIdOneOf as AuditInfoIdOneOf, type context_Automation as Automation, type context_AutomationConfiguration as AutomationConfiguration, type context_AutomationConfigurationError as AutomationConfigurationError, type context_AutomationCreatedEnvelope as AutomationCreatedEnvelope, type context_AutomationDeletedEnvelope as AutomationDeletedEnvelope, type context_AutomationDeletedWithEntityEnvelope as AutomationDeletedWithEntityEnvelope, context_AutomationErrorType as AutomationErrorType, type context_AutomationNonNullableFields as AutomationNonNullableFields, type context_AutomationOriginInfoOneOf as AutomationOriginInfoOneOf, type context_AutomationSettings as AutomationSettings, type context_AutomationUpdatedEnvelope as AutomationUpdatedEnvelope, type context_AutomationUpdatedWithPreviousEntityEnvelope as AutomationUpdatedWithPreviousEntityEnvelope, type context_AutomationValidationError as AutomationValidationError, type context_AutomationValidationErrorErrorOneOf as AutomationValidationErrorErrorOneOf, context_AutomationValidationErrorValidationErrorType as AutomationValidationErrorValidationErrorType, type context_AutomationsQueryBuilder as AutomationsQueryBuilder, type context_AutomationsQueryResult as AutomationsQueryResult, type context_BaseEventMetadata as BaseEventMetadata, type context_BulkActionMetadata as BulkActionMetadata, type context_BulkDeleteAutomationsRequest as BulkDeleteAutomationsRequest, type context_BulkDeleteAutomationsResponse as BulkDeleteAutomationsResponse, type context_BulkDeleteAutomationsResponseNonNullableFields as BulkDeleteAutomationsResponseNonNullableFields, type context_BulkDeleteResult as BulkDeleteResult, type context_CTA as CTA, type context_CommonCursorPaging as CommonCursorPaging, type context_CommonCursorPagingMetadata as CommonCursorPagingMetadata, type context_CommonCursorQuery as CommonCursorQuery, type context_CommonCursorQueryPagingMethodOneOf as CommonCursorQueryPagingMethodOneOf, type context_CommonCursors as CommonCursors, context_CommonSortOrder as CommonSortOrder, type context_CommonSorting as CommonSorting, type context_ConditionAction as ConditionAction, type context_ConditionExpressionGroup as ConditionExpressionGroup, type context_CopyAutomationOptions as CopyAutomationOptions, type context_CopyAutomationRequest as CopyAutomationRequest, type context_CopyAutomationResponse as CopyAutomationResponse, type context_CopyAutomationResponseNonNullableFields as CopyAutomationResponseNonNullableFields, type context_CreateAutomationRequest as CreateAutomationRequest, type context_CreateAutomationResponse as CreateAutomationResponse, type context_CreateAutomationResponseNonNullableFields as CreateAutomationResponseNonNullableFields, type context_CreateDraftAutomationOptions as CreateDraftAutomationOptions, type context_CreateDraftAutomationRequest as CreateDraftAutomationRequest, type context_CreateDraftAutomationResponse as CreateDraftAutomationResponse, type context_CreateDraftAutomationResponseNonNullableFields as CreateDraftAutomationResponseNonNullableFields, type context_CreatePreinstalledAutomationRequest as CreatePreinstalledAutomationRequest, type context_CreatePreinstalledAutomationResponse as CreatePreinstalledAutomationResponse, type context_CursorPaging as CursorPaging, type context_CursorPagingMetadata as CursorPagingMetadata, type context_CursorQuery as CursorQuery, type context_CursorQueryPagingMethodOneOf as CursorQueryPagingMethodOneOf, type context_Cursors as Cursors, type context_DelayAction as DelayAction, type context_DeleteAutomationRequest as DeleteAutomationRequest, type context_DeleteAutomationResponse as DeleteAutomationResponse, type context_DeleteContext as DeleteContext, type context_DeleteDraftAutomationRequest as DeleteDraftAutomationRequest, type context_DeleteDraftAutomationResponse as DeleteDraftAutomationResponse, type context_DeletePreinstalledAutomationRequest as DeletePreinstalledAutomationRequest, type context_DeletePreinstalledAutomationResponse as DeletePreinstalledAutomationResponse, context_DeleteStatus as DeleteStatus, type context_DeletedWithEntity as DeletedWithEntity, type context_DomainEvent as DomainEvent, type context_DomainEventBodyOneOf as DomainEventBodyOneOf, type context_DraftInfo as DraftInfo, type context_DraftsInfo as DraftsInfo, type context_Empty as Empty, type context_EntityCreatedEvent as EntityCreatedEvent, type context_EntityDeletedEvent as EntityDeletedEvent, type context_EntityUpdatedEvent as EntityUpdatedEvent, type context_EventMetadata as EventMetadata, type context_Filter as Filter, type context_FutureDateActivationOffset as FutureDateActivationOffset, type context_GetActionsQuotaInfoRequest as GetActionsQuotaInfoRequest, type context_GetActionsQuotaInfoResponse as GetActionsQuotaInfoResponse, type context_GetActionsQuotaInfoResponseNonNullableFields as GetActionsQuotaInfoResponseNonNullableFields, type context_GetAutomationActionSchemaIdentifiers as GetAutomationActionSchemaIdentifiers, type context_GetAutomationActionSchemaRequest as GetAutomationActionSchemaRequest, type context_GetAutomationActionSchemaResponse as GetAutomationActionSchemaResponse, type context_GetAutomationOptions as GetAutomationOptions, type context_GetAutomationRequest as GetAutomationRequest, type context_GetAutomationResponse as GetAutomationResponse, type context_GetAutomationResponseNonNullableFields as GetAutomationResponseNonNullableFields, type context_GetAutomationRevisionRequest as GetAutomationRevisionRequest, type context_GetAutomationRevisionResponse as GetAutomationRevisionResponse, type context_GetOrCreateDraftAutomationRequest as GetOrCreateDraftAutomationRequest, type context_GetOrCreateDraftAutomationResponse as GetOrCreateDraftAutomationResponse, type context_GetOrCreateDraftAutomationResponseNonNullableFields as GetOrCreateDraftAutomationResponseNonNullableFields, type context_IdentificationData as IdentificationData, type context_IdentificationDataIdOneOf as IdentificationDataIdOneOf, type context_ItemMetadata as ItemMetadata, type context_MessageEnvelope as MessageEnvelope, type context_MetaSiteSpecialEvent as MetaSiteSpecialEvent, type context_MetaSiteSpecialEventPayloadOneOf as MetaSiteSpecialEventPayloadOneOf, context_Namespace as Namespace, type context_NamespaceChanged as NamespaceChanged, context_Operator as Operator, context_Origin as Origin, type context_OriginAutomationInfo as OriginAutomationInfo, type context_OutputAction as OutputAction, type context_Plan as Plan, type context_PreinstalledAutomationSpecInfo as PreinstalledAutomationSpecInfo, type context_PreinstalledOrigin as PreinstalledOrigin, type context_ProviderConfigurationError as ProviderConfigurationError, type context_PublishDraftAutomationRequest as PublishDraftAutomationRequest, type context_PublishDraftAutomationResponse as PublishDraftAutomationResponse, type context_QueryAutomationsRequest as QueryAutomationsRequest, type context_QueryAutomationsResponse as QueryAutomationsResponse, type context_QueryAutomationsResponseNonNullableFields as QueryAutomationsResponseNonNullableFields, type context_QueryAutomationsWithDraftsOptions as QueryAutomationsWithDraftsOptions, type context_QueryAutomationsWithDraftsRequest as QueryAutomationsWithDraftsRequest, type context_QueryAutomationsWithDraftsResponse as QueryAutomationsWithDraftsResponse, type context_QueryAutomationsWithDraftsResponseNonNullableFields as QueryAutomationsWithDraftsResponseNonNullableFields, type context_QueryPreinstalledAutomationsForAppRequest as QueryPreinstalledAutomationsForAppRequest, type context_QueryPreinstalledAutomationsForAppResponse as QueryPreinstalledAutomationsForAppResponse, type context_Quota as Quota, type context_QuotaInfo as QuotaInfo, type context_RateLimit as RateLimit, type context_RateLimitAction as RateLimitAction, type context_RestoreInfo as RestoreInfo, type context_ServiceProvisioned as ServiceProvisioned, type context_ServiceRemoved as ServiceRemoved, type context_SiteCreated as SiteCreated, context_SiteCreatedContext as SiteCreatedContext, type context_SiteDeleted as SiteDeleted, type context_SiteHardDeleted as SiteHardDeleted, type context_SiteMarkedAsTemplate as SiteMarkedAsTemplate, type context_SiteMarkedAsWixSite as SiteMarkedAsWixSite, type context_SitePublished as SitePublished, type context_SiteRenamed as SiteRenamed, type context_SiteTransferred as SiteTransferred, type context_SiteUndeleted as SiteUndeleted, type context_SiteUnpublished as SiteUnpublished, context_SortOrder as SortOrder, type context_Sorting as Sorting, context_State as State, context_Status as Status, type context_StudioAssigned as StudioAssigned, type context_StudioUnassigned as StudioUnassigned, context_TimeUnit as TimeUnit, type context_Trigger as Trigger, type context_TriggerConfigurationError as TriggerConfigurationError, context_TriggerErrorType as TriggerErrorType, type context_TriggerValidationError as TriggerValidationError, type context_TriggerValidationErrorErrorOneOf as TriggerValidationErrorErrorOneOf, context_TriggerValidationErrorValidationErrorType as TriggerValidationErrorValidationErrorType, context_Type as Type, type context_UpdateAutomation as UpdateAutomation, type context_UpdateAutomationRequest as UpdateAutomationRequest, type context_UpdateAutomationResponse as UpdateAutomationResponse, type context_UpdateAutomationResponseNonNullableFields as UpdateAutomationResponseNonNullableFields, type context_UpdateDraftAutomation as UpdateDraftAutomation, type context_UpdateDraftAutomationRequest as UpdateDraftAutomationRequest, type context_UpdateDraftAutomationResponse as UpdateDraftAutomationResponse, type context_UpdateDraftAutomationResponseNonNullableFields as UpdateDraftAutomationResponseNonNullableFields, type context_UpdatePreinstalledAutomationRequest as UpdatePreinstalledAutomationRequest, type context_UpdatePreinstalledAutomationResponse as UpdatePreinstalledAutomationResponse, type context_UpdatedWithPreviousEntity as UpdatedWithPreviousEntity, type context_UpgradeCTA as UpgradeCTA, type context_ValidateAutomationOptions as ValidateAutomationOptions, type context_ValidateAutomationRequest as ValidateAutomationRequest, type context_ValidateAutomationResponse as ValidateAutomationResponse, type context_ValidateAutomationResponseNonNullableFields as ValidateAutomationResponseNonNullableFields, context_ValidationErrorSeverity as ValidationErrorSeverity, context_ValidationErrorType as ValidationErrorType, type context_ValidationSettings as ValidationSettings, context_WebhookIdentityType as WebhookIdentityType, type context__publicOnAutomationCreatedType as _publicOnAutomationCreatedType, type context__publicOnAutomationDeletedType as _publicOnAutomationDeletedType, type context__publicOnAutomationDeletedWithEntityType as _publicOnAutomationDeletedWithEntityType, type context__publicOnAutomationUpdatedType as _publicOnAutomationUpdatedType, type context__publicOnAutomationUpdatedWithPreviousEntityType as _publicOnAutomationUpdatedWithPreviousEntityType, context_bulkDeleteAutomations as bulkDeleteAutomations, context_copyAutomation as copyAutomation, context_createAutomation as createAutomation, context_createDraftAutomation as createDraftAutomation, context_deleteAutomation as deleteAutomation, context_deleteDraftAutomation as deleteDraftAutomation, context_getActionsQuotaInfo as getActionsQuotaInfo, context_getAutomation as getAutomation, context_getAutomationActionSchema as getAutomationActionSchema, context_getOrCreateDraftAutomation as getOrCreateDraftAutomation, context_onAutomationCreated as onAutomationCreated, context_onAutomationDeleted as onAutomationDeleted, context_onAutomationDeletedWithEntity as onAutomationDeletedWithEntity, context_onAutomationUpdated as onAutomationUpdated, context_onAutomationUpdatedWithPreviousEntity as onAutomationUpdatedWithPreviousEntity, onAutomationCreated$1 as publicOnAutomationCreated, onAutomationDeleted$1 as publicOnAutomationDeleted, onAutomationDeletedWithEntity$1 as publicOnAutomationDeletedWithEntity, onAutomationUpdated$1 as publicOnAutomationUpdated, onAutomationUpdatedWithPreviousEntity$1 as publicOnAutomationUpdatedWithPreviousEntity, context_queryAutomations as queryAutomations, context_queryAutomationsWithDrafts as queryAutomationsWithDrafts, context_updateAutomation as updateAutomation, context_updateDraftAutomation as updateDraftAutomation, context_validateAutomation as validateAutomation };
|
|
5704
6992
|
}
|
|
5705
6993
|
|
|
5706
6994
|
export { context$1 as activations, context$2 as automationsService, context as automationsServiceV2 };
|