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

main
ts 33 lines 1.22 KB
Raw
1 import type * as serverless from "@distilled.cloud/aws/redshift-serverless";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4
5 /**
6 * Runtime binding for the `GetSnapshot` operation (IAM actions
7 * `redshift-serverless:GetSnapshot`).
8 *
9 * Reads one snapshot by name or ARN — e.g. polling a snapshot taken with
10 * {@link CreateSnapshot} until its `status` reaches `AVAILABLE`. Provide the implementation with
11 * `Effect.provide(AWS.RedshiftServerless.GetSnapshotHttp)`.
12 * ### Managing Snapshots
13 * **Example:** Poll a Snapshot Until Available
14 * ```typescript
15 * // init — resolve the runtime client
16 * const getSnapshot = yield* AWS.RedshiftServerless.GetSnapshot();
17 *
18 * const { snapshot } = yield* getSnapshot({ snapshotName: "pre-migration-1" });
19 * // snapshot?.status -> "CREATING" | "AVAILABLE" | ...
20 * ```
21 *
22 * @binding
23 */
24 export interface GetSnapshot extends Binding.Service<
25 GetSnapshot,
26 "AWS.RedshiftServerless.GetSnapshot",
27 () => Effect.Effect<
28 (
29 request: serverless.GetSnapshotRequest,
30 ) => Effect.Effect<serverless.GetSnapshotResponse, serverless.GetSnapshotError>
31 >
32 > {}
33 export const GetSnapshot = Binding.Service<GetSnapshot>("AWS.RedshiftServerless.GetSnapshot");