@wix/auto_sdk_automations_activations 1.0.93 → 1.0.95
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.d.ts +8 -4
- package/build/cjs/index.js +13 -11
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +12 -33
- package/build/cjs/index.typings.js +10 -10
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +5 -22
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +8 -4
- package/build/es/index.mjs +13 -11
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +12 -33
- package/build/es/index.typings.mjs +10 -10
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +5 -22
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +8 -4
- package/build/internal/cjs/index.js +13 -11
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +12 -33
- package/build/internal/cjs/index.typings.js +10 -10
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +5 -22
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +8 -4
- package/build/internal/es/index.mjs +13 -11
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +12 -33
- package/build/internal/es/index.typings.mjs +10 -10
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +5 -22
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +2 -2
package/build/cjs/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
|
|
2
|
-
import { ReportEventOptions, ReportEventResponse, ReportEventApplicationErrors, EventInfo, BulkReportEventResponse, BulkCancelEventResponse, ReportActionInvocationCompletedOptions } from './index.typings.js';
|
|
3
|
-
export { AIMetadata,
|
|
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, 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, RestoreInfo, ResumeAfterAsyncActionCompleted, ResumeAfterAsyncActionCompletedStatusInfoOneOf, RetryInfo, RunAutomationRequest, RunAutomationResponse, 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 {
|
|
@@ -81,8 +81,12 @@ interface ReportActionInvocationCompletedSignature {
|
|
|
81
81
|
* When Wix calls [Invoke](https://dev.wix.com/docs/api-reference/business-management/automations/actions/action-provider-service-plugin/invoke) to run your [action that has a timeout](https://dev.wix.com/docs/api-reference/business-management/automations/actions/action-provider-service-plugin/introduction#action-timeouts), it pauses the automation until you call this method or until the timeout period ends. If your action has an [output schema](https://dev.wix.com/docs/api-reference/business-management/automations/actions/about-actions#the-output-schema), include your action's results.
|
|
82
82
|
*
|
|
83
83
|
* If you don't call this method in the timeout period, Wix [marks the action as failed](https://support.wix.com/en/article/wix-automations-understanding-run-logs#understanding-statuses) and continues to the next step in the automation. Subsequent actions may fail if they rely on your action's output.
|
|
84
|
+
* @param - Action completion status.
|
|
85
|
+
* @param - Invocation token from Wix's original call to [Invoke](https://dev.wix.com/docs/api-reference/business-management/automations/actions/action-provider-service-plugin/invoke). Wix uses this token to match your results with the correct automation run.
|
|
86
|
+
*
|
|
87
|
+
* Learn more about [running an invoked action with a timeout](https://dev.wix.com/docs/api-reference/business-management/automations/actions/action-provider-service-plugin/sample-flow#run-an-invoked-action-with-a-timeout).
|
|
84
88
|
*/
|
|
85
|
-
(
|
|
89
|
+
(status: StatusWithLiterals, invocationToken: string, options?: ReportActionInvocationCompletedOptions): Promise<void>;
|
|
86
90
|
}
|
|
87
91
|
|
|
88
92
|
declare const reportEvent: MaybeContext<BuildRESTFunction<typeof reportEvent$1> & typeof reportEvent$1>;
|
|
@@ -91,4 +95,4 @@ declare const bulkCancelEvent: MaybeContext<BuildRESTFunction<typeof bulkCancelE
|
|
|
91
95
|
declare const cancelEvent: MaybeContext<BuildRESTFunction<typeof cancelEvent$1> & typeof cancelEvent$1>;
|
|
92
96
|
declare const reportActionInvocationCompleted: MaybeContext<BuildRESTFunction<typeof reportActionInvocationCompleted$1> & typeof reportActionInvocationCompleted$1>;
|
|
93
97
|
|
|
94
|
-
export { BulkCancelEventResponse, BulkReportEventResponse, EventInfo, ReportActionInvocationCompletedOptions, ReportEventApplicationErrors, ReportEventOptions, ReportEventResponse, bulkCancelEvent, bulkReportEvent, cancelEvent, reportActionInvocationCompleted, reportEvent };
|
|
98
|
+
export { BulkCancelEventResponse, BulkReportEventResponse, EventInfo, ReportActionInvocationCompletedOptions, ReportEventApplicationErrors, ReportEventOptions, ReportEventResponse, StatusWithLiterals, bulkCancelEvent, bulkReportEvent, cancelEvent, reportActionInvocationCompleted, reportEvent };
|
package/build/cjs/index.js
CHANGED
|
@@ -520,13 +520,13 @@ async function cancelEvent2(triggerKey, externalEntityId) {
|
|
|
520
520
|
throw transformedError;
|
|
521
521
|
}
|
|
522
522
|
}
|
|
523
|
-
async function reportActionInvocationCompleted2(options) {
|
|
524
|
-
const { httpClient, sideEffects } = arguments[
|
|
523
|
+
async function reportActionInvocationCompleted2(status, invocationToken, options) {
|
|
524
|
+
const { httpClient, sideEffects } = arguments[3];
|
|
525
525
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
526
|
-
status
|
|
526
|
+
status,
|
|
527
|
+
invocationToken,
|
|
527
528
|
successInfo: options?.successInfo,
|
|
528
|
-
failureInfo: options?.failureInfo
|
|
529
|
-
invocationToken: options?.invocationToken
|
|
529
|
+
failureInfo: options?.failureInfo
|
|
530
530
|
});
|
|
531
531
|
const reqOpts = reportActionInvocationCompleted(
|
|
532
532
|
payload
|
|
@@ -541,14 +541,14 @@ async function reportActionInvocationCompleted2(options) {
|
|
|
541
541
|
{
|
|
542
542
|
spreadPathsToArguments: {},
|
|
543
543
|
explicitPathsToArguments: {
|
|
544
|
-
status: "$[0]
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
544
|
+
status: "$[0]",
|
|
545
|
+
invocationToken: "$[1]",
|
|
546
|
+
successInfo: "$[2].successInfo",
|
|
547
|
+
failureInfo: "$[2].failureInfo"
|
|
548
548
|
},
|
|
549
549
|
singleArgumentUnchanged: false
|
|
550
550
|
},
|
|
551
|
-
["options"]
|
|
551
|
+
["status", "invocationToken", "options"]
|
|
552
552
|
);
|
|
553
553
|
sideEffects?.onError?.(err);
|
|
554
554
|
throw transformedError;
|
|
@@ -589,7 +589,9 @@ function cancelEvent3(httpClient) {
|
|
|
589
589
|
);
|
|
590
590
|
}
|
|
591
591
|
function reportActionInvocationCompleted3(httpClient) {
|
|
592
|
-
return (options) => reportActionInvocationCompleted2(
|
|
592
|
+
return (status, invocationToken, options) => reportActionInvocationCompleted2(
|
|
593
|
+
status,
|
|
594
|
+
invocationToken,
|
|
593
595
|
options,
|
|
594
596
|
// @ts-ignore
|
|
595
597
|
{ httpClient }
|