@wix/auto_sdk_automations_activations 1.0.109 → 1.0.111

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 +1 -1
  2. package/build/cjs/index.js +67 -2
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/index.typings.d.ts +6 -2
  5. package/build/cjs/index.typings.js +58 -2
  6. package/build/cjs/index.typings.js.map +1 -1
  7. package/build/cjs/meta.d.ts +4 -3
  8. package/build/cjs/meta.js +47 -2
  9. package/build/cjs/meta.js.map +1 -1
  10. package/build/es/index.d.mts +1 -1
  11. package/build/es/index.mjs +65 -1
  12. package/build/es/index.mjs.map +1 -1
  13. package/build/es/index.typings.d.mts +6 -2
  14. package/build/es/index.typings.mjs +56 -1
  15. package/build/es/index.typings.mjs.map +1 -1
  16. package/build/es/meta.d.mts +4 -3
  17. package/build/es/meta.mjs +45 -1
  18. package/build/es/meta.mjs.map +1 -1
  19. package/build/internal/cjs/index.d.ts +14 -3
  20. package/build/internal/cjs/index.js +67 -2
  21. package/build/internal/cjs/index.js.map +1 -1
  22. package/build/internal/cjs/index.typings.d.ts +16 -2
  23. package/build/internal/cjs/index.typings.js +58 -2
  24. package/build/internal/cjs/index.typings.js.map +1 -1
  25. package/build/internal/cjs/meta.d.ts +4 -3
  26. package/build/internal/cjs/meta.js +47 -2
  27. package/build/internal/cjs/meta.js.map +1 -1
  28. package/build/internal/es/index.d.mts +14 -3
  29. package/build/internal/es/index.mjs +65 -1
  30. package/build/internal/es/index.mjs.map +1 -1
  31. package/build/internal/es/index.typings.d.mts +16 -2
  32. package/build/internal/es/index.typings.mjs +56 -1
  33. package/build/internal/es/index.typings.mjs.map +1 -1
  34. package/build/internal/es/meta.d.mts +4 -3
  35. package/build/internal/es/meta.mjs +45 -1
  36. package/build/internal/es/meta.mjs.map +1 -1
  37. package/package.json +2 -2
@@ -1,6 +1,6 @@
1
1
  import { HttpClient, NonNullablePaths, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
2
2
  import { ReportEventOptions, ReportEventResponse, ReportEventApplicationErrors, EventInfo, BulkReportEventResponse, BulkCancelEventResponse, StatusWithLiterals, ReportActionInvocationCompletedOptions } from './index.typings.js';
3
- export { AIMetadata, AccountInfo, Action, ActionActionOneOf, ActionAttributes, ActionCodeSnippet, ActionCompletedRequest, ActionData, ActionEvent, ActionRetryRequest, ActionSettings, ActionSplitAction, ActionsData, Activation, ActivationActionStatusChanged, ActivationActionStatusChangedInfoOneOf, ActivationActionStatusChangedStatus, ActivationActionStatusChangedStatusInfoOneOf, ActivationActionStatusChangedStatusWithLiterals, ActivationContext, ActivationContinuedAfterSchedule, ActivationInitiationSource, ActivationInitiationSourceInfo, ActivationInitiationSourceInfoInitiationSourceInfoOneOf, ActivationInitiationSourceWithLiterals, ActivationRequest, ActivationResumeAfterDelay, ActivationScheduleCompleted, ActivationSource, ActivationSourceOfOneOf, ActivationStatusChanged, ActivationStatusChangedFailedStatusInfo, ActivationStatusChangedStartedStatusInfo, ActivationStatusChangedStatus, ActivationStatusChangedStatusInfoOneOf, ActivationStatusChangedStatusWithLiterals, AppDefinedAction, AppDefinedActionInfo, ApplicationError, ApplicationOrigin, AsyncAction, AuditInfo, AuditInfoIdOneOf, AutoArchivePolicy, Automation, AutomationConfiguration, AutomationConfigurationAction, AutomationConfigurationActionInfoOneOf, AutomationConfigurationStatus, AutomationConfigurationStatusWithLiterals, AutomationIdentifier, AutomationInfo, AutomationInfoOriginInfoOneOf, AutomationInfoTriggerInfo, AutomationOriginInfoOneOf, AutomationSettings, BatchActivationRequest, BlockType, BlockTypeWithLiterals, BulkActionMetadata, BulkCancelEventRequest, BulkCancelEventResult, BulkReportEventRequest, BulkReportEventResult, CancelEventRequest, CancelEventResponse, CancelPendingScheduleRequest, CancelPendingScheduleRequestByOneOf, CancelPendingScheduleResponse, CancellationReason, CancellationReasonWithLiterals, CancelledStatusInfo, Case, CodeConditionAction, CodeConditionActionInfo, CodeConditionFilter, CodeSnippet, CodeSnippetLanguage, CodeSnippetLanguageWithLiterals, ConditionAction, ConditionActionInfo, ConditionBlock, ConditionExpressionGroup, ConditionFilter, ConsumeReportEventRequest, Delay, DelayAction, DelayActionInfo, DelayHelper, DelayOfOneOf, Dimensions, Domain, DomainEvent, DomainEventBodyOneOf, DomainWithLiterals, DraftInfo, Empty, EndedStatusInfo, EndedStatusInfoAppDefinedActionInfo, EndedStatusInfoTypeInfoOneOf, Enrichment, Enrichments, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, ErrorReason, ErrorReasonWithLiterals, ExecuteFromActionRequest, ExecuteFromActionResponse, ExpressionEvaluationResult, ExtendedFields, FailedStatusInfo, FailureInfo, Filter, FilterValueSelection, FilterableAppDefinedActions, FutureDateActivationOffset, GetScheduleRequest, GetScheduleResponse, Idempotency, IdentificationData, IdentificationDataIdOneOf, IdentifierType, IdentifierTypeWithLiterals, Identity, IfFilter, InitiatedStatusInfo, InitiatorInfo, InvokedAsyncStatusInfo, InvokedAsyncStatusInfoAppDefinedActionInfo, InvokedAsyncStatusInfoTypeInfoOneOf, ItemMetadata, Language, LanguageWithLiterals, ManualActivationInfo, MessageEnvelope, Metadata, Note, Notes, Offset, Operator, OperatorWithLiterals, Origin, OriginWithLiterals, Output, OutputAction, Path, Position, PreinstalledIdentifier, PreinstalledOrigin, RateLimit, RateLimitAction, RateLimitActionInfo, RateLimiting, RefreshPayloadRequest, RefreshPayloadResponse, ReportAccountLevelEventRequest, ReportAccountLevelEventResponse, ReportActionInvocationCompletedOptionsStatusInfoOneOf, ReportActionInvocationCompletedRequest, ReportActionInvocationCompletedRequestStatusInfoOneOf, ReportActionInvocationCompletedResponse, ReportDomainEventRequest, ReportDomainEventResponse, ReportEventRequest, RerunActivationInfo, RerunActivationRequest, RerunActivationResponse, RestoreInfo, ResumeAfterAsyncActionCompleted, ResumeAfterAsyncActionCompletedStatusInfoOneOf, RetryInfo, RunAutomationRequest, RunAutomationResponse, RunOptions, Runtime, RuntimeStatus, RuntimeStatusWithLiterals, Schedule, ScheduleActivationRequested, ScheduleRequest, ScheduleResponse, ScheduleStatus, ScheduleStatusWithLiterals, ScheduledAction, ScheduledStatusInfo, Scheduler, Service, ServiceMapping, SetVariables, SetVariablesAction, SetVariablesActionInfo, SimpleDelay, SkipReason, SkipReasonWithLiterals, SkippedStatusInfo, SpiAction, SplitAction, SplitActionPath, StartedStatusInfo, StartedStatusInfoAppDefinedActionInfo, StartedStatusInfoDelayActionInfo, StartedStatusInfoTypeInfoOneOf, Status, SuccessInfo, SwitchFilter, SystemHelper, SystemHelperHelperOneOf, Target, TargetWithLiterals, TestAutomationRequest, TestAutomationRequestIdentifierOneOf, TestAutomationResponse, TimeUnit, TimeUnitWithLiterals, Trigger, TriggerInfo, TriggerSettings, Type, TypeWithLiterals, Units, UnitsWithLiterals, UpdatePendingSchedulesPayloadRequest, UpdatePendingSchedulesPayloadResponse, UpdateScheduleStatusRequest, UpdateScheduleStatusResponse, V1RunAutomationRequest, V1RunAutomationRequestIdentifierOneOf, V1RunAutomationResponse, WebhookIdentityType, WebhookIdentityTypeWithLiterals } from './index.typings.js';
3
+ export { AIMetadata, AccountInfo, Action, ActionActionOneOf, ActionAttributes, ActionCodeSnippet, ActionCompletedRequest, ActionData, ActionEvent, ActionRetryRequest, ActionSettings, ActionSplitAction, ActionsData, Activation, ActivationActionStatusChanged, ActivationActionStatusChangedInfoOneOf, ActivationActionStatusChangedStatus, ActivationActionStatusChangedStatusInfoOneOf, ActivationActionStatusChangedStatusWithLiterals, ActivationContext, ActivationContinuedAfterSchedule, ActivationInitiationSource, ActivationInitiationSourceInfo, ActivationInitiationSourceInfoInitiationSourceInfoOneOf, ActivationInitiationSourceWithLiterals, ActivationRequest, ActivationResumeAfterDelay, ActivationScheduleCompleted, ActivationSource, ActivationSourceOfOneOf, ActivationStatusChanged, ActivationStatusChangedFailedStatusInfo, ActivationStatusChangedStartedStatusInfo, ActivationStatusChangedStatus, ActivationStatusChangedStatusInfoOneOf, ActivationStatusChangedStatusWithLiterals, AppDefinedAction, AppDefinedActionInfo, ApplicationError, ApplicationOrigin, AsyncAction, AuditInfo, AuditInfoIdOneOf, AutoArchivePolicy, Automation, AutomationConfiguration, AutomationConfigurationAction, AutomationConfigurationActionInfoOneOf, AutomationConfigurationStatus, AutomationConfigurationStatusWithLiterals, AutomationIdentifier, AutomationInfo, AutomationInfoOriginInfoOneOf, AutomationInfoTriggerInfo, AutomationOriginInfoOneOf, AutomationSettings, BatchActivationRequest, BlockType, BlockTypeWithLiterals, BulkActionMetadata, BulkCancelEventRequest, BulkCancelEventResult, BulkReportEventRequest, BulkReportEventResult, CancelEventRequest, CancelEventResponse, CancelPendingScheduleRequest, CancelPendingScheduleRequestByOneOf, CancelPendingScheduleResponse, CancellationReason, CancellationReasonWithLiterals, CancelledStatusInfo, Case, CodeConditionAction, CodeConditionActionInfo, CodeConditionFilter, CodeSnippet, CodeSnippetLanguage, CodeSnippetLanguageWithLiterals, ConditionAction, ConditionActionInfo, ConditionBlock, ConditionExpressionGroup, ConditionFilter, ConsumeReportEventRequest, Delay, DelayAction, DelayActionInfo, DelayHelper, DelayOfOneOf, Dimensions, Domain, DomainEvent, DomainEventBodyOneOf, DomainWithLiterals, DraftInfo, Empty, EndedStatusInfo, EndedStatusInfoAppDefinedActionInfo, EndedStatusInfoTypeInfoOneOf, Enrichment, Enrichments, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, ErrorReason, ErrorReasonWithLiterals, ExecuteFromActionRequest, ExecuteFromActionResponse, ExpressionEvaluationResult, ExtendedFields, FailedStatusInfo, FailureInfo, Filter, FilterValueSelection, FilterableAppDefinedActions, FutureDateActivationOffset, GetScheduleRequest, GetScheduleResponse, Idempotency, IdentificationData, IdentificationDataIdOneOf, IdentifierType, IdentifierTypeWithLiterals, Identity, IfFilter, InitiatedStatusInfo, InitiatorInfo, InvokedAsyncStatusInfo, InvokedAsyncStatusInfoAppDefinedActionInfo, InvokedAsyncStatusInfoTypeInfoOneOf, ItemMetadata, Language, LanguageWithLiterals, ManualActivationInfo, MessageEnvelope, Metadata, Note, Notes, Offset, Operator, OperatorWithLiterals, Origin, OriginWithLiterals, Output, OutputAction, Path, Position, PreinstalledIdentifier, PreinstalledOrigin, RateLimit, RateLimitAction, RateLimitActionInfo, RateLimiting, RefreshPayloadRequest, RefreshPayloadResponse, ReportAccountLevelEventRequest, ReportAccountLevelEventResponse, ReportActionInvocationCompletedOptionsStatusInfoOneOf, ReportActionInvocationCompletedRequest, ReportActionInvocationCompletedRequestStatusInfoOneOf, ReportActionInvocationCompletedResponse, ReportDomainEventRequest, ReportDomainEventResponse, ReportEventRequest, RerunActivationInfo, RerunActivationOptions, RerunActivationRequest, RerunActivationResponse, RestoreInfo, ResumeAfterAsyncActionCompleted, ResumeAfterAsyncActionCompletedStatusInfoOneOf, RetryInfo, RunAutomationRequest, RunAutomationResponse, RunOptions, Runtime, RuntimeStatus, RuntimeStatusWithLiterals, Schedule, ScheduleActivationRequested, ScheduleRequest, ScheduleResponse, ScheduleStatus, ScheduleStatusWithLiterals, ScheduledAction, ScheduledStatusInfo, Scheduler, Service, ServiceMapping, SetVariables, SetVariablesAction, SetVariablesActionInfo, SimpleDelay, SkipReason, SkipReasonWithLiterals, SkippedStatusInfo, SpiAction, SplitAction, SplitActionPath, StartedStatusInfo, StartedStatusInfoAppDefinedActionInfo, StartedStatusInfoDelayActionInfo, StartedStatusInfoTypeInfoOneOf, Status, SuccessInfo, SwitchFilter, SystemHelper, SystemHelperHelperOneOf, Target, TargetWithLiterals, TestAutomationRequest, TestAutomationRequestIdentifierOneOf, TestAutomationResponse, TimeUnit, TimeUnitWithLiterals, Trigger, TriggerInfo, TriggerSettings, Type, TypeWithLiterals, Units, UnitsWithLiterals, UpdatePendingSchedulesPayloadRequest, UpdatePendingSchedulesPayloadResponse, UpdateScheduleStatusRequest, UpdateScheduleStatusResponse, V1RunAutomationRequest, V1RunAutomationRequestIdentifierOneOf, V1RunAutomationResponse, WebhookIdentityType, WebhookIdentityTypeWithLiterals } from './index.typings.js';
4
4
 
5
5
  declare function reportEvent$1(httpClient: HttpClient): ReportEventSignature;
6
6
  interface ReportEventSignature {
@@ -46,7 +46,8 @@ __export(index_exports, {
46
46
  bulkReportEvent: () => bulkReportEvent4,
47
47
  cancelEvent: () => cancelEvent4,
48
48
  reportActionInvocationCompleted: () => reportActionInvocationCompleted4,
49
- reportEvent: () => reportEvent4
49
+ reportEvent: () => reportEvent4,
50
+ rerunActivation: () => rerunActivation4
50
51
  });
51
52
  module.exports = __toCommonJS(index_exports);
52
53
 
@@ -145,6 +146,10 @@ function resolveWixAutomationsEsbResolverV1EsbConfigResolverUrl(opts) {
145
146
  {
146
147
  srcPath: "/automations/v1/events/bulk-report",
147
148
  destPath: "/v1/events/bulk-report"
149
+ },
150
+ {
151
+ srcPath: "/automations/v1/events/rerun-activation",
152
+ destPath: "/v1/events/rerun-activation"
148
153
  }
149
154
  ]
150
155
  };
@@ -235,6 +240,27 @@ function cancelEvent(payload) {
235
240
  }
236
241
  return __cancelEvent;
237
242
  }
243
+ function rerunActivation(payload) {
244
+ function __rerunActivation({ host }) {
245
+ const metadata = {
246
+ entityFqdn: "wix.automations.v2.activation",
247
+ method: "POST",
248
+ methodFqn: "wix.automations.esb.resolver.v1.EsbConfigResolver.RerunActivation",
249
+ packageName: PACKAGE_NAME,
250
+ migrationOptions: {
251
+ optInTransformResponse: true
252
+ },
253
+ url: resolveWixAutomationsEsbResolverV1EsbConfigResolverUrl({
254
+ protoPath: "/v1/events/rerun-activation",
255
+ data: payload,
256
+ host
257
+ }),
258
+ data: payload
259
+ };
260
+ return metadata;
261
+ }
262
+ return __rerunActivation;
263
+ }
238
264
  function reportActionInvocationCompleted(payload) {
239
265
  function __reportActionInvocationCompleted({ host }) {
240
266
  const metadata = {
@@ -540,6 +566,35 @@ async function cancelEvent2(triggerKey, externalEntityId) {
540
566
  throw transformedError;
541
567
  }
542
568
  }
569
+ async function rerunActivation2(activationId, options) {
570
+ const { httpClient, sideEffects } = arguments[2];
571
+ const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
572
+ activationId,
573
+ options: options?.options
574
+ });
575
+ const reqOpts = rerunActivation(payload);
576
+ sideEffects?.onSiteCall?.();
577
+ try {
578
+ const result = await httpClient.request(reqOpts);
579
+ sideEffects?.onSuccess?.(result);
580
+ return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
581
+ } catch (err) {
582
+ const transformedError = (0, import_transform_error.transformError)(
583
+ err,
584
+ {
585
+ spreadPathsToArguments: {},
586
+ explicitPathsToArguments: {
587
+ activationId: "$[0]",
588
+ options: "$[1].options"
589
+ },
590
+ singleArgumentUnchanged: false
591
+ },
592
+ ["activationId", "options"]
593
+ );
594
+ sideEffects?.onError?.(err);
595
+ throw transformedError;
596
+ }
597
+ }
543
598
  async function reportActionInvocationCompleted2(status, invocationToken, options) {
544
599
  const { httpClient, sideEffects } = arguments[3];
545
600
  const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
@@ -608,6 +663,14 @@ function cancelEvent3(httpClient) {
608
663
  { httpClient }
609
664
  );
610
665
  }
666
+ function rerunActivation3(httpClient) {
667
+ return (activationId, options) => rerunActivation2(
668
+ activationId,
669
+ options,
670
+ // @ts-ignore
671
+ { httpClient }
672
+ );
673
+ }
611
674
  function reportActionInvocationCompleted3(httpClient) {
612
675
  return (status, invocationToken, options) => reportActionInvocationCompleted2(
613
676
  status,
@@ -624,6 +687,7 @@ var reportEvent4 = /* @__PURE__ */ (0, import_rest_modules2.createRESTModule)(re
624
687
  var bulkReportEvent4 = /* @__PURE__ */ (0, import_rest_modules2.createRESTModule)(bulkReportEvent3);
625
688
  var bulkCancelEvent4 = /* @__PURE__ */ (0, import_rest_modules2.createRESTModule)(bulkCancelEvent3);
626
689
  var cancelEvent4 = /* @__PURE__ */ (0, import_rest_modules2.createRESTModule)(cancelEvent3);
690
+ var rerunActivation4 = /* @__PURE__ */ (0, import_rest_modules2.createRESTModule)(rerunActivation3);
627
691
  var reportActionInvocationCompleted4 = /* @__PURE__ */ (0, import_rest_modules2.createRESTModule)(reportActionInvocationCompleted3);
628
692
  // Annotate the CommonJS export names for ESM import in node:
629
693
  0 && (module.exports = {
@@ -653,6 +717,7 @@ var reportActionInvocationCompleted4 = /* @__PURE__ */ (0, import_rest_modules2.
653
717
  bulkReportEvent,
654
718
  cancelEvent,
655
719
  reportActionInvocationCompleted,
656
- reportEvent
720
+ reportEvent,
721
+ rerunActivation
657
722
  });
658
723
  //# sourceMappingURL=index.js.map