Skip to content

CancelFlowExecutions

Source: src/AWS/AppFlow/CancelFlowExecutions.ts

Runtime binding for appflow:CancelFlowExecutions.

Bind this operation to a Flow in the function’s init phase to get a callable that cancels in-progress runs of the flow — all active runs when called with no arguments, or only the given executionIds. Executions that cannot be canceled (already finished, unknown) are returned in invalidExecutions. The flow name is injected automatically and appflow:CancelFlowExecutions is granted on the flow. Provide the implementation with Effect.provide(AWS.AppFlow.CancelFlowExecutionsHttp).

// init — bind the operation to the flow
const cancelFlowExecutions = yield* AWS.AppFlow.CancelFlowExecutions(flow);
// runtime — cancel a run by execution id
const result = yield* cancelFlowExecutions({
executionIds: [executionId],
});
// result.invalidExecutions lists ids that could not be canceled