@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 36 lines 1.16 KB
Raw
1 import type * as deadline from "@distilled.cloud/aws/deadline";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Queue } from "./Queue.ts";
5
6 /**
7 * Runtime binding for `deadline:ListSessions`.
8 *
9 * Enumerates the worker sessions of a job in the bound {@link Queue}
10 * (paginated). The queue's `farmId`/`queueId` are injected from the
11 * binding. Provide the implementation with
12 * `Effect.provide(AWS.Deadline.ListSessionsHttp)`.
13 * ### Monitoring Sessions
14 * **Example:** List A Job's Sessions
15 * ```typescript
16 * // init — bind the operation to the queue
17 * const listSessions = yield* AWS.Deadline.ListSessions(queue);
18 *
19 * // runtime
20 * const { sessions } = yield* listSessions({ jobId });
21 * ```
22 *
23 * @binding
24 */
25 export interface ListSessions extends Binding.Service<
26 ListSessions,
27 "AWS.Deadline.ListSessions",
28 (
29 queue: Queue,
30 ) => Effect.Effect<
31 (
32 request: Omit<deadline.ListSessionsRequest, "farmId" | "queueId">,
33 ) => Effect.Effect<deadline.ListSessionsResponse, deadline.ListSessionsError>
34 >
35 > {}
36 export const ListSessions = Binding.Service<ListSessions>("AWS.Deadline.ListSessions");