1import type * as kendra from "@distilled.cloud/aws/kendra";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { Index } from "./SearchIndex.ts";
5
6/**
7 * `ListGroupsOlderThanOrderingId` request with `IndexId` injected from the bound index.
8 */
9export interface ListGroupsOlderThanOrderingIdRequest extends Omit<
10 kendra.ListGroupsOlderThanOrderingIdRequest,
11 "IndexId"
12> {}
13
14/**
15 * Runtime binding for the `ListGroupsOlderThanOrderingId` operation (IAM action
16 * `kendra:ListGroupsOlderThanOrderingId`), scoped to one {@link Index}.
17 *
18 * Lists groups whose principal mapping is older than the given ordering
19 * id — used to find stale group mappings to refresh or delete.
20 * Provide the implementation with
21 * `Effect.provide(AWS.Kendra.ListGroupsOlderThanOrderingIdHttp)`.
22 *
23 * ### Principal Mapping
24 * **Example:** List Stale Groups
25 * ```typescript
26 * const listGroups = yield* AWS.Kendra.ListGroupsOlderThanOrderingId(index);
27 *
28 * const stale = yield* listGroups({ OrderingId: orderingId });
29 * console.log(stale.GroupsSummaries);
30 * ```
31 *
32 * @binding
33 */
34export interface ListGroupsOlderThanOrderingId extends Binding.Service<
35 ListGroupsOlderThanOrderingId,
36 "AWS.Kendra.ListGroupsOlderThanOrderingId",
37 (
38 index: Index,
39 ) => Effect.Effect<
40 (
41 request: ListGroupsOlderThanOrderingIdRequest,
42 ) => Effect.Effect<
43 kendra.ListGroupsOlderThanOrderingIdResponse,
44 kendra.ListGroupsOlderThanOrderingIdError
45 >
46 >
47> {}
48export const ListGroupsOlderThanOrderingId =
49 Binding.Service<ListGroupsOlderThanOrderingId>(
50 "AWS.Kendra.ListGroupsOlderThanOrderingId",
51 );