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

main
ts 40 lines 1.52 KB
Raw
1 import type * as emrc from "@distilled.cloud/aws/emr-containers";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { VirtualCluster } from "./VirtualCluster.ts";
5
6 /**
7 * Runtime binding for `emr-containers:DescribeVirtualCluster`.
8 *
9 * Reads the bound {@link VirtualCluster}'s live state — its lifecycle state
10 * (`RUNNING`/`TERMINATING`/`TERMINATED`/`ARRESTED`), the backing EKS
11 * container provider, and the attached security configuration. The virtual
12 * cluster ID is injected from the binding — the runtime callable takes no
13 * arguments. Provide the implementation with
14 * `Effect.provide(AWS.EMRContainers.DescribeVirtualClusterHttp)`.
15 * ### Virtual Clusters
16 * **Example:** Read The Bound Virtual Cluster
17 * ```typescript
18 * // init — bind the operation to the virtual cluster
19 * const describeVirtualCluster =
20 * yield* AWS.EMRContainers.DescribeVirtualCluster(virtualCluster);
21 *
22 * // runtime
23 * const { virtualCluster } = yield* describeVirtualCluster();
24 * yield* Effect.log(`virtual cluster is ${virtualCluster?.state}`);
25 * ```
26 *
27 * @binding
28 */
29 export interface DescribeVirtualCluster extends Binding.Service<
30 DescribeVirtualCluster,
31 "AWS.EMRContainers.DescribeVirtualCluster",
32 (
33 virtualCluster: VirtualCluster,
34 ) => Effect.Effect<
35 () => Effect.Effect<emrc.DescribeVirtualClusterResponse, emrc.DescribeVirtualClusterError>
36 >
37 > {}
38 export const DescribeVirtualCluster = Binding.Service<DescribeVirtualCluster>(
39 "AWS.EMRContainers.DescribeVirtualCluster",
40 );