The best way to control Claude Code, Codex and more from any computer or phone
| 1 | import type * as docdb from "@distilled.cloud/aws/docdb"; |
| 2 | import * as Binding from "alchemy/Binding"; |
| 3 | import type * as Effect from "effect/Effect"; |
| 4 | import type { DBCluster } from "./DBCluster.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for the `StopDBCluster` operation (IAM action |
| 8 | * `rds:StopDBCluster`). |
| 9 | * |
| 10 | * Stops the bound {@link DBCluster} — compute billing pauses while storage |
| 11 | * is retained (up to 7 days, after which DocumentDB starts it back up) — |
| 12 | * e.g. an ops function that parks a development cluster overnight. The |
| 13 | * cluster identifier is injected from the binding. Provide the |
| 14 | * implementation with `Effect.provide(AWS.DocDB.StopDBClusterHttp)`. |
| 15 | * ### Operating a Cluster |
| 16 | * **Example:** Stop a Running Cluster |
| 17 | * ```typescript |
| 18 | * // init — bind the operation to the cluster |
| 19 | * const stopDBCluster = yield* AWS.DocDB.StopDBCluster(cluster); |
| 20 | * |
| 21 | * // runtime |
| 22 | * yield* stopDBCluster(); |
| 23 | * ``` |
| 24 | * |
| 25 | * @binding |
| 26 | */ |
| 27 | export interface StopDBCluster extends Binding.Service< |
| 28 | StopDBCluster, |
| 29 | "AWS.DocDB.StopDBCluster", |
| 30 | ( |
| 31 | cluster: DBCluster, |
| 32 | ) => Effect.Effect<() => Effect.Effect<docdb.StopDBClusterResult, docdb.StopDBClusterError>> |
| 33 | > {} |
| 34 | export const StopDBCluster = Binding.Service<StopDBCluster>("AWS.DocDB.StopDBCluster"); |