1import type * as detective from "@distilled.cloud/aws/detective";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4
5/**
6 * Runtime binding for `detective:AcceptInvitation`.
7 *
8 * Accepts an invitation into an administrator account's behavior graph —
9 * the graph belongs to the admin account, so its ARN arrives at runtime
10 * (typically from `ListInvitations`) rather than from a bound resource.
11 * Provide the implementation with
12 * `Effect.provide(AWS.Detective.AcceptInvitationHttp)`.
13 * ### Responding to Invitations
14 * **Example:** Auto-Accept An Invitation
15 * ```typescript
16 * // init — account-level binding, no resource argument
17 * const acceptInvitation = yield* AWS.Detective.AcceptInvitation();
18 *
19 * // runtime
20 * yield* acceptInvitation({ GraphArn: invitation.GraphArn! });
21 * ```
22 *
23 * @binding
24 */
25export interface AcceptInvitation extends Binding.Service<
26 AcceptInvitation,
27 "AWS.Detective.AcceptInvitation",
28 () => Effect.Effect<
29 (
30 request: detective.AcceptInvitationRequest,
31 ) => Effect.Effect<
32 detective.AcceptInvitationResponse,
33 detective.AcceptInvitationError
34 >
35 >
36> {}
37export const AcceptInvitation = Binding.Service<AcceptInvitation>(
38 "AWS.Detective.AcceptInvitation",
39);