@devries-cameron20 / t3code Mirror · read-only
Fork 0

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

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 04:45 UTC

main
ts 43 lines 1.5 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:DescribeTaskExecution`.
8 *
9 * Reads one execution of the bound {@link Task} — status, bytes/files
10 * transferred, per-phase results — to monitor an ongoing transfer or check
11 * a finished one. 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.DescribeTaskExecutionHttp)`.
15 * ### Running Transfers
16 * **Example:** Watch A Transfer's Progress
17 * ```typescript
18 * // init — bind the operation to the task
19 * const describeTaskExecution = yield* AWS.DataSync.DescribeTaskExecution(task);
20 *
21 * // runtime
22 * const execution = yield* describeTaskExecution({
23 * TaskExecutionArn: executionArn,
24 * });
25 * yield* Effect.log(`${execution.Status}: ${execution.BytesTransferred} bytes`);
26 * ```
27 *
28 * @binding
29 */
30 export interface DescribeTaskExecution extends Binding.Service<
31 DescribeTaskExecution,
32 "AWS.DataSync.DescribeTaskExecution",
33 (
34 task: Task,
35 ) => Effect.Effect<
36 (
37 request: datasync.DescribeTaskExecutionRequest,
38 ) => Effect.Effect<datasync.DescribeTaskExecutionResponse, datasync.DescribeTaskExecutionError>
39 >
40 > {}
41 export const DescribeTaskExecution = Binding.Service<DescribeTaskExecution>(
42 "AWS.DataSync.DescribeTaskExecution",
43 );