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

main
ts 33 lines 1.27 KB
Raw
1 import type * as organizations from "@distilled.cloud/aws/organizations";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4
5 /**
6 * Runtime binding for `organizations:ListPolicies`.
7 *
8 * Lists all policies of the specified type (service control, tag, backup, AI-services opt-out, …) in the organization.
9 * Account-level operation — Organizations is a management-account-scoped
10 * global service, so the binding takes no resource argument. Provide the
11 * implementation with `Effect.provide(AWS.Organizations.ListPoliciesHttp)`.
12 * ### Policies & Effective Policy
13 * **Example:** List Service Control Policies
14 * ```typescript
15 * // init — account-level binding, no resource argument
16 * const listPolicies = yield* AWS.Organizations.ListPolicies();
17 *
18 * // runtime
19 * const { Policies } = yield* listPolicies({ Filter: "SERVICE_CONTROL_POLICY" });
20 * ```
21 *
22 * @binding
23 */
24 export interface ListPolicies extends Binding.Service<
25 ListPolicies,
26 "AWS.Organizations.ListPolicies",
27 () => Effect.Effect<
28 (
29 request: organizations.ListPoliciesRequest,
30 ) => Effect.Effect<organizations.ListPoliciesResponse, organizations.ListPoliciesError>
31 >
32 > {}
33 export const ListPolicies = Binding.Service<ListPolicies>("AWS.Organizations.ListPolicies");