@wix/automations 1.0.45 → 1.0.46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +5 -5
- package/type-bundles/context.bundle.d.ts +1468 -660
- package/type-bundles/index.bundle.d.ts +1468 -660
- package/type-bundles/meta.bundle.d.ts +1 -166
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
type HostModule<T, H extends Host> = {
|
|
1
|
+
type HostModule$2<T, H extends Host$2> = {
|
|
2
2
|
__type: 'host';
|
|
3
3
|
create(host: H): T;
|
|
4
4
|
};
|
|
5
|
-
type HostModuleAPI<T extends HostModule<any, any>> = T extends HostModule<infer U, any> ? U : never;
|
|
6
|
-
type Host<Environment = unknown> = {
|
|
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
7
|
channel: {
|
|
8
8
|
observeState(callback: (props: unknown, environment: Environment) => unknown): {
|
|
9
9
|
disconnect: () => void;
|
|
@@ -12,6 +12,10 @@ type Host<Environment = unknown> = {
|
|
|
12
12
|
}>;
|
|
13
13
|
};
|
|
14
14
|
environment?: Environment;
|
|
15
|
+
/**
|
|
16
|
+
* Optional name of the environment, use for logging
|
|
17
|
+
*/
|
|
18
|
+
name?: string;
|
|
15
19
|
/**
|
|
16
20
|
* Optional bast url to use for API requests, for example `www.wixapis.com`
|
|
17
21
|
*/
|
|
@@ -36,92 +40,92 @@ type Host<Environment = unknown> = {
|
|
|
36
40
|
};
|
|
37
41
|
};
|
|
38
42
|
|
|
39
|
-
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
40
|
-
interface HttpClient {
|
|
41
|
-
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
43
|
+
type RESTFunctionDescriptor$2<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$2) => T;
|
|
44
|
+
interface HttpClient$2 {
|
|
45
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory$2<TResponse, TData>): Promise<HttpResponse$2<TResponse>>;
|
|
42
46
|
fetchWithAuth: typeof fetch;
|
|
43
47
|
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
44
48
|
getActiveToken?: () => string | undefined;
|
|
45
49
|
}
|
|
46
|
-
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
47
|
-
type HttpResponse<T = any> = {
|
|
50
|
+
type RequestOptionsFactory$2<TResponse = any, TData = any> = (context: any) => RequestOptions$2<TResponse, TData>;
|
|
51
|
+
type HttpResponse$2<T = any> = {
|
|
48
52
|
data: T;
|
|
49
53
|
status: number;
|
|
50
54
|
statusText: string;
|
|
51
55
|
headers: any;
|
|
52
56
|
request?: any;
|
|
53
57
|
};
|
|
54
|
-
type RequestOptions<_TResponse = any, Data = any> = {
|
|
58
|
+
type RequestOptions$2<_TResponse = any, Data = any> = {
|
|
55
59
|
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
56
60
|
url: string;
|
|
57
61
|
data?: Data;
|
|
58
62
|
params?: URLSearchParams;
|
|
59
|
-
} & APIMetadata;
|
|
60
|
-
type APIMetadata = {
|
|
63
|
+
} & APIMetadata$2;
|
|
64
|
+
type APIMetadata$2 = {
|
|
61
65
|
methodFqn?: string;
|
|
62
66
|
entityFqdn?: string;
|
|
63
67
|
packageName?: string;
|
|
64
68
|
};
|
|
65
|
-
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
66
|
-
type EventDefinition$
|
|
69
|
+
type BuildRESTFunction$2<T extends RESTFunctionDescriptor$2> = T extends RESTFunctionDescriptor$2<infer U> ? U : never;
|
|
70
|
+
type EventDefinition$2<Payload = unknown, Type extends string = string> = {
|
|
67
71
|
__type: 'event-definition';
|
|
68
72
|
type: Type;
|
|
69
73
|
isDomainEvent?: boolean;
|
|
70
74
|
transformations?: (envelope: unknown) => Payload;
|
|
71
75
|
__payload: Payload;
|
|
72
76
|
};
|
|
73
|
-
declare function EventDefinition$
|
|
74
|
-
type EventHandler$
|
|
75
|
-
type BuildEventDefinition$
|
|
77
|
+
declare function EventDefinition$2<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$2<Payload, Type>;
|
|
78
|
+
type EventHandler$2<T extends EventDefinition$2> = (payload: T['__payload']) => void | Promise<void>;
|
|
79
|
+
type BuildEventDefinition$2<T extends EventDefinition$2<any, string>> = (handler: EventHandler$2<T>) => void;
|
|
76
80
|
|
|
77
|
-
type ServicePluginMethodInput = {
|
|
81
|
+
type ServicePluginMethodInput$2 = {
|
|
78
82
|
request: any;
|
|
79
83
|
metadata: any;
|
|
80
84
|
};
|
|
81
|
-
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
82
|
-
type ServicePluginMethodMetadata = {
|
|
85
|
+
type ServicePluginContract$2 = Record<string, (payload: ServicePluginMethodInput$2) => unknown | Promise<unknown>>;
|
|
86
|
+
type ServicePluginMethodMetadata$2 = {
|
|
83
87
|
name: string;
|
|
84
88
|
primaryHttpMappingPath: string;
|
|
85
89
|
transformations: {
|
|
86
|
-
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
90
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput$2;
|
|
87
91
|
toREST: (...args: unknown[]) => unknown;
|
|
88
92
|
};
|
|
89
93
|
};
|
|
90
|
-
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
94
|
+
type ServicePluginDefinition$2<Contract extends ServicePluginContract$2> = {
|
|
91
95
|
__type: 'service-plugin-definition';
|
|
92
96
|
componentType: string;
|
|
93
|
-
methods: ServicePluginMethodMetadata[];
|
|
97
|
+
methods: ServicePluginMethodMetadata$2[];
|
|
94
98
|
__contract: Contract;
|
|
95
99
|
};
|
|
96
|
-
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
97
|
-
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
98
|
-
declare const SERVICE_PLUGIN_ERROR_TYPE = "wix_spi_error";
|
|
100
|
+
declare function ServicePluginDefinition$2<Contract extends ServicePluginContract$2>(componentType: string, methods: ServicePluginMethodMetadata$2[]): ServicePluginDefinition$2<Contract>;
|
|
101
|
+
type BuildServicePluginDefinition$2<T extends ServicePluginDefinition$2<any>> = (implementation: T['__contract']) => void;
|
|
102
|
+
declare const SERVICE_PLUGIN_ERROR_TYPE$2 = "wix_spi_error";
|
|
99
103
|
|
|
100
|
-
type RequestContext = {
|
|
104
|
+
type RequestContext$2 = {
|
|
101
105
|
isSSR: boolean;
|
|
102
106
|
host: string;
|
|
103
107
|
protocol?: string;
|
|
104
108
|
};
|
|
105
|
-
type ResponseTransformer = (data: any, headers?: any) => any;
|
|
109
|
+
type ResponseTransformer$2 = (data: any, headers?: any) => any;
|
|
106
110
|
/**
|
|
107
111
|
* Ambassador request options types are copied mostly from AxiosRequestConfig.
|
|
108
112
|
* They are copied and not imported to reduce the amount of dependencies (to reduce install time).
|
|
109
113
|
* https://github.com/axios/axios/blob/3f53eb6960f05a1f88409c4b731a40de595cb825/index.d.ts#L307-L315
|
|
110
114
|
*/
|
|
111
|
-
type Method = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
112
|
-
type AmbassadorRequestOptions<T = any> = {
|
|
115
|
+
type Method$2 = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
116
|
+
type AmbassadorRequestOptions$2<T = any> = {
|
|
113
117
|
_?: T;
|
|
114
118
|
url?: string;
|
|
115
|
-
method?: Method;
|
|
119
|
+
method?: Method$2;
|
|
116
120
|
params?: any;
|
|
117
121
|
data?: any;
|
|
118
|
-
transformResponse?: ResponseTransformer | ResponseTransformer[];
|
|
122
|
+
transformResponse?: ResponseTransformer$2 | ResponseTransformer$2[];
|
|
119
123
|
};
|
|
120
|
-
type AmbassadorFactory<Request, Response> = (payload: Request) => ((context: RequestContext) => AmbassadorRequestOptions<Response>) & {
|
|
124
|
+
type AmbassadorFactory$2<Request, Response> = (payload: Request) => ((context: RequestContext$2) => AmbassadorRequestOptions$2<Response>) & {
|
|
121
125
|
__isAmbassador: boolean;
|
|
122
126
|
};
|
|
123
|
-
type AmbassadorFunctionDescriptor<Request = any, Response = any> = AmbassadorFactory<Request, Response>;
|
|
124
|
-
type BuildAmbassadorFunction<T extends AmbassadorFunctionDescriptor> = T extends AmbassadorFunctionDescriptor<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
127
|
+
type AmbassadorFunctionDescriptor$2<Request = any, Response = any> = AmbassadorFactory$2<Request, Response>;
|
|
128
|
+
type BuildAmbassadorFunction$2<T extends AmbassadorFunctionDescriptor$2> = T extends AmbassadorFunctionDescriptor$2<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
125
129
|
|
|
126
130
|
declare global {
|
|
127
131
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -130,7 +134,7 @@ declare global {
|
|
|
130
134
|
}
|
|
131
135
|
}
|
|
132
136
|
|
|
133
|
-
declare const emptyObjectSymbol: unique symbol;
|
|
137
|
+
declare const emptyObjectSymbol$2: unique symbol;
|
|
134
138
|
|
|
135
139
|
/**
|
|
136
140
|
Represents a strictly empty plain object, the `{}` value.
|
|
@@ -158,7 +162,7 @@ Unfortunately, `Record<string, never>`, `Record<keyof any, never>` and `Record<n
|
|
|
158
162
|
|
|
159
163
|
@category Object
|
|
160
164
|
*/
|
|
161
|
-
type EmptyObject = {[emptyObjectSymbol]?: never};
|
|
165
|
+
type EmptyObject$2 = {[emptyObjectSymbol$2]?: never};
|
|
162
166
|
|
|
163
167
|
/**
|
|
164
168
|
Returns a boolean for whether the two given types are equal.
|
|
@@ -186,7 +190,7 @@ type Includes<Value extends readonly any[], Item> =
|
|
|
186
190
|
@category Type Guard
|
|
187
191
|
@category Utilities
|
|
188
192
|
*/
|
|
189
|
-
type IsEqual<A, B> =
|
|
193
|
+
type IsEqual$2<A, B> =
|
|
190
194
|
(<G>() => G extends A ? 1 : 2) extends
|
|
191
195
|
(<G>() => G extends B ? 1 : 2)
|
|
192
196
|
? true
|
|
@@ -219,9 +223,9 @@ type Filtered = Filter<'bar', 'foo'>;
|
|
|
219
223
|
|
|
220
224
|
@see {Except}
|
|
221
225
|
*/
|
|
222
|
-
type Filter$
|
|
226
|
+
type Filter$5<KeyType, ExcludeType> = IsEqual$2<KeyType, ExcludeType> extends true ? never : (KeyType extends ExcludeType ? never : KeyType);
|
|
223
227
|
|
|
224
|
-
type ExceptOptions = {
|
|
228
|
+
type ExceptOptions$2 = {
|
|
225
229
|
/**
|
|
226
230
|
Disallow assigning non-specified properties.
|
|
227
231
|
|
|
@@ -265,12 +269,78 @@ const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
|
|
|
265
269
|
|
|
266
270
|
@category Object
|
|
267
271
|
*/
|
|
268
|
-
type Except<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions = {requireExactProps: false}> = {
|
|
269
|
-
[KeyType in keyof ObjectType as Filter$
|
|
272
|
+
type Except$2<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions$2 = {requireExactProps: false}> = {
|
|
273
|
+
[KeyType in keyof ObjectType as Filter$5<KeyType, KeysType>]: ObjectType[KeyType];
|
|
270
274
|
} & (Options['requireExactProps'] extends true
|
|
271
275
|
? Partial<Record<KeysType, never>>
|
|
272
276
|
: {});
|
|
273
277
|
|
|
278
|
+
/**
|
|
279
|
+
Returns a boolean for whether the given type is `never`.
|
|
280
|
+
|
|
281
|
+
@link https://github.com/microsoft/TypeScript/issues/31751#issuecomment-498526919
|
|
282
|
+
@link https://stackoverflow.com/a/53984913/10292952
|
|
283
|
+
@link https://www.zhenghao.io/posts/ts-never
|
|
284
|
+
|
|
285
|
+
Useful in type utilities, such as checking if something does not occur.
|
|
286
|
+
|
|
287
|
+
@example
|
|
288
|
+
```
|
|
289
|
+
import type {IsNever, And} from 'type-fest';
|
|
290
|
+
|
|
291
|
+
// https://github.com/andnp/SimplyTyped/blob/master/src/types/strings.ts
|
|
292
|
+
type AreStringsEqual<A extends string, B extends string> =
|
|
293
|
+
And<
|
|
294
|
+
IsNever<Exclude<A, B>> extends true ? true : false,
|
|
295
|
+
IsNever<Exclude<B, A>> extends true ? true : false
|
|
296
|
+
>;
|
|
297
|
+
|
|
298
|
+
type EndIfEqual<I extends string, O extends string> =
|
|
299
|
+
AreStringsEqual<I, O> extends true
|
|
300
|
+
? never
|
|
301
|
+
: void;
|
|
302
|
+
|
|
303
|
+
function endIfEqual<I extends string, O extends string>(input: I, output: O): EndIfEqual<I, O> {
|
|
304
|
+
if (input === output) {
|
|
305
|
+
process.exit(0);
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
endIfEqual('abc', 'abc');
|
|
310
|
+
//=> never
|
|
311
|
+
|
|
312
|
+
endIfEqual('abc', '123');
|
|
313
|
+
//=> void
|
|
314
|
+
```
|
|
315
|
+
|
|
316
|
+
@category Type Guard
|
|
317
|
+
@category Utilities
|
|
318
|
+
*/
|
|
319
|
+
type IsNever$2<T> = [T] extends [never] ? true : false;
|
|
320
|
+
|
|
321
|
+
/**
|
|
322
|
+
An if-else-like type that resolves depending on whether the given type is `never`.
|
|
323
|
+
|
|
324
|
+
@see {@link IsNever}
|
|
325
|
+
|
|
326
|
+
@example
|
|
327
|
+
```
|
|
328
|
+
import type {IfNever} from 'type-fest';
|
|
329
|
+
|
|
330
|
+
type ShouldBeTrue = IfNever<never>;
|
|
331
|
+
//=> true
|
|
332
|
+
|
|
333
|
+
type ShouldBeBar = IfNever<'not never', 'foo', 'bar'>;
|
|
334
|
+
//=> 'bar'
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
@category Type Guard
|
|
338
|
+
@category Utilities
|
|
339
|
+
*/
|
|
340
|
+
type IfNever$2<T, TypeIfNever = true, TypeIfNotNever = false> = (
|
|
341
|
+
IsNever$2<T> extends true ? TypeIfNever : TypeIfNotNever
|
|
342
|
+
);
|
|
343
|
+
|
|
274
344
|
/**
|
|
275
345
|
Extract the keys from a type where the value type of the key extends the given `Condition`.
|
|
276
346
|
|
|
@@ -303,21 +373,19 @@ type StringKeysAndUndefined = ConditionalKeys<Example, string | undefined>;
|
|
|
303
373
|
|
|
304
374
|
@category Object
|
|
305
375
|
*/
|
|
306
|
-
type ConditionalKeys<Base, Condition> =
|
|
307
|
-
// Wrap in `NonNullable` to strip away the `undefined` type from the produced union.
|
|
376
|
+
type ConditionalKeys$2<Base, Condition> =
|
|
308
377
|
{
|
|
309
378
|
// Map through all the keys of the given base type.
|
|
310
|
-
[Key in keyof Base]
|
|
379
|
+
[Key in keyof Base]-?:
|
|
311
380
|
// Pick only keys with types extending the given `Condition` type.
|
|
312
381
|
Base[Key] extends Condition
|
|
313
|
-
// Retain this key
|
|
314
|
-
|
|
382
|
+
// Retain this key
|
|
383
|
+
// If the value for the key extends never, only include it if `Condition` also extends never
|
|
384
|
+
? IfNever$2<Base[Key], IfNever$2<Condition, Key, never>, Key>
|
|
315
385
|
// Discard this key since the condition fails.
|
|
316
386
|
: never;
|
|
317
|
-
|
|
318
387
|
// Convert the produced object into a union type of the keys which passed the conditional test.
|
|
319
|
-
}[keyof Base]
|
|
320
|
-
>;
|
|
388
|
+
}[keyof Base];
|
|
321
389
|
|
|
322
390
|
/**
|
|
323
391
|
Exclude keys from a shape that matches the given `Condition`.
|
|
@@ -357,9 +425,9 @@ type NonStringKeysOnly = ConditionalExcept<Example, string>;
|
|
|
357
425
|
|
|
358
426
|
@category Object
|
|
359
427
|
*/
|
|
360
|
-
type ConditionalExcept<Base, Condition> = Except<
|
|
428
|
+
type ConditionalExcept$2<Base, Condition> = Except$2<
|
|
361
429
|
Base,
|
|
362
|
-
ConditionalKeys<Base, Condition>
|
|
430
|
+
ConditionalKeys$2<Base, Condition>
|
|
363
431
|
>;
|
|
364
432
|
|
|
365
433
|
/**
|
|
@@ -367,8 +435,8 @@ ConditionalKeys<Base, Condition>
|
|
|
367
435
|
* can either be a REST module or a host module.
|
|
368
436
|
* This type is recursive, so it can describe nested modules.
|
|
369
437
|
*/
|
|
370
|
-
type Descriptors = RESTFunctionDescriptor | AmbassadorFunctionDescriptor | HostModule<any, any> | EventDefinition$
|
|
371
|
-
[key: string]: Descriptors | PublicMetadata | any;
|
|
438
|
+
type Descriptors$2 = RESTFunctionDescriptor$2 | AmbassadorFunctionDescriptor$2 | HostModule$2<any, any> | EventDefinition$2<any> | ServicePluginDefinition$2<any> | {
|
|
439
|
+
[key: string]: Descriptors$2 | PublicMetadata$2 | any;
|
|
372
440
|
};
|
|
373
441
|
/**
|
|
374
442
|
* This type takes in a descriptors object of a certain Host (including an `unknown` host)
|
|
@@ -376,12 +444,12 @@ type Descriptors = RESTFunctionDescriptor | AmbassadorFunctionDescriptor | HostM
|
|
|
376
444
|
* Any non-descriptor properties are removed from the returned object, including descriptors that
|
|
377
445
|
* do not match the given host (as they will not work with the given host).
|
|
378
446
|
*/
|
|
379
|
-
type BuildDescriptors<T extends Descriptors, H extends Host<any> | undefined, Depth extends number = 5> = {
|
|
447
|
+
type BuildDescriptors$2<T extends Descriptors$2, H extends Host$2<any> | undefined, Depth extends number = 5> = {
|
|
380
448
|
done: T;
|
|
381
449
|
recurse: T extends {
|
|
382
|
-
__type: typeof SERVICE_PLUGIN_ERROR_TYPE;
|
|
383
|
-
} ? never : T extends AmbassadorFunctionDescriptor ? BuildAmbassadorFunction<T> : T extends RESTFunctionDescriptor ? BuildRESTFunction<T> : T extends EventDefinition$
|
|
384
|
-
[Key in keyof T]: T[Key] extends Descriptors ? BuildDescriptors<T[Key], H, [
|
|
450
|
+
__type: typeof SERVICE_PLUGIN_ERROR_TYPE$2;
|
|
451
|
+
} ? never : T extends AmbassadorFunctionDescriptor$2 ? BuildAmbassadorFunction$2<T> : T extends RESTFunctionDescriptor$2 ? BuildRESTFunction$2<T> : T extends EventDefinition$2<any> ? BuildEventDefinition$2<T> : T extends ServicePluginDefinition$2<any> ? BuildServicePluginDefinition$2<T> : T extends HostModule$2<any, any> ? HostModuleAPI$2<T> : ConditionalExcept$2<{
|
|
452
|
+
[Key in keyof T]: T[Key] extends Descriptors$2 ? BuildDescriptors$2<T[Key], H, [
|
|
385
453
|
-1,
|
|
386
454
|
0,
|
|
387
455
|
1,
|
|
@@ -390,9 +458,9 @@ type BuildDescriptors<T extends Descriptors, H extends Host<any> | undefined, De
|
|
|
390
458
|
4,
|
|
391
459
|
5
|
|
392
460
|
][Depth]> : never;
|
|
393
|
-
}, EmptyObject>;
|
|
461
|
+
}, EmptyObject$2>;
|
|
394
462
|
}[Depth extends -1 ? 'done' : 'recurse'];
|
|
395
|
-
type PublicMetadata = {
|
|
463
|
+
type PublicMetadata$2 = {
|
|
396
464
|
PACKAGE_NAME?: string;
|
|
397
465
|
};
|
|
398
466
|
|
|
@@ -404,9 +472,9 @@ declare global {
|
|
|
404
472
|
* A type used to create concerete types from SDK descriptors in
|
|
405
473
|
* case a contextual client is available.
|
|
406
474
|
*/
|
|
407
|
-
type MaybeContext<T extends Descriptors> = globalThis.ContextualClient extends {
|
|
408
|
-
host: Host;
|
|
409
|
-
} ? BuildDescriptors<T, globalThis.ContextualClient['host']> : T;
|
|
475
|
+
type MaybeContext$2<T extends Descriptors$2> = globalThis.ContextualClient extends {
|
|
476
|
+
host: Host$2;
|
|
477
|
+
} ? BuildDescriptors$2<T, globalThis.ContextualClient['host']> : T;
|
|
410
478
|
|
|
411
479
|
/** Automation */
|
|
412
480
|
interface Automation$2 {
|
|
@@ -486,7 +554,7 @@ interface Trigger$2 {
|
|
|
486
554
|
/** Identifier for this trigger - human readable action key */
|
|
487
555
|
triggerKey?: string;
|
|
488
556
|
/** optional list of filters on schema fields */
|
|
489
|
-
filters?: Filter$
|
|
557
|
+
filters?: Filter$4[];
|
|
490
558
|
/**
|
|
491
559
|
* 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.
|
|
492
560
|
* 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),
|
|
@@ -494,7 +562,7 @@ interface Trigger$2 {
|
|
|
494
562
|
*/
|
|
495
563
|
debounce?: Debounce;
|
|
496
564
|
}
|
|
497
|
-
interface Filter$
|
|
565
|
+
interface Filter$4 {
|
|
498
566
|
/** the filter identifier */
|
|
499
567
|
_id?: string | null;
|
|
500
568
|
/** the field key from the schema, for example "formId" */
|
|
@@ -2042,7 +2110,7 @@ interface GenerateActionInputMappingFromTemplateOptions {
|
|
|
2042
2110
|
actionInputMappingTemplate: Record<string, any> | null;
|
|
2043
2111
|
}
|
|
2044
2112
|
|
|
2045
|
-
declare function createAutomation$3(httpClient: HttpClient): CreateAutomationSignature$1;
|
|
2113
|
+
declare function createAutomation$3(httpClient: HttpClient$2): CreateAutomationSignature$1;
|
|
2046
2114
|
interface CreateAutomationSignature$1 {
|
|
2047
2115
|
/**
|
|
2048
2116
|
* Creates a new Automation
|
|
@@ -2051,7 +2119,7 @@ interface CreateAutomationSignature$1 {
|
|
|
2051
2119
|
*/
|
|
2052
2120
|
(automation: Automation$2): Promise<Automation$2 & AutomationNonNullableFields$1>;
|
|
2053
2121
|
}
|
|
2054
|
-
declare function getAutomation$3(httpClient: HttpClient): GetAutomationSignature$1;
|
|
2122
|
+
declare function getAutomation$3(httpClient: HttpClient$2): GetAutomationSignature$1;
|
|
2055
2123
|
interface GetAutomationSignature$1 {
|
|
2056
2124
|
/**
|
|
2057
2125
|
* Get a Automation by id
|
|
@@ -2060,7 +2128,7 @@ interface GetAutomationSignature$1 {
|
|
|
2060
2128
|
*/
|
|
2061
2129
|
(automationId: string, options?: GetAutomationOptions$1 | undefined): Promise<Automation$2 & AutomationNonNullableFields$1>;
|
|
2062
2130
|
}
|
|
2063
|
-
declare function updateAutomation$3(httpClient: HttpClient): UpdateAutomationSignature$1;
|
|
2131
|
+
declare function updateAutomation$3(httpClient: HttpClient$2): UpdateAutomationSignature$1;
|
|
2064
2132
|
interface UpdateAutomationSignature$1 {
|
|
2065
2133
|
/**
|
|
2066
2134
|
* Update a Automation, supports partial update
|
|
@@ -2069,7 +2137,7 @@ interface UpdateAutomationSignature$1 {
|
|
|
2069
2137
|
*/
|
|
2070
2138
|
(_id: string | null, automation: UpdateAutomation$1): Promise<UpdateAutomationResponse$1 & UpdateAutomationResponseNonNullableFields$1>;
|
|
2071
2139
|
}
|
|
2072
|
-
declare function migrationUpdateAutomation$1(httpClient: HttpClient): MigrationUpdateAutomationSignature;
|
|
2140
|
+
declare function migrationUpdateAutomation$1(httpClient: HttpClient$2): MigrationUpdateAutomationSignature;
|
|
2073
2141
|
interface MigrationUpdateAutomationSignature {
|
|
2074
2142
|
/**
|
|
2075
2143
|
* @param - Automation ID
|
|
@@ -2077,7 +2145,7 @@ interface MigrationUpdateAutomationSignature {
|
|
|
2077
2145
|
*/
|
|
2078
2146
|
(_id: string | null, automation: MigrationUpdateAutomation): Promise<Automation$2 & AutomationNonNullableFields$1>;
|
|
2079
2147
|
}
|
|
2080
|
-
declare function deleteAutomation$3(httpClient: HttpClient): DeleteAutomationSignature$1;
|
|
2148
|
+
declare function deleteAutomation$3(httpClient: HttpClient$2): DeleteAutomationSignature$1;
|
|
2081
2149
|
interface DeleteAutomationSignature$1 {
|
|
2082
2150
|
/**
|
|
2083
2151
|
* Delete an Automation
|
|
@@ -2085,14 +2153,14 @@ interface DeleteAutomationSignature$1 {
|
|
|
2085
2153
|
*/
|
|
2086
2154
|
(automationId: string, options?: DeleteAutomationOptions | undefined): Promise<void>;
|
|
2087
2155
|
}
|
|
2088
|
-
declare function queryAutomations$3(httpClient: HttpClient): QueryAutomationsSignature$1;
|
|
2156
|
+
declare function queryAutomations$3(httpClient: HttpClient$2): QueryAutomationsSignature$1;
|
|
2089
2157
|
interface QueryAutomationsSignature$1 {
|
|
2090
2158
|
/**
|
|
2091
2159
|
* Query Automations using [WQL - Wix Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language)
|
|
2092
2160
|
*/
|
|
2093
2161
|
(options?: QueryAutomationsOptions | undefined): AutomationsQueryBuilder$1;
|
|
2094
2162
|
}
|
|
2095
|
-
declare function overrideApplicationAutomation$1(httpClient: HttpClient): OverrideApplicationAutomationSignature;
|
|
2163
|
+
declare function overrideApplicationAutomation$1(httpClient: HttpClient$2): OverrideApplicationAutomationSignature;
|
|
2096
2164
|
interface OverrideApplicationAutomationSignature {
|
|
2097
2165
|
/**
|
|
2098
2166
|
* Creates a new Automation
|
|
@@ -2100,7 +2168,7 @@ interface OverrideApplicationAutomationSignature {
|
|
|
2100
2168
|
*/
|
|
2101
2169
|
(automation: Automation$2): Promise<OverrideApplicationAutomationResponse & OverrideApplicationAutomationResponseNonNullableFields>;
|
|
2102
2170
|
}
|
|
2103
|
-
declare function validateAutomationById$1(httpClient: HttpClient): ValidateAutomationByIdSignature;
|
|
2171
|
+
declare function validateAutomationById$1(httpClient: HttpClient$2): ValidateAutomationByIdSignature;
|
|
2104
2172
|
interface ValidateAutomationByIdSignature {
|
|
2105
2173
|
/**
|
|
2106
2174
|
* Validate Automation by Id
|
|
@@ -2108,7 +2176,7 @@ interface ValidateAutomationByIdSignature {
|
|
|
2108
2176
|
*/
|
|
2109
2177
|
(automationId: string, options?: ValidateAutomationByIdOptions | undefined): Promise<ValidateAutomationByIdResponse & ValidateAutomationByIdResponseNonNullableFields>;
|
|
2110
2178
|
}
|
|
2111
|
-
declare function validateAutomation$3(httpClient: HttpClient): ValidateAutomationSignature$1;
|
|
2179
|
+
declare function validateAutomation$3(httpClient: HttpClient$2): ValidateAutomationSignature$1;
|
|
2112
2180
|
interface ValidateAutomationSignature$1 {
|
|
2113
2181
|
/**
|
|
2114
2182
|
* Validate Automation
|
|
@@ -2116,19 +2184,19 @@ interface ValidateAutomationSignature$1 {
|
|
|
2116
2184
|
*/
|
|
2117
2185
|
(automation: Automation$2): Promise<ValidateAutomationResponse$1 & ValidateAutomationResponseNonNullableFields$1>;
|
|
2118
2186
|
}
|
|
2119
|
-
declare function getAutomationActivationStats$1(httpClient: HttpClient): GetAutomationActivationStatsSignature;
|
|
2187
|
+
declare function getAutomationActivationStats$1(httpClient: HttpClient$2): GetAutomationActivationStatsSignature;
|
|
2120
2188
|
interface GetAutomationActivationStatsSignature {
|
|
2121
2189
|
/** @param - Automation ID */
|
|
2122
2190
|
(automationId: string, options?: GetAutomationActivationStatsOptions | undefined): Promise<GetAutomationActivationReportsResponse & GetAutomationActivationReportsResponseNonNullableFields>;
|
|
2123
2191
|
}
|
|
2124
|
-
declare function getActionsQuotaInfo$3(httpClient: HttpClient): GetActionsQuotaInfoSignature$1;
|
|
2192
|
+
declare function getActionsQuotaInfo$3(httpClient: HttpClient$2): GetActionsQuotaInfoSignature$1;
|
|
2125
2193
|
interface GetActionsQuotaInfoSignature$1 {
|
|
2126
2194
|
/**
|
|
2127
2195
|
* Get actions quota information
|
|
2128
2196
|
*/
|
|
2129
2197
|
(): Promise<GetActionsQuotaInfoResponse$1 & GetActionsQuotaInfoResponseNonNullableFields$1>;
|
|
2130
2198
|
}
|
|
2131
|
-
declare function generateActionInputMappingFromTemplate$1(httpClient: HttpClient): GenerateActionInputMappingFromTemplateSignature;
|
|
2199
|
+
declare function generateActionInputMappingFromTemplate$1(httpClient: HttpClient$2): GenerateActionInputMappingFromTemplateSignature;
|
|
2132
2200
|
interface GenerateActionInputMappingFromTemplateSignature {
|
|
2133
2201
|
/**
|
|
2134
2202
|
* Generate action input mapping from a template
|
|
@@ -2136,44 +2204,26 @@ interface GenerateActionInputMappingFromTemplateSignature {
|
|
|
2136
2204
|
*/
|
|
2137
2205
|
(appId: string, options: GenerateActionInputMappingFromTemplateOptions): Promise<GenerateActionInputMappingFromTemplateResponse>;
|
|
2138
2206
|
}
|
|
2139
|
-
declare const onAutomationCreated$3: EventDefinition$
|
|
2140
|
-
declare const onAutomationUpdated$3: EventDefinition$
|
|
2141
|
-
declare const onAutomationDeleted$3: EventDefinition$
|
|
2142
|
-
declare const onAutomationUpdatedWithPreviousEntity$3: EventDefinition$
|
|
2143
|
-
declare const onAutomationDeletedWithEntity$3: EventDefinition$
|
|
2144
|
-
|
|
2145
|
-
type EventDefinition$2<Payload = unknown, Type extends string = string> = {
|
|
2146
|
-
__type: 'event-definition';
|
|
2147
|
-
type: Type;
|
|
2148
|
-
isDomainEvent?: boolean;
|
|
2149
|
-
transformations?: (envelope: unknown) => Payload;
|
|
2150
|
-
__payload: Payload;
|
|
2151
|
-
};
|
|
2152
|
-
declare function EventDefinition$2<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$2<Payload, Type>;
|
|
2153
|
-
type EventHandler$2<T extends EventDefinition$2> = (payload: T['__payload']) => void | Promise<void>;
|
|
2154
|
-
type BuildEventDefinition$2<T extends EventDefinition$2<any, string>> = (handler: EventHandler$2<T>) => void;
|
|
2155
|
-
|
|
2156
|
-
declare global {
|
|
2157
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
2158
|
-
interface SymbolConstructor {
|
|
2159
|
-
readonly observable: symbol;
|
|
2160
|
-
}
|
|
2161
|
-
}
|
|
2207
|
+
declare const onAutomationCreated$3: EventDefinition$2<AutomationCreatedEnvelope$1, "wix.automations.v1.automation_created">;
|
|
2208
|
+
declare const onAutomationUpdated$3: EventDefinition$2<AutomationUpdatedEnvelope$1, "wix.automations.v1.automation_updated">;
|
|
2209
|
+
declare const onAutomationDeleted$3: EventDefinition$2<AutomationDeletedEnvelope$1, "wix.automations.v1.automation_deleted">;
|
|
2210
|
+
declare const onAutomationUpdatedWithPreviousEntity$3: EventDefinition$2<AutomationUpdatedWithPreviousEntityEnvelope$1, "wix.automations.v1.automation_updated_with_previous_entity">;
|
|
2211
|
+
declare const onAutomationDeletedWithEntity$3: EventDefinition$2<AutomationDeletedWithEntityEnvelope$1, "wix.automations.v1.automation_deleted_with_entity">;
|
|
2162
2212
|
|
|
2163
2213
|
declare function createEventModule$2<T extends EventDefinition$2<any, string>>(eventDefinition: T): BuildEventDefinition$2<T> & T;
|
|
2164
2214
|
|
|
2165
|
-
declare const createAutomation$2: MaybeContext<BuildRESTFunction<typeof createAutomation$3> & typeof createAutomation$3>;
|
|
2166
|
-
declare const getAutomation$2: MaybeContext<BuildRESTFunction<typeof getAutomation$3> & typeof getAutomation$3>;
|
|
2167
|
-
declare const updateAutomation$2: MaybeContext<BuildRESTFunction<typeof updateAutomation$3> & typeof updateAutomation$3>;
|
|
2168
|
-
declare const migrationUpdateAutomation: MaybeContext<BuildRESTFunction<typeof migrationUpdateAutomation$1> & typeof migrationUpdateAutomation$1>;
|
|
2169
|
-
declare const deleteAutomation$2: MaybeContext<BuildRESTFunction<typeof deleteAutomation$3> & typeof deleteAutomation$3>;
|
|
2170
|
-
declare const queryAutomations$2: MaybeContext<BuildRESTFunction<typeof queryAutomations$3> & typeof queryAutomations$3>;
|
|
2171
|
-
declare const overrideApplicationAutomation: MaybeContext<BuildRESTFunction<typeof overrideApplicationAutomation$1> & typeof overrideApplicationAutomation$1>;
|
|
2172
|
-
declare const validateAutomationById: MaybeContext<BuildRESTFunction<typeof validateAutomationById$1> & typeof validateAutomationById$1>;
|
|
2173
|
-
declare const validateAutomation$2: MaybeContext<BuildRESTFunction<typeof validateAutomation$3> & typeof validateAutomation$3>;
|
|
2174
|
-
declare const getAutomationActivationStats: MaybeContext<BuildRESTFunction<typeof getAutomationActivationStats$1> & typeof getAutomationActivationStats$1>;
|
|
2175
|
-
declare const getActionsQuotaInfo$2: MaybeContext<BuildRESTFunction<typeof getActionsQuotaInfo$3> & typeof getActionsQuotaInfo$3>;
|
|
2176
|
-
declare const generateActionInputMappingFromTemplate: MaybeContext<BuildRESTFunction<typeof generateActionInputMappingFromTemplate$1> & typeof generateActionInputMappingFromTemplate$1>;
|
|
2215
|
+
declare const createAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof createAutomation$3> & typeof createAutomation$3>;
|
|
2216
|
+
declare const getAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof getAutomation$3> & typeof getAutomation$3>;
|
|
2217
|
+
declare const updateAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof updateAutomation$3> & typeof updateAutomation$3>;
|
|
2218
|
+
declare const migrationUpdateAutomation: MaybeContext$2<BuildRESTFunction$2<typeof migrationUpdateAutomation$1> & typeof migrationUpdateAutomation$1>;
|
|
2219
|
+
declare const deleteAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof deleteAutomation$3> & typeof deleteAutomation$3>;
|
|
2220
|
+
declare const queryAutomations$2: MaybeContext$2<BuildRESTFunction$2<typeof queryAutomations$3> & typeof queryAutomations$3>;
|
|
2221
|
+
declare const overrideApplicationAutomation: MaybeContext$2<BuildRESTFunction$2<typeof overrideApplicationAutomation$1> & typeof overrideApplicationAutomation$1>;
|
|
2222
|
+
declare const validateAutomationById: MaybeContext$2<BuildRESTFunction$2<typeof validateAutomationById$1> & typeof validateAutomationById$1>;
|
|
2223
|
+
declare const validateAutomation$2: MaybeContext$2<BuildRESTFunction$2<typeof validateAutomation$3> & typeof validateAutomation$3>;
|
|
2224
|
+
declare const getAutomationActivationStats: MaybeContext$2<BuildRESTFunction$2<typeof getAutomationActivationStats$1> & typeof getAutomationActivationStats$1>;
|
|
2225
|
+
declare const getActionsQuotaInfo$2: MaybeContext$2<BuildRESTFunction$2<typeof getActionsQuotaInfo$3> & typeof getActionsQuotaInfo$3>;
|
|
2226
|
+
declare const generateActionInputMappingFromTemplate: MaybeContext$2<BuildRESTFunction$2<typeof generateActionInputMappingFromTemplate$1> & typeof generateActionInputMappingFromTemplate$1>;
|
|
2177
2227
|
|
|
2178
2228
|
type _publicOnAutomationCreatedType$1 = typeof onAutomationCreated$3;
|
|
2179
2229
|
/** */
|
|
@@ -2258,131 +2308,609 @@ declare const context$2_migrationUpdateAutomation: typeof migrationUpdateAutomat
|
|
|
2258
2308
|
declare const context$2_overrideApplicationAutomation: typeof overrideApplicationAutomation;
|
|
2259
2309
|
declare const context$2_validateAutomationById: typeof validateAutomationById;
|
|
2260
2310
|
declare namespace context$2 {
|
|
2261
|
-
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_MigrationUpdateAutomation as MigrationUpdateAutomation, type context$2_MigrationUpdateAutomationRequest as MigrationUpdateAutomationRequest, type context$2_MigrationUpdateAutomationResponse as MigrationUpdateAutomationResponse, type context$2_MigrationUpdateAutomationResponseNonNullableFields as MigrationUpdateAutomationResponseNonNullableFields, 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, context$2_migrationUpdateAutomation as migrationUpdateAutomation, 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 };
|
|
2311
|
+
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_MigrationUpdateAutomation as MigrationUpdateAutomation, type context$2_MigrationUpdateAutomationRequest as MigrationUpdateAutomationRequest, type context$2_MigrationUpdateAutomationResponse as MigrationUpdateAutomationResponse, type context$2_MigrationUpdateAutomationResponseNonNullableFields as MigrationUpdateAutomationResponseNonNullableFields, 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, context$2_migrationUpdateAutomation as migrationUpdateAutomation, 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 };
|
|
2262
2312
|
}
|
|
2263
2313
|
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
*/
|
|
2279
|
-
_id?: string | null;
|
|
2280
|
-
/**
|
|
2281
|
-
* Revision number, which increments by 1 each time the automation is updated.
|
|
2282
|
-
* To prevent conflicting changes,
|
|
2283
|
-
* the current revision must be passed when updating the automation.
|
|
2284
|
-
*
|
|
2285
|
-
* Ignored when creating an automation.
|
|
2286
|
-
* @readonly
|
|
2287
|
-
*/
|
|
2288
|
-
revision?: string | null;
|
|
2289
|
-
/**
|
|
2290
|
-
* Information about the creator of the automation.
|
|
2291
|
-
* @readonly
|
|
2292
|
-
*/
|
|
2293
|
-
createdBy?: AuditInfo$1;
|
|
2294
|
-
/**
|
|
2295
|
-
* Date and time the automation was created.
|
|
2296
|
-
* @readonly
|
|
2297
|
-
*/
|
|
2298
|
-
_createdDate?: Date;
|
|
2299
|
-
/**
|
|
2300
|
-
* The entity that last updated the automation.
|
|
2301
|
-
* @readonly
|
|
2302
|
-
*/
|
|
2303
|
-
updatedBy?: AuditInfo$1;
|
|
2314
|
+
type HostModule$1<T, H extends Host$1> = {
|
|
2315
|
+
__type: 'host';
|
|
2316
|
+
create(host: H): T;
|
|
2317
|
+
};
|
|
2318
|
+
type HostModuleAPI$1<T extends HostModule$1<any, any>> = T extends HostModule$1<infer U, any> ? U : never;
|
|
2319
|
+
type Host$1<Environment = unknown> = {
|
|
2320
|
+
channel: {
|
|
2321
|
+
observeState(callback: (props: unknown, environment: Environment) => unknown): {
|
|
2322
|
+
disconnect: () => void;
|
|
2323
|
+
} | Promise<{
|
|
2324
|
+
disconnect: () => void;
|
|
2325
|
+
}>;
|
|
2326
|
+
};
|
|
2327
|
+
environment?: Environment;
|
|
2304
2328
|
/**
|
|
2305
|
-
*
|
|
2306
|
-
* @readonly
|
|
2329
|
+
* Optional name of the environment, use for logging
|
|
2307
2330
|
*/
|
|
2308
|
-
_updatedDate?: Date;
|
|
2309
|
-
/** Automation name that is displayed on the user's site. */
|
|
2310
2331
|
name?: string;
|
|
2311
|
-
/** Automation description. */
|
|
2312
|
-
description?: string | null;
|
|
2313
|
-
/** Object that defines the automation's trigger, actions, and activation status. */
|
|
2314
|
-
configuration?: AutomationConfiguration$1;
|
|
2315
|
-
/** Defines how the automation was added to the site. */
|
|
2316
|
-
origin?: Origin$1;
|
|
2317
|
-
/** Automation settings. */
|
|
2318
|
-
settings?: AutomationSettings$1;
|
|
2319
|
-
/**
|
|
2320
|
-
* Draft info (optional - only if the automation is a draft)
|
|
2321
|
-
* @readonly
|
|
2322
|
-
*/
|
|
2323
|
-
draftInfo?: DraftInfo$1;
|
|
2324
|
-
/** Namespace */
|
|
2325
|
-
namespace?: string | null;
|
|
2326
|
-
}
|
|
2327
|
-
/** @oneof */
|
|
2328
|
-
interface AutomationOriginInfoOneOf$1 {
|
|
2329
|
-
/** Application info */
|
|
2330
|
-
applicationInfo?: ApplicationOrigin$1;
|
|
2331
|
-
/** Preinstalled info */
|
|
2332
|
-
preinstalledInfo?: PreinstalledOrigin$1;
|
|
2333
|
-
}
|
|
2334
|
-
interface ActionSettings$1 {
|
|
2335
|
-
/**
|
|
2336
|
-
* List of actions that cannot be deleted.
|
|
2337
|
-
* Default: Empty. All actions are deletable by default.
|
|
2338
|
-
*/
|
|
2339
|
-
permanentActionIds?: string[];
|
|
2340
2332
|
/**
|
|
2341
|
-
*
|
|
2342
|
-
* Default: Empty. All actions are editable by default.
|
|
2333
|
+
* Optional bast url to use for API requests, for example `www.wixapis.com`
|
|
2343
2334
|
*/
|
|
2344
|
-
|
|
2345
|
-
/** Whether the option to add a delay is disabled for the automation. */
|
|
2346
|
-
disableDelayAddition?: boolean;
|
|
2347
|
-
/** Whether the option to add a condition is disabled for the automation. */
|
|
2348
|
-
disableConditionAddition?: boolean;
|
|
2349
|
-
}
|
|
2350
|
-
interface AuditInfo$1 extends AuditInfoIdOneOf$1 {
|
|
2351
|
-
/** User ID. */
|
|
2352
|
-
userId?: string;
|
|
2353
|
-
/** Application ID. */
|
|
2354
|
-
appId?: string;
|
|
2355
|
-
}
|
|
2356
|
-
/** @oneof */
|
|
2357
|
-
interface AuditInfoIdOneOf$1 {
|
|
2358
|
-
/** User ID. */
|
|
2359
|
-
userId?: string;
|
|
2360
|
-
/** Application ID. */
|
|
2361
|
-
appId?: string;
|
|
2362
|
-
}
|
|
2363
|
-
/** Automation runtime configuration */
|
|
2364
|
-
interface AutomationConfiguration$1 {
|
|
2365
|
-
/** Status of the automation on the site. */
|
|
2366
|
-
status?: AutomationConfigurationStatus;
|
|
2367
|
-
/** Automation trigger configuration. */
|
|
2368
|
-
trigger?: Trigger$1;
|
|
2369
|
-
/** List of IDs of root actions. Root actions are the first actions to run after the trigger. The actions in the list run in parallel. */
|
|
2370
|
-
rootActionIds?: string[];
|
|
2335
|
+
apiBaseUrl?: string;
|
|
2371
2336
|
/**
|
|
2372
|
-
*
|
|
2373
|
-
*
|
|
2337
|
+
* Possible data to be provided by every host, for cross cutting concerns
|
|
2338
|
+
* like internationalization, billing, etc.
|
|
2374
2339
|
*/
|
|
2375
|
-
|
|
2340
|
+
essentials?: {
|
|
2341
|
+
/**
|
|
2342
|
+
* The language of the currently viewed session
|
|
2343
|
+
*/
|
|
2344
|
+
language?: string;
|
|
2345
|
+
/**
|
|
2346
|
+
* The locale of the currently viewed session
|
|
2347
|
+
*/
|
|
2348
|
+
locale?: string;
|
|
2349
|
+
/**
|
|
2350
|
+
* Any headers that should be passed through to the API requests
|
|
2351
|
+
*/
|
|
2352
|
+
passThroughHeaders?: Record<string, string>;
|
|
2353
|
+
};
|
|
2354
|
+
};
|
|
2355
|
+
|
|
2356
|
+
type RESTFunctionDescriptor$1<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient$1) => T;
|
|
2357
|
+
interface HttpClient$1 {
|
|
2358
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
|
|
2359
|
+
fetchWithAuth: typeof fetch;
|
|
2360
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
2361
|
+
getActiveToken?: () => string | undefined;
|
|
2376
2362
|
}
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2381
|
-
|
|
2382
|
-
|
|
2383
|
-
|
|
2363
|
+
type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
|
|
2364
|
+
type HttpResponse$1<T = any> = {
|
|
2365
|
+
data: T;
|
|
2366
|
+
status: number;
|
|
2367
|
+
statusText: string;
|
|
2368
|
+
headers: any;
|
|
2369
|
+
request?: any;
|
|
2370
|
+
};
|
|
2371
|
+
type RequestOptions$1<_TResponse = any, Data = any> = {
|
|
2372
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
2373
|
+
url: string;
|
|
2374
|
+
data?: Data;
|
|
2375
|
+
params?: URLSearchParams;
|
|
2376
|
+
} & APIMetadata$1;
|
|
2377
|
+
type APIMetadata$1 = {
|
|
2378
|
+
methodFqn?: string;
|
|
2379
|
+
entityFqdn?: string;
|
|
2380
|
+
packageName?: string;
|
|
2381
|
+
};
|
|
2382
|
+
type BuildRESTFunction$1<T extends RESTFunctionDescriptor$1> = T extends RESTFunctionDescriptor$1<infer U> ? U : never;
|
|
2383
|
+
type EventDefinition$1<Payload = unknown, Type extends string = string> = {
|
|
2384
|
+
__type: 'event-definition';
|
|
2385
|
+
type: Type;
|
|
2386
|
+
isDomainEvent?: boolean;
|
|
2387
|
+
transformations?: (envelope: unknown) => Payload;
|
|
2388
|
+
__payload: Payload;
|
|
2389
|
+
};
|
|
2390
|
+
declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
|
|
2391
|
+
type EventHandler$1<T extends EventDefinition$1> = (payload: T['__payload']) => void | Promise<void>;
|
|
2392
|
+
type BuildEventDefinition$1<T extends EventDefinition$1<any, string>> = (handler: EventHandler$1<T>) => void;
|
|
2393
|
+
|
|
2394
|
+
type ServicePluginMethodInput$1 = {
|
|
2395
|
+
request: any;
|
|
2396
|
+
metadata: any;
|
|
2397
|
+
};
|
|
2398
|
+
type ServicePluginContract$1 = Record<string, (payload: ServicePluginMethodInput$1) => unknown | Promise<unknown>>;
|
|
2399
|
+
type ServicePluginMethodMetadata$1 = {
|
|
2400
|
+
name: string;
|
|
2401
|
+
primaryHttpMappingPath: string;
|
|
2402
|
+
transformations: {
|
|
2403
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput$1;
|
|
2404
|
+
toREST: (...args: unknown[]) => unknown;
|
|
2405
|
+
};
|
|
2406
|
+
};
|
|
2407
|
+
type ServicePluginDefinition$1<Contract extends ServicePluginContract$1> = {
|
|
2408
|
+
__type: 'service-plugin-definition';
|
|
2409
|
+
componentType: string;
|
|
2410
|
+
methods: ServicePluginMethodMetadata$1[];
|
|
2411
|
+
__contract: Contract;
|
|
2412
|
+
};
|
|
2413
|
+
declare function ServicePluginDefinition$1<Contract extends ServicePluginContract$1>(componentType: string, methods: ServicePluginMethodMetadata$1[]): ServicePluginDefinition$1<Contract>;
|
|
2414
|
+
type BuildServicePluginDefinition$1<T extends ServicePluginDefinition$1<any>> = (implementation: T['__contract']) => void;
|
|
2415
|
+
declare const SERVICE_PLUGIN_ERROR_TYPE$1 = "wix_spi_error";
|
|
2416
|
+
|
|
2417
|
+
type RequestContext$1 = {
|
|
2418
|
+
isSSR: boolean;
|
|
2419
|
+
host: string;
|
|
2420
|
+
protocol?: string;
|
|
2421
|
+
};
|
|
2422
|
+
type ResponseTransformer$1 = (data: any, headers?: any) => any;
|
|
2423
|
+
/**
|
|
2424
|
+
* Ambassador request options types are copied mostly from AxiosRequestConfig.
|
|
2425
|
+
* They are copied and not imported to reduce the amount of dependencies (to reduce install time).
|
|
2426
|
+
* https://github.com/axios/axios/blob/3f53eb6960f05a1f88409c4b731a40de595cb825/index.d.ts#L307-L315
|
|
2427
|
+
*/
|
|
2428
|
+
type Method$1 = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
2429
|
+
type AmbassadorRequestOptions$1<T = any> = {
|
|
2430
|
+
_?: T;
|
|
2431
|
+
url?: string;
|
|
2432
|
+
method?: Method$1;
|
|
2433
|
+
params?: any;
|
|
2434
|
+
data?: any;
|
|
2435
|
+
transformResponse?: ResponseTransformer$1 | ResponseTransformer$1[];
|
|
2436
|
+
};
|
|
2437
|
+
type AmbassadorFactory$1<Request, Response> = (payload: Request) => ((context: RequestContext$1) => AmbassadorRequestOptions$1<Response>) & {
|
|
2438
|
+
__isAmbassador: boolean;
|
|
2439
|
+
};
|
|
2440
|
+
type AmbassadorFunctionDescriptor$1<Request = any, Response = any> = AmbassadorFactory$1<Request, Response>;
|
|
2441
|
+
type BuildAmbassadorFunction$1<T extends AmbassadorFunctionDescriptor$1> = T extends AmbassadorFunctionDescriptor$1<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
2442
|
+
|
|
2443
|
+
declare global {
|
|
2444
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
2445
|
+
interface SymbolConstructor {
|
|
2446
|
+
readonly observable: symbol;
|
|
2447
|
+
}
|
|
2448
|
+
}
|
|
2449
|
+
|
|
2450
|
+
declare const emptyObjectSymbol$1: unique symbol;
|
|
2451
|
+
|
|
2452
|
+
/**
|
|
2453
|
+
Represents a strictly empty plain object, the `{}` value.
|
|
2454
|
+
|
|
2455
|
+
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)).
|
|
2456
|
+
|
|
2457
|
+
@example
|
|
2458
|
+
```
|
|
2459
|
+
import type {EmptyObject} from 'type-fest';
|
|
2460
|
+
|
|
2461
|
+
// The following illustrates the problem with `{}`.
|
|
2462
|
+
const foo1: {} = {}; // Pass
|
|
2463
|
+
const foo2: {} = []; // Pass
|
|
2464
|
+
const foo3: {} = 42; // Pass
|
|
2465
|
+
const foo4: {} = {a: 1}; // Pass
|
|
2466
|
+
|
|
2467
|
+
// With `EmptyObject` only the first case is valid.
|
|
2468
|
+
const bar1: EmptyObject = {}; // Pass
|
|
2469
|
+
const bar2: EmptyObject = 42; // Fail
|
|
2470
|
+
const bar3: EmptyObject = []; // Fail
|
|
2471
|
+
const bar4: EmptyObject = {a: 1}; // Fail
|
|
2472
|
+
```
|
|
2473
|
+
|
|
2474
|
+
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}.
|
|
2475
|
+
|
|
2476
|
+
@category Object
|
|
2477
|
+
*/
|
|
2478
|
+
type EmptyObject$1 = {[emptyObjectSymbol$1]?: never};
|
|
2479
|
+
|
|
2480
|
+
/**
|
|
2481
|
+
Returns a boolean for whether the two given types are equal.
|
|
2482
|
+
|
|
2483
|
+
@link https://github.com/microsoft/TypeScript/issues/27024#issuecomment-421529650
|
|
2484
|
+
@link https://stackoverflow.com/questions/68961864/how-does-the-equals-work-in-typescript/68963796#68963796
|
|
2485
|
+
|
|
2486
|
+
Use-cases:
|
|
2487
|
+
- If you want to make a conditional branch based on the result of a comparison of two types.
|
|
2488
|
+
|
|
2489
|
+
@example
|
|
2490
|
+
```
|
|
2491
|
+
import type {IsEqual} from 'type-fest';
|
|
2492
|
+
|
|
2493
|
+
// This type returns a boolean for whether the given array includes the given item.
|
|
2494
|
+
// `IsEqual` is used to compare the given array at position 0 and the given item and then return true if they are equal.
|
|
2495
|
+
type Includes<Value extends readonly any[], Item> =
|
|
2496
|
+
Value extends readonly [Value[0], ...infer rest]
|
|
2497
|
+
? IsEqual<Value[0], Item> extends true
|
|
2498
|
+
? true
|
|
2499
|
+
: Includes<rest, Item>
|
|
2500
|
+
: false;
|
|
2501
|
+
```
|
|
2502
|
+
|
|
2503
|
+
@category Type Guard
|
|
2504
|
+
@category Utilities
|
|
2505
|
+
*/
|
|
2506
|
+
type IsEqual$1<A, B> =
|
|
2507
|
+
(<G>() => G extends A ? 1 : 2) extends
|
|
2508
|
+
(<G>() => G extends B ? 1 : 2)
|
|
2509
|
+
? true
|
|
2510
|
+
: false;
|
|
2511
|
+
|
|
2512
|
+
/**
|
|
2513
|
+
Filter out keys from an object.
|
|
2514
|
+
|
|
2515
|
+
Returns `never` if `Exclude` is strictly equal to `Key`.
|
|
2516
|
+
Returns `never` if `Key` extends `Exclude`.
|
|
2517
|
+
Returns `Key` otherwise.
|
|
2518
|
+
|
|
2519
|
+
@example
|
|
2520
|
+
```
|
|
2521
|
+
type Filtered = Filter<'foo', 'foo'>;
|
|
2522
|
+
//=> never
|
|
2523
|
+
```
|
|
2524
|
+
|
|
2525
|
+
@example
|
|
2526
|
+
```
|
|
2527
|
+
type Filtered = Filter<'bar', string>;
|
|
2528
|
+
//=> never
|
|
2529
|
+
```
|
|
2530
|
+
|
|
2531
|
+
@example
|
|
2532
|
+
```
|
|
2533
|
+
type Filtered = Filter<'bar', 'foo'>;
|
|
2534
|
+
//=> 'bar'
|
|
2535
|
+
```
|
|
2536
|
+
|
|
2537
|
+
@see {Except}
|
|
2538
|
+
*/
|
|
2539
|
+
type Filter$3<KeyType, ExcludeType> = IsEqual$1<KeyType, ExcludeType> extends true ? never : (KeyType extends ExcludeType ? never : KeyType);
|
|
2540
|
+
|
|
2541
|
+
type ExceptOptions$1 = {
|
|
2542
|
+
/**
|
|
2543
|
+
Disallow assigning non-specified properties.
|
|
2544
|
+
|
|
2545
|
+
Note that any omitted properties in the resulting type will be present in autocomplete as `undefined`.
|
|
2546
|
+
|
|
2547
|
+
@default false
|
|
2548
|
+
*/
|
|
2549
|
+
requireExactProps?: boolean;
|
|
2550
|
+
};
|
|
2551
|
+
|
|
2552
|
+
/**
|
|
2553
|
+
Create a type from an object type without certain keys.
|
|
2554
|
+
|
|
2555
|
+
We recommend setting the `requireExactProps` option to `true`.
|
|
2556
|
+
|
|
2557
|
+
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.
|
|
2558
|
+
|
|
2559
|
+
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)).
|
|
2560
|
+
|
|
2561
|
+
@example
|
|
2562
|
+
```
|
|
2563
|
+
import type {Except} from 'type-fest';
|
|
2564
|
+
|
|
2565
|
+
type Foo = {
|
|
2566
|
+
a: number;
|
|
2567
|
+
b: string;
|
|
2568
|
+
};
|
|
2569
|
+
|
|
2570
|
+
type FooWithoutA = Except<Foo, 'a'>;
|
|
2571
|
+
//=> {b: string}
|
|
2572
|
+
|
|
2573
|
+
const fooWithoutA: FooWithoutA = {a: 1, b: '2'};
|
|
2574
|
+
//=> errors: 'a' does not exist in type '{ b: string; }'
|
|
2575
|
+
|
|
2576
|
+
type FooWithoutB = Except<Foo, 'b', {requireExactProps: true}>;
|
|
2577
|
+
//=> {a: number} & Partial<Record<"b", never>>
|
|
2578
|
+
|
|
2579
|
+
const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
|
|
2580
|
+
//=> errors at 'b': Type 'string' is not assignable to type 'undefined'.
|
|
2581
|
+
```
|
|
2582
|
+
|
|
2583
|
+
@category Object
|
|
2584
|
+
*/
|
|
2585
|
+
type Except$1<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions$1 = {requireExactProps: false}> = {
|
|
2586
|
+
[KeyType in keyof ObjectType as Filter$3<KeyType, KeysType>]: ObjectType[KeyType];
|
|
2587
|
+
} & (Options['requireExactProps'] extends true
|
|
2588
|
+
? Partial<Record<KeysType, never>>
|
|
2589
|
+
: {});
|
|
2590
|
+
|
|
2591
|
+
/**
|
|
2592
|
+
Returns a boolean for whether the given type is `never`.
|
|
2593
|
+
|
|
2594
|
+
@link https://github.com/microsoft/TypeScript/issues/31751#issuecomment-498526919
|
|
2595
|
+
@link https://stackoverflow.com/a/53984913/10292952
|
|
2596
|
+
@link https://www.zhenghao.io/posts/ts-never
|
|
2597
|
+
|
|
2598
|
+
Useful in type utilities, such as checking if something does not occur.
|
|
2599
|
+
|
|
2600
|
+
@example
|
|
2601
|
+
```
|
|
2602
|
+
import type {IsNever, And} from 'type-fest';
|
|
2603
|
+
|
|
2604
|
+
// https://github.com/andnp/SimplyTyped/blob/master/src/types/strings.ts
|
|
2605
|
+
type AreStringsEqual<A extends string, B extends string> =
|
|
2606
|
+
And<
|
|
2607
|
+
IsNever<Exclude<A, B>> extends true ? true : false,
|
|
2608
|
+
IsNever<Exclude<B, A>> extends true ? true : false
|
|
2609
|
+
>;
|
|
2610
|
+
|
|
2611
|
+
type EndIfEqual<I extends string, O extends string> =
|
|
2612
|
+
AreStringsEqual<I, O> extends true
|
|
2613
|
+
? never
|
|
2614
|
+
: void;
|
|
2615
|
+
|
|
2616
|
+
function endIfEqual<I extends string, O extends string>(input: I, output: O): EndIfEqual<I, O> {
|
|
2617
|
+
if (input === output) {
|
|
2618
|
+
process.exit(0);
|
|
2619
|
+
}
|
|
2620
|
+
}
|
|
2621
|
+
|
|
2622
|
+
endIfEqual('abc', 'abc');
|
|
2623
|
+
//=> never
|
|
2624
|
+
|
|
2625
|
+
endIfEqual('abc', '123');
|
|
2626
|
+
//=> void
|
|
2627
|
+
```
|
|
2628
|
+
|
|
2629
|
+
@category Type Guard
|
|
2630
|
+
@category Utilities
|
|
2631
|
+
*/
|
|
2632
|
+
type IsNever$1<T> = [T] extends [never] ? true : false;
|
|
2633
|
+
|
|
2634
|
+
/**
|
|
2635
|
+
An if-else-like type that resolves depending on whether the given type is `never`.
|
|
2636
|
+
|
|
2637
|
+
@see {@link IsNever}
|
|
2638
|
+
|
|
2639
|
+
@example
|
|
2640
|
+
```
|
|
2641
|
+
import type {IfNever} from 'type-fest';
|
|
2642
|
+
|
|
2643
|
+
type ShouldBeTrue = IfNever<never>;
|
|
2644
|
+
//=> true
|
|
2645
|
+
|
|
2646
|
+
type ShouldBeBar = IfNever<'not never', 'foo', 'bar'>;
|
|
2647
|
+
//=> 'bar'
|
|
2648
|
+
```
|
|
2649
|
+
|
|
2650
|
+
@category Type Guard
|
|
2651
|
+
@category Utilities
|
|
2652
|
+
*/
|
|
2653
|
+
type IfNever$1<T, TypeIfNever = true, TypeIfNotNever = false> = (
|
|
2654
|
+
IsNever$1<T> extends true ? TypeIfNever : TypeIfNotNever
|
|
2655
|
+
);
|
|
2656
|
+
|
|
2657
|
+
/**
|
|
2658
|
+
Extract the keys from a type where the value type of the key extends the given `Condition`.
|
|
2659
|
+
|
|
2660
|
+
Internally this is used for the `ConditionalPick` and `ConditionalExcept` types.
|
|
2661
|
+
|
|
2662
|
+
@example
|
|
2663
|
+
```
|
|
2664
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
2665
|
+
|
|
2666
|
+
interface Example {
|
|
2667
|
+
a: string;
|
|
2668
|
+
b: string | number;
|
|
2669
|
+
c?: string;
|
|
2670
|
+
d: {};
|
|
2671
|
+
}
|
|
2672
|
+
|
|
2673
|
+
type StringKeysOnly = ConditionalKeys<Example, string>;
|
|
2674
|
+
//=> 'a'
|
|
2675
|
+
```
|
|
2676
|
+
|
|
2677
|
+
To support partial types, make sure your `Condition` is a union of undefined (for example, `string | undefined`) as demonstrated below.
|
|
2678
|
+
|
|
2679
|
+
@example
|
|
2680
|
+
```
|
|
2681
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
2682
|
+
|
|
2683
|
+
type StringKeysAndUndefined = ConditionalKeys<Example, string | undefined>;
|
|
2684
|
+
//=> 'a' | 'c'
|
|
2685
|
+
```
|
|
2686
|
+
|
|
2687
|
+
@category Object
|
|
2688
|
+
*/
|
|
2689
|
+
type ConditionalKeys$1<Base, Condition> =
|
|
2690
|
+
{
|
|
2691
|
+
// Map through all the keys of the given base type.
|
|
2692
|
+
[Key in keyof Base]-?:
|
|
2693
|
+
// Pick only keys with types extending the given `Condition` type.
|
|
2694
|
+
Base[Key] extends Condition
|
|
2695
|
+
// Retain this key
|
|
2696
|
+
// If the value for the key extends never, only include it if `Condition` also extends never
|
|
2697
|
+
? IfNever$1<Base[Key], IfNever$1<Condition, Key, never>, Key>
|
|
2698
|
+
// Discard this key since the condition fails.
|
|
2699
|
+
: never;
|
|
2700
|
+
// Convert the produced object into a union type of the keys which passed the conditional test.
|
|
2701
|
+
}[keyof Base];
|
|
2702
|
+
|
|
2703
|
+
/**
|
|
2704
|
+
Exclude keys from a shape that matches the given `Condition`.
|
|
2705
|
+
|
|
2706
|
+
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.
|
|
2707
|
+
|
|
2708
|
+
@example
|
|
2709
|
+
```
|
|
2710
|
+
import type {Primitive, ConditionalExcept} from 'type-fest';
|
|
2711
|
+
|
|
2712
|
+
class Awesome {
|
|
2713
|
+
name: string;
|
|
2714
|
+
successes: number;
|
|
2715
|
+
failures: bigint;
|
|
2716
|
+
|
|
2717
|
+
run() {}
|
|
2718
|
+
}
|
|
2719
|
+
|
|
2720
|
+
type ExceptPrimitivesFromAwesome = ConditionalExcept<Awesome, Primitive>;
|
|
2721
|
+
//=> {run: () => void}
|
|
2722
|
+
```
|
|
2723
|
+
|
|
2724
|
+
@example
|
|
2725
|
+
```
|
|
2726
|
+
import type {ConditionalExcept} from 'type-fest';
|
|
2727
|
+
|
|
2728
|
+
interface Example {
|
|
2729
|
+
a: string;
|
|
2730
|
+
b: string | number;
|
|
2731
|
+
c: () => void;
|
|
2732
|
+
d: {};
|
|
2733
|
+
}
|
|
2734
|
+
|
|
2735
|
+
type NonStringKeysOnly = ConditionalExcept<Example, string>;
|
|
2736
|
+
//=> {b: string | number; c: () => void; d: {}}
|
|
2737
|
+
```
|
|
2738
|
+
|
|
2739
|
+
@category Object
|
|
2740
|
+
*/
|
|
2741
|
+
type ConditionalExcept$1<Base, Condition> = Except$1<
|
|
2742
|
+
Base,
|
|
2743
|
+
ConditionalKeys$1<Base, Condition>
|
|
2744
|
+
>;
|
|
2745
|
+
|
|
2746
|
+
/**
|
|
2747
|
+
* Descriptors are objects that describe the API of a module, and the module
|
|
2748
|
+
* can either be a REST module or a host module.
|
|
2749
|
+
* This type is recursive, so it can describe nested modules.
|
|
2750
|
+
*/
|
|
2751
|
+
type Descriptors$1 = RESTFunctionDescriptor$1 | AmbassadorFunctionDescriptor$1 | HostModule$1<any, any> | EventDefinition$1<any> | ServicePluginDefinition$1<any> | {
|
|
2752
|
+
[key: string]: Descriptors$1 | PublicMetadata$1 | any;
|
|
2753
|
+
};
|
|
2754
|
+
/**
|
|
2755
|
+
* This type takes in a descriptors object of a certain Host (including an `unknown` host)
|
|
2756
|
+
* and returns an object with the same structure, but with all descriptors replaced with their API.
|
|
2757
|
+
* Any non-descriptor properties are removed from the returned object, including descriptors that
|
|
2758
|
+
* do not match the given host (as they will not work with the given host).
|
|
2759
|
+
*/
|
|
2760
|
+
type BuildDescriptors$1<T extends Descriptors$1, H extends Host$1<any> | undefined, Depth extends number = 5> = {
|
|
2761
|
+
done: T;
|
|
2762
|
+
recurse: T extends {
|
|
2763
|
+
__type: typeof SERVICE_PLUGIN_ERROR_TYPE$1;
|
|
2764
|
+
} ? never : T extends AmbassadorFunctionDescriptor$1 ? BuildAmbassadorFunction$1<T> : T extends RESTFunctionDescriptor$1 ? BuildRESTFunction$1<T> : T extends EventDefinition$1<any> ? BuildEventDefinition$1<T> : T extends ServicePluginDefinition$1<any> ? BuildServicePluginDefinition$1<T> : T extends HostModule$1<any, any> ? HostModuleAPI$1<T> : ConditionalExcept$1<{
|
|
2765
|
+
[Key in keyof T]: T[Key] extends Descriptors$1 ? BuildDescriptors$1<T[Key], H, [
|
|
2766
|
+
-1,
|
|
2767
|
+
0,
|
|
2768
|
+
1,
|
|
2769
|
+
2,
|
|
2770
|
+
3,
|
|
2771
|
+
4,
|
|
2772
|
+
5
|
|
2773
|
+
][Depth]> : never;
|
|
2774
|
+
}, EmptyObject$1>;
|
|
2775
|
+
}[Depth extends -1 ? 'done' : 'recurse'];
|
|
2776
|
+
type PublicMetadata$1 = {
|
|
2777
|
+
PACKAGE_NAME?: string;
|
|
2778
|
+
};
|
|
2779
|
+
|
|
2780
|
+
declare global {
|
|
2781
|
+
interface ContextualClient {
|
|
2782
|
+
}
|
|
2783
|
+
}
|
|
2784
|
+
/**
|
|
2785
|
+
* A type used to create concerete types from SDK descriptors in
|
|
2786
|
+
* case a contextual client is available.
|
|
2787
|
+
*/
|
|
2788
|
+
type MaybeContext$1<T extends Descriptors$1> = globalThis.ContextualClient extends {
|
|
2789
|
+
host: Host$1;
|
|
2790
|
+
} ? BuildDescriptors$1<T, globalThis.ContextualClient['host']> : T;
|
|
2791
|
+
|
|
2792
|
+
interface Activation {
|
|
2793
|
+
/** Activation ID */
|
|
2794
|
+
_id?: string;
|
|
2795
|
+
/** Activation automation */
|
|
2796
|
+
automation?: Automation$1;
|
|
2797
|
+
}
|
|
2798
|
+
interface Automation$1 extends AutomationOriginInfoOneOf$1 {
|
|
2799
|
+
/** Application info */
|
|
2800
|
+
applicationInfo?: ApplicationOrigin$1;
|
|
2801
|
+
/** Preinstalled info */
|
|
2802
|
+
preinstalledInfo?: PreinstalledOrigin$1;
|
|
2803
|
+
/**
|
|
2804
|
+
* Automation ID.
|
|
2805
|
+
* @readonly
|
|
2806
|
+
*/
|
|
2807
|
+
_id?: string | null;
|
|
2808
|
+
/**
|
|
2809
|
+
* Revision number, which increments by 1 each time the automation is updated.
|
|
2810
|
+
* To prevent conflicting changes,
|
|
2811
|
+
* the current revision must be passed when updating the automation.
|
|
2812
|
+
*
|
|
2813
|
+
* Ignored when creating an automation.
|
|
2814
|
+
* @readonly
|
|
2815
|
+
*/
|
|
2816
|
+
revision?: string | null;
|
|
2817
|
+
/**
|
|
2818
|
+
* Information about the creator of the automation.
|
|
2819
|
+
* @readonly
|
|
2820
|
+
*/
|
|
2821
|
+
createdBy?: AuditInfo$1;
|
|
2822
|
+
/**
|
|
2823
|
+
* Date and time the automation was created.
|
|
2824
|
+
* @readonly
|
|
2825
|
+
*/
|
|
2826
|
+
_createdDate?: Date;
|
|
2827
|
+
/**
|
|
2828
|
+
* The entity that last updated the automation.
|
|
2829
|
+
* @readonly
|
|
2830
|
+
*/
|
|
2831
|
+
updatedBy?: AuditInfo$1;
|
|
2832
|
+
/**
|
|
2833
|
+
* Date and time the automation was last updated.
|
|
2834
|
+
* @readonly
|
|
2835
|
+
*/
|
|
2836
|
+
_updatedDate?: Date;
|
|
2837
|
+
/** Automation name that is displayed on the user's site. */
|
|
2838
|
+
name?: string;
|
|
2839
|
+
/** Automation description. */
|
|
2840
|
+
description?: string | null;
|
|
2841
|
+
/** Object that defines the automation's trigger, actions, and activation status. */
|
|
2842
|
+
configuration?: AutomationConfiguration$1;
|
|
2843
|
+
/** Defines how the automation was added to the site. */
|
|
2844
|
+
origin?: Origin$1;
|
|
2845
|
+
/** Automation settings. */
|
|
2846
|
+
settings?: AutomationSettings$1;
|
|
2847
|
+
/**
|
|
2848
|
+
* Draft info (optional - only if the automation is a draft)
|
|
2849
|
+
* @readonly
|
|
2850
|
+
*/
|
|
2851
|
+
draftInfo?: DraftInfo$1;
|
|
2852
|
+
/** Namespace */
|
|
2853
|
+
namespace?: string | null;
|
|
2854
|
+
}
|
|
2855
|
+
/** @oneof */
|
|
2856
|
+
interface AutomationOriginInfoOneOf$1 {
|
|
2857
|
+
/** Application info */
|
|
2858
|
+
applicationInfo?: ApplicationOrigin$1;
|
|
2859
|
+
/** Preinstalled info */
|
|
2860
|
+
preinstalledInfo?: PreinstalledOrigin$1;
|
|
2861
|
+
}
|
|
2862
|
+
interface ActionSettings$1 {
|
|
2863
|
+
/**
|
|
2864
|
+
* List of actions that cannot be deleted.
|
|
2865
|
+
* Default: Empty. All actions are deletable by default.
|
|
2866
|
+
*/
|
|
2867
|
+
permanentActionIds?: string[];
|
|
2868
|
+
/**
|
|
2869
|
+
* List of actions that cannot be edited.
|
|
2870
|
+
* Default: Empty. All actions are editable by default.
|
|
2871
|
+
*/
|
|
2872
|
+
readonlyActionIds?: string[];
|
|
2873
|
+
/** Whether the option to add a delay is disabled for the automation. */
|
|
2874
|
+
disableDelayAddition?: boolean;
|
|
2875
|
+
/** Whether the option to add a condition is disabled for the automation. */
|
|
2876
|
+
disableConditionAddition?: boolean;
|
|
2877
|
+
}
|
|
2878
|
+
interface AuditInfo$1 extends AuditInfoIdOneOf$1 {
|
|
2879
|
+
/** User ID. */
|
|
2880
|
+
userId?: string;
|
|
2881
|
+
/** Application ID. */
|
|
2882
|
+
appId?: string;
|
|
2883
|
+
}
|
|
2884
|
+
/** @oneof */
|
|
2885
|
+
interface AuditInfoIdOneOf$1 {
|
|
2886
|
+
/** User ID. */
|
|
2887
|
+
userId?: string;
|
|
2888
|
+
/** Application ID. */
|
|
2889
|
+
appId?: string;
|
|
2890
|
+
}
|
|
2891
|
+
/** Automation runtime configuration */
|
|
2892
|
+
interface AutomationConfiguration$1 {
|
|
2893
|
+
/** Status of the automation on the site. */
|
|
2894
|
+
status?: AutomationConfigurationStatus;
|
|
2895
|
+
/** Automation trigger configuration. */
|
|
2896
|
+
trigger?: Trigger$1;
|
|
2897
|
+
/** List of IDs of root actions. Root actions are the first actions to run after the trigger. The actions in the list run in parallel. */
|
|
2898
|
+
rootActionIds?: string[];
|
|
2899
|
+
/**
|
|
2900
|
+
* Map of all actions that the automation may execute.
|
|
2901
|
+
* The key is the action ID, and the value is the action configuration.
|
|
2902
|
+
*/
|
|
2903
|
+
actions?: Record<string, AutomationConfigurationAction>;
|
|
2904
|
+
}
|
|
2905
|
+
declare enum TimeUnit$1 {
|
|
2906
|
+
UNKNOWN_TIME_UNIT = "UNKNOWN_TIME_UNIT",
|
|
2907
|
+
MINUTES = "MINUTES",
|
|
2908
|
+
HOURS = "HOURS",
|
|
2909
|
+
DAYS = "DAYS",
|
|
2910
|
+
WEEKS = "WEEKS",
|
|
2911
|
+
MONTHS = "MONTHS"
|
|
2384
2912
|
}
|
|
2385
|
-
interface Filter$
|
|
2913
|
+
interface Filter$2 {
|
|
2386
2914
|
/** Filter ID. */
|
|
2387
2915
|
_id?: string;
|
|
2388
2916
|
/** Field key from the payload schema, for example "formId". */
|
|
@@ -2508,7 +3036,7 @@ interface Trigger$1 {
|
|
|
2508
3036
|
* List of filters on schema fields.
|
|
2509
3037
|
* In order for the automation to run, all filter expressions must evaluate to `true` for a given payload.
|
|
2510
3038
|
*/
|
|
2511
|
-
filters?: Filter$
|
|
3039
|
+
filters?: Filter$2[];
|
|
2512
3040
|
/** Defines the time offset between the trigger date and when the automation runs. */
|
|
2513
3041
|
scheduledEventOffset?: FutureDateActivationOffset$1;
|
|
2514
3042
|
/** Limits the number of times an automation can be triggered. */
|
|
@@ -3729,265 +4257,725 @@ interface ActivationStatusChangedEnvelope {
|
|
|
3729
4257
|
}
|
|
3730
4258
|
interface ReportEventOptions {
|
|
3731
4259
|
/**
|
|
3732
|
-
* Event payload, formatted as key:value pairs.
|
|
3733
|
-
* Must comply with the payload schema
|
|
3734
|
-
* if you provided one when configuring your trigger.
|
|
3735
|
-
*
|
|
3736
|
-
* Key names can include only alphanumeric characters or underscores
|
|
3737
|
-
* (`A-Z`, `a-z`, `0-9`, `_`).
|
|
3738
|
-
* They cannot start with an underscore.
|
|
3739
|
-
*
|
|
3740
|
-
* Values can be strings, numbers, integers, booleans, or arrays.
|
|
3741
|
-
* If a value is an array, the array items must be objects,
|
|
3742
|
-
* and nested object properties must be
|
|
3743
|
-
* strings, numbers, integers, or booleans only.
|
|
4260
|
+
* Event payload, formatted as key:value pairs.
|
|
4261
|
+
* Must comply with the payload schema
|
|
4262
|
+
* if you provided one when configuring your trigger.
|
|
4263
|
+
*
|
|
4264
|
+
* Key names can include only alphanumeric characters or underscores
|
|
4265
|
+
* (`A-Z`, `a-z`, `0-9`, `_`).
|
|
4266
|
+
* They cannot start with an underscore.
|
|
4267
|
+
*
|
|
4268
|
+
* Values can be strings, numbers, integers, booleans, or arrays.
|
|
4269
|
+
* If a value is an array, the array items must be objects,
|
|
4270
|
+
* and nested object properties must be
|
|
4271
|
+
* strings, numbers, integers, or booleans only.
|
|
4272
|
+
*/
|
|
4273
|
+
payload?: Record<string, any> | null;
|
|
4274
|
+
/**
|
|
4275
|
+
* ID of the related resource in GUID format.
|
|
4276
|
+
* For example, `fc81a355-3429-50fc-a4c7-def486e828f3`.
|
|
4277
|
+
*
|
|
4278
|
+
* Required if your app needs to
|
|
4279
|
+
* [cancel the event](https://dev.wix.com/docs/sdk/backend-modules/automations/triggered-events/cancel-event)
|
|
4280
|
+
* if the automation becomes no longer relevant.
|
|
4281
|
+
*
|
|
4282
|
+
* Typically, this ID is defined in your system,
|
|
4283
|
+
* but you can also use any Wix resource GUID,
|
|
4284
|
+
* such as contact ID, member ID, or invoice ID.
|
|
4285
|
+
* See
|
|
4286
|
+
* [Choose the right `externalEntityId`](https://dev.wix.com/docs/rest/business-management/automations/triggered-events/reporting-and-canceling-events#about-canceling-events)
|
|
4287
|
+
* for more information.
|
|
4288
|
+
*/
|
|
4289
|
+
externalEntityId?: string | null;
|
|
4290
|
+
/** Idempotency information for the event */
|
|
4291
|
+
idempotency?: Idempotency;
|
|
4292
|
+
}
|
|
4293
|
+
|
|
4294
|
+
declare function reportEvent$1(httpClient: HttpClient$1): ReportEventSignature;
|
|
4295
|
+
interface ReportEventSignature {
|
|
4296
|
+
/**
|
|
4297
|
+
* Reports an event and activates site automations with the specified trigger key.
|
|
4298
|
+
*
|
|
4299
|
+
*
|
|
4300
|
+
* Only the app that created a trigger can report events for it.
|
|
4301
|
+
* This means other apps can't report events for your triggers,
|
|
4302
|
+
* and you can't report events for another app's triggers.
|
|
4303
|
+
*
|
|
4304
|
+
* If your app supports canceling events,
|
|
4305
|
+
* `externalEntityId` must be provided.
|
|
4306
|
+
* `externalEntityId` is required when calling [cancelEvent()](#cancel-event).
|
|
4307
|
+
* @param - Trigger key as defined in your app's trigger configuration
|
|
4308
|
+
* in the app dashboard.
|
|
4309
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
4310
|
+
*/
|
|
4311
|
+
(triggerKey: string, options?: ReportEventOptions | undefined): Promise<ReportEventResponse & ReportEventResponseNonNullableFields>;
|
|
4312
|
+
}
|
|
4313
|
+
declare function bulkReportEvent$1(httpClient: HttpClient$1): BulkReportEventSignature;
|
|
4314
|
+
interface BulkReportEventSignature {
|
|
4315
|
+
/**
|
|
4316
|
+
* Bulk reports events and activates site automations with the specified trigger key.
|
|
4317
|
+
* @param - Trigger key as defined in your app's trigger configuration
|
|
4318
|
+
* in the app dashboard.
|
|
4319
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
4320
|
+
* @param - Repeated list of event details for bulk reporting
|
|
4321
|
+
*/
|
|
4322
|
+
(triggerKey: string, eventsInfo: EventInfo[]): Promise<BulkReportEventResponse & BulkReportEventResponseNonNullableFields>;
|
|
4323
|
+
}
|
|
4324
|
+
declare function bulkCancelEvent$1(httpClient: HttpClient$1): BulkCancelEventSignature;
|
|
4325
|
+
interface BulkCancelEventSignature {
|
|
4326
|
+
/**
|
|
4327
|
+
* Bulk cancels any remaining actions for a trigger and external entities.
|
|
4328
|
+
* @param - Trigger key whose events you want to cancel.
|
|
4329
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
4330
|
+
* @param - Repeated list of external_entity_id, representing the related resources' IDs
|
|
4331
|
+
*/
|
|
4332
|
+
(triggerKey: string, externalEntityIds: string[]): Promise<BulkCancelEventResponse & BulkCancelEventResponseNonNullableFields>;
|
|
4333
|
+
}
|
|
4334
|
+
declare function cancelEvent$1(httpClient: HttpClient$1): CancelEventSignature;
|
|
4335
|
+
interface CancelEventSignature {
|
|
4336
|
+
/**
|
|
4337
|
+
* Cancels any remaining actions for a trigger and external entity.
|
|
4338
|
+
*
|
|
4339
|
+
*
|
|
4340
|
+
* Events are not cancelable by default.
|
|
4341
|
+
* To make an event cancelable,
|
|
4342
|
+
* you must first pass an `externalEntityId`
|
|
4343
|
+
* and the applicable `triggerKey` to [reportEvent()](#report-event).
|
|
4344
|
+
* When you call cancelEvent() with the same `externalEntityId` and `triggerKey`,
|
|
4345
|
+
* the event is canceled,
|
|
4346
|
+
* as are all other events that share the `externalEntityId` and `triggerKey`.
|
|
4347
|
+
* @param - Trigger key whose event you want to cancel.
|
|
4348
|
+
* For example, `form_submitted` or `invoice_due`.
|
|
4349
|
+
* @param - ID of the related resource in GUID format.
|
|
4350
|
+
* For example, `fc81a355-3429-50fc-a4c7-def486e828f3`.
|
|
4351
|
+
*
|
|
4352
|
+
* Typically, this ID is defined in your system,
|
|
4353
|
+
* but you can also use any Wix resource GUID,
|
|
4354
|
+
* such as contact ID, member ID, or invoice ID.
|
|
4355
|
+
* See
|
|
4356
|
+
* [Choose the right `externalEntityId`](https://dev.wix.com/docs/rest/business-management/automations/triggered-events/reporting-and-canceling-events#choose-the-right-externalentityid)
|
|
4357
|
+
* for more information.
|
|
4358
|
+
*/
|
|
4359
|
+
(triggerKey: string, externalEntityId: string): Promise<void>;
|
|
4360
|
+
}
|
|
4361
|
+
declare const onActivationStatusChanged$1: EventDefinition$1<ActivationStatusChangedEnvelope, "wix.automations.v2.activation_activation_status_changed">;
|
|
4362
|
+
|
|
4363
|
+
declare function createEventModule$1<T extends EventDefinition$1<any, string>>(eventDefinition: T): BuildEventDefinition$1<T> & T;
|
|
4364
|
+
|
|
4365
|
+
declare const reportEvent: MaybeContext$1<BuildRESTFunction$1<typeof reportEvent$1> & typeof reportEvent$1>;
|
|
4366
|
+
declare const bulkReportEvent: MaybeContext$1<BuildRESTFunction$1<typeof bulkReportEvent$1> & typeof bulkReportEvent$1>;
|
|
4367
|
+
declare const bulkCancelEvent: MaybeContext$1<BuildRESTFunction$1<typeof bulkCancelEvent$1> & typeof bulkCancelEvent$1>;
|
|
4368
|
+
declare const cancelEvent: MaybeContext$1<BuildRESTFunction$1<typeof cancelEvent$1> & typeof cancelEvent$1>;
|
|
4369
|
+
|
|
4370
|
+
type _publicOnActivationStatusChangedType = typeof onActivationStatusChanged$1;
|
|
4371
|
+
/**
|
|
4372
|
+
* activation status changed message
|
|
4373
|
+
*/
|
|
4374
|
+
declare const onActivationStatusChanged: ReturnType<typeof createEventModule$1<_publicOnActivationStatusChangedType>>;
|
|
4375
|
+
|
|
4376
|
+
type context$1_ActionActionOneOf = ActionActionOneOf;
|
|
4377
|
+
type context$1_ActionCompletedRequest = ActionCompletedRequest;
|
|
4378
|
+
type context$1_ActionData = ActionData;
|
|
4379
|
+
type context$1_ActionStatus = ActionStatus;
|
|
4380
|
+
type context$1_ActionsData = ActionsData;
|
|
4381
|
+
type context$1_Activation = Activation;
|
|
4382
|
+
type context$1_ActivationActionStatusChanged = ActivationActionStatusChanged;
|
|
4383
|
+
type context$1_ActivationActionStatusChangedStatus = ActivationActionStatusChangedStatus;
|
|
4384
|
+
declare const context$1_ActivationActionStatusChangedStatus: typeof ActivationActionStatusChangedStatus;
|
|
4385
|
+
type context$1_ActivationActionStatusChangedStatusInfoOneOf = ActivationActionStatusChangedStatusInfoOneOf;
|
|
4386
|
+
type context$1_ActivationContinuedAfterSchedule = ActivationContinuedAfterSchedule;
|
|
4387
|
+
type context$1_ActivationRequest = ActivationRequest;
|
|
4388
|
+
type context$1_ActivationResumeAfterDelay = ActivationResumeAfterDelay;
|
|
4389
|
+
type context$1_ActivationScheduleCompleted = ActivationScheduleCompleted;
|
|
4390
|
+
type context$1_ActivationScheduleRequested = ActivationScheduleRequested;
|
|
4391
|
+
type context$1_ActivationSource = ActivationSource;
|
|
4392
|
+
type context$1_ActivationSourceOfOneOf = ActivationSourceOfOneOf;
|
|
4393
|
+
type context$1_ActivationStatus = ActivationStatus;
|
|
4394
|
+
type context$1_ActivationStatusChanged = ActivationStatusChanged;
|
|
4395
|
+
type context$1_ActivationStatusChangedEnvelope = ActivationStatusChangedEnvelope;
|
|
4396
|
+
type context$1_ActivationStatusChangedFailedStatusInfo = ActivationStatusChangedFailedStatusInfo;
|
|
4397
|
+
type context$1_ActivationStatusChangedStatus = ActivationStatusChangedStatus;
|
|
4398
|
+
declare const context$1_ActivationStatusChangedStatus: typeof ActivationStatusChangedStatus;
|
|
4399
|
+
type context$1_ActivationStatusChangedStatusInfoOneOf = ActivationStatusChangedStatusInfoOneOf;
|
|
4400
|
+
type context$1_AppDefinedActionInfo = AppDefinedActionInfo;
|
|
4401
|
+
type context$1_AsyncAction = AsyncAction;
|
|
4402
|
+
type context$1_AutomationConfigurationAction = AutomationConfigurationAction;
|
|
4403
|
+
type context$1_AutomationConfigurationActionInfoOneOf = AutomationConfigurationActionInfoOneOf;
|
|
4404
|
+
type context$1_AutomationConfigurationStatus = AutomationConfigurationStatus;
|
|
4405
|
+
declare const context$1_AutomationConfigurationStatus: typeof AutomationConfigurationStatus;
|
|
4406
|
+
type context$1_AutomationIdentifier = AutomationIdentifier;
|
|
4407
|
+
type context$1_AutomationInfo = AutomationInfo;
|
|
4408
|
+
type context$1_AutomationInfoOriginInfoOneOf = AutomationInfoOriginInfoOneOf;
|
|
4409
|
+
type context$1_BatchActivationRequest = BatchActivationRequest;
|
|
4410
|
+
type context$1_BlockType = BlockType;
|
|
4411
|
+
declare const context$1_BlockType: typeof BlockType;
|
|
4412
|
+
type context$1_BulkCancelEventRequest = BulkCancelEventRequest;
|
|
4413
|
+
type context$1_BulkCancelEventResponse = BulkCancelEventResponse;
|
|
4414
|
+
type context$1_BulkCancelEventResponseNonNullableFields = BulkCancelEventResponseNonNullableFields;
|
|
4415
|
+
type context$1_BulkCancelEventResult = BulkCancelEventResult;
|
|
4416
|
+
type context$1_BulkReportEventRequest = BulkReportEventRequest;
|
|
4417
|
+
type context$1_BulkReportEventResponse = BulkReportEventResponse;
|
|
4418
|
+
type context$1_BulkReportEventResponseNonNullableFields = BulkReportEventResponseNonNullableFields;
|
|
4419
|
+
type context$1_BulkReportEventResult = BulkReportEventResult;
|
|
4420
|
+
type context$1_CancelEventRequest = CancelEventRequest;
|
|
4421
|
+
type context$1_CancelEventResponse = CancelEventResponse;
|
|
4422
|
+
type context$1_CancelPendingScheduleRequest = CancelPendingScheduleRequest;
|
|
4423
|
+
type context$1_CancelPendingScheduleRequestByOneOf = CancelPendingScheduleRequestByOneOf;
|
|
4424
|
+
type context$1_CancelPendingScheduleResponse = CancelPendingScheduleResponse;
|
|
4425
|
+
type context$1_CancellationReason = CancellationReason;
|
|
4426
|
+
declare const context$1_CancellationReason: typeof CancellationReason;
|
|
4427
|
+
type context$1_CancelledStatusInfo = CancelledStatusInfo;
|
|
4428
|
+
type context$1_Case = Case;
|
|
4429
|
+
type context$1_ConditionActionInfo = ConditionActionInfo;
|
|
4430
|
+
type context$1_ConditionBlock = ConditionBlock;
|
|
4431
|
+
type context$1_ConditionFilter = ConditionFilter;
|
|
4432
|
+
type context$1_Delay = Delay;
|
|
4433
|
+
type context$1_DelayActionInfo = DelayActionInfo;
|
|
4434
|
+
type context$1_DelayHelper = DelayHelper;
|
|
4435
|
+
type context$1_DelayOfOneOf = DelayOfOneOf;
|
|
4436
|
+
type context$1_EndedStatusInfo = EndedStatusInfo;
|
|
4437
|
+
type context$1_EndedStatusInfoTypeInfoOneOf = EndedStatusInfoTypeInfoOneOf;
|
|
4438
|
+
type context$1_EventInfo = EventInfo;
|
|
4439
|
+
type context$1_ExecuteFromActionRequest = ExecuteFromActionRequest;
|
|
4440
|
+
type context$1_ExecuteFromActionResponse = ExecuteFromActionResponse;
|
|
4441
|
+
type context$1_ExpressionEvaluationResult = ExpressionEvaluationResult;
|
|
4442
|
+
type context$1_FailedStatusInfo = FailedStatusInfo;
|
|
4443
|
+
type context$1_Idempotency = Idempotency;
|
|
4444
|
+
type context$1_IdentifierType = IdentifierType;
|
|
4445
|
+
declare const context$1_IdentifierType: typeof IdentifierType;
|
|
4446
|
+
type context$1_Identity = Identity;
|
|
4447
|
+
type context$1_IfFilter = IfFilter;
|
|
4448
|
+
type context$1_InitiatedStatusInfo = InitiatedStatusInfo;
|
|
4449
|
+
type context$1_Output = Output;
|
|
4450
|
+
type context$1_PreinstalledIdentifier = PreinstalledIdentifier;
|
|
4451
|
+
type context$1_RateLimitActionInfo = RateLimitActionInfo;
|
|
4452
|
+
type context$1_RateLimiting = RateLimiting;
|
|
4453
|
+
type context$1_RefreshPayloadRequest = RefreshPayloadRequest;
|
|
4454
|
+
type context$1_RefreshPayloadResponse = RefreshPayloadResponse;
|
|
4455
|
+
type context$1_ReportDomainEventRequest = ReportDomainEventRequest;
|
|
4456
|
+
type context$1_ReportDomainEventResponse = ReportDomainEventResponse;
|
|
4457
|
+
type context$1_ReportEventOptions = ReportEventOptions;
|
|
4458
|
+
type context$1_ReportEventRequest = ReportEventRequest;
|
|
4459
|
+
type context$1_ReportEventResponse = ReportEventResponse;
|
|
4460
|
+
type context$1_ReportEventResponseNonNullableFields = ReportEventResponseNonNullableFields;
|
|
4461
|
+
type context$1_RunAutomationRequest = RunAutomationRequest;
|
|
4462
|
+
type context$1_RunAutomationResponse = RunAutomationResponse;
|
|
4463
|
+
type context$1_Runtime = Runtime;
|
|
4464
|
+
type context$1_Schedule = Schedule;
|
|
4465
|
+
type context$1_ScheduleRequest = ScheduleRequest;
|
|
4466
|
+
type context$1_ScheduleResponse = ScheduleResponse;
|
|
4467
|
+
type context$1_ScheduleStatus = ScheduleStatus;
|
|
4468
|
+
declare const context$1_ScheduleStatus: typeof ScheduleStatus;
|
|
4469
|
+
type context$1_ScheduledAction = ScheduledAction;
|
|
4470
|
+
type context$1_ScheduledStatusInfo = ScheduledStatusInfo;
|
|
4471
|
+
type context$1_Scheduler = Scheduler;
|
|
4472
|
+
type context$1_Service = Service;
|
|
4473
|
+
type context$1_ServiceMapping = ServiceMapping;
|
|
4474
|
+
type context$1_SimpleDelay = SimpleDelay;
|
|
4475
|
+
type context$1_SpiAction = SpiAction;
|
|
4476
|
+
type context$1_StartedStatusInfo = StartedStatusInfo;
|
|
4477
|
+
type context$1_StartedStatusInfoAppDefinedActionInfo = StartedStatusInfoAppDefinedActionInfo;
|
|
4478
|
+
type context$1_StartedStatusInfoTypeInfoOneOf = StartedStatusInfoTypeInfoOneOf;
|
|
4479
|
+
type context$1_SwitchFilter = SwitchFilter;
|
|
4480
|
+
type context$1_SystemHelper = SystemHelper;
|
|
4481
|
+
type context$1_SystemHelperHelperOneOf = SystemHelperHelperOneOf;
|
|
4482
|
+
type context$1_Target = Target;
|
|
4483
|
+
declare const context$1_Target: typeof Target;
|
|
4484
|
+
type context$1_TriggerInfo = TriggerInfo;
|
|
4485
|
+
type context$1_Units = Units;
|
|
4486
|
+
declare const context$1_Units: typeof Units;
|
|
4487
|
+
type context$1_UpdatePendingSchedulesPayloadRequest = UpdatePendingSchedulesPayloadRequest;
|
|
4488
|
+
type context$1_UpdatePendingSchedulesPayloadResponse = UpdatePendingSchedulesPayloadResponse;
|
|
4489
|
+
type context$1_V1RunAutomationRequest = V1RunAutomationRequest;
|
|
4490
|
+
type context$1_V1RunAutomationRequestIdentifierOneOf = V1RunAutomationRequestIdentifierOneOf;
|
|
4491
|
+
type context$1_V1RunAutomationResponse = V1RunAutomationResponse;
|
|
4492
|
+
type context$1__publicOnActivationStatusChangedType = _publicOnActivationStatusChangedType;
|
|
4493
|
+
declare const context$1_bulkCancelEvent: typeof bulkCancelEvent;
|
|
4494
|
+
declare const context$1_bulkReportEvent: typeof bulkReportEvent;
|
|
4495
|
+
declare const context$1_cancelEvent: typeof cancelEvent;
|
|
4496
|
+
declare const context$1_onActivationStatusChanged: typeof onActivationStatusChanged;
|
|
4497
|
+
declare const context$1_reportEvent: typeof reportEvent;
|
|
4498
|
+
declare namespace context$1 {
|
|
4499
|
+
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 };
|
|
4500
|
+
}
|
|
4501
|
+
|
|
4502
|
+
type HostModule<T, H extends Host> = {
|
|
4503
|
+
__type: 'host';
|
|
4504
|
+
create(host: H): T;
|
|
4505
|
+
};
|
|
4506
|
+
type HostModuleAPI<T extends HostModule<any, any>> = T extends HostModule<infer U, any> ? U : never;
|
|
4507
|
+
type Host<Environment = unknown> = {
|
|
4508
|
+
channel: {
|
|
4509
|
+
observeState(callback: (props: unknown, environment: Environment) => unknown): {
|
|
4510
|
+
disconnect: () => void;
|
|
4511
|
+
} | Promise<{
|
|
4512
|
+
disconnect: () => void;
|
|
4513
|
+
}>;
|
|
4514
|
+
};
|
|
4515
|
+
environment?: Environment;
|
|
4516
|
+
/**
|
|
4517
|
+
* Optional name of the environment, use for logging
|
|
3744
4518
|
*/
|
|
3745
|
-
|
|
4519
|
+
name?: string;
|
|
3746
4520
|
/**
|
|
3747
|
-
*
|
|
3748
|
-
* For example, `fc81a355-3429-50fc-a4c7-def486e828f3`.
|
|
3749
|
-
*
|
|
3750
|
-
* Required if your app needs to
|
|
3751
|
-
* [cancel the event](https://dev.wix.com/docs/sdk/backend-modules/automations/triggered-events/cancel-event)
|
|
3752
|
-
* if the automation becomes no longer relevant.
|
|
3753
|
-
*
|
|
3754
|
-
* Typically, this ID is defined in your system,
|
|
3755
|
-
* but you can also use any Wix resource GUID,
|
|
3756
|
-
* such as contact ID, member ID, or invoice ID.
|
|
3757
|
-
* See
|
|
3758
|
-
* [Choose the right `externalEntityId`](https://dev.wix.com/docs/rest/business-management/automations/triggered-events/reporting-and-canceling-events#about-canceling-events)
|
|
3759
|
-
* for more information.
|
|
4521
|
+
* Optional bast url to use for API requests, for example `www.wixapis.com`
|
|
3760
4522
|
*/
|
|
3761
|
-
|
|
3762
|
-
/**
|
|
3763
|
-
|
|
4523
|
+
apiBaseUrl?: string;
|
|
4524
|
+
/**
|
|
4525
|
+
* Possible data to be provided by every host, for cross cutting concerns
|
|
4526
|
+
* like internationalization, billing, etc.
|
|
4527
|
+
*/
|
|
4528
|
+
essentials?: {
|
|
4529
|
+
/**
|
|
4530
|
+
* The language of the currently viewed session
|
|
4531
|
+
*/
|
|
4532
|
+
language?: string;
|
|
4533
|
+
/**
|
|
4534
|
+
* The locale of the currently viewed session
|
|
4535
|
+
*/
|
|
4536
|
+
locale?: string;
|
|
4537
|
+
/**
|
|
4538
|
+
* Any headers that should be passed through to the API requests
|
|
4539
|
+
*/
|
|
4540
|
+
passThroughHeaders?: Record<string, string>;
|
|
4541
|
+
};
|
|
4542
|
+
};
|
|
4543
|
+
|
|
4544
|
+
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
4545
|
+
interface HttpClient {
|
|
4546
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
4547
|
+
fetchWithAuth: typeof fetch;
|
|
4548
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
4549
|
+
getActiveToken?: () => string | undefined;
|
|
4550
|
+
}
|
|
4551
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
4552
|
+
type HttpResponse<T = any> = {
|
|
4553
|
+
data: T;
|
|
4554
|
+
status: number;
|
|
4555
|
+
statusText: string;
|
|
4556
|
+
headers: any;
|
|
4557
|
+
request?: any;
|
|
4558
|
+
};
|
|
4559
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
|
4560
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
4561
|
+
url: string;
|
|
4562
|
+
data?: Data;
|
|
4563
|
+
params?: URLSearchParams;
|
|
4564
|
+
} & APIMetadata;
|
|
4565
|
+
type APIMetadata = {
|
|
4566
|
+
methodFqn?: string;
|
|
4567
|
+
entityFqdn?: string;
|
|
4568
|
+
packageName?: string;
|
|
4569
|
+
};
|
|
4570
|
+
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
4571
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
4572
|
+
__type: 'event-definition';
|
|
4573
|
+
type: Type;
|
|
4574
|
+
isDomainEvent?: boolean;
|
|
4575
|
+
transformations?: (envelope: unknown) => Payload;
|
|
4576
|
+
__payload: Payload;
|
|
4577
|
+
};
|
|
4578
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
4579
|
+
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
4580
|
+
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
4581
|
+
|
|
4582
|
+
type ServicePluginMethodInput = {
|
|
4583
|
+
request: any;
|
|
4584
|
+
metadata: any;
|
|
4585
|
+
};
|
|
4586
|
+
type ServicePluginContract = Record<string, (payload: ServicePluginMethodInput) => unknown | Promise<unknown>>;
|
|
4587
|
+
type ServicePluginMethodMetadata = {
|
|
4588
|
+
name: string;
|
|
4589
|
+
primaryHttpMappingPath: string;
|
|
4590
|
+
transformations: {
|
|
4591
|
+
fromREST: (...args: unknown[]) => ServicePluginMethodInput;
|
|
4592
|
+
toREST: (...args: unknown[]) => unknown;
|
|
4593
|
+
};
|
|
4594
|
+
};
|
|
4595
|
+
type ServicePluginDefinition<Contract extends ServicePluginContract> = {
|
|
4596
|
+
__type: 'service-plugin-definition';
|
|
4597
|
+
componentType: string;
|
|
4598
|
+
methods: ServicePluginMethodMetadata[];
|
|
4599
|
+
__contract: Contract;
|
|
4600
|
+
};
|
|
4601
|
+
declare function ServicePluginDefinition<Contract extends ServicePluginContract>(componentType: string, methods: ServicePluginMethodMetadata[]): ServicePluginDefinition<Contract>;
|
|
4602
|
+
type BuildServicePluginDefinition<T extends ServicePluginDefinition<any>> = (implementation: T['__contract']) => void;
|
|
4603
|
+
declare const SERVICE_PLUGIN_ERROR_TYPE = "wix_spi_error";
|
|
4604
|
+
|
|
4605
|
+
type RequestContext = {
|
|
4606
|
+
isSSR: boolean;
|
|
4607
|
+
host: string;
|
|
4608
|
+
protocol?: string;
|
|
4609
|
+
};
|
|
4610
|
+
type ResponseTransformer = (data: any, headers?: any) => any;
|
|
4611
|
+
/**
|
|
4612
|
+
* Ambassador request options types are copied mostly from AxiosRequestConfig.
|
|
4613
|
+
* They are copied and not imported to reduce the amount of dependencies (to reduce install time).
|
|
4614
|
+
* https://github.com/axios/axios/blob/3f53eb6960f05a1f88409c4b731a40de595cb825/index.d.ts#L307-L315
|
|
4615
|
+
*/
|
|
4616
|
+
type Method = 'get' | 'GET' | 'delete' | 'DELETE' | 'head' | 'HEAD' | 'options' | 'OPTIONS' | 'post' | 'POST' | 'put' | 'PUT' | 'patch' | 'PATCH' | 'purge' | 'PURGE' | 'link' | 'LINK' | 'unlink' | 'UNLINK';
|
|
4617
|
+
type AmbassadorRequestOptions<T = any> = {
|
|
4618
|
+
_?: T;
|
|
4619
|
+
url?: string;
|
|
4620
|
+
method?: Method;
|
|
4621
|
+
params?: any;
|
|
4622
|
+
data?: any;
|
|
4623
|
+
transformResponse?: ResponseTransformer | ResponseTransformer[];
|
|
4624
|
+
};
|
|
4625
|
+
type AmbassadorFactory<Request, Response> = (payload: Request) => ((context: RequestContext) => AmbassadorRequestOptions<Response>) & {
|
|
4626
|
+
__isAmbassador: boolean;
|
|
4627
|
+
};
|
|
4628
|
+
type AmbassadorFunctionDescriptor<Request = any, Response = any> = AmbassadorFactory<Request, Response>;
|
|
4629
|
+
type BuildAmbassadorFunction<T extends AmbassadorFunctionDescriptor> = T extends AmbassadorFunctionDescriptor<infer Request, infer Response> ? (req: Request) => Promise<Response> : never;
|
|
4630
|
+
|
|
4631
|
+
declare global {
|
|
4632
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
4633
|
+
interface SymbolConstructor {
|
|
4634
|
+
readonly observable: symbol;
|
|
4635
|
+
}
|
|
3764
4636
|
}
|
|
3765
4637
|
|
|
3766
|
-
declare
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3771
|
-
|
|
3772
|
-
|
|
3773
|
-
|
|
3774
|
-
|
|
3775
|
-
|
|
3776
|
-
|
|
3777
|
-
|
|
3778
|
-
|
|
3779
|
-
|
|
3780
|
-
|
|
3781
|
-
|
|
3782
|
-
|
|
3783
|
-
|
|
3784
|
-
}
|
|
3785
|
-
|
|
3786
|
-
|
|
3787
|
-
|
|
3788
|
-
|
|
3789
|
-
|
|
3790
|
-
|
|
3791
|
-
|
|
3792
|
-
|
|
3793
|
-
|
|
3794
|
-
|
|
3795
|
-
|
|
3796
|
-
|
|
3797
|
-
|
|
3798
|
-
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3802
|
-
|
|
3803
|
-
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
|
-
|
|
3807
|
-
|
|
3808
|
-
|
|
3809
|
-
|
|
3810
|
-
|
|
3811
|
-
|
|
3812
|
-
|
|
3813
|
-
|
|
3814
|
-
|
|
3815
|
-
|
|
3816
|
-
|
|
3817
|
-
|
|
3818
|
-
|
|
3819
|
-
|
|
3820
|
-
|
|
3821
|
-
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
|
|
3825
|
-
|
|
3826
|
-
|
|
3827
|
-
|
|
3828
|
-
|
|
3829
|
-
|
|
3830
|
-
|
|
3831
|
-
|
|
3832
|
-
|
|
3833
|
-
|
|
4638
|
+
declare const emptyObjectSymbol: unique symbol;
|
|
4639
|
+
|
|
4640
|
+
/**
|
|
4641
|
+
Represents a strictly empty plain object, the `{}` value.
|
|
4642
|
+
|
|
4643
|
+
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)).
|
|
4644
|
+
|
|
4645
|
+
@example
|
|
4646
|
+
```
|
|
4647
|
+
import type {EmptyObject} from 'type-fest';
|
|
4648
|
+
|
|
4649
|
+
// The following illustrates the problem with `{}`.
|
|
4650
|
+
const foo1: {} = {}; // Pass
|
|
4651
|
+
const foo2: {} = []; // Pass
|
|
4652
|
+
const foo3: {} = 42; // Pass
|
|
4653
|
+
const foo4: {} = {a: 1}; // Pass
|
|
4654
|
+
|
|
4655
|
+
// With `EmptyObject` only the first case is valid.
|
|
4656
|
+
const bar1: EmptyObject = {}; // Pass
|
|
4657
|
+
const bar2: EmptyObject = 42; // Fail
|
|
4658
|
+
const bar3: EmptyObject = []; // Fail
|
|
4659
|
+
const bar4: EmptyObject = {a: 1}; // Fail
|
|
4660
|
+
```
|
|
4661
|
+
|
|
4662
|
+
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}.
|
|
4663
|
+
|
|
4664
|
+
@category Object
|
|
4665
|
+
*/
|
|
4666
|
+
type EmptyObject = {[emptyObjectSymbol]?: never};
|
|
4667
|
+
|
|
4668
|
+
/**
|
|
4669
|
+
Returns a boolean for whether the two given types are equal.
|
|
4670
|
+
|
|
4671
|
+
@link https://github.com/microsoft/TypeScript/issues/27024#issuecomment-421529650
|
|
4672
|
+
@link https://stackoverflow.com/questions/68961864/how-does-the-equals-work-in-typescript/68963796#68963796
|
|
4673
|
+
|
|
4674
|
+
Use-cases:
|
|
4675
|
+
- If you want to make a conditional branch based on the result of a comparison of two types.
|
|
4676
|
+
|
|
4677
|
+
@example
|
|
4678
|
+
```
|
|
4679
|
+
import type {IsEqual} from 'type-fest';
|
|
4680
|
+
|
|
4681
|
+
// This type returns a boolean for whether the given array includes the given item.
|
|
4682
|
+
// `IsEqual` is used to compare the given array at position 0 and the given item and then return true if they are equal.
|
|
4683
|
+
type Includes<Value extends readonly any[], Item> =
|
|
4684
|
+
Value extends readonly [Value[0], ...infer rest]
|
|
4685
|
+
? IsEqual<Value[0], Item> extends true
|
|
4686
|
+
? true
|
|
4687
|
+
: Includes<rest, Item>
|
|
4688
|
+
: false;
|
|
4689
|
+
```
|
|
4690
|
+
|
|
4691
|
+
@category Type Guard
|
|
4692
|
+
@category Utilities
|
|
4693
|
+
*/
|
|
4694
|
+
type IsEqual<A, B> =
|
|
4695
|
+
(<G>() => G extends A ? 1 : 2) extends
|
|
4696
|
+
(<G>() => G extends B ? 1 : 2)
|
|
4697
|
+
? true
|
|
4698
|
+
: false;
|
|
4699
|
+
|
|
4700
|
+
/**
|
|
4701
|
+
Filter out keys from an object.
|
|
4702
|
+
|
|
4703
|
+
Returns `never` if `Exclude` is strictly equal to `Key`.
|
|
4704
|
+
Returns `never` if `Key` extends `Exclude`.
|
|
4705
|
+
Returns `Key` otherwise.
|
|
4706
|
+
|
|
4707
|
+
@example
|
|
4708
|
+
```
|
|
4709
|
+
type Filtered = Filter<'foo', 'foo'>;
|
|
4710
|
+
//=> never
|
|
4711
|
+
```
|
|
4712
|
+
|
|
4713
|
+
@example
|
|
4714
|
+
```
|
|
4715
|
+
type Filtered = Filter<'bar', string>;
|
|
4716
|
+
//=> never
|
|
4717
|
+
```
|
|
4718
|
+
|
|
4719
|
+
@example
|
|
4720
|
+
```
|
|
4721
|
+
type Filtered = Filter<'bar', 'foo'>;
|
|
4722
|
+
//=> 'bar'
|
|
4723
|
+
```
|
|
4724
|
+
|
|
4725
|
+
@see {Except}
|
|
4726
|
+
*/
|
|
4727
|
+
type Filter$1<KeyType, ExcludeType> = IsEqual<KeyType, ExcludeType> extends true ? never : (KeyType extends ExcludeType ? never : KeyType);
|
|
4728
|
+
|
|
4729
|
+
type ExceptOptions = {
|
|
4730
|
+
/**
|
|
4731
|
+
Disallow assigning non-specified properties.
|
|
4732
|
+
|
|
4733
|
+
Note that any omitted properties in the resulting type will be present in autocomplete as `undefined`.
|
|
4734
|
+
|
|
4735
|
+
@default false
|
|
4736
|
+
*/
|
|
4737
|
+
requireExactProps?: boolean;
|
|
4738
|
+
};
|
|
4739
|
+
|
|
4740
|
+
/**
|
|
4741
|
+
Create a type from an object type without certain keys.
|
|
4742
|
+
|
|
4743
|
+
We recommend setting the `requireExactProps` option to `true`.
|
|
4744
|
+
|
|
4745
|
+
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.
|
|
4746
|
+
|
|
4747
|
+
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)).
|
|
4748
|
+
|
|
4749
|
+
@example
|
|
4750
|
+
```
|
|
4751
|
+
import type {Except} from 'type-fest';
|
|
3834
4752
|
|
|
3835
|
-
type
|
|
3836
|
-
|
|
3837
|
-
|
|
3838
|
-
isDomainEvent?: boolean;
|
|
3839
|
-
transformations?: (envelope: unknown) => Payload;
|
|
3840
|
-
__payload: Payload;
|
|
4753
|
+
type Foo = {
|
|
4754
|
+
a: number;
|
|
4755
|
+
b: string;
|
|
3841
4756
|
};
|
|
3842
|
-
declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
|
|
3843
|
-
type EventHandler$1<T extends EventDefinition$1> = (payload: T['__payload']) => void | Promise<void>;
|
|
3844
|
-
type BuildEventDefinition$1<T extends EventDefinition$1<any, string>> = (handler: EventHandler$1<T>) => void;
|
|
3845
4757
|
|
|
3846
|
-
|
|
3847
|
-
|
|
3848
|
-
|
|
3849
|
-
|
|
4758
|
+
type FooWithoutA = Except<Foo, 'a'>;
|
|
4759
|
+
//=> {b: string}
|
|
4760
|
+
|
|
4761
|
+
const fooWithoutA: FooWithoutA = {a: 1, b: '2'};
|
|
4762
|
+
//=> errors: 'a' does not exist in type '{ b: string; }'
|
|
4763
|
+
|
|
4764
|
+
type FooWithoutB = Except<Foo, 'b', {requireExactProps: true}>;
|
|
4765
|
+
//=> {a: number} & Partial<Record<"b", never>>
|
|
4766
|
+
|
|
4767
|
+
const fooWithoutB: FooWithoutB = {a: 1, b: '2'};
|
|
4768
|
+
//=> errors at 'b': Type 'string' is not assignable to type 'undefined'.
|
|
4769
|
+
```
|
|
4770
|
+
|
|
4771
|
+
@category Object
|
|
4772
|
+
*/
|
|
4773
|
+
type Except<ObjectType, KeysType extends keyof ObjectType, Options extends ExceptOptions = {requireExactProps: false}> = {
|
|
4774
|
+
[KeyType in keyof ObjectType as Filter$1<KeyType, KeysType>]: ObjectType[KeyType];
|
|
4775
|
+
} & (Options['requireExactProps'] extends true
|
|
4776
|
+
? Partial<Record<KeysType, never>>
|
|
4777
|
+
: {});
|
|
4778
|
+
|
|
4779
|
+
/**
|
|
4780
|
+
Returns a boolean for whether the given type is `never`.
|
|
4781
|
+
|
|
4782
|
+
@link https://github.com/microsoft/TypeScript/issues/31751#issuecomment-498526919
|
|
4783
|
+
@link https://stackoverflow.com/a/53984913/10292952
|
|
4784
|
+
@link https://www.zhenghao.io/posts/ts-never
|
|
4785
|
+
|
|
4786
|
+
Useful in type utilities, such as checking if something does not occur.
|
|
4787
|
+
|
|
4788
|
+
@example
|
|
4789
|
+
```
|
|
4790
|
+
import type {IsNever, And} from 'type-fest';
|
|
4791
|
+
|
|
4792
|
+
// https://github.com/andnp/SimplyTyped/blob/master/src/types/strings.ts
|
|
4793
|
+
type AreStringsEqual<A extends string, B extends string> =
|
|
4794
|
+
And<
|
|
4795
|
+
IsNever<Exclude<A, B>> extends true ? true : false,
|
|
4796
|
+
IsNever<Exclude<B, A>> extends true ? true : false
|
|
4797
|
+
>;
|
|
4798
|
+
|
|
4799
|
+
type EndIfEqual<I extends string, O extends string> =
|
|
4800
|
+
AreStringsEqual<I, O> extends true
|
|
4801
|
+
? never
|
|
4802
|
+
: void;
|
|
4803
|
+
|
|
4804
|
+
function endIfEqual<I extends string, O extends string>(input: I, output: O): EndIfEqual<I, O> {
|
|
4805
|
+
if (input === output) {
|
|
4806
|
+
process.exit(0);
|
|
3850
4807
|
}
|
|
3851
4808
|
}
|
|
3852
4809
|
|
|
3853
|
-
|
|
4810
|
+
endIfEqual('abc', 'abc');
|
|
4811
|
+
//=> never
|
|
3854
4812
|
|
|
3855
|
-
|
|
3856
|
-
|
|
3857
|
-
|
|
3858
|
-
|
|
4813
|
+
endIfEqual('abc', '123');
|
|
4814
|
+
//=> void
|
|
4815
|
+
```
|
|
4816
|
+
|
|
4817
|
+
@category Type Guard
|
|
4818
|
+
@category Utilities
|
|
4819
|
+
*/
|
|
4820
|
+
type IsNever<T> = [T] extends [never] ? true : false;
|
|
3859
4821
|
|
|
3860
|
-
type _publicOnActivationStatusChangedType = typeof onActivationStatusChanged$1;
|
|
3861
4822
|
/**
|
|
3862
|
-
|
|
3863
|
-
*/
|
|
3864
|
-
declare const onActivationStatusChanged: ReturnType<typeof createEventModule$1<_publicOnActivationStatusChangedType>>;
|
|
4823
|
+
An if-else-like type that resolves depending on whether the given type is `never`.
|
|
3865
4824
|
|
|
3866
|
-
|
|
3867
|
-
|
|
3868
|
-
|
|
3869
|
-
|
|
3870
|
-
type
|
|
3871
|
-
|
|
3872
|
-
type
|
|
3873
|
-
|
|
3874
|
-
|
|
3875
|
-
type
|
|
3876
|
-
|
|
3877
|
-
|
|
3878
|
-
|
|
3879
|
-
|
|
3880
|
-
|
|
3881
|
-
|
|
3882
|
-
type
|
|
3883
|
-
|
|
3884
|
-
|
|
3885
|
-
|
|
3886
|
-
|
|
3887
|
-
type
|
|
3888
|
-
|
|
3889
|
-
|
|
3890
|
-
|
|
3891
|
-
|
|
3892
|
-
|
|
3893
|
-
type
|
|
3894
|
-
|
|
3895
|
-
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
|
|
3899
|
-
|
|
3900
|
-
|
|
3901
|
-
|
|
3902
|
-
type
|
|
3903
|
-
|
|
3904
|
-
|
|
3905
|
-
|
|
3906
|
-
|
|
3907
|
-
|
|
3908
|
-
|
|
3909
|
-
|
|
3910
|
-
type
|
|
3911
|
-
|
|
3912
|
-
type
|
|
3913
|
-
|
|
3914
|
-
|
|
3915
|
-
|
|
3916
|
-
|
|
3917
|
-
|
|
3918
|
-
type
|
|
3919
|
-
|
|
3920
|
-
|
|
3921
|
-
|
|
3922
|
-
|
|
3923
|
-
|
|
3924
|
-
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
|
|
3929
|
-
type
|
|
3930
|
-
|
|
3931
|
-
|
|
3932
|
-
|
|
3933
|
-
|
|
3934
|
-
|
|
3935
|
-
|
|
3936
|
-
|
|
3937
|
-
|
|
3938
|
-
|
|
3939
|
-
type
|
|
3940
|
-
|
|
3941
|
-
|
|
3942
|
-
|
|
3943
|
-
|
|
3944
|
-
|
|
3945
|
-
|
|
3946
|
-
|
|
3947
|
-
|
|
3948
|
-
|
|
3949
|
-
type
|
|
3950
|
-
|
|
3951
|
-
|
|
3952
|
-
|
|
3953
|
-
|
|
3954
|
-
|
|
3955
|
-
type
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
-
|
|
3959
|
-
|
|
3960
|
-
|
|
3961
|
-
|
|
3962
|
-
|
|
3963
|
-
|
|
3964
|
-
type
|
|
3965
|
-
|
|
3966
|
-
|
|
3967
|
-
|
|
3968
|
-
|
|
3969
|
-
|
|
3970
|
-
type
|
|
3971
|
-
|
|
3972
|
-
|
|
3973
|
-
|
|
3974
|
-
|
|
3975
|
-
|
|
3976
|
-
|
|
3977
|
-
|
|
3978
|
-
type
|
|
3979
|
-
|
|
3980
|
-
type
|
|
3981
|
-
|
|
3982
|
-
|
|
3983
|
-
|
|
3984
|
-
|
|
3985
|
-
|
|
3986
|
-
|
|
3987
|
-
|
|
3988
|
-
|
|
3989
|
-
|
|
4825
|
+
@see {@link IsNever}
|
|
4826
|
+
|
|
4827
|
+
@example
|
|
4828
|
+
```
|
|
4829
|
+
import type {IfNever} from 'type-fest';
|
|
4830
|
+
|
|
4831
|
+
type ShouldBeTrue = IfNever<never>;
|
|
4832
|
+
//=> true
|
|
4833
|
+
|
|
4834
|
+
type ShouldBeBar = IfNever<'not never', 'foo', 'bar'>;
|
|
4835
|
+
//=> 'bar'
|
|
4836
|
+
```
|
|
4837
|
+
|
|
4838
|
+
@category Type Guard
|
|
4839
|
+
@category Utilities
|
|
4840
|
+
*/
|
|
4841
|
+
type IfNever<T, TypeIfNever = true, TypeIfNotNever = false> = (
|
|
4842
|
+
IsNever<T> extends true ? TypeIfNever : TypeIfNotNever
|
|
4843
|
+
);
|
|
4844
|
+
|
|
4845
|
+
/**
|
|
4846
|
+
Extract the keys from a type where the value type of the key extends the given `Condition`.
|
|
4847
|
+
|
|
4848
|
+
Internally this is used for the `ConditionalPick` and `ConditionalExcept` types.
|
|
4849
|
+
|
|
4850
|
+
@example
|
|
4851
|
+
```
|
|
4852
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
4853
|
+
|
|
4854
|
+
interface Example {
|
|
4855
|
+
a: string;
|
|
4856
|
+
b: string | number;
|
|
4857
|
+
c?: string;
|
|
4858
|
+
d: {};
|
|
4859
|
+
}
|
|
4860
|
+
|
|
4861
|
+
type StringKeysOnly = ConditionalKeys<Example, string>;
|
|
4862
|
+
//=> 'a'
|
|
4863
|
+
```
|
|
4864
|
+
|
|
4865
|
+
To support partial types, make sure your `Condition` is a union of undefined (for example, `string | undefined`) as demonstrated below.
|
|
4866
|
+
|
|
4867
|
+
@example
|
|
4868
|
+
```
|
|
4869
|
+
import type {ConditionalKeys} from 'type-fest';
|
|
4870
|
+
|
|
4871
|
+
type StringKeysAndUndefined = ConditionalKeys<Example, string | undefined>;
|
|
4872
|
+
//=> 'a' | 'c'
|
|
4873
|
+
```
|
|
4874
|
+
|
|
4875
|
+
@category Object
|
|
4876
|
+
*/
|
|
4877
|
+
type ConditionalKeys<Base, Condition> =
|
|
4878
|
+
{
|
|
4879
|
+
// Map through all the keys of the given base type.
|
|
4880
|
+
[Key in keyof Base]-?:
|
|
4881
|
+
// Pick only keys with types extending the given `Condition` type.
|
|
4882
|
+
Base[Key] extends Condition
|
|
4883
|
+
// Retain this key
|
|
4884
|
+
// If the value for the key extends never, only include it if `Condition` also extends never
|
|
4885
|
+
? IfNever<Base[Key], IfNever<Condition, Key, never>, Key>
|
|
4886
|
+
// Discard this key since the condition fails.
|
|
4887
|
+
: never;
|
|
4888
|
+
// Convert the produced object into a union type of the keys which passed the conditional test.
|
|
4889
|
+
}[keyof Base];
|
|
4890
|
+
|
|
4891
|
+
/**
|
|
4892
|
+
Exclude keys from a shape that matches the given `Condition`.
|
|
4893
|
+
|
|
4894
|
+
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.
|
|
4895
|
+
|
|
4896
|
+
@example
|
|
4897
|
+
```
|
|
4898
|
+
import type {Primitive, ConditionalExcept} from 'type-fest';
|
|
4899
|
+
|
|
4900
|
+
class Awesome {
|
|
4901
|
+
name: string;
|
|
4902
|
+
successes: number;
|
|
4903
|
+
failures: bigint;
|
|
4904
|
+
|
|
4905
|
+
run() {}
|
|
4906
|
+
}
|
|
4907
|
+
|
|
4908
|
+
type ExceptPrimitivesFromAwesome = ConditionalExcept<Awesome, Primitive>;
|
|
4909
|
+
//=> {run: () => void}
|
|
4910
|
+
```
|
|
4911
|
+
|
|
4912
|
+
@example
|
|
4913
|
+
```
|
|
4914
|
+
import type {ConditionalExcept} from 'type-fest';
|
|
4915
|
+
|
|
4916
|
+
interface Example {
|
|
4917
|
+
a: string;
|
|
4918
|
+
b: string | number;
|
|
4919
|
+
c: () => void;
|
|
4920
|
+
d: {};
|
|
4921
|
+
}
|
|
4922
|
+
|
|
4923
|
+
type NonStringKeysOnly = ConditionalExcept<Example, string>;
|
|
4924
|
+
//=> {b: string | number; c: () => void; d: {}}
|
|
4925
|
+
```
|
|
4926
|
+
|
|
4927
|
+
@category Object
|
|
4928
|
+
*/
|
|
4929
|
+
type ConditionalExcept<Base, Condition> = Except<
|
|
4930
|
+
Base,
|
|
4931
|
+
ConditionalKeys<Base, Condition>
|
|
4932
|
+
>;
|
|
4933
|
+
|
|
4934
|
+
/**
|
|
4935
|
+
* Descriptors are objects that describe the API of a module, and the module
|
|
4936
|
+
* can either be a REST module or a host module.
|
|
4937
|
+
* This type is recursive, so it can describe nested modules.
|
|
4938
|
+
*/
|
|
4939
|
+
type Descriptors = RESTFunctionDescriptor | AmbassadorFunctionDescriptor | HostModule<any, any> | EventDefinition<any> | ServicePluginDefinition<any> | {
|
|
4940
|
+
[key: string]: Descriptors | PublicMetadata | any;
|
|
4941
|
+
};
|
|
4942
|
+
/**
|
|
4943
|
+
* This type takes in a descriptors object of a certain Host (including an `unknown` host)
|
|
4944
|
+
* and returns an object with the same structure, but with all descriptors replaced with their API.
|
|
4945
|
+
* Any non-descriptor properties are removed from the returned object, including descriptors that
|
|
4946
|
+
* do not match the given host (as they will not work with the given host).
|
|
4947
|
+
*/
|
|
4948
|
+
type BuildDescriptors<T extends Descriptors, H extends Host<any> | undefined, Depth extends number = 5> = {
|
|
4949
|
+
done: T;
|
|
4950
|
+
recurse: T extends {
|
|
4951
|
+
__type: typeof SERVICE_PLUGIN_ERROR_TYPE;
|
|
4952
|
+
} ? never : T extends AmbassadorFunctionDescriptor ? BuildAmbassadorFunction<T> : T extends RESTFunctionDescriptor ? BuildRESTFunction<T> : T extends EventDefinition<any> ? BuildEventDefinition<T> : T extends ServicePluginDefinition<any> ? BuildServicePluginDefinition<T> : T extends HostModule<any, any> ? HostModuleAPI<T> : ConditionalExcept<{
|
|
4953
|
+
[Key in keyof T]: T[Key] extends Descriptors ? BuildDescriptors<T[Key], H, [
|
|
4954
|
+
-1,
|
|
4955
|
+
0,
|
|
4956
|
+
1,
|
|
4957
|
+
2,
|
|
4958
|
+
3,
|
|
4959
|
+
4,
|
|
4960
|
+
5
|
|
4961
|
+
][Depth]> : never;
|
|
4962
|
+
}, EmptyObject>;
|
|
4963
|
+
}[Depth extends -1 ? 'done' : 'recurse'];
|
|
4964
|
+
type PublicMetadata = {
|
|
4965
|
+
PACKAGE_NAME?: string;
|
|
4966
|
+
};
|
|
4967
|
+
|
|
4968
|
+
declare global {
|
|
4969
|
+
interface ContextualClient {
|
|
4970
|
+
}
|
|
3990
4971
|
}
|
|
4972
|
+
/**
|
|
4973
|
+
* A type used to create concerete types from SDK descriptors in
|
|
4974
|
+
* case a contextual client is available.
|
|
4975
|
+
*/
|
|
4976
|
+
type MaybeContext<T extends Descriptors> = globalThis.ContextualClient extends {
|
|
4977
|
+
host: Host;
|
|
4978
|
+
} ? BuildDescriptors<T, globalThis.ContextualClient['host']> : T;
|
|
3991
4979
|
|
|
3992
4980
|
interface Automation extends AutomationOriginInfoOneOf {
|
|
3993
4981
|
/** Application info */
|
|
@@ -5047,7 +6035,7 @@ interface CreateDraftAutomationResponse {
|
|
|
5047
6035
|
}
|
|
5048
6036
|
interface GetOrCreateDraftAutomationRequest {
|
|
5049
6037
|
/** Original automation id */
|
|
5050
|
-
originalAutomationId
|
|
6038
|
+
originalAutomationId?: string;
|
|
5051
6039
|
}
|
|
5052
6040
|
interface GetOrCreateDraftAutomationResponse {
|
|
5053
6041
|
/** Draft automation. */
|
|
@@ -5055,7 +6043,7 @@ interface GetOrCreateDraftAutomationResponse {
|
|
|
5055
6043
|
}
|
|
5056
6044
|
interface UpdateDraftAutomationRequest {
|
|
5057
6045
|
/** Automation to be updated, may be partial. */
|
|
5058
|
-
automation
|
|
6046
|
+
automation?: Automation;
|
|
5059
6047
|
}
|
|
5060
6048
|
interface UpdateDraftAutomationResponse {
|
|
5061
6049
|
/** Updated draft automation. */
|
|
@@ -5083,7 +6071,7 @@ interface DraftsInfo {
|
|
|
5083
6071
|
}
|
|
5084
6072
|
interface DeleteDraftAutomationRequest {
|
|
5085
6073
|
/** Id of the draft automation to delete. */
|
|
5086
|
-
automationId
|
|
6074
|
+
automationId?: string;
|
|
5087
6075
|
}
|
|
5088
6076
|
interface DeleteDraftAutomationResponse {
|
|
5089
6077
|
}
|
|
@@ -5263,9 +6251,9 @@ declare enum AutomationErrorType {
|
|
|
5263
6251
|
}
|
|
5264
6252
|
interface GetAutomationActionSchemaRequest {
|
|
5265
6253
|
/** Automation ID */
|
|
5266
|
-
automationId
|
|
6254
|
+
automationId?: string;
|
|
5267
6255
|
/** Action ID */
|
|
5268
|
-
actionId
|
|
6256
|
+
actionId?: string;
|
|
5269
6257
|
}
|
|
5270
6258
|
interface GetAutomationActionSchemaResponse {
|
|
5271
6259
|
/** The accumulated payload schema for an action. */
|
|
@@ -5451,18 +6439,6 @@ interface QueryAutomationsResponseNonNullableFields {
|
|
|
5451
6439
|
interface CopyAutomationResponseNonNullableFields {
|
|
5452
6440
|
automation?: AutomationNonNullableFields;
|
|
5453
6441
|
}
|
|
5454
|
-
interface CreateDraftAutomationResponseNonNullableFields {
|
|
5455
|
-
automation?: AutomationNonNullableFields;
|
|
5456
|
-
}
|
|
5457
|
-
interface GetOrCreateDraftAutomationResponseNonNullableFields {
|
|
5458
|
-
automation?: AutomationNonNullableFields;
|
|
5459
|
-
}
|
|
5460
|
-
interface UpdateDraftAutomationResponseNonNullableFields {
|
|
5461
|
-
automation?: AutomationNonNullableFields;
|
|
5462
|
-
}
|
|
5463
|
-
interface QueryAutomationsWithDraftsResponseNonNullableFields {
|
|
5464
|
-
automations: AutomationNonNullableFields[];
|
|
5465
|
-
}
|
|
5466
6442
|
interface TriggerConfigurationErrorNonNullableFields {
|
|
5467
6443
|
errorType: TriggerErrorType;
|
|
5468
6444
|
}
|
|
@@ -5735,81 +6711,10 @@ interface CopyAutomationOptions {
|
|
|
5735
6711
|
/** Automation origin. */
|
|
5736
6712
|
origin?: Origin;
|
|
5737
6713
|
}
|
|
5738
|
-
interface CreateDraftAutomationOptions {
|
|
5739
|
-
/** Draft automation to be created. */
|
|
5740
|
-
automation?: Automation;
|
|
5741
|
-
}
|
|
5742
|
-
interface UpdateDraftAutomation {
|
|
5743
|
-
/** Application info */
|
|
5744
|
-
applicationInfo?: ApplicationOrigin;
|
|
5745
|
-
/** Preinstalled info */
|
|
5746
|
-
preinstalledInfo?: PreinstalledOrigin;
|
|
5747
|
-
/**
|
|
5748
|
-
* Automation ID.
|
|
5749
|
-
* @readonly
|
|
5750
|
-
*/
|
|
5751
|
-
_id?: string | null;
|
|
5752
|
-
/**
|
|
5753
|
-
* Revision number, which increments by 1 each time the automation is updated.
|
|
5754
|
-
* To prevent conflicting changes,
|
|
5755
|
-
* the current revision must be passed when updating the automation.
|
|
5756
|
-
*
|
|
5757
|
-
* Ignored when creating an automation.
|
|
5758
|
-
* @readonly
|
|
5759
|
-
*/
|
|
5760
|
-
revision?: string | null;
|
|
5761
|
-
/**
|
|
5762
|
-
* Information about the creator of the automation.
|
|
5763
|
-
* @readonly
|
|
5764
|
-
*/
|
|
5765
|
-
createdBy?: AuditInfo;
|
|
5766
|
-
/**
|
|
5767
|
-
* Date and time the automation was created.
|
|
5768
|
-
* @readonly
|
|
5769
|
-
*/
|
|
5770
|
-
_createdDate?: Date;
|
|
5771
|
-
/**
|
|
5772
|
-
* The entity that last updated the automation.
|
|
5773
|
-
* @readonly
|
|
5774
|
-
*/
|
|
5775
|
-
updatedBy?: AuditInfo;
|
|
5776
|
-
/**
|
|
5777
|
-
* Date and time the automation was last updated.
|
|
5778
|
-
* @readonly
|
|
5779
|
-
*/
|
|
5780
|
-
_updatedDate?: Date;
|
|
5781
|
-
/** Automation name that is displayed on the user's site. */
|
|
5782
|
-
name?: string;
|
|
5783
|
-
/** Automation description. */
|
|
5784
|
-
description?: string | null;
|
|
5785
|
-
/** Object that defines the automation's trigger, actions, and activation status. */
|
|
5786
|
-
configuration?: AutomationConfiguration;
|
|
5787
|
-
/** Defines how the automation was added to the site. */
|
|
5788
|
-
origin?: Origin;
|
|
5789
|
-
/** Automation settings. */
|
|
5790
|
-
settings?: AutomationSettings;
|
|
5791
|
-
/**
|
|
5792
|
-
* Draft info (optional - only if the automation is a draft)
|
|
5793
|
-
* @readonly
|
|
5794
|
-
*/
|
|
5795
|
-
draftInfo?: DraftInfo;
|
|
5796
|
-
/** Namespace */
|
|
5797
|
-
namespace?: string | null;
|
|
5798
|
-
}
|
|
5799
|
-
interface QueryAutomationsWithDraftsOptions {
|
|
5800
|
-
/** WQL expression. */
|
|
5801
|
-
query?: CursorQuery;
|
|
5802
|
-
}
|
|
5803
6714
|
interface ValidateAutomationOptions {
|
|
5804
6715
|
/** Settings to customize the validation. */
|
|
5805
6716
|
validationSettings?: ValidationSettings;
|
|
5806
6717
|
}
|
|
5807
|
-
interface GetAutomationActionSchemaIdentifiers {
|
|
5808
|
-
/** Automation ID */
|
|
5809
|
-
automationId: string;
|
|
5810
|
-
/** Action ID */
|
|
5811
|
-
actionId: string;
|
|
5812
|
-
}
|
|
5813
6718
|
|
|
5814
6719
|
declare function createAutomation$1(httpClient: HttpClient): CreateAutomationSignature;
|
|
5815
6720
|
interface CreateAutomationSignature {
|
|
@@ -5887,58 +6792,6 @@ interface CopyAutomationSignature {
|
|
|
5887
6792
|
*/
|
|
5888
6793
|
(automationId: string, options?: CopyAutomationOptions | undefined): Promise<CopyAutomationResponse & CopyAutomationResponseNonNullableFields>;
|
|
5889
6794
|
}
|
|
5890
|
-
declare function createDraftAutomation$1(httpClient: HttpClient): CreateDraftAutomationSignature;
|
|
5891
|
-
interface CreateDraftAutomationSignature {
|
|
5892
|
-
/**
|
|
5893
|
-
* Creates a draft automation.
|
|
5894
|
-
*/
|
|
5895
|
-
(options?: CreateDraftAutomationOptions | undefined): Promise<CreateDraftAutomationResponse & CreateDraftAutomationResponseNonNullableFields>;
|
|
5896
|
-
}
|
|
5897
|
-
declare function getOrCreateDraftAutomation$1(httpClient: HttpClient): GetOrCreateDraftAutomationSignature;
|
|
5898
|
-
interface GetOrCreateDraftAutomationSignature {
|
|
5899
|
-
/**
|
|
5900
|
-
* Gets the draft of the given original automation if exists, or creates one and returns it
|
|
5901
|
-
*
|
|
5902
|
-
* - if the original automation is a draft, returns the original automation
|
|
5903
|
-
* @param - Original automation id
|
|
5904
|
-
*/
|
|
5905
|
-
(originalAutomationId: string): Promise<GetOrCreateDraftAutomationResponse & GetOrCreateDraftAutomationResponseNonNullableFields>;
|
|
5906
|
-
}
|
|
5907
|
-
declare function updateDraftAutomation$1(httpClient: HttpClient): UpdateDraftAutomationSignature;
|
|
5908
|
-
interface UpdateDraftAutomationSignature {
|
|
5909
|
-
/**
|
|
5910
|
-
* Updates a draft automation
|
|
5911
|
-
* @param - Automation ID.
|
|
5912
|
-
*/
|
|
5913
|
-
(_id: string | null, automation: UpdateDraftAutomation): Promise<UpdateDraftAutomationResponse & UpdateDraftAutomationResponseNonNullableFields>;
|
|
5914
|
-
}
|
|
5915
|
-
declare function queryAutomationsWithDrafts$1(httpClient: HttpClient): QueryAutomationsWithDraftsSignature;
|
|
5916
|
-
interface QueryAutomationsWithDraftsSignature {
|
|
5917
|
-
/**
|
|
5918
|
-
* Retrieves a list of automations including drafts. Max query filter depth is 3.
|
|
5919
|
-
*
|
|
5920
|
-
* Relevant automations for the query are returned. This includes automations created on the site and pre-installed automations.
|
|
5921
|
-
* If there's an existing override for a pre-installed automation, the override is returned in the query result.
|
|
5922
|
-
* The query only returns automations from apps that are installed on the site.
|
|
5923
|
-
*
|
|
5924
|
-
* - new drafts that are not related to existing automations will be returned in the list
|
|
5925
|
-
* - the response will contain a map of originalAutomationId => relatedDrafts
|
|
5926
|
-
*
|
|
5927
|
-
* To learn about working with _Query_ endpoints, see
|
|
5928
|
-
* [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language),
|
|
5929
|
-
* [Sorting and Paging](https://dev.wix.com/api/rest/getting-started/pagination),
|
|
5930
|
-
* and [Field Projection](https://dev.wix.com/api/rest/getting-started/field-projection).
|
|
5931
|
-
*/
|
|
5932
|
-
(options?: QueryAutomationsWithDraftsOptions | undefined): Promise<QueryAutomationsWithDraftsResponse & QueryAutomationsWithDraftsResponseNonNullableFields>;
|
|
5933
|
-
}
|
|
5934
|
-
declare function deleteDraftAutomation$1(httpClient: HttpClient): DeleteDraftAutomationSignature;
|
|
5935
|
-
interface DeleteDraftAutomationSignature {
|
|
5936
|
-
/**
|
|
5937
|
-
* Deletes a draft automation.
|
|
5938
|
-
* @param - Id of the draft automation to delete.
|
|
5939
|
-
*/
|
|
5940
|
-
(automationId: string): Promise<void>;
|
|
5941
|
-
}
|
|
5942
6795
|
declare function validateAutomation$1(httpClient: HttpClient): ValidateAutomationSignature;
|
|
5943
6796
|
interface ValidateAutomationSignature {
|
|
5944
6797
|
/**
|
|
@@ -5947,13 +6800,6 @@ interface ValidateAutomationSignature {
|
|
|
5947
6800
|
*/
|
|
5948
6801
|
(automation: Automation, options?: ValidateAutomationOptions | undefined): Promise<ValidateAutomationResponse & ValidateAutomationResponseNonNullableFields>;
|
|
5949
6802
|
}
|
|
5950
|
-
declare function getAutomationActionSchema$1(httpClient: HttpClient): GetAutomationActionSchemaSignature;
|
|
5951
|
-
interface GetAutomationActionSchemaSignature {
|
|
5952
|
-
/**
|
|
5953
|
-
* Gets the payload schema received by the action whose ID is passed in.
|
|
5954
|
-
*/
|
|
5955
|
-
(identifiers: GetAutomationActionSchemaIdentifiers): Promise<GetAutomationActionSchemaResponse>;
|
|
5956
|
-
}
|
|
5957
6803
|
declare function getActionsQuotaInfo$1(httpClient: HttpClient): GetActionsQuotaInfoSignature;
|
|
5958
6804
|
interface GetActionsQuotaInfoSignature {
|
|
5959
6805
|
/**
|
|
@@ -5961,29 +6807,11 @@ interface GetActionsQuotaInfoSignature {
|
|
|
5961
6807
|
*/
|
|
5962
6808
|
(): Promise<GetActionsQuotaInfoResponse & GetActionsQuotaInfoResponseNonNullableFields>;
|
|
5963
6809
|
}
|
|
5964
|
-
declare const onAutomationCreated$1: EventDefinition
|
|
5965
|
-
declare const onAutomationUpdated$1: EventDefinition
|
|
5966
|
-
declare const onAutomationDeleted$1: EventDefinition
|
|
5967
|
-
declare const onAutomationUpdatedWithPreviousEntity$1: EventDefinition
|
|
5968
|
-
declare const onAutomationDeletedWithEntity$1: EventDefinition
|
|
5969
|
-
|
|
5970
|
-
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
5971
|
-
__type: 'event-definition';
|
|
5972
|
-
type: Type;
|
|
5973
|
-
isDomainEvent?: boolean;
|
|
5974
|
-
transformations?: (envelope: unknown) => Payload;
|
|
5975
|
-
__payload: Payload;
|
|
5976
|
-
};
|
|
5977
|
-
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
5978
|
-
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
5979
|
-
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
5980
|
-
|
|
5981
|
-
declare global {
|
|
5982
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
5983
|
-
interface SymbolConstructor {
|
|
5984
|
-
readonly observable: symbol;
|
|
5985
|
-
}
|
|
5986
|
-
}
|
|
6810
|
+
declare const onAutomationCreated$1: EventDefinition<AutomationCreatedEnvelope, "wix.automations.v2.automation_created">;
|
|
6811
|
+
declare const onAutomationUpdated$1: EventDefinition<AutomationUpdatedEnvelope, "wix.automations.v2.automation_updated">;
|
|
6812
|
+
declare const onAutomationDeleted$1: EventDefinition<AutomationDeletedEnvelope, "wix.automations.v2.automation_deleted">;
|
|
6813
|
+
declare const onAutomationUpdatedWithPreviousEntity$1: EventDefinition<AutomationUpdatedWithPreviousEntityEnvelope, "wix.automations.v2.automation_updated_with_previous_entity">;
|
|
6814
|
+
declare const onAutomationDeletedWithEntity$1: EventDefinition<AutomationDeletedWithEntityEnvelope, "wix.automations.v2.automation_deleted_with_entity">;
|
|
5987
6815
|
|
|
5988
6816
|
declare function createEventModule<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
|
|
5989
6817
|
|
|
@@ -5994,13 +6822,7 @@ declare const deleteAutomation: MaybeContext<BuildRESTFunction<typeof deleteAuto
|
|
|
5994
6822
|
declare const bulkDeleteAutomations: MaybeContext<BuildRESTFunction<typeof bulkDeleteAutomations$1> & typeof bulkDeleteAutomations$1>;
|
|
5995
6823
|
declare const queryAutomations: MaybeContext<BuildRESTFunction<typeof queryAutomations$1> & typeof queryAutomations$1>;
|
|
5996
6824
|
declare const copyAutomation: MaybeContext<BuildRESTFunction<typeof copyAutomation$1> & typeof copyAutomation$1>;
|
|
5997
|
-
declare const createDraftAutomation: MaybeContext<BuildRESTFunction<typeof createDraftAutomation$1> & typeof createDraftAutomation$1>;
|
|
5998
|
-
declare const getOrCreateDraftAutomation: MaybeContext<BuildRESTFunction<typeof getOrCreateDraftAutomation$1> & typeof getOrCreateDraftAutomation$1>;
|
|
5999
|
-
declare const updateDraftAutomation: MaybeContext<BuildRESTFunction<typeof updateDraftAutomation$1> & typeof updateDraftAutomation$1>;
|
|
6000
|
-
declare const queryAutomationsWithDrafts: MaybeContext<BuildRESTFunction<typeof queryAutomationsWithDrafts$1> & typeof queryAutomationsWithDrafts$1>;
|
|
6001
|
-
declare const deleteDraftAutomation: MaybeContext<BuildRESTFunction<typeof deleteDraftAutomation$1> & typeof deleteDraftAutomation$1>;
|
|
6002
6825
|
declare const validateAutomation: MaybeContext<BuildRESTFunction<typeof validateAutomation$1> & typeof validateAutomation$1>;
|
|
6003
|
-
declare const getAutomationActionSchema: MaybeContext<BuildRESTFunction<typeof getAutomationActionSchema$1> & typeof getAutomationActionSchema$1>;
|
|
6004
6826
|
declare const getActionsQuotaInfo: MaybeContext<BuildRESTFunction<typeof getActionsQuotaInfo$1> & typeof getActionsQuotaInfo$1>;
|
|
6005
6827
|
|
|
6006
6828
|
type _publicOnAutomationCreatedType = typeof onAutomationCreated$1;
|
|
@@ -6085,10 +6907,8 @@ type context_CopyAutomationResponseNonNullableFields = CopyAutomationResponseNon
|
|
|
6085
6907
|
type context_CreateAutomationRequest = CreateAutomationRequest;
|
|
6086
6908
|
type context_CreateAutomationResponse = CreateAutomationResponse;
|
|
6087
6909
|
type context_CreateAutomationResponseNonNullableFields = CreateAutomationResponseNonNullableFields;
|
|
6088
|
-
type context_CreateDraftAutomationOptions = CreateDraftAutomationOptions;
|
|
6089
6910
|
type context_CreateDraftAutomationRequest = CreateDraftAutomationRequest;
|
|
6090
6911
|
type context_CreateDraftAutomationResponse = CreateDraftAutomationResponse;
|
|
6091
|
-
type context_CreateDraftAutomationResponseNonNullableFields = CreateDraftAutomationResponseNonNullableFields;
|
|
6092
6912
|
type context_CreatePreinstalledAutomationRequest = CreatePreinstalledAutomationRequest;
|
|
6093
6913
|
type context_CreatePreinstalledAutomationResponse = CreatePreinstalledAutomationResponse;
|
|
6094
6914
|
type context_CursorPaging = CursorPaging;
|
|
@@ -6121,7 +6941,6 @@ type context_FutureDateActivationOffset = FutureDateActivationOffset;
|
|
|
6121
6941
|
type context_GetActionsQuotaInfoRequest = GetActionsQuotaInfoRequest;
|
|
6122
6942
|
type context_GetActionsQuotaInfoResponse = GetActionsQuotaInfoResponse;
|
|
6123
6943
|
type context_GetActionsQuotaInfoResponseNonNullableFields = GetActionsQuotaInfoResponseNonNullableFields;
|
|
6124
|
-
type context_GetAutomationActionSchemaIdentifiers = GetAutomationActionSchemaIdentifiers;
|
|
6125
6944
|
type context_GetAutomationActionSchemaRequest = GetAutomationActionSchemaRequest;
|
|
6126
6945
|
type context_GetAutomationActionSchemaResponse = GetAutomationActionSchemaResponse;
|
|
6127
6946
|
type context_GetAutomationOptions = GetAutomationOptions;
|
|
@@ -6132,7 +6951,6 @@ type context_GetAutomationRevisionRequest = GetAutomationRevisionRequest;
|
|
|
6132
6951
|
type context_GetAutomationRevisionResponse = GetAutomationRevisionResponse;
|
|
6133
6952
|
type context_GetOrCreateDraftAutomationRequest = GetOrCreateDraftAutomationRequest;
|
|
6134
6953
|
type context_GetOrCreateDraftAutomationResponse = GetOrCreateDraftAutomationResponse;
|
|
6135
|
-
type context_GetOrCreateDraftAutomationResponseNonNullableFields = GetOrCreateDraftAutomationResponseNonNullableFields;
|
|
6136
6954
|
type context_IdentificationData = IdentificationData;
|
|
6137
6955
|
type context_IdentificationDataIdOneOf = IdentificationDataIdOneOf;
|
|
6138
6956
|
type context_ItemMetadata = ItemMetadata;
|
|
@@ -6157,10 +6975,8 @@ type context_PublishDraftAutomationResponse = PublishDraftAutomationResponse;
|
|
|
6157
6975
|
type context_QueryAutomationsRequest = QueryAutomationsRequest;
|
|
6158
6976
|
type context_QueryAutomationsResponse = QueryAutomationsResponse;
|
|
6159
6977
|
type context_QueryAutomationsResponseNonNullableFields = QueryAutomationsResponseNonNullableFields;
|
|
6160
|
-
type context_QueryAutomationsWithDraftsOptions = QueryAutomationsWithDraftsOptions;
|
|
6161
6978
|
type context_QueryAutomationsWithDraftsRequest = QueryAutomationsWithDraftsRequest;
|
|
6162
6979
|
type context_QueryAutomationsWithDraftsResponse = QueryAutomationsWithDraftsResponse;
|
|
6163
|
-
type context_QueryAutomationsWithDraftsResponseNonNullableFields = QueryAutomationsWithDraftsResponseNonNullableFields;
|
|
6164
6980
|
type context_QueryPreinstalledAutomationsForAppRequest = QueryPreinstalledAutomationsForAppRequest;
|
|
6165
6981
|
type context_QueryPreinstalledAutomationsForAppResponse = QueryPreinstalledAutomationsForAppResponse;
|
|
6166
6982
|
type context_Quota = Quota;
|
|
@@ -6207,10 +7023,8 @@ type context_UpdateAutomation = UpdateAutomation;
|
|
|
6207
7023
|
type context_UpdateAutomationRequest = UpdateAutomationRequest;
|
|
6208
7024
|
type context_UpdateAutomationResponse = UpdateAutomationResponse;
|
|
6209
7025
|
type context_UpdateAutomationResponseNonNullableFields = UpdateAutomationResponseNonNullableFields;
|
|
6210
|
-
type context_UpdateDraftAutomation = UpdateDraftAutomation;
|
|
6211
7026
|
type context_UpdateDraftAutomationRequest = UpdateDraftAutomationRequest;
|
|
6212
7027
|
type context_UpdateDraftAutomationResponse = UpdateDraftAutomationResponse;
|
|
6213
|
-
type context_UpdateDraftAutomationResponseNonNullableFields = UpdateDraftAutomationResponseNonNullableFields;
|
|
6214
7028
|
type context_UpdatePreinstalledAutomationRequest = UpdatePreinstalledAutomationRequest;
|
|
6215
7029
|
type context_UpdatePreinstalledAutomationResponse = UpdatePreinstalledAutomationResponse;
|
|
6216
7030
|
type context_UpdatedWithPreviousEntity = UpdatedWithPreviousEntity;
|
|
@@ -6234,25 +7048,19 @@ type context__publicOnAutomationUpdatedWithPreviousEntityType = _publicOnAutomat
|
|
|
6234
7048
|
declare const context_bulkDeleteAutomations: typeof bulkDeleteAutomations;
|
|
6235
7049
|
declare const context_copyAutomation: typeof copyAutomation;
|
|
6236
7050
|
declare const context_createAutomation: typeof createAutomation;
|
|
6237
|
-
declare const context_createDraftAutomation: typeof createDraftAutomation;
|
|
6238
7051
|
declare const context_deleteAutomation: typeof deleteAutomation;
|
|
6239
|
-
declare const context_deleteDraftAutomation: typeof deleteDraftAutomation;
|
|
6240
7052
|
declare const context_getActionsQuotaInfo: typeof getActionsQuotaInfo;
|
|
6241
7053
|
declare const context_getAutomation: typeof getAutomation;
|
|
6242
|
-
declare const context_getAutomationActionSchema: typeof getAutomationActionSchema;
|
|
6243
|
-
declare const context_getOrCreateDraftAutomation: typeof getOrCreateDraftAutomation;
|
|
6244
7054
|
declare const context_onAutomationCreated: typeof onAutomationCreated;
|
|
6245
7055
|
declare const context_onAutomationDeleted: typeof onAutomationDeleted;
|
|
6246
7056
|
declare const context_onAutomationDeletedWithEntity: typeof onAutomationDeletedWithEntity;
|
|
6247
7057
|
declare const context_onAutomationUpdated: typeof onAutomationUpdated;
|
|
6248
7058
|
declare const context_onAutomationUpdatedWithPreviousEntity: typeof onAutomationUpdatedWithPreviousEntity;
|
|
6249
7059
|
declare const context_queryAutomations: typeof queryAutomations;
|
|
6250
|
-
declare const context_queryAutomationsWithDrafts: typeof queryAutomationsWithDrafts;
|
|
6251
7060
|
declare const context_updateAutomation: typeof updateAutomation;
|
|
6252
|
-
declare const context_updateDraftAutomation: typeof updateDraftAutomation;
|
|
6253
7061
|
declare const context_validateAutomation: typeof validateAutomation;
|
|
6254
7062
|
declare namespace context {
|
|
6255
|
-
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 };
|
|
7063
|
+
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_CreateDraftAutomationRequest as CreateDraftAutomationRequest, type context_CreateDraftAutomationResponse as CreateDraftAutomationResponse, 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_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_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_QueryAutomationsWithDraftsRequest as QueryAutomationsWithDraftsRequest, type context_QueryAutomationsWithDraftsResponse as QueryAutomationsWithDraftsResponse, 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_UpdateDraftAutomationRequest as UpdateDraftAutomationRequest, type context_UpdateDraftAutomationResponse as UpdateDraftAutomationResponse, 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_deleteAutomation as deleteAutomation, context_getActionsQuotaInfo as getActionsQuotaInfo, context_getAutomation as getAutomation, 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_updateAutomation as updateAutomation, context_validateAutomation as validateAutomation };
|
|
6256
7064
|
}
|
|
6257
7065
|
|
|
6258
7066
|
export { context$1 as activations, context$2 as automationsService, context as automationsServiceV2 };
|