1import type * as aoss from "@distilled.cloud/aws/opensearchserverless";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4
5/**
6 * Runtime binding for the `GetPoliciesStats` operation (IAM action
7 * `aoss:GetPoliciesStats`; the action does not support resource-level
8 * scoping, so the grant is on `*`).
9 *
10 * Returns counts of the account's access policies, security policies,
11 * security configurations, and lifecycle policies — useful for quota
12 * dashboards (each policy type has an account quota). Provide the
13 * implementation with
14 * `Effect.provide(AWS.OpenSearchServerless.GetPoliciesStatsHttp)`.
15 * ### Account Settings
16 * **Example:** Count the account's policies
17 * ```typescript
18 * const getPoliciesStats = yield* AWS.OpenSearchServerless.GetPoliciesStats();
19 *
20 * const stats = yield* getPoliciesStats();
21 * yield* Effect.log(`total policies: ${stats.TotalPolicyCount}`);
22 * ```
23 *
24 * @binding
25 */
26export interface GetPoliciesStats extends Binding.Service<
27 GetPoliciesStats,
28 "AWS.OpenSearchServerless.GetPoliciesStats",
29 () => Effect.Effect<
30 (
31 request?: aoss.GetPoliciesStatsRequest,
32 ) => Effect.Effect<
33 aoss.GetPoliciesStatsResponse,
34 aoss.GetPoliciesStatsError
35 >
36 >
37> {}
38export const GetPoliciesStats = Binding.Service<GetPoliciesStats>(
39 "AWS.OpenSearchServerless.GetPoliciesStats",
40);