@devries-cameron20 / t3code Mirror · read-only
Fork 0

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

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 06:00 UTC

main
ts 34 lines 1.09 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 PublishSmsRequest extends Omit<sns.PublishInput, "TopicArn" | "TargetArn"> {}
6
7 /**
8 * Runtime binding for `sns:Publish`.
9 *
10 * Runtime binding for direct SMS delivery with `sns:Publish` — send a text
11 * message straight to a phone number without a topic. Accounts start in the
12 * SMS sandbox, where only verified destination numbers are deliverable.
13 * Provide the `PublishSmsHttp` layer on the Function to implement the binding.
14 * ### Sending SMS
15 * **Example:** Send a Text Message
16 * ```typescript
17 * const publishSms = yield* SNS.PublishSms();
18 * yield* publishSms({
19 * PhoneNumber: "+15555550123",
20 * Message: "Your code is 123456",
21 * });
22 * ```
23 *
24 * @binding
25 */
26 export interface PublishSms extends Binding.Service<
27 PublishSms,
28 "AWS.SNS.PublishSms",
29 () => Effect.Effect<
30 (request: PublishSmsRequest) => Effect.Effect<sns.PublishResponse, sns.PublishError>
31 >
32 > {}
33
34 export const PublishSms = Binding.Service<PublishSms>("AWS.SNS.PublishSms");