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

main
ts 50 lines 1.53 KB
Raw
1 import type * as kendra from "@distilled.cloud/aws/kendra";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Index } from "./SearchIndex.ts";
5
6 /**
7 * `DescribePrincipalMapping` request with `IndexId` injected from the bound index.
8 */
9 export interface DescribePrincipalMappingRequest extends Omit<
10 kendra.DescribePrincipalMappingRequest,
11 "IndexId"
12 > {}
13
14 /**
15 * Runtime binding for the `DescribePrincipalMapping` operation (IAM action
16 * `kendra:DescribePrincipalMapping`), scoped to one {@link Index}.
17 *
18 * Describes the processing state of the `PUT`/`DELETE` actions applied
19 * to a group's principal mapping.
20 * Provide the implementation with
21 * `Effect.provide(AWS.Kendra.DescribePrincipalMappingHttp)`.
22 *
23 * ### Principal Mapping
24 * **Example:** Inspect Mapping Actions
25 * ```typescript
26 * const describeMapping = yield* AWS.Kendra.DescribePrincipalMapping(index);
27 *
28 * const mapping = yield* describeMapping({ GroupId: "engineering" });
29 * console.log(mapping.GroupOrderingIdSummaries);
30 * ```
31 *
32 * @binding
33 */
34 export interface DescribePrincipalMapping extends Binding.Service<
35 DescribePrincipalMapping,
36 "AWS.Kendra.DescribePrincipalMapping",
37 (
38 index: Index,
39 ) => Effect.Effect<
40 (
41 request: DescribePrincipalMappingRequest,
42 ) => Effect.Effect<
43 kendra.DescribePrincipalMappingResponse,
44 kendra.DescribePrincipalMappingError
45 >
46 >
47 > {}
48 export const DescribePrincipalMapping = Binding.Service<DescribePrincipalMapping>(
49 "AWS.Kendra.DescribePrincipalMapping",
50 );