@wix/auto_sdk_automations_automations-v-2 1.0.54 → 1.0.56

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.
Files changed (37) hide show
  1. package/build/cjs/index.d.ts +10 -15
  2. package/build/cjs/index.js +56 -7
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +19 -6
  5. package/build/cjs/index.typings.js +35 -5
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +9 -4
  8. package/build/cjs/meta.js +0 -1
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/es/index.d.mts +10 -15
  11. package/build/es/index.mjs +56 -7
  12. package/build/es/index.mjs.map +1 -1
  13. package/build/es/index.typings.d.mts +19 -6
  14. package/build/es/index.typings.mjs +34 -5
  15. package/build/es/index.typings.mjs.map +1 -1
  16. package/build/es/meta.d.mts +9 -4
  17. package/build/es/meta.mjs +0 -1
  18. package/build/es/meta.mjs.map +1 -1
  19. package/build/internal/cjs/index.d.ts +10 -15
  20. package/build/internal/cjs/index.js +56 -7
  21. package/build/internal/cjs/index.js.map +1 -1
  22. package/build/internal/cjs/index.typings.d.ts +19 -6
  23. package/build/internal/cjs/index.typings.js +35 -5
  24. package/build/internal/cjs/index.typings.js.map +1 -1
  25. package/build/internal/cjs/meta.d.ts +9 -4
  26. package/build/internal/cjs/meta.js +0 -1
  27. package/build/internal/cjs/meta.js.map +1 -1
  28. package/build/internal/es/index.d.mts +10 -15
  29. package/build/internal/es/index.mjs +56 -7
  30. package/build/internal/es/index.mjs.map +1 -1
  31. package/build/internal/es/index.typings.d.mts +19 -6
  32. package/build/internal/es/index.typings.mjs +34 -5
  33. package/build/internal/es/index.typings.mjs.map +1 -1
  34. package/build/internal/es/meta.d.mts +9 -4
  35. package/build/internal/es/meta.mjs +0 -1
  36. package/build/internal/es/meta.mjs.map +1 -1
  37. package/package.json +3 -3
@@ -1,6 +1,6 @@
1
1
  import { HttpClient, NonNullablePaths, EventDefinition, MaybeContext, BuildRESTFunction, BuildEventDefinition } from '@wix/sdk-types';
2
- import { Automation, UpdateAutomation, BulkDeleteAutomationsResponse, GeneratePreinstalledAutomationOptions, GeneratePreinstalledAutomationResponse, AutomationsQueryBuilder, GetAggregatedUsageInfoOptions, GetAggregatedUsageInfoResponse, CopyAutomationOptions, CopyAutomationResponse, CreateDraftAutomationOptions, CreateDraftAutomationResponse, GetOrCreateDraftAutomationResponse, UpdateDraftAutomation, UpdateDraftAutomationResponse, QueryAutomationsWithDraftsOptions, QueryAutomationsWithDraftsResponse, BulkCountAutomationsWithDraftsOptions, BulkCountAutomationsWithDraftsResponse, PublishDraftAutomationResponse, ValidateAutomationOptions, ValidateAutomationResponse, ValidateAutomationByIdOptions, ValidateAutomationByIdResponse, GetAutomationRevisionOptions, GetAutomationRevisionResponse, AutomationCreatedEnvelope, AutomationDeletedEnvelope, AutomationUpdatedEnvelope } from './index.typings.js';
3
- export { AIMetadata, Action, ActionConfigurationError, ActionErrorType, ActionErrorTypeWithLiterals, ActionEvent, ActionInfoOneOf, ActionProviderQuotaInfo, ActionQuotaInfo, ActionSettings, ActionUsageSummary, ActionValidationError, ActionValidationErrorErrorOneOf, ActionValidationInfo, AdditionalInfo, AppDefinedAction, ApplicationError, ApplicationOrigin, Asset, AuditInfo, AuditInfoIdOneOf, AutoArchivePolicy, AutomationConfiguration, AutomationConfigurationError, AutomationErrorType, AutomationErrorTypeWithLiterals, AutomationOriginInfoOneOf, AutomationSettings, AutomationValidationError, AutomationValidationErrorErrorOneOf, AutomationValidationErrorValidationErrorType, AutomationValidationErrorValidationErrorTypeWithLiterals, AutomationsQueryResult, BaseEventMetadata, BulkActionMetadata, BulkCountAutomationsWithDraftsRequest, BulkDeleteAutomationsRequest, BulkDeleteResult, CTA, CodeConditionAction, CodeSnippet, ConditionAction, ConditionExpressionGroup, CopyAutomationRequest, CreateAutomationRequest, CreateAutomationResponse, CreateDraftAutomationRequest, CreatePreinstalledAutomationRequest, CreatePreinstalledAutomationResponse, CreatedByAppIdUsageSummary, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, DelayAction, DeleteAutomationRequest, DeleteAutomationResponse, DeleteContext, DeleteDraftAutomationRequest, DeleteDraftAutomationResponse, DeletePreinstalledAutomationRequest, DeletePreinstalledAutomationResponse, DeleteStatus, DeleteStatusWithLiterals, DeletedWithEntity, Dimensions, Domain, DomainEvent, DomainEventBodyOneOf, DomainWithLiterals, DraftInfo, DraftPublished, DraftsInfo, Empty, Enrichment, Enrichments, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, EventMetadata, ExtendedFields, Filter, FilterValueSelection, FilterableAppDefinedActions, FutureDateActivationOffset, GeneratePreinstalledAutomationRequest, GetActionsQuotaInfoRequest, GetActionsQuotaInfoResponse, GetAggregatedUsageInfoRequest, GetAutomationActionSchemaRequest, GetAutomationActionSchemaResponse, GetAutomationRequest, GetAutomationResponse, GetAutomationRevisionRequest, GetOrCreateDraftAutomationRequest, IdentificationData, IdentificationDataIdOneOf, ItemMetadata, Language, LanguageWithLiterals, MergeOverridePreinstalledWithRuntimeVersionRequest, MergeOverridePreinstalledWithRuntimeVersionResponse, MessageEnvelope, MetaSiteSpecialEvent, MetaSiteSpecialEventPayloadOneOf, MigrateVeloActionAutomationsRequest, MigrateVeloActionAutomationsResponse, Namespace, NamespaceChanged, NamespaceWithLiterals, Note, Notes, OdeditorAssigned, OdeditorUnassigned, Offset, Operator, OperatorWithLiterals, Origin, OriginAutomationInfo, OriginWithLiterals, OutputAction, Path, PicassoAssigned, PicassoUnassigned, Plan, Position, PreinstalledAutomationSpecInfo, PreinstalledOrigin, ProviderConfigurationError, PublishDraftAutomationRequest, QueryAutomationsRequest, QueryAutomationsResponse, QueryAutomationsWithDraftsRequest, QueryPreinstalledAutomationsForAppRequest, QueryPreinstalledAutomationsForAppResponse, QueryPreinstalledAutomationsRequest, QueryPreinstalledAutomationsResponse, Quota, QuotaInfo, RateLimit, RateLimitAction, RequestedFields, RequestedFieldsWithLiterals, RestoreInfo, ServiceProvisioned, ServiceRemoved, SetVariablesAction, Severity, SeverityWithLiterals, SiteCreated, SiteCreatedContext, SiteCreatedContextWithLiterals, SiteDeleted, SiteHardDeleted, SiteMarkedAsTemplate, SiteMarkedAsWixSite, SitePublished, SitePurgedExternally, SiteRenamed, SiteTransferred, SiteUndeleted, SiteUnpublished, SiteUrlChanged, SortOrder, SortOrderWithLiterals, Sorting, SplitAction, State, StateWithLiterals, Status, StatusWithLiterals, StudioAssigned, StudioTwoAssigned, StudioTwoUnassigned, StudioUnassigned, TimeUnit, TimeUnitWithLiterals, Trigger, TriggerConfigurationError, TriggerErrorType, TriggerErrorTypeWithLiterals, TriggerSettings, TriggerUsageSummary, TriggerValidationError, TriggerValidationErrorErrorOneOf, TriggerValidationErrorValidationErrorType, TriggerValidationErrorValidationErrorTypeWithLiterals, Type, TypeWithLiterals, UpdateAutomationRequest, UpdateAutomationResponse, UpdateDraftAutomationRequest, UpdatePreinstalledAutomationRequest, UpdatePreinstalledAutomationResponse, UpdatedWithPreviousEntity, UpgradeCTA, ValidateAutomationByIdRequest, ValidateAutomationRequest, ValidationErrorSeverity, ValidationErrorSeverityWithLiterals, ValidationErrorType, ValidationErrorTypeWithLiterals, ValidationResultStatus, ValidationResultStatusWithLiterals, ValidationSettings, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WixelAssigned, WixelUnassigned } from './index.typings.js';
2
+ import { Automation, UpdateAutomation, BulkDeleteAutomationsResponse, GeneratePreinstalledAutomationOptions, GeneratePreinstalledAutomationResponse, GetAggregatedUsageInfoOptions, GetAggregatedUsageInfoResponse, CopyAutomationOptions, CopyAutomationResponse, CreateDraftAutomationOptions, CreateDraftAutomationResponse, GetOrCreateDraftAutomationResponse, UpdateDraftAutomation, UpdateDraftAutomationResponse, QueryAutomationsWithDraftsOptions, QueryAutomationsWithDraftsResponse, BulkCountAutomationsWithDraftsOptions, BulkCountAutomationsWithDraftsResponse, PublishDraftAutomationResponse, ValidateAutomationOptions, ValidateAutomationResponse, ValidateAutomationByIdOptions, ValidateAutomationByIdResponse, GetAutomationRevisionOptions, GetAutomationRevisionResponse, AutomationCreatedEnvelope, AutomationDeletedEnvelope, AutomationUpdatedEnvelope, CursorQuery, typedQueryAutomations, QueryAutomationsOptions, AutomationsQueryBuilder } from './index.typings.js';
3
+ export { AIMetadata, Action, ActionConfigurationError, ActionErrorType, ActionErrorTypeWithLiterals, ActionEvent, ActionInfoOneOf, ActionProviderQuotaInfo, ActionQuotaInfo, ActionSettings, ActionUsageSummary, ActionValidationError, ActionValidationErrorErrorOneOf, ActionValidationInfo, AdditionalInfo, AppDefinedAction, ApplicationError, ApplicationOrigin, Asset, AuditInfo, AuditInfoIdOneOf, AutoArchivePolicy, AutomationConfiguration, AutomationConfigurationError, AutomationErrorType, AutomationErrorTypeWithLiterals, AutomationOriginInfoOneOf, AutomationSettings, AutomationValidationError, AutomationValidationErrorErrorOneOf, AutomationValidationErrorValidationErrorType, AutomationValidationErrorValidationErrorTypeWithLiterals, AutomationsQueryResult, BaseEventMetadata, BulkActionMetadata, BulkCountAutomationsWithDraftsRequest, BulkDeleteAutomationsRequest, BulkDeleteResult, CTA, CodeConditionAction, CodeSnippet, ConditionAction, ConditionExpressionGroup, CopyAutomationRequest, CreateAutomationRequest, CreateAutomationResponse, CreateDraftAutomationRequest, CreatePreinstalledAutomationRequest, CreatePreinstalledAutomationResponse, CreatedByAppIdUsageSummary, CursorPaging, CursorPagingMetadata, CursorQueryPagingMethodOneOf, Cursors, DelayAction, DeleteAutomationRequest, DeleteAutomationResponse, DeleteContext, DeleteDraftAutomationRequest, DeleteDraftAutomationResponse, DeletePreinstalledAutomationRequest, DeletePreinstalledAutomationResponse, DeleteStatus, DeleteStatusWithLiterals, DeletedWithEntity, Dimensions, Domain, DomainEvent, DomainEventBodyOneOf, DomainWithLiterals, DraftInfo, DraftPublished, DraftsInfo, Empty, Enrichment, Enrichments, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, EventMetadata, ExtendedFields, Filter, FilterValueSelection, FilterableAppDefinedActions, FutureDateActivationOffset, GeneratePreinstalledAutomationRequest, GetActionsQuotaInfoRequest, GetActionsQuotaInfoResponse, GetAggregatedUsageInfoRequest, GetAutomationActionSchemaRequest, GetAutomationActionSchemaResponse, GetAutomationRequest, GetAutomationResponse, GetAutomationRevisionRequest, GetOrCreateDraftAutomationRequest, IdentificationData, IdentificationDataIdOneOf, ItemMetadata, Language, LanguageWithLiterals, MergeOverridePreinstalledWithRuntimeVersionRequest, MergeOverridePreinstalledWithRuntimeVersionResponse, MessageEnvelope, MetaSiteSpecialEvent, MetaSiteSpecialEventPayloadOneOf, MigrateVeloActionAutomationsRequest, MigrateVeloActionAutomationsResponse, Namespace, NamespaceChanged, NamespaceWithLiterals, Note, Notes, OdeditorAssigned, OdeditorUnassigned, Offset, Operator, OperatorWithLiterals, Origin, OriginAutomationInfo, OriginWithLiterals, OutputAction, Path, PicassoAssigned, PicassoUnassigned, Plan, Position, PreinstalledAutomationSpecInfo, PreinstalledOrigin, ProviderConfigurationError, PublishDraftAutomationRequest, QueryAutomationsRequest, QueryAutomationsResponse, QueryAutomationsWithDraftsRequest, QueryPreinstalledAutomationsForAppRequest, QueryPreinstalledAutomationsForAppResponse, QueryPreinstalledAutomationsRequest, QueryPreinstalledAutomationsResponse, Quota, QuotaInfo, RateLimit, RateLimitAction, RequestedFields, RequestedFieldsWithLiterals, RestoreInfo, ServiceProvisioned, ServiceRemoved, SetVariablesAction, Severity, SeverityWithLiterals, SiteCreated, SiteCreatedContext, SiteCreatedContextWithLiterals, SiteDeleted, SiteHardDeleted, SiteMarkedAsTemplate, SiteMarkedAsWixSite, SitePublished, SitePurgedExternally, SiteRenamed, SiteTransferred, SiteUndeleted, SiteUnpublished, SiteUrlChanged, SortOrder, SortOrderWithLiterals, Sorting, SplitAction, State, StateWithLiterals, Status, StatusWithLiterals, StudioAssigned, StudioTwoAssigned, StudioTwoUnassigned, StudioUnassigned, TimeUnit, TimeUnitWithLiterals, Trigger, TriggerConfigurationError, TriggerErrorType, TriggerErrorTypeWithLiterals, TriggerSettings, TriggerUsageSummary, TriggerValidationError, TriggerValidationErrorErrorOneOf, TriggerValidationErrorValidationErrorType, TriggerValidationErrorValidationErrorTypeWithLiterals, Type, TypeWithLiterals, UpdateAutomationRequest, UpdateAutomationResponse, UpdateDraftAutomationRequest, UpdatePreinstalledAutomationRequest, UpdatePreinstalledAutomationResponse, UpdatedWithPreviousEntity, UpgradeCTA, ValidateAutomationByIdRequest, ValidateAutomationRequest, ValidationErrorSeverity, ValidationErrorSeverityWithLiterals, ValidationErrorType, ValidationErrorTypeWithLiterals, ValidationResultStatus, ValidationResultStatusWithLiterals, ValidationSettings, WebhookIdentityType, WebhookIdentityTypeWithLiterals, WixelAssigned, WixelUnassigned } from './index.typings.js';
4
4
 
5
5
  declare function createAutomation$1(httpClient: HttpClient): CreateAutomationSignature;
6
6
  interface CreateAutomationSignature {
@@ -59,17 +59,6 @@ interface GeneratePreinstalledAutomationSignature {
59
59
  */
60
60
  (automation: Automation, options?: GeneratePreinstalledAutomationOptions): Promise<NonNullablePaths<GeneratePreinstalledAutomationResponse, `automation.applicationInfo.appId` | `automation.preinstalledInfo.appId` | `automation.createdBy.userId` | `automation.createdBy.appId` | `automation.name` | `automation.configuration.status` | `automation.configuration.trigger.appId` | `automation.configuration.trigger.triggerKey` | `automation.configuration.trigger.filters` | `automation.configuration.trigger.filters.${number}._id` | `automation.configuration.trigger.filters.${number}.fieldKey` | `automation.configuration.trigger.filters.${number}.filterExpression` | `automation.configuration.trigger.scheduledEventOffset.preScheduledEventOffsetExpression` | `automation.configuration.trigger.scheduledEventOffset.scheduledEventOffsetTimeUnit` | `automation.configuration.trigger.rateLimit.maxActivationsExpression` | `automation.configuration.trigger.rateLimit.durationTimeUnit` | `automation.configuration.rootActionIds` | `automation.origin` | `automation.settings.hidden` | `automation.settings.readonly` | `automation.settings.disableDelete` | `automation.settings.disableStatusChange` | `automation.settings.actionSettings.permanentActionIds` | `automation.settings.actionSettings.readonlyActionIds` | `automation.archived`, 7>>;
61
61
  }
62
- declare function queryAutomations$1(httpClient: HttpClient): QueryAutomationsSignature;
63
- interface QueryAutomationsSignature {
64
- /**
65
- * Retrieves a list of automations. This includes both automations overridden on a site and preinstalled automations. If a preinstalled automation has been overridden on the site, the method returns the override automation.
66
- *
67
- * > **Note**: The method only returns automations by apps installed on the site.
68
- *
69
- * Learn more about [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).
70
- */
71
- (): AutomationsQueryBuilder;
72
- }
73
62
  declare function getAggregatedUsageInfo$1(httpClient: HttpClient): GetAggregatedUsageInfoSignature;
74
63
  interface GetAggregatedUsageInfoSignature {
75
64
  /**
@@ -181,13 +170,18 @@ declare const onAutomationCreated$1: EventDefinition<AutomationCreatedEnvelope,
181
170
  declare const onAutomationDeleted$1: EventDefinition<AutomationDeletedEnvelope, "wix.automations.v2.automation_deleted">;
182
171
  declare const onAutomationUpdated$1: EventDefinition<AutomationUpdatedEnvelope, "wix.automations.v2.automation_updated">;
183
172
 
173
+ declare function customQueryAutomations(httpClient: HttpClient): {
174
+ (query: CursorQuery): ReturnType<typeof typedQueryAutomations>;
175
+ (query: CursorQuery, options: QueryAutomationsOptions): ReturnType<typeof typedQueryAutomations>;
176
+ (): AutomationsQueryBuilder;
177
+ (options: QueryAutomationsOptions): AutomationsQueryBuilder;
178
+ };
184
179
  declare const createAutomation: MaybeContext<BuildRESTFunction<typeof createAutomation$1> & typeof createAutomation$1>;
185
180
  declare const getAutomation: MaybeContext<BuildRESTFunction<typeof getAutomation$1> & typeof getAutomation$1>;
186
181
  declare const updateAutomation: MaybeContext<BuildRESTFunction<typeof updateAutomation$1> & typeof updateAutomation$1>;
187
182
  declare const deleteAutomation: MaybeContext<BuildRESTFunction<typeof deleteAutomation$1> & typeof deleteAutomation$1>;
188
183
  declare const bulkDeleteAutomations: MaybeContext<BuildRESTFunction<typeof bulkDeleteAutomations$1> & typeof bulkDeleteAutomations$1>;
189
184
  declare const generatePreinstalledAutomation: MaybeContext<BuildRESTFunction<typeof generatePreinstalledAutomation$1> & typeof generatePreinstalledAutomation$1>;
190
- declare const queryAutomations: MaybeContext<BuildRESTFunction<typeof queryAutomations$1> & typeof queryAutomations$1>;
191
185
  declare const getAggregatedUsageInfo: MaybeContext<BuildRESTFunction<typeof getAggregatedUsageInfo$1> & typeof getAggregatedUsageInfo$1>;
192
186
  declare const copyAutomation: MaybeContext<BuildRESTFunction<typeof copyAutomation$1> & typeof copyAutomation$1>;
193
187
  declare const createDraftAutomation: MaybeContext<BuildRESTFunction<typeof createDraftAutomation$1> & typeof createDraftAutomation$1>;
@@ -200,6 +194,7 @@ declare const publishDraftAutomation: MaybeContext<BuildRESTFunction<typeof publ
200
194
  declare const validateAutomation: MaybeContext<BuildRESTFunction<typeof validateAutomation$1> & typeof validateAutomation$1>;
201
195
  declare const validateAutomationById: MaybeContext<BuildRESTFunction<typeof validateAutomationById$1> & typeof validateAutomationById$1>;
202
196
  declare const getAutomationRevision: MaybeContext<BuildRESTFunction<typeof getAutomationRevision$1> & typeof getAutomationRevision$1>;
197
+ declare const queryAutomations: MaybeContext<BuildRESTFunction<typeof customQueryAutomations> & typeof customQueryAutomations>;
203
198
  /**
204
199
  * Triggered when a new automation is created.
205
200
  */
@@ -213,4 +208,4 @@ declare const onAutomationDeleted: BuildEventDefinition<typeof onAutomationDelet
213
208
  */
214
209
  declare const onAutomationUpdated: BuildEventDefinition<typeof onAutomationUpdated$1> & typeof onAutomationUpdated$1;
215
210
 
216
- export { Automation, AutomationCreatedEnvelope, AutomationDeletedEnvelope, AutomationUpdatedEnvelope, AutomationsQueryBuilder, BulkCountAutomationsWithDraftsOptions, BulkCountAutomationsWithDraftsResponse, BulkDeleteAutomationsResponse, CopyAutomationOptions, CopyAutomationResponse, CreateDraftAutomationOptions, CreateDraftAutomationResponse, GeneratePreinstalledAutomationOptions, GeneratePreinstalledAutomationResponse, GetAggregatedUsageInfoOptions, GetAggregatedUsageInfoResponse, GetAutomationRevisionOptions, GetAutomationRevisionResponse, GetOrCreateDraftAutomationResponse, PublishDraftAutomationResponse, QueryAutomationsWithDraftsOptions, QueryAutomationsWithDraftsResponse, UpdateAutomation, UpdateDraftAutomation, UpdateDraftAutomationResponse, ValidateAutomationByIdOptions, ValidateAutomationByIdResponse, ValidateAutomationOptions, ValidateAutomationResponse, bulkCountAutomationsWithDrafts, bulkDeleteAutomations, copyAutomation, createAutomation, createDraftAutomation, deleteAutomation, deleteDraftAutomation, generatePreinstalledAutomation, getAggregatedUsageInfo, getAutomation, getAutomationRevision, getOrCreateDraftAutomation, onAutomationCreated, onAutomationDeleted, onAutomationUpdated, publishDraftAutomation, queryAutomations, queryAutomationsWithDrafts, updateAutomation, updateDraftAutomation, validateAutomation, validateAutomationById };
211
+ export { Automation, AutomationCreatedEnvelope, AutomationDeletedEnvelope, AutomationUpdatedEnvelope, AutomationsQueryBuilder, BulkCountAutomationsWithDraftsOptions, BulkCountAutomationsWithDraftsResponse, BulkDeleteAutomationsResponse, CopyAutomationOptions, CopyAutomationResponse, CreateDraftAutomationOptions, CreateDraftAutomationResponse, CursorQuery, GeneratePreinstalledAutomationOptions, GeneratePreinstalledAutomationResponse, GetAggregatedUsageInfoOptions, GetAggregatedUsageInfoResponse, GetAutomationRevisionOptions, GetAutomationRevisionResponse, GetOrCreateDraftAutomationResponse, PublishDraftAutomationResponse, QueryAutomationsOptions, QueryAutomationsWithDraftsOptions, QueryAutomationsWithDraftsResponse, UpdateAutomation, UpdateDraftAutomation, UpdateDraftAutomationResponse, ValidateAutomationByIdOptions, ValidateAutomationByIdResponse, ValidateAutomationOptions, ValidateAutomationResponse, bulkCountAutomationsWithDrafts, bulkDeleteAutomations, copyAutomation, createAutomation, createDraftAutomation, deleteAutomation, deleteDraftAutomation, generatePreinstalledAutomation, getAggregatedUsageInfo, getAutomation, getAutomationRevision, getOrCreateDraftAutomation, onAutomationCreated, onAutomationDeleted, onAutomationUpdated, publishDraftAutomation, queryAutomations, queryAutomationsWithDrafts, updateAutomation, updateDraftAutomation, validateAutomation, validateAutomationById };
@@ -960,7 +960,6 @@ var ActionErrorType = /* @__PURE__ */ ((ActionErrorType2) => {
960
960
  ActionErrorType2["MAPPING_MISSING_REQUIRED_FIELD"] = "MAPPING_MISSING_REQUIRED_FIELD";
961
961
  ActionErrorType2["MAPPING_SCHEMA_MISMATCH"] = "MAPPING_SCHEMA_MISMATCH";
962
962
  ActionErrorType2["MAPPING_VARIABLE_MISSING_FROM_SCHEMA"] = "MAPPING_VARIABLE_MISSING_FROM_SCHEMA";
963
- ActionErrorType2["SAMPLE_CODE_RUN_FAILED"] = "SAMPLE_CODE_RUN_FAILED";
964
963
  ActionErrorType2["POST_ACTION_NOT_FOUND"] = "POST_ACTION_NOT_FOUND";
965
964
  return ActionErrorType2;
966
965
  })(ActionErrorType || {});
@@ -1126,11 +1125,14 @@ async function generatePreinstalledAutomation2(automation, options) {
1126
1125
  throw transformedError;
1127
1126
  }
1128
1127
  }
1129
- function queryAutomations2() {
1130
- const { httpClient, sideEffects } = arguments[0];
1128
+ function queryAutomations2(options) {
1129
+ const { httpClient, sideEffects } = arguments[1];
1131
1130
  return (0, import_query_builder.queryBuilder)({
1132
1131
  func: async (payload) => {
1133
- const reqOpts = queryAutomations(payload);
1132
+ const reqOpts = queryAutomations({
1133
+ ...payload,
1134
+ ...options ?? {}
1135
+ });
1134
1136
  sideEffects?.onSiteCall?.();
1135
1137
  try {
1136
1138
  const result = await httpClient.request(reqOpts);
@@ -1142,7 +1144,7 @@ function queryAutomations2() {
1142
1144
  }
1143
1145
  },
1144
1146
  requestTransformer: (query) => {
1145
- const args = [query, {}];
1147
+ const args = [query, options];
1146
1148
  return (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1147
1149
  ...args?.[1],
1148
1150
  query: args?.[0]
@@ -1169,6 +1171,32 @@ function queryAutomations2() {
1169
1171
  transformationPaths: {}
1170
1172
  });
1171
1173
  }
1174
+ async function typedQueryAutomations(query, options) {
1175
+ const { httpClient, sideEffects } = arguments[2];
1176
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
1177
+ query,
1178
+ ...options
1179
+ });
1180
+ const reqOpts = queryAutomations(payload);
1181
+ sideEffects?.onSiteCall?.();
1182
+ try {
1183
+ const result = await httpClient.request(reqOpts);
1184
+ sideEffects?.onSuccess?.(result);
1185
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
1186
+ } catch (err) {
1187
+ const transformedError = (0, import_transform_error.transformError)(
1188
+ err,
1189
+ {
1190
+ spreadPathsToArguments: {},
1191
+ explicitPathsToArguments: { query: "$[0]" },
1192
+ singleArgumentUnchanged: false
1193
+ },
1194
+ ["query", "options"]
1195
+ );
1196
+ sideEffects?.onError?.(err);
1197
+ throw transformedError;
1198
+ }
1199
+ }
1172
1200
  async function getAggregatedUsageInfo2(options) {
1173
1201
  const { httpClient, sideEffects } = arguments[1];
1174
1202
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
@@ -1537,7 +1565,16 @@ function generatePreinstalledAutomation3(httpClient) {
1537
1565
  );
1538
1566
  }
1539
1567
  function queryAutomations3(httpClient) {
1540
- return () => queryAutomations2(
1568
+ return (options) => queryAutomations2(
1569
+ options,
1570
+ // @ts-ignore
1571
+ { httpClient }
1572
+ );
1573
+ }
1574
+ function typedQueryAutomations2(httpClient) {
1575
+ return (query, options) => typedQueryAutomations(
1576
+ query,
1577
+ options,
1541
1578
  // @ts-ignore
1542
1579
  { httpClient }
1543
1580
  );
@@ -1689,13 +1726,24 @@ var onAutomationUpdated = (0, import_sdk_types.EventDefinition)(
1689
1726
  // src/automations-v2-automation-automations-v-2.context.ts
1690
1727
  var import_rest_modules3 = require("@wix/sdk-runtime/rest-modules");
1691
1728
  var import_event_definition_modules = require("@wix/sdk-runtime/event-definition-modules");
1729
+ var import_query_method_router = require("@wix/sdk-runtime/query-method-router");
1730
+ function customQueryAutomations(httpClient) {
1731
+ const router = (0, import_query_method_router.createQueryOverloadRouter)({
1732
+ builderQueryFunction: (options) => queryAutomations3(httpClient)(options),
1733
+ typedQueryFunction: (query, options) => typedQueryAutomations2(httpClient)(query, options),
1734
+ hasOptionsParameter: true
1735
+ });
1736
+ function overloadedQuery(queryOrOptions, options) {
1737
+ return router(...arguments);
1738
+ }
1739
+ return overloadedQuery;
1740
+ }
1692
1741
  var createAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createAutomation3);
1693
1742
  var getAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getAutomation3);
1694
1743
  var updateAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(updateAutomation3);
1695
1744
  var deleteAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(deleteAutomation3);
1696
1745
  var bulkDeleteAutomations4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkDeleteAutomations3);
1697
1746
  var generatePreinstalledAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(generatePreinstalledAutomation3);
1698
- var queryAutomations4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(queryAutomations3);
1699
1747
  var getAggregatedUsageInfo4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getAggregatedUsageInfo3);
1700
1748
  var copyAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(copyAutomation3);
1701
1749
  var createDraftAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(createDraftAutomation3);
@@ -1708,6 +1756,7 @@ var publishDraftAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRES
1708
1756
  var validateAutomation4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(validateAutomation3);
1709
1757
  var validateAutomationById4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(validateAutomationById3);
1710
1758
  var getAutomationRevision4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(getAutomationRevision3);
1759
+ var queryAutomations4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customQueryAutomations);
1711
1760
  var onAutomationCreated2 = (0, import_event_definition_modules.createEventModule)(
1712
1761
  onAutomationCreated
1713
1762
  );