Skip to content

CreateSnapshot

Source: src/AWS/RedshiftServerless/CreateSnapshot.ts

Runtime binding for the CreateSnapshot operation (IAM actions redshift-serverless:CreateSnapshot + redshift-serverless:TagResource).

Takes a manual snapshot of the bound Namespace — e.g. a pre-migration backup function or a scheduled snapshot-rotation job. The namespace name is injected from the binding. Provide the implementation with Effect.provide(AWS.RedshiftServerless.CreateSnapshotHttp).

// init — resolve the runtime client
const createSnapshot = yield* AWS.RedshiftServerless.CreateSnapshot(namespace);
// runtime
yield* createSnapshot({
snapshotName: `pre-migration-${runId}`,
retentionPeriod: 7,
});