sailfork / t3code-github / .repos/ alchemy-effect/ packages/ aws/ src/ RedshiftServerless/ ConvertRecoveryPointToSnapshot.ts

import type * as serverless from "@distilled.cloud/aws/redshift-serverless";
import * as Binding from "alchemy/Binding";
import type * as Effect from "effect/Effect";

/**
 * Runtime binding for the `ConvertRecoveryPointToSnapshot` operation (IAM actions
 * `redshift-serverless:ConvertRecoveryPointToSnapshot` +
 * `redshift-serverless:TagResource`).
 *
 * Converts an automatic recovery point into a manual snapshot so it
 * outlives the 24-hour recovery-point window. Provide the implementation with
 * `Effect.provide(AWS.RedshiftServerless.ConvertRecoveryPointToSnapshotHttp)`.
 * ### Working with Recovery Points
 * **Example:** Preserve a Recovery Point as a Snapshot
 * ```typescript
 * // init — resolve the runtime client
 * const convert = yield* AWS.RedshiftServerless.ConvertRecoveryPointToSnapshot();
 *
 * yield* convert({ recoveryPointId, snapshotName: `preserved-${runId}` });
 * ```
 *
 * @binding
 */
export interface ConvertRecoveryPointToSnapshot extends Binding.Service<
  ConvertRecoveryPointToSnapshot,
  "AWS.RedshiftServerless.ConvertRecoveryPointToSnapshot",
  () => Effect.Effect<
    (
      request: serverless.ConvertRecoveryPointToSnapshotRequest,
    ) => Effect.Effect<
      serverless.ConvertRecoveryPointToSnapshotResponse,
      serverless.ConvertRecoveryPointToSnapshotError
    >
  >
> {}
export const ConvertRecoveryPointToSnapshot = Binding.Service<ConvertRecoveryPointToSnapshot>(
  "AWS.RedshiftServerless.ConvertRecoveryPointToSnapshot",
);