GetSnapshotLimits
Source:
src/AWS/DirectoryService/GetSnapshotLimits.ts
Runtime binding for the GetSnapshotLimits operation (IAM action
ds:GetSnapshotLimits), scoped to one Directory.
Reads the bound directory’s manual snapshot limits — how many manual
snapshots exist versus the allowed maximum — so a backup function can
prune before taking a new snapshot. The directory id is injected from the
binding. Provide the implementation with
Effect.provide(AWS.DirectoryService.GetSnapshotLimitsHttp).
Managing Snapshots
Section titled “Managing Snapshots”// init — bind the operation to the directoryconst getSnapshotLimits = yield* AWS.DirectoryService.GetSnapshotLimits(directory);
// runtimeconst { SnapshotLimits } = yield* getSnapshotLimits();if (SnapshotLimits?.ManualSnapshotsLimitReached) { yield* Effect.logWarning("manual snapshot limit reached");}