The best way to control Claude Code, Codex and more from any computer or phone

main
ts 40 lines 1.35 KB
Raw
1 import type * as datasync from "@distilled.cloud/aws/datasync";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Task } from "./Task.ts";
5
6 /**
7 * Runtime binding for `datasync:CancelTaskExecution`.
8 *
9 * Stops a queued or in-flight execution of the bound {@link Task} — e.g. a
10 * kill switch when a transfer was started by mistake or is saturating a
11 * link. Address the execution with the ARN returned by
12 * `StartTaskExecution`; access is granted on the bound task's executions.
13 * Provide the implementation with
14 * `Effect.provide(AWS.DataSync.CancelTaskExecutionHttp)`.
15 * ### Running Transfers
16 * **Example:** Cancel A Transfer
17 * ```typescript
18 * // init — bind the operation to the task
19 * const cancelTaskExecution = yield* AWS.DataSync.CancelTaskExecution(task);
20 *
21 * // runtime
22 * yield* cancelTaskExecution({ TaskExecutionArn: executionArn });
23 * ```
24 *
25 * @binding
26 */
27 export interface CancelTaskExecution extends Binding.Service<
28 CancelTaskExecution,
29 "AWS.DataSync.CancelTaskExecution",
30 (
31 task: Task,
32 ) => Effect.Effect<
33 (
34 request: datasync.CancelTaskExecutionRequest,
35 ) => Effect.Effect<datasync.CancelTaskExecutionResponse, datasync.CancelTaskExecutionError>
36 >
37 > {}
38 export const CancelTaskExecution = Binding.Service<CancelTaskExecution>(
39 "AWS.DataSync.CancelTaskExecution",
40 );