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

main
ts 35 lines 1.25 KB
Raw
1 import type * as docdbelastic from "@distilled.cloud/aws/docdb-elastic";
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 the `StopCluster` operation (IAM action
8 * `docdb-elastic:StopCluster`), scoped to one {@link Cluster}.
9 *
10 * Stops the bound elastic cluster — compute billing pauses (storage is still
11 * billed) and the cluster transitions through `STOPPING` to `STOPPED`. Use
12 * from a scheduled Lambda to park non-production clusters outside working
13 * hours. Provide the implementation with
14 * `Effect.provide(AWS.DocDBElastic.StopClusterHttp)`.
15 * ### Starting and Stopping a Cluster
16 * **Example:** Stop a Running Cluster
17 * ```typescript
18 * const stopCluster = yield* DocDBElastic.StopCluster(cluster);
19 *
20 * const result = yield* stopCluster();
21 * // result.cluster.status → "STOPPING"
22 * ```
23 *
24 * @binding
25 */
26 export interface StopCluster extends Binding.Service<
27 StopCluster,
28 "AWS.DocDBElastic.StopCluster",
29 (
30 cluster: Cluster,
31 ) => Effect.Effect<
32 () => Effect.Effect<docdbelastic.StopClusterOutput, docdbelastic.StopClusterError>
33 >
34 > {}
35 export const StopCluster = Binding.Service<StopCluster>("AWS.DocDBElastic.StopCluster");