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

main
ts 38 lines 1.35 KB
Raw
1 import type * as r53r from "@distilled.cloud/aws/route53resolver";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { ResolverEndpoint } from "./ResolverEndpoint.ts";
5
6 /**
7 * Runtime binding for `route53resolver:GetResolverEndpoint` — read the bound
8 * {@link ResolverEndpoint}'s live state (status, IP address count, host VPC,
9 * protocols); the endpoint ID is injected automatically.
10 *
11 * Provide `Route53Resolver.GetResolverEndpointHttp` on the hosting Lambda
12 * Function to satisfy the requirement.
13 * ### Reading Endpoint State
14 * **Example:** Read the Endpoint Status
15 * ```typescript
16 * // init — grants route53resolver:GetResolverEndpoint on the endpoint
17 * const getEndpoint = yield* AWS.Route53Resolver.GetResolverEndpoint(endpoint);
18 *
19 * // runtime
20 * const { ResolverEndpoint } = yield* getEndpoint();
21 * console.log(ResolverEndpoint?.Status, ResolverEndpoint?.IpAddressCount);
22 * ```
23 *
24 * @binding
25 */
26 export interface GetResolverEndpoint extends Binding.Service<
27 GetResolverEndpoint,
28 "AWS.Route53Resolver.GetResolverEndpoint",
29 (
30 endpoint: ResolverEndpoint,
31 ) => Effect.Effect<
32 () => Effect.Effect<r53r.GetResolverEndpointResponse, r53r.GetResolverEndpointError>
33 >
34 > {}
35
36 export const GetResolverEndpoint = Binding.Service<GetResolverEndpoint>(
37 "AWS.Route53Resolver.GetResolverEndpoint",
38 );