@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 40 lines 1.16 KB
Raw
1 import type * as dataproc from "@distilled.cloud/gcp/dataproc_v1";
2 import * as Binding from "alchemy/Binding";
3 import type { RuntimeContext } from "alchemy/RuntimeContext";
4 import type * as Effect from "effect/Effect";
5 import type { Cluster } from "./Cluster.ts";
6
7 export interface GetClusterRequest extends Omit<
8 dataproc.GetProjectsRegionsClustersRequest,
9 "projectId" | "region" | "clusterName"
10 > {}
11
12 /**
13 * Runtime binding for Dataproc `clusters.get`.
14 *
15 * Bind this operation to a {@link Cluster} in a Function/Action init
16 * phase. Provide {@link GetClusterHttp}.
17 *
18 * ### Observing Clusters
19 * **Example:** Read the bound cluster
20 * ```typescript
21 * const getCluster = yield* GCP.Dataproc.GetCluster(cluster);
22 * const live = yield* getCluster();
23 * ```
24 *
25 * @binding
26 * @category Dataproc
27 */
28 export interface GetCluster extends Binding.Service<
29 GetCluster,
30 "GCP.Dataproc.GetCluster",
31 (
32 cluster: Cluster,
33 ) => Effect.Effect<
34 (
35 request?: GetClusterRequest,
36 ) => Effect.Effect<dataproc.Cluster, dataproc.GetProjectsRegionsClustersError, RuntimeContext>
37 >
38 > {}
39
40 export const GetCluster = Binding.Service<GetCluster>("GCP.Dataproc.GetCluster");