@wix/auto_sdk_automations_automations-v-2 1.0.84 → 1.0.85

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.
@@ -89,17 +89,19 @@ interface AIMetadata {
89
89
  }
90
90
  interface ActionSettings {
91
91
  /**
92
- * Permanent actions. PermanentAction's skipActionExpression cannot be modified.
92
+ * IDs of actions whose `skipActionExpression` can't be modified.
93
93
  *
94
- * When empty, all actions can be set as skipped
94
+ * An action's `skipActionExpression` determines whether the action is skipped. Including an action's ID in this array makes its `skipActionExpression` permanent, so it can't be changed.
95
+ *
96
+ * When empty, the `skipActionExpression` of all actions can be edited.
95
97
  * @maxSize 30
96
98
  * @format GUID
97
99
  */
98
100
  permanentActionIds?: string[];
99
101
  /**
100
- * Read-only actions. Read-only actions cannot be edited.
102
+ * IDs of read-only actions. Read-only actions cannot be modified.
101
103
  *
102
- * When empty, all actions are editable.
104
+ * When empty and the automation's `settings.readonly` is `false`, all actions are modifiable.
103
105
  * @maxSize 30
104
106
  * @format GUID
105
107
  */
@@ -309,15 +311,29 @@ declare enum Type {
309
311
  UNKNOWN_ACTION_TYPE = "UNKNOWN_ACTION_TYPE",
310
312
  /** 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. */
311
313
  APP_DEFINED = "APP_DEFINED",
312
- /** Condition. This determines which action runs next. */
314
+ /**
315
+ * Condition action. Evaluates a condition to determine which action runs next.
316
+ *
317
+ * Learn more about [adding and setting up conditions](https://support.wix.com/en/article/the-new-automation-builder-understanding-conditions-operators) in Wix Automations.
318
+ *
319
+ * > **Note**: When `skipActionExpression` evaluates to `true`, the actions in `conditionInfo.truePostActionIds` run and those in `conditionInfo.falsePostActionIds` are skipped.
320
+ */
313
321
  CONDITION = "CONDITION",
322
+ /**
323
+ * Code condition action. Evaluates custom code to determine which action runs next.
324
+ *
325
+ * Learn more about [adding and setting up conditions](https://support.wix.com/en/article/the-new-automation-builder-understanding-conditions-operators) in Wix Automations.
326
+ *
327
+ * > **Note**: When `skipActionExpression` evaluates to `true`, the actions in `codeConditionInfo.truePostActionIds` run and those in `codeConditionInfo.falsePostActionIds` are skipped.
328
+ */
329
+ CODE_CONDITION = "CODE_CONDITION",
314
330
  /** Delay. The automation must wait before executing the next step. */
315
331
  DELAY = "DELAY",
316
332
  /** Rate-limiter. This stops the automation flow if the subsequent action has reached its maximum allowed executions. */
317
333
  RATE_LIMIT = "RATE_LIMIT"
318
334
  }
319
335
  /** @enumType */
320
- type TypeWithLiterals = Type | 'UNKNOWN_ACTION_TYPE' | 'APP_DEFINED' | 'CONDITION' | 'DELAY' | 'RATE_LIMIT';
336
+ type TypeWithLiterals = Type | 'UNKNOWN_ACTION_TYPE' | 'APP_DEFINED' | 'CONDITION' | 'CODE_CONDITION' | 'DELAY' | 'RATE_LIMIT';
321
337
  interface AppDefinedAction {
322
338
  /**
323
339
  * ID of the app that defines the action.
@@ -535,15 +551,15 @@ interface Trigger {
535
551
  overrideSchema?: Record<string, any> | null;
536
552
  }
537
553
  interface Action extends ActionInfoOneOf {
538
- /** Details of the action when its `type` is `APP_DEFINED`. */
554
+ /** Details of the action whose `type` is `APP_DEFINED`. */
539
555
  appDefinedInfo?: AppDefinedAction;
540
- /** Details of the action when its `type` is `CONDITION`. */
556
+ /** Details of the action whose `type` is `CONDITION`. */
541
557
  conditionInfo?: ConditionAction;
542
- /** Details of the action when its `type` is `CODE_CONDITION`. */
558
+ /** Details of the action whose `type` is `CODE_CONDITION`. */
543
559
  codeConditionInfo?: CodeConditionAction;
544
- /** Details of the action when its `type` is `DELAY`. */
560
+ /** Details of the action whose `type` is `DELAY`. */
545
561
  delayInfo?: DelayAction;
546
- /** Details of the action when its `type` is `RATE_LIMIT`. */
562
+ /** Details of the action whose `type` is `RATE_LIMIT`. */
547
563
  rateLimitInfo?: RateLimitAction;
548
564
  /**
549
565
  * Action ID.
@@ -571,24 +587,24 @@ interface Action extends ActionInfoOneOf {
571
587
  */
572
588
  namespace?: string | null;
573
589
  /**
574
- * Evaluated to boolean to decide whether the action is skipped.
575
- * For ConditionAction: if skipped, true_post_action_ids execute; false_post_action_ids are skipped
576
- * SplitAction and OutputAction do not support skip_action_expression
590
+ * Evaluated to determine whether the action is skipped. When evaluated to `true`, the action is skipped. Otherwise, the action runs.
591
+ *
592
+ * When empty, the action runs.
577
593
  * @maxLength 1000
578
594
  */
579
595
  skipActionExpression?: string | null;
580
596
  }
581
597
  /** @oneof */
582
598
  interface ActionInfoOneOf {
583
- /** Details of the action when its `type` is `APP_DEFINED`. */
599
+ /** Details of the action whose `type` is `APP_DEFINED`. */
584
600
  appDefinedInfo?: AppDefinedAction;
585
- /** Details of the action when its `type` is `CONDITION`. */
601
+ /** Details of the action whose `type` is `CONDITION`. */
586
602
  conditionInfo?: ConditionAction;
587
- /** Details of the action when its `type` is `CODE_CONDITION`. */
603
+ /** Details of the action whose `type` is `CODE_CONDITION`. */
588
604
  codeConditionInfo?: CodeConditionAction;
589
- /** Details of the action when its `type` is `DELAY`. */
605
+ /** Details of the action whose `type` is `DELAY`. */
590
606
  delayInfo?: DelayAction;
591
- /** Details of the action when its `type` is `RATE_LIMIT`. */
607
+ /** Details of the action whose `type` is `RATE_LIMIT`. */
592
608
  rateLimitInfo?: RateLimitAction;
593
609
  }
594
610
  interface FilterableAppDefinedActions {
@@ -652,11 +668,12 @@ interface AutomationSettings {
652
668
  hidden?: boolean;
653
669
  /**
654
670
  * Whether the automation is read-only.
655
- * If true - modifications to the automation trigger or action/s are disabled.
656
- * **Note**: this setting takes precedent over triggerSettings/actionSettings.
657
- * If false - allows selective read-only settings via those fields.
658
671
  *
659
- * Default: `false`
672
+ * When `true`, site owners can't modify the automation or any of its actions. When `false`, users can configure specific actions as skippable or read-only using `settings.actionSettings`.
673
+ *
674
+ * Default: `false`.
675
+ *
676
+ * > **Note**: Setting `readOnly` to `true` overrides `settings.actionSettings`.
660
677
  */
661
678
  readonly?: boolean;
662
679
  /**
@@ -666,7 +683,7 @@ interface AutomationSettings {
666
683
  */
667
684
  disableDelete?: boolean;
668
685
  /**
669
- * Whether to disable the option to change the automation's `configuration.status`, for example from `ACTIVE` to `INACTIVE`.
686
+ * Whether to disable the option to change the automation's `configuration.status`.
670
687
  *
671
688
  * Default: `false`.
672
689
  */
@@ -785,6 +785,7 @@ var Type = /* @__PURE__ */ ((Type2) => {
785
785
  Type2["UNKNOWN_ACTION_TYPE"] = "UNKNOWN_ACTION_TYPE";
786
786
  Type2["APP_DEFINED"] = "APP_DEFINED";
787
787
  Type2["CONDITION"] = "CONDITION";
788
+ Type2["CODE_CONDITION"] = "CODE_CONDITION";
788
789
  Type2["DELAY"] = "DELAY";
789
790
  Type2["RATE_LIMIT"] = "RATE_LIMIT";
790
791
  return Type2;