1import type * as controltower from "@distilled.cloud/aws/controltower";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { LandingZone } from "./LandingZone.ts";
5
6/**
7 * Runtime binding for `controltower:ResetLandingZone`.
8 *
9 * Bind this operation to a {@link LandingZone} to re-deploy the landing
10 * zone to its last-known configuration from inside a function runtime —
11 * remediating landing zone drift. The call starts an asynchronous operation
12 * (landing zone operations routinely take an hour); poll it with
13 * {@link GetLandingZoneOperation}. Provide the implementation with
14 * `Effect.provide(AWS.ControlTower.ResetLandingZoneHttp)`.
15 * ### Remediating Drift
16 * **Example:** Reset a Drifted Landing Zone
17 * ```typescript
18 * // init — bind the operation to the landing zone
19 * const resetLandingZone = yield* AWS.ControlTower.ResetLandingZone(landingZone);
20 *
21 * // runtime
22 * const { operationIdentifier } = yield* resetLandingZone();
23 * ```
24 *
25 * @binding
26 */
27export interface ResetLandingZone extends Binding.Service<
28 ResetLandingZone,
29 "AWS.ControlTower.ResetLandingZone",
30 (
31 landingZone: LandingZone,
32 ) => Effect.Effect<
33 () => Effect.Effect<
34 controltower.ResetLandingZoneOutput,
35 controltower.ResetLandingZoneError
36 >
37 >
38> {}
39
40export const ResetLandingZone = Binding.Service<ResetLandingZone>(
41 "AWS.ControlTower.ResetLandingZone",
42);