@wix/auto_sdk_automations_activation-log 1.0.20 → 1.0.21

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.
@@ -245,6 +245,801 @@ declare enum WarningReason {
245
245
  }
246
246
  /** @enumType */
247
247
  type WarningReasonWithLiterals = WarningReason | 'UNKNOWN_WARNING_REASON' | 'STUDIO_SITE_ENRICHMENT_FAILED' | 'REFRESH_PAYLOAD_FAILED' | 'GET_CONTACT_ENRICHMENT_FAILED' | 'GET_MEMBER_ENRICHMENT_FAILED';
248
+ interface DomainEvent extends DomainEventBodyOneOf {
249
+ createdEvent?: EntityCreatedEvent;
250
+ updatedEvent?: EntityUpdatedEvent;
251
+ deletedEvent?: EntityDeletedEvent;
252
+ actionEvent?: ActionEvent;
253
+ /** Event ID. With this ID you can easily spot duplicated events and ignore them. */
254
+ id?: string;
255
+ /**
256
+ * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
257
+ * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
258
+ */
259
+ entityFqdn?: string;
260
+ /**
261
+ * Event action name, placed at the top level to make it easier for users to dispatch messages.
262
+ * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
263
+ */
264
+ slug?: string;
265
+ /** ID of the entity associated with the event. */
266
+ entityId?: string;
267
+ /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
268
+ eventTime?: Date | null;
269
+ /**
270
+ * Whether the event was triggered as a result of a privacy regulation application
271
+ * (for example, GDPR).
272
+ */
273
+ triggeredByAnonymizeRequest?: boolean | null;
274
+ /** If present, indicates the action that triggered the event. */
275
+ originatedFrom?: string | null;
276
+ /**
277
+ * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at 16:00 and then again at 16:01, the second update will always have a higher sequence number.
278
+ * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
279
+ */
280
+ entityEventSequence?: string | null;
281
+ }
282
+ /** @oneof */
283
+ interface DomainEventBodyOneOf {
284
+ createdEvent?: EntityCreatedEvent;
285
+ updatedEvent?: EntityUpdatedEvent;
286
+ deletedEvent?: EntityDeletedEvent;
287
+ actionEvent?: ActionEvent;
288
+ }
289
+ interface EntityCreatedEvent {
290
+ entityAsJson?: string;
291
+ /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
292
+ restoreInfo?: RestoreInfo;
293
+ }
294
+ interface RestoreInfo {
295
+ deletedDate?: Date | null;
296
+ }
297
+ interface EntityUpdatedEvent {
298
+ /**
299
+ * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
300
+ * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
301
+ * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
302
+ */
303
+ currentEntityAsJson?: string;
304
+ }
305
+ interface EntityDeletedEvent {
306
+ /** Entity that was deleted. */
307
+ deletedEntityAsJson?: string | null;
308
+ }
309
+ interface ActionEvent {
310
+ bodyAsJson?: string;
311
+ }
312
+ interface Empty {
313
+ }
314
+ interface ActivationContinuedAfterSchedule {
315
+ /**
316
+ * Activation identifier
317
+ * @format GUID
318
+ */
319
+ id?: string;
320
+ /** Activation Automation */
321
+ automation?: Automation;
322
+ }
323
+ interface Automation extends AutomationOriginInfoOneOf {
324
+ /** When the origin of the automation is `APPLICATION`, the details of the app that created it. */
325
+ applicationInfo?: ApplicationOrigin;
326
+ /** When the origin of the automation is `PREINSTALLED`, the details of the preinstalled automation. */
327
+ preinstalledInfo?: PreinstalledOrigin;
328
+ /**
329
+ * Automation ID.
330
+ * @format GUID
331
+ * @readonly
332
+ */
333
+ id?: string | null;
334
+ /**
335
+ * Revision number. This increments by 1 whenever the automation is updated. Specify the current revision number whenever updating an existing automation.
336
+ * @readonly
337
+ */
338
+ revision?: string | null;
339
+ /**
340
+ * Who created the automation.
341
+ * @immutable
342
+ * @readonly
343
+ */
344
+ createdBy?: AuditInfo;
345
+ /**
346
+ * When the automation was created.
347
+ * @readonly
348
+ */
349
+ createdDate?: Date | null;
350
+ /**
351
+ * Who last updated the automation.
352
+ * @readonly
353
+ */
354
+ updatedBy?: AuditInfo;
355
+ /**
356
+ * When the automation was last updated.
357
+ * @readonly
358
+ */
359
+ updatedDate?: Date | null;
360
+ /**
361
+ * Automation name as displayed on the user's site.
362
+ * @minLength 1
363
+ * @maxLength 500
364
+ */
365
+ name?: string;
366
+ /**
367
+ * Automation description.
368
+ * @maxLength 2000
369
+ */
370
+ description?: string | null;
371
+ /** Automation configuration. */
372
+ configuration?: AutomationConfiguration;
373
+ /**
374
+ * How the automation was added to the user's site.
375
+ * @immutable
376
+ */
377
+ origin?: OriginWithLiterals;
378
+ /** Automation settings. */
379
+ settings?: AutomationSettings;
380
+ /**
381
+ * When the automation is a draft, the draft details.
382
+ * @readonly
383
+ */
384
+ draftInfo?: DraftInfo;
385
+ /**
386
+ * Whether the automation is archived.
387
+ *
388
+ * To archive an automation, set this to `true`. To restore an archived automation, set this to `false`.
389
+ */
390
+ archived?: boolean;
391
+ /** Auto archive policy */
392
+ autoArchivePolicy?: AutoArchivePolicy;
393
+ }
394
+ /** @oneof */
395
+ interface AutomationOriginInfoOneOf {
396
+ /** When the origin of the automation is `APPLICATION`, the details of the app that created it. */
397
+ applicationInfo?: ApplicationOrigin;
398
+ /** When the origin of the automation is `PREINSTALLED`, the details of the preinstalled automation. */
399
+ preinstalledInfo?: PreinstalledOrigin;
400
+ }
401
+ interface ActionSettings {
402
+ /**
403
+ * Permanent actions. PermanentAction's skipActionExpression cannot be modified.
404
+ *
405
+ * When empty, all actions can be set as skipped
406
+ * @maxSize 30
407
+ * @format GUID
408
+ */
409
+ permanentActionIds?: string[];
410
+ /**
411
+ * Read-only actions. Read-only actions cannot be edited.
412
+ *
413
+ * When empty, all actions are editable.
414
+ * @maxSize 30
415
+ * @format GUID
416
+ */
417
+ readonlyActionIds?: string[];
418
+ /**
419
+ * Whether to disable the ability to add a delay to the automation.
420
+ *
421
+ * Default: `false`.
422
+ */
423
+ disableDelayAddition?: boolean;
424
+ /**
425
+ * Whether to disable the ability to add a condition to the automation.
426
+ *
427
+ * Default: `false`.
428
+ */
429
+ disableConditionAddition?: boolean;
430
+ }
431
+ declare enum Domain {
432
+ /** User domain (default). */
433
+ USER = "USER",
434
+ /** Wix domain. */
435
+ WIX = "WIX",
436
+ /** Wix account-level domain. */
437
+ WIX_ACCOUNT = "WIX_ACCOUNT"
438
+ }
439
+ /** @enumType */
440
+ type DomainWithLiterals = Domain | 'USER' | 'WIX' | 'WIX_ACCOUNT';
441
+ interface Enrichment {
442
+ /**
443
+ * Enrichment input mappings.
444
+ * @maxSize 2
445
+ */
446
+ inputMappings?: Record<string, any>[] | null;
447
+ }
448
+ interface AuditInfo extends AuditInfoIdOneOf {
449
+ /**
450
+ * [User ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#user-id).
451
+ * @format GUID
452
+ */
453
+ userId?: string;
454
+ /**
455
+ * [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
456
+ *
457
+ * You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
458
+ * @format GUID
459
+ */
460
+ appId?: string;
461
+ }
462
+ /** @oneof */
463
+ interface AuditInfoIdOneOf {
464
+ /**
465
+ * [User ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#user-id).
466
+ * @format GUID
467
+ */
468
+ userId?: string;
469
+ /**
470
+ * [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
471
+ *
472
+ * You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
473
+ * @format GUID
474
+ */
475
+ appId?: string;
476
+ }
477
+ interface AutomationConfiguration {
478
+ /** Status of the automation on the site. */
479
+ status?: AutomationConfigurationStatusWithLiterals;
480
+ /** Trigger configuration. */
481
+ trigger?: Trigger;
482
+ /**
483
+ * Root action IDs. A root action is the first action that runs after the trigger occurs. Root actions run in parallel.
484
+ *
485
+ * > **Note**: You can currently only specify 1 root action.
486
+ * @maxSize 20
487
+ * @format GUID
488
+ */
489
+ rootActionIds?: string[];
490
+ /** Actions the automation can execute, as key:value pairs. For the key, specify the action ID. The value must be an object structured as described below. */
491
+ actions?: Record<string, Action>;
492
+ }
493
+ declare enum TimeUnit {
494
+ UNKNOWN_TIME_UNIT = "UNKNOWN_TIME_UNIT",
495
+ /** Minutes. */
496
+ MINUTES = "MINUTES",
497
+ /** Hours. */
498
+ HOURS = "HOURS",
499
+ /** Days. */
500
+ DAYS = "DAYS",
501
+ /** Weeks. */
502
+ WEEKS = "WEEKS",
503
+ /** Months. */
504
+ MONTHS = "MONTHS"
505
+ }
506
+ /** @enumType */
507
+ type TimeUnitWithLiterals = TimeUnit | 'UNKNOWN_TIME_UNIT' | 'MINUTES' | 'HOURS' | 'DAYS' | 'WEEKS' | 'MONTHS';
508
+ interface Filter {
509
+ /**
510
+ * Filter ID.
511
+ * @format GUID
512
+ */
513
+ id?: string;
514
+ /**
515
+ * Field key.
516
+ *
517
+ * You can find the field key in [the trigger payload schema](https://dev.wix.com/docs/rest/business-management/automations/triggers/the-trigger-payload-schema).
518
+ * @minLength 1
519
+ * @maxLength 110
520
+ */
521
+ fieldKey?: string;
522
+ /**
523
+ * Filter expression.
524
+ *
525
+ * For the automation to run, the expression must evaluate to `true`.
526
+ * @maxLength 2500
527
+ */
528
+ filterExpression?: string;
529
+ }
530
+ interface FutureDateActivationOffset {
531
+ /**
532
+ * Amount of time before the trigger to run the automation.
533
+ *
534
+ * > **Note**: To delay an automation after the trigger event occurs, use a [delay action](https://dev.wix.com/docs/rest/business-management/automations/automations/automations-v2/configure-your-automation#delay-action).
535
+ * @maxLength 1000
536
+ */
537
+ preScheduledEventOffsetExpression?: string;
538
+ /** Unit in which to set the action offset. */
539
+ scheduledEventOffsetTimeUnit?: TimeUnitWithLiterals;
540
+ }
541
+ interface RateLimit {
542
+ /**
543
+ * Maximum number of times the trigger can be activated.
544
+ * @maxLength 1000
545
+ */
546
+ maxActivationsExpression?: string;
547
+ /**
548
+ * Duration of the rate limit. The rate limit applies for the specified duration and then expires.
549
+ *
550
+ * When empty, the rate limit does not expire.
551
+ * @maxLength 1000
552
+ */
553
+ durationExpression?: string | null;
554
+ /** Unit in which to set the duration of the rate limit. */
555
+ durationTimeUnit?: TimeUnitWithLiterals;
556
+ /**
557
+ * Activation identifier used to count the number of activations.
558
+ * @minLength 1
559
+ * @maxLength 400
560
+ */
561
+ uniqueIdentifierExpression?: string | null;
562
+ }
563
+ interface FilterValueSelection {
564
+ /**
565
+ * Values that can help the user filter certain automations. Specify values in the following format: `<filter_id>__<selected_value>`.
566
+ * @maxLength 80
567
+ * @maxSize 50
568
+ */
569
+ selectedFilterValues?: string[];
570
+ }
571
+ interface ConditionExpressionGroup {
572
+ /** Logical operator used to evaluate the condition expressions. */
573
+ operator?: OperatorWithLiterals;
574
+ /**
575
+ * Expressions evaluated using the selected operator.
576
+ * @minSize 1
577
+ * @maxSize 20
578
+ * @maxLength 2500
579
+ */
580
+ booleanExpressions?: string[];
581
+ }
582
+ declare enum Operator {
583
+ /** Unknown. */
584
+ UNKNOWN_OPERATOR = "UNKNOWN_OPERATOR",
585
+ /** `OR` operator. */
586
+ OR = "OR",
587
+ /** `AND` operator. */
588
+ AND = "AND"
589
+ }
590
+ /** @enumType */
591
+ type OperatorWithLiterals = Operator | 'UNKNOWN_OPERATOR' | 'OR' | 'AND';
592
+ interface CodeSnippet {
593
+ /** Logical operator used to evaluate the condition expressions. */
594
+ language?: LanguageWithLiterals;
595
+ /**
596
+ * Expressions evaluated using the selected operator. this code should comply the language syntax. and format
597
+ * @maxLength 1000
598
+ */
599
+ code?: string;
600
+ }
601
+ declare enum Language {
602
+ /** Unknown. */
603
+ UNKNOWN_LANGUAGE = "UNKNOWN_LANGUAGE",
604
+ /** `JAVASCRIPT` language. */
605
+ JAVASCRIPT = "JAVASCRIPT"
606
+ }
607
+ /** @enumType */
608
+ type LanguageWithLiterals = Language | 'UNKNOWN_LANGUAGE' | 'JAVASCRIPT';
609
+ /** Path definition */
610
+ interface Path {
611
+ /**
612
+ * Unique path ID.
613
+ * @format GUID
614
+ */
615
+ id?: string;
616
+ /**
617
+ * Path display name.
618
+ * @minLength 1
619
+ * @maxLength 100
620
+ */
621
+ name?: string;
622
+ /**
623
+ * ID of the action to run when this path is taken.
624
+ * @format GUID
625
+ */
626
+ postActionId?: string | null;
627
+ }
628
+ declare enum Type {
629
+ /** Based on the trigger. */
630
+ UNKNOWN_ACTION_TYPE = "UNKNOWN_ACTION_TYPE",
631
+ /** Defined by a [Wix app](https://dev.wix.com/docs/rest/business-management/automations/automations/automations-v2/configure-your-automation#app-defined-action). This action type is available in the site dashboard. */
632
+ APP_DEFINED = "APP_DEFINED",
633
+ /** Condition. This determines which action runs next. */
634
+ CONDITION = "CONDITION",
635
+ /** Delay. The automation must wait before executing the next step. */
636
+ DELAY = "DELAY",
637
+ /** Rate-limiter. This stops the automation flow if the subsequent action has reached its maximum allowed executions. */
638
+ RATE_LIMIT = "RATE_LIMIT"
639
+ }
640
+ /** @enumType */
641
+ type TypeWithLiterals = Type | 'UNKNOWN_ACTION_TYPE' | 'APP_DEFINED' | 'CONDITION' | 'DELAY' | 'RATE_LIMIT';
642
+ interface AppDefinedAction {
643
+ /**
644
+ * ID of the app that defines the action.
645
+ * @format GUID
646
+ */
647
+ appId?: string;
648
+ /**
649
+ * Action key.
650
+ * @minLength 1
651
+ * @maxLength 100
652
+ */
653
+ actionKey?: string;
654
+ /** Action input mapping as defined in the action's [input schema](https://dev.wix.com/docs/rest/business-management/automations/actions/the-action-input-schema). */
655
+ inputMapping?: Record<string, any> | null;
656
+ /**
657
+ * Action skip conditions. An action is skipped if any of the specified conditions evaluates to `true`.
658
+ *
659
+ * > **Note**: Actions that follow a skipped action still run.
660
+ * @maxSize 10
661
+ * @deprecated Action skip conditions. An action is skipped if any of the specified conditions evaluates to `true`.
662
+ *
663
+ * > **Note**: Actions that follow a skipped action still run.
664
+ * @replacedBy skip_expression
665
+ * @targetRemovalDate 2026-02-01
666
+ */
667
+ skipConditionOrExpressionGroups?: ConditionExpressionGroup[];
668
+ /**
669
+ * IDs of actions that run in parallel after the action completes.
670
+ * @maxSize 1
671
+ * @format GUID
672
+ */
673
+ postActionIds?: string[];
674
+ /** Action output schema. When specified, this replaces the action schema. */
675
+ overrideOutputSchema?: Record<string, any> | null;
676
+ }
677
+ interface ConditionAction {
678
+ /**
679
+ * Condition is `true` if one or more of the expression groups evaluates to `true`.
680
+ * @minSize 1
681
+ * @maxSize 10
682
+ */
683
+ orExpressionGroups?: ConditionExpressionGroup[];
684
+ /**
685
+ * IDs of actions to run when the condition evaluates to `true`.
686
+ * @maxSize 1
687
+ * @format GUID
688
+ */
689
+ truePostActionIds?: string[];
690
+ /**
691
+ * IDs of actions to run when the condition evaluates to `false`.
692
+ * @maxSize 1
693
+ * @format GUID
694
+ */
695
+ falsePostActionIds?: string[];
696
+ }
697
+ interface CodeConditionAction {
698
+ /** condition code. This is a code that can be used to identify the condition in the automation. code should return a boolean value. otherwise the value will be tried to be casted to boolean. */
699
+ snippet?: CodeSnippet;
700
+ /**
701
+ * IDs of actions to run when the condition evaluates to `true`.
702
+ * @maxSize 1
703
+ * @format GUID
704
+ */
705
+ truePostActionIds?: string[];
706
+ /**
707
+ * IDs of actions to run when the condition evaluates to `false`.
708
+ * @maxSize 1
709
+ * @format GUID
710
+ */
711
+ falsePostActionIds?: string[];
712
+ }
713
+ interface DelayAction {
714
+ /**
715
+ * Time to wait before running the action. The wait time starts from when the current action completes.
716
+ *
717
+ * > **Note**: To define the wait time from a specific moment in time, use `dueDateEpochExpression` or `dueDateExpression`.
718
+ * @maxLength 1000
719
+ */
720
+ offsetExpression?: string | null;
721
+ /** Unit in which to set the wait time to wait before the action runs. */
722
+ offsetTimeUnit?: TimeUnitWithLiterals;
723
+ /**
724
+ * Action run date in milliseconds elapsed since January 1, 1970 UTC.
725
+ *
726
+ * > **Note**: If an `offsetExpression` is defined, the delay is calculated from the time of the offset.
727
+ * @maxLength 1000
728
+ * @deprecated Action run date in milliseconds elapsed since January 1, 1970 UTC.
729
+ *
730
+ * > **Note**: If an `offsetExpression` is defined, the delay is calculated from the time of the offset.
731
+ * @replacedBy due_date_expression
732
+ * @targetRemovalDate 2026-02-01
733
+ */
734
+ dueDateEpochExpression?: string | null;
735
+ /**
736
+ * Action run date as a timestamp/datetime string expression using bracket language.
737
+ * The expression will be converted to JSONata and should evaluate to a timestamp/datetime format.
738
+ *
739
+ * > **Note**: If an `offsetExpression` is defined, the delay is calculated from the time of the offset.
740
+ * @maxLength 1000
741
+ */
742
+ dueDateExpression?: string | null;
743
+ /**
744
+ * IDs of actions to run in parallel after the time delay.
745
+ * @maxSize 1
746
+ * @format GUID
747
+ */
748
+ postActionIds?: string[];
749
+ }
750
+ interface RateLimitAction {
751
+ /**
752
+ * Maximum number of times the action can run.
753
+ * @maxLength 1000
754
+ */
755
+ maxActivationsExpression?: string;
756
+ /**
757
+ * Rate limit duration.
758
+ *
759
+ * When empty, the rate limit does not expire.
760
+ * @maxLength 1000
761
+ */
762
+ rateLimitDurationExpression?: string | null;
763
+ /** Unit in which to set the duration of the rate limit. */
764
+ rateLimitDurationTimeUnit?: TimeUnitWithLiterals;
765
+ /**
766
+ * Unique identifier of each activation by which rate limiter counts activations.
767
+ * @minLength 1
768
+ * @maxLength 400
769
+ */
770
+ uniqueIdentifierExpression?: string | null;
771
+ /**
772
+ * IDs of actions to run in parallel after the action completes.
773
+ * @maxSize 1
774
+ * @format GUID
775
+ */
776
+ postActionIds?: string[];
777
+ }
778
+ interface SetVariablesAction {
779
+ /** Output mapping. For example: `{"someField": "{{10}}", "someOtherField": "{{multiply( var('account.points.balance') ;2 )}}" }`. */
780
+ outputMapping?: Record<string, any> | null;
781
+ /**
782
+ * Output JSON schema representation.
783
+ *
784
+ * > **Note**: To minimize request size, you can also specify a string.
785
+ */
786
+ outputSchema?: Record<string, any> | null;
787
+ /**
788
+ * IDs of actions to run in parallel after variable initialization.
789
+ * @maxSize 1
790
+ * @format GUID
791
+ */
792
+ postActionIds?: string[];
793
+ }
794
+ interface OutputAction {
795
+ /** Output action output mapping. */
796
+ outputMapping?: Record<string, any> | null;
797
+ }
798
+ interface SplitAction {
799
+ /**
800
+ * List of paths to split execution into.
801
+ * @minSize 2
802
+ * @maxSize 10
803
+ */
804
+ paths?: Path[];
805
+ }
806
+ declare enum AutomationConfigurationStatus {
807
+ /** Unknown. */
808
+ UNKNOWN_STATUS = "UNKNOWN_STATUS",
809
+ /** Active. Active automations can be triggered. */
810
+ ACTIVE = "ACTIVE",
811
+ /** Inactive. Inactive automations cannot be triggered. */
812
+ INACTIVE = "INACTIVE"
813
+ }
814
+ /** @enumType */
815
+ type AutomationConfigurationStatusWithLiterals = AutomationConfigurationStatus | 'UNKNOWN_STATUS' | 'ACTIVE' | 'INACTIVE';
816
+ interface Trigger {
817
+ /**
818
+ * ID of the app that defines the trigger.
819
+ * @format GUID
820
+ */
821
+ appId?: string;
822
+ /**
823
+ * Trigger key.
824
+ *
825
+ * Learn about [setting up a trigger](https://dev.wix.com/docs/rest/business-management/automations/triggers/add-a-trigger-to-your-app#step-1--set-up-the-trigger).
826
+ * @minLength 1
827
+ * @maxLength 100
828
+ */
829
+ triggerKey?: string;
830
+ /**
831
+ * Schema field filters. All filter conditions must be met for the automation to run.
832
+ *
833
+ * Learn more about setting up [automation filters](https://dev.wix.com/docs/rest/business-management/automations/automations/automations-v2/configure-your-automation#filters).
834
+ * @maxSize 5
835
+ */
836
+ filters?: Filter[];
837
+ /**
838
+ * Automation offset. You can schedule automations to run before the trigger occurs.
839
+ *
840
+ * Learn more about [scheduled events](https://dev.wix.com/docs/rest/business-management/automations/automations/automations-v2/configure-your-automation#scheduled-events).
841
+ */
842
+ scheduledEventOffset?: FutureDateActivationOffset;
843
+ /** Limit on the number of times an automation can be triggered. */
844
+ rateLimit?: RateLimit;
845
+ /** Trigger schema override. When specified, this replaces the trigger schema. */
846
+ overrideSchema?: Record<string, any> | null;
847
+ }
848
+ interface Action extends ActionInfoOneOf {
849
+ /** Details of the action when its `type` is `APP_DEFINED`. */
850
+ appDefinedInfo?: AppDefinedAction;
851
+ /** Details of the action when its `type` is `CONDITION`. */
852
+ conditionInfo?: ConditionAction;
853
+ /** Details of the action when its `type` is `CODE_CONDITION`. */
854
+ codeConditionInfo?: CodeConditionAction;
855
+ /** Details of the action when its `type` is `DELAY`. */
856
+ delayInfo?: DelayAction;
857
+ /** Details of the action when its `type` is `RATE_LIMIT`. */
858
+ rateLimitInfo?: RateLimitAction;
859
+ /**
860
+ * Action ID.
861
+ *
862
+ * If not specified, automatically generated by Wix.
863
+ * @format GUID
864
+ */
865
+ id?: string | null;
866
+ /** [Action type](https://dev.wix.com/docs/rest/business-management/automations/automations/automations-v2/configure-your-automation#action-type). */
867
+ type?: TypeWithLiterals;
868
+ /**
869
+ * [Action namespace](https://dev.wix.com/docs/rest/business-management/automations/automations/automations-v2/configure-your-automation#namespace). This differentiates it from other actions of the same type.
870
+ *
871
+ * If the action outputs any data, the data appears under the namespace in the payload sent to the subsequent steps in the automation. If the user has multiple actions with the same `appId` and `actionKey`, the output of the previous action is overwritten.
872
+ * @minLength 1
873
+ * @maxLength 100
874
+ */
875
+ namespace?: string | null;
876
+ /**
877
+ * skip_action_expression: evaluates to a boolean to decide if the action should be skipped
878
+ * For ConditionAction: if skipped, true_post_action_ids execute; false_post_action_ids are skipped
879
+ * SplitAction and OutputAction do not support skip_action_expression
880
+ * @maxLength 1000
881
+ */
882
+ skipActionExpression?: string | null;
883
+ }
884
+ /** @oneof */
885
+ interface ActionInfoOneOf {
886
+ /** Details of the action when its `type` is `APP_DEFINED`. */
887
+ appDefinedInfo?: AppDefinedAction;
888
+ /** Details of the action when its `type` is `CONDITION`. */
889
+ conditionInfo?: ConditionAction;
890
+ /** Details of the action when its `type` is `CODE_CONDITION`. */
891
+ codeConditionInfo?: CodeConditionAction;
892
+ /** Details of the action when its `type` is `DELAY`. */
893
+ delayInfo?: DelayAction;
894
+ /** Details of the action when its `type` is `RATE_LIMIT`. */
895
+ rateLimitInfo?: RateLimitAction;
896
+ }
897
+ interface FilterableAppDefinedActions {
898
+ /**
899
+ * App-defined action identifiers. Identifiers have the following format: `${appId}_${actionKey}`.
900
+ * @minSize 1
901
+ * @maxSize 100
902
+ * @minLength 1
903
+ * @maxLength 150
904
+ */
905
+ actionIdentifiers?: string[];
906
+ }
907
+ declare enum Origin {
908
+ /** Default value. */
909
+ UNKNOWN_ORIGIN = "UNKNOWN_ORIGIN",
910
+ /** Created by a [Wix user](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#wix-user). */
911
+ USER = "USER",
912
+ /** Created by a [Wix app](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#wix-app) for a particular site. */
913
+ APPLICATION = "APPLICATION",
914
+ /** [Preinstalled automation](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/automations/pre-installed-automations/about-pre-installed-automations). */
915
+ PREINSTALLED = "PREINSTALLED"
916
+ }
917
+ /** @enumType */
918
+ type OriginWithLiterals = Origin | 'UNKNOWN_ORIGIN' | 'USER' | 'APPLICATION' | 'PREINSTALLED';
919
+ interface ApplicationOrigin {
920
+ /**
921
+ * [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
922
+ *
923
+ * You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
924
+ * @format GUID
925
+ */
926
+ appId?: string;
927
+ }
928
+ interface PreinstalledOrigin {
929
+ /**
930
+ * ID of the app that added the [preinstalled automation](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/automations/pre-installed-automations/about-pre-installed-automations).
931
+ * @format GUID
932
+ */
933
+ appId?: string;
934
+ /**
935
+ * Whether the automation is an override.
936
+ *
937
+ * When a user modifies the preinstalled automation installed on their site, a site-specific version of the automation is created that overrides the automation that was originally installed. This override automation has the same automation ID as the original preinstalled automation.
938
+ *
939
+ * > **Note**: An override automation can no longer be updated by the app that originally installed it.
940
+ * >
941
+ * > To revert to the original preinstalled version, the user must delete the override by calling the Delete Automation method. Calling Delete Automation on an override automation removes the override method and restores the preinstalled automation that was previously installed.
942
+ *
943
+ * Default: `false`.
944
+ * @immutable
945
+ * @readonly
946
+ */
947
+ override?: boolean | null;
948
+ }
949
+ interface AutomationSettings {
950
+ /**
951
+ * Whether the automation is hidden from users.
952
+ *
953
+ * Default: `false`
954
+ */
955
+ hidden?: boolean;
956
+ /**
957
+ * Whether the automation is read-only.
958
+ *
959
+ * Default: `false`
960
+ */
961
+ readonly?: boolean;
962
+ /**
963
+ * Whether to disable the option to delete the automation from the site.
964
+ *
965
+ * Default: `false`.
966
+ */
967
+ disableDelete?: boolean;
968
+ /**
969
+ * Whether to disable the option to change the automation's `configuration.status`, for example from `ACTIVE` to `INACTIVE`.
970
+ *
971
+ * Default: `false`.
972
+ */
973
+ disableStatusChange?: boolean;
974
+ /** Automation action settings. */
975
+ actionSettings?: ActionSettings;
976
+ }
977
+ interface DraftInfo {
978
+ /**
979
+ * ID of the original automation.
980
+ * @format GUID
981
+ * @readonly
982
+ */
983
+ originalAutomationId?: string | null;
984
+ }
985
+ interface Enrichments {
986
+ /** Whether the studio site enrichment is wanted. */
987
+ studioSite?: Enrichment;
988
+ }
989
+ interface ExtendedFields {
990
+ /**
991
+ * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.
992
+ * The value of each key is structured according to the schema defined when the extended fields were configured.
993
+ *
994
+ * You can only access fields for which you have the appropriate permissions.
995
+ *
996
+ * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).
997
+ */
998
+ namespaces?: Record<string, Record<string, any>>;
999
+ }
1000
+ interface AutoArchivePolicy {
1001
+ /**
1002
+ * Date when to archive the automation
1003
+ * If this date in the past, nothing will happen (automation will not go into archived state)
1004
+ * If this date in the future, on this date the automation will be updated with archived = true and configuration.status = INACTIVE
1005
+ * After this date the automation may be unarchived and archived again, this date will have no influence
1006
+ */
1007
+ archiveDate?: Date | null;
1008
+ }
1009
+ interface Notes {
1010
+ }
1011
+ interface Note {
1012
+ }
1013
+ interface Position {
1014
+ }
1015
+ interface Offset {
1016
+ }
1017
+ interface Dimensions {
1018
+ }
1019
+ interface UouDeleteRequest {
1020
+ /** Original UouRightToBeDeletedRequest request */
1021
+ originalRequest?: Record<string, any> | null;
1022
+ /**
1023
+ * Found client ids
1024
+ * @maxSize 100
1025
+ */
1026
+ foundClientEntityIdsByNamespace?: ClientEntityIdsByNamespace[];
1027
+ }
1028
+ interface ClientEntityIdsByNamespace {
1029
+ /**
1030
+ * Client namespace
1031
+ * @minLength 5
1032
+ * @maxLength 50
1033
+ */
1034
+ namespace?: string;
1035
+ /**
1036
+ * Client entity IDs
1037
+ * @minLength 5
1038
+ * @maxLength 50
1039
+ * @maxSize 100
1040
+ */
1041
+ clientEntityIds?: string[];
1042
+ }
248
1043
  interface GetActivationLogRequest {
249
1044
  /**
250
1045
  * Activation log ID
@@ -386,6 +1181,78 @@ interface SearchActivationLogsByPayloadPiiValueResponse {
386
1181
  /** Paging metadata */
387
1182
  pagingMetadata?: CursorPagingMetadata;
388
1183
  }
1184
+ interface MessageEnvelope {
1185
+ /**
1186
+ * App instance ID.
1187
+ * @format GUID
1188
+ */
1189
+ instanceId?: string | null;
1190
+ /**
1191
+ * Event type.
1192
+ * @maxLength 150
1193
+ */
1194
+ eventType?: string;
1195
+ /** The identification type and identity data. */
1196
+ identity?: IdentificationData;
1197
+ /** Stringify payload. */
1198
+ data?: string;
1199
+ }
1200
+ interface IdentificationData extends IdentificationDataIdOneOf {
1201
+ /**
1202
+ * ID of a site visitor that has not logged in to the site.
1203
+ * @format GUID
1204
+ */
1205
+ anonymousVisitorId?: string;
1206
+ /**
1207
+ * ID of a site visitor that has logged in to the site.
1208
+ * @format GUID
1209
+ */
1210
+ memberId?: string;
1211
+ /**
1212
+ * ID of a Wix user (site owner, contributor, etc.).
1213
+ * @format GUID
1214
+ */
1215
+ wixUserId?: string;
1216
+ /**
1217
+ * ID of an app.
1218
+ * @format GUID
1219
+ */
1220
+ appId?: string;
1221
+ /** @readonly */
1222
+ identityType?: WebhookIdentityTypeWithLiterals;
1223
+ }
1224
+ /** @oneof */
1225
+ interface IdentificationDataIdOneOf {
1226
+ /**
1227
+ * ID of a site visitor that has not logged in to the site.
1228
+ * @format GUID
1229
+ */
1230
+ anonymousVisitorId?: string;
1231
+ /**
1232
+ * ID of a site visitor that has logged in to the site.
1233
+ * @format GUID
1234
+ */
1235
+ memberId?: string;
1236
+ /**
1237
+ * ID of a Wix user (site owner, contributor, etc.).
1238
+ * @format GUID
1239
+ */
1240
+ wixUserId?: string;
1241
+ /**
1242
+ * ID of an app.
1243
+ * @format GUID
1244
+ */
1245
+ appId?: string;
1246
+ }
1247
+ declare enum WebhookIdentityType {
1248
+ UNKNOWN = "UNKNOWN",
1249
+ ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
1250
+ MEMBER = "MEMBER",
1251
+ WIX_USER = "WIX_USER",
1252
+ APP = "APP"
1253
+ }
1254
+ /** @enumType */
1255
+ type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
389
1256
 
390
1257
  type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
391
1258
  getUrl: (context: any) => string;
@@ -403,4 +1270,4 @@ declare function getActivationLog(): __PublicMethodMetaInfo<'GET', {
403
1270
  declare function listActivationLogs(): __PublicMethodMetaInfo<'GET', {}, ListActivationLogsRequest$1, ListActivationLogsRequest, ListActivationLogsResponse$1, ListActivationLogsResponse>;
404
1271
  declare function searchActivationLogsByPayloadPiiValue(): __PublicMethodMetaInfo<'POST', {}, SearchActivationLogsByPayloadPiiValueRequest$1, SearchActivationLogsByPayloadPiiValueRequest, SearchActivationLogsByPayloadPiiValueResponse$1, SearchActivationLogsByPayloadPiiValueResponse>;
405
1272
 
406
- export { type __PublicMethodMetaInfo, getActivationLog, listActivationLogs, searchActivationLogsByPayloadPiiValue };
1273
+ export { type ActionEvent as ActionEventOriginal, type ActionInfoOneOf as ActionInfoOneOfOriginal, type Action as ActionOriginal, type ActionSettings as ActionSettingsOriginal, type ActivationContinuedAfterSchedule as ActivationContinuedAfterScheduleOriginal, type ActivationLog as ActivationLogOriginal, type AppDefinedAction as AppDefinedActionOriginal, type ApplicationOrigin as ApplicationOriginOriginal, type AuditInfoIdOneOf as AuditInfoIdOneOfOriginal, type AuditInfo as AuditInfoOriginal, type AutoArchivePolicy as AutoArchivePolicyOriginal, type AutomationConfiguration as AutomationConfigurationOriginal, AutomationConfigurationStatus as AutomationConfigurationStatusOriginal, type AutomationConfigurationStatusWithLiterals as AutomationConfigurationStatusWithLiteralsOriginal, type AutomationIdInfo as AutomationIdInfoOriginal, type AutomationOriginInfoOneOf as AutomationOriginInfoOneOfOriginal, type Automation as AutomationOriginal, type AutomationSettings as AutomationSettingsOriginal, CancellationReason as CancellationReasonOriginal, type CancellationReasonWithLiterals as CancellationReasonWithLiteralsOriginal, type CancelledStatusInfo as CancelledStatusInfoOriginal, type ClientEntityIdsByNamespace as ClientEntityIdsByNamespaceOriginal, type CodeConditionAction as CodeConditionActionOriginal, type CodeSnippet as CodeSnippetOriginal, type ConditionAction as ConditionActionOriginal, type ConditionExpressionGroup as ConditionExpressionGroupOriginal, type CursorPagingMetadata as CursorPagingMetadataOriginal, type CursorPaging as CursorPagingOriginal, type Cursors as CursorsOriginal, type DelayAction as DelayActionOriginal, type Dimensions as DimensionsOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, Domain as DomainOriginal, type DomainWithLiterals as DomainWithLiteralsOriginal, type DraftInfo as DraftInfoOriginal, type Empty as EmptyOriginal, type EndedStatusInfo as EndedStatusInfoOriginal, type Enrichment as EnrichmentOriginal, type Enrichments as EnrichmentsOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, ErrorReason as ErrorReasonOriginal, type ErrorReasonWithLiterals as ErrorReasonWithLiteralsOriginal, type ExtendedFields as ExtendedFieldsOriginal, type FailedStatusInfo as FailedStatusInfoOriginal, FilterBy as FilterByOriginal, type FilterByWithLiterals as FilterByWithLiteralsOriginal, type Filter as FilterOriginal, type FilterValueSelection as FilterValueSelectionOriginal, type FilterableAppDefinedActions as FilterableAppDefinedActionsOriginal, type FutureDateActivationOffset as FutureDateActivationOffsetOriginal, type GetActivationLogRequest as GetActivationLogRequestOriginal, type GetActivationLogResponse as GetActivationLogResponseOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, IdentifierType as IdentifierTypeOriginal, type IdentifierTypeWithLiterals as IdentifierTypeWithLiteralsOriginal, type Identity as IdentityOriginal, type InitiatedStatusInfo as InitiatedStatusInfoOriginal, Language as LanguageOriginal, type LanguageWithLiterals as LanguageWithLiteralsOriginal, type ListActivationLogsRequestIdentifierOneOf as ListActivationLogsRequestIdentifierOneOfOriginal, type ListActivationLogsRequest as ListActivationLogsRequestOriginal, type ListActivationLogsResponse as ListActivationLogsResponseOriginal, type MessageEnvelope as MessageEnvelopeOriginal, type Note as NoteOriginal, type Notes as NotesOriginal, type Offset as OffsetOriginal, Operator as OperatorOriginal, type OperatorWithLiterals as OperatorWithLiteralsOriginal, Origin as OriginOriginal, type OriginWithLiterals as OriginWithLiteralsOriginal, type OutputAction as OutputActionOriginal, type Path as PathOriginal, type Position as PositionOriginal, type PreinstalledIdentifierInfo as PreinstalledIdentifierInfoOriginal, type PreinstalledOrigin as PreinstalledOriginOriginal, type RateLimitAction as RateLimitActionOriginal, type RateLimit as RateLimitOriginal, type RestoreInfo as RestoreInfoOriginal, type ScheduledStatusInfo as ScheduledStatusInfoOriginal, type SearchActivationLogsByPayloadPiiValueRequestFilterOptionOneOf as SearchActivationLogsByPayloadPiiValueRequestFilterOptionOneOfOriginal, type SearchActivationLogsByPayloadPiiValueRequest as SearchActivationLogsByPayloadPiiValueRequestOriginal, type SearchActivationLogsByPayloadPiiValueResponse as SearchActivationLogsByPayloadPiiValueResponseOriginal, type SetVariablesAction as SetVariablesActionOriginal, SkipReason as SkipReasonOriginal, type SkipReasonWithLiterals as SkipReasonWithLiteralsOriginal, type SkippedStatusInfo as SkippedStatusInfoOriginal, type SplitAction as SplitActionOriginal, type StartedStatusInfo as StartedStatusInfoOriginal, Status as StatusOriginal, type StatusWithLiterals as StatusWithLiteralsOriginal, Target as TargetOriginal, type TargetWithLiterals as TargetWithLiteralsOriginal, TimeUnit as TimeUnitOriginal, type TimeUnitWithLiterals as TimeUnitWithLiteralsOriginal, type Trigger as TriggerOriginal, Type as TypeOriginal, type TypeWithLiterals as TypeWithLiteralsOriginal, type UouDeleteRequest as UouDeleteRequestOriginal, type Warning as WarningOriginal, WarningReason as WarningReasonOriginal, type WarningReasonWithLiterals as WarningReasonWithLiteralsOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, getActivationLog, listActivationLogs, searchActivationLogsByPayloadPiiValue };