@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 04:45 UTC

main
ts 44 lines 1.55 KB
Raw
1 import type * as identitystore from "@distilled.cloud/aws/identitystore";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Instance } from "./Instance.ts";
5
6 /**
7 * Runtime binding for the `CreateGroupMembership` operation (IAM action
8 * `identitystore:CreateGroupMembership`), scoped to one {@link Instance}.
9 *
10 * Adds a user to a group in the bound instance's identity store, returning the new `MembershipId`. The instance's
11 * `IdentityStoreId` is injected from the binding. Provide the implementation with
12 * `Effect.provide(AWS.IdentityCenter.CreateGroupMembershipHttp)`.
13 * ### Managing Group Memberships
14 * **Example:** Add a User to a Group
15 * ```typescript
16 * // init — bind the operation to the Identity Center instance
17 * const createGroupMembership = yield* AWS.IdentityCenter.CreateGroupMembership(instance);
18 *
19 * // runtime
20 * const { MembershipId } = yield* createGroupMembership({
21 * GroupId: groupId,
22 * MemberId: { UserId: userId },
23 * });
24 * ```
25 *
26 * @binding
27 */
28 export interface CreateGroupMembership extends Binding.Service<
29 CreateGroupMembership,
30 "AWS.IdentityCenter.CreateGroupMembership",
31 (
32 instance: Instance,
33 ) => Effect.Effect<
34 (
35 request: Omit<identitystore.CreateGroupMembershipRequest, "IdentityStoreId">,
36 ) => Effect.Effect<
37 identitystore.CreateGroupMembershipResponse,
38 identitystore.CreateGroupMembershipError
39 >
40 >
41 > {}
42 export const CreateGroupMembership = Binding.Service<CreateGroupMembership>(
43 "AWS.IdentityCenter.CreateGroupMembership",
44 );