@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, 06:00 UTC

main
ts 43 lines 1.48 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 `GetGroupId` operation (IAM action
8 * `identitystore:GetGroupId`), scoped to one {@link Instance}.
9 *
10 * Resolves a group's `GroupId` from a unique attribute (e.g. the display name) in the bound instance's identity store. The instance's
11 * `IdentityStoreId` is injected from the binding. Provide the implementation with
12 * `Effect.provide(AWS.IdentityCenter.GetGroupIdHttp)`.
13 * ### Looking Up Groups
14 * **Example:** Resolve a GroupId From a Display Name
15 * ```typescript
16 * // init — bind the operation to the Identity Center instance
17 * const getGroupId = yield* AWS.IdentityCenter.GetGroupId(instance);
18 *
19 * // runtime
20 * const { GroupId } = yield* getGroupId({
21 * AlternateIdentifier: {
22 * UniqueAttribute: {
23 * AttributePath: "displayName",
24 * AttributeValue: "platform-engineers",
25 * },
26 * },
27 * });
28 * ```
29 *
30 * @binding
31 */
32 export interface GetGroupId extends Binding.Service<
33 GetGroupId,
34 "AWS.IdentityCenter.GetGroupId",
35 (
36 instance: Instance,
37 ) => Effect.Effect<
38 (
39 request: Omit<identitystore.GetGroupIdRequest, "IdentityStoreId">,
40 ) => Effect.Effect<identitystore.GetGroupIdResponse, identitystore.GetGroupIdError>
41 >
42 > {}
43 export const GetGroupId = Binding.Service<GetGroupId>("AWS.IdentityCenter.GetGroupId");