1import type * as identitystore from "@distilled.cloud/aws/identitystore";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { Instance } from "./Instance.ts";
5
6/**
7 * Runtime binding for the `DeleteUser` operation (IAM action
8 * `identitystore:DeleteUser`), scoped to one {@link Instance}.
9 *
10 * Deletes a user from the bound instance's identity store — the deprovisioning half of a user-sync Lambda. The instance's
11 * `IdentityStoreId` is injected from the binding. Provide the implementation with
12 * `Effect.provide(AWS.IdentityCenter.DeleteUserHttp)`.
13 * ### Managing Users
14 * **Example:** Deprovision a User
15 * ```typescript
16 * // init — bind the operation to the Identity Center instance
17 * const deleteUser = yield* AWS.IdentityCenter.DeleteUser(instance);
18 *
19 * // runtime
20 * yield* deleteUser({ UserId: userId });
21 * ```
22 *
23 * @binding
24 */
25export interface DeleteUser extends Binding.Service<
26 DeleteUser,
27 "AWS.IdentityCenter.DeleteUser",
28 (
29 instance: Instance,
30 ) => Effect.Effect<
31 (
32 request: Omit<identitystore.DeleteUserRequest, "IdentityStoreId">,
33 ) => Effect.Effect<
34 identitystore.DeleteUserResponse,
35 identitystore.DeleteUserError
36 >
37 >
38> {}
39export const DeleteUser = Binding.Service<DeleteUser>(
40 "AWS.IdentityCenter.DeleteUser",
41);