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

main
ts 40 lines 1.35 KB
Raw
1 import * as sns from "@distilled.cloud/aws/sns";
2 import * as Binding from "alchemy/Binding";
3 import * as Effect from "effect/Effect";
4
5 export interface ListSubscriptionsRequest extends sns.ListSubscriptionsInput {}
6
7 /**
8 * Runtime binding for `sns:ListSubscriptions`.
9 *
10 * An account-scoped operation — bind it with no arguments to page through
11 * all subscriptions in the account/region. The binding grants the host
12 * function `sns:ListSubscriptions`. Provide the `ListSubscriptionsHttp`
13 * layer on the Function to implement the binding.
14 *
15 * To list only the subscriptions of one topic, use
16 * {@link ListSubscriptionsByTopic}.
17 * ### Listing Subscriptions
18 * **Example:** List All Subscriptions
19 * ```typescript
20 * // init (provide SNS.ListSubscriptionsHttp on the Function)
21 * const listSubscriptions = yield* SNS.ListSubscriptions();
22 *
23 * // runtime: pass NextToken to page through large accounts
24 * const response = yield* listSubscriptions();
25 * // response.Subscriptions
26 * ```
27 *
28 * @binding
29 */
30 export interface ListSubscriptions extends Binding.Service<
31 ListSubscriptions,
32 "AWS.SNS.ListSubscriptions",
33 () => Effect.Effect<
34 (
35 request?: ListSubscriptionsRequest,
36 ) => Effect.Effect<sns.ListSubscriptionsResponse, sns.ListSubscriptionsError>
37 >
38 > {}
39
40 export const ListSubscriptions = Binding.Service<ListSubscriptions>("AWS.SNS.ListSubscriptions");