@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, 06:00 UTC

main
ts 36 lines 1.21 KB
Raw
1 import type * as eks from "@distilled.cloud/aws/eks";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Cluster } from "./Cluster.ts";
5
6 /**
7 * Runtime binding for `eks:DescribeInsight`.
8 *
9 * Reads one insight's full detail — category, status, recommendation, and the resources it flags.
10 * The cluster `clusterName` is injected from the bound {@link Cluster} and `eks:DescribeInsight` is granted on the cluster's ARN.
11 * Provide the implementation with
12 * `Effect.provide(AWS.EKS.DescribeInsightHttp)`.
13 * ### Cluster Insights
14 * **Example:** Read an Insight's Recommendation
15 * ```typescript
16 * // init
17 * const describeInsight = yield* AWS.EKS.DescribeInsight(cluster);
18 *
19 * // runtime
20 * const { insight } = yield* describeInsight({ id: insightId });
21 * ```
22 *
23 * @binding
24 */
25 export interface DescribeInsight extends Binding.Service<
26 DescribeInsight,
27 "AWS.EKS.DescribeInsight",
28 (
29 cluster: Cluster,
30 ) => Effect.Effect<
31 (
32 request: Omit<eks.DescribeInsightRequest, "clusterName">,
33 ) => Effect.Effect<eks.DescribeInsightResponse, eks.DescribeInsightError>
34 >
35 > {}
36 export const DescribeInsight = Binding.Service<DescribeInsight>("AWS.EKS.DescribeInsight");