@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, 07:15 UTC

main
ts 22 lines 551 Bytes
Raw
1 import * as AWS from "@alchemy.run/aws";
2 import * as Effect from "effect/Effect";
3
4 // #region show
5 export default AWS.Lambda.Function(
6 "Archive",
7 { main: import.meta.url },
8 Effect.gen(function* () {
9 const source = yield* AWS.Kinesis.Stream("Messages");
10
11 yield* AWS.Kinesis.consumeStreamRecords(
12 source,
13 { startingPosition: "LATEST" },
14 Effect.fn(function* (event) {
15 yield* Effect.log(event.Records);
16 }),
17 );
18
19 return {};
20 }).pipe(Effect.provide(AWS.Lambda.StreamEventSource)),
21 );
22 // #endregion show