| 1 | import type * as qbusiness from "@distilled.cloud/aws/qbusiness"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { Index } from "./SearchIndex.ts"; |
| 5 | |
| 6 | /** |
| 7 | * `ListGroups` request with `applicationId` + `indexId` injected from the bound index. |
| 8 | */ |
| 9 | export interface ListGroupsRequest extends Omit< |
| 10 | qbusiness.ListGroupsRequest, |
| 11 | "applicationId" | "indexId" |
| 12 | > {} |
| 13 | |
| 14 | /** |
| 15 | * Runtime binding for the `ListGroups` operation (IAM action |
| 16 | * `qbusiness:ListGroups`), scoped to one {@link Index}. |
| 17 | * |
| 18 | * Lists the groups mapped into the index before a given time. |
| 19 | * Provide the implementation with |
| 20 | * `Effect.provide(AWS.QBusiness.ListGroupsHttp)`. |
| 21 | * |
| 22 | * ### Principal Mapping |
| 23 | * **Example:** List Mapped Groups |
| 24 | * ```typescript |
| 25 | * const listGroups = yield* AWS.QBusiness.ListGroups(index); |
| 26 | * |
| 27 | * const { items } = yield* listGroups({ updatedEarlierThan: new Date() }); |
| 28 | * ``` |
| 29 | * |
| 30 | * @binding |
| 31 | */ |
| 32 | export interface ListGroups extends Binding.Service< |
| 33 | ListGroups, |
| 34 | "AWS.QBusiness.ListGroups", |
| 35 | ( |
| 36 | index: Index, |
| 37 | ) => Effect.Effect< |
| 38 | ( |
| 39 | request: ListGroupsRequest, |
| 40 | ) => Effect.Effect<qbusiness.ListGroupsResponse, qbusiness.ListGroupsError> |
| 41 | > |
| 42 | > {} |
| 43 | export const ListGroups = Binding.Service<ListGroups>( |
| 44 | "AWS.QBusiness.ListGroups", |
| 45 | ); |