@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.26 KB
Raw
1 import type * as osis from "@distilled.cloud/aws/osis";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Pipeline } from "./Pipeline.ts";
5
6 /**
7 * Runtime binding for `osis:GetPipeline`.
8 *
9 * Reads the bound {@link Pipeline}'s live detail — status, capacity, ingest
10 * endpoint URLs, and destinations — so an ops function can health-check the
11 * pipeline or discover its ingest endpoints at runtime. The pipeline name is
12 * injected from the binding. Provide the implementation with
13 * `Effect.provide(AWS.OSIS.GetPipelineHttp)`.
14 * ### Monitoring a Pipeline
15 * **Example:** Check the Pipeline's Status
16 * ```typescript
17 * // init — bind the operation to the pipeline
18 * const getPipeline = yield* AWS.OSIS.GetPipeline(pipeline);
19 *
20 * // runtime
21 * const { Pipeline } = yield* getPipeline();
22 * if (Pipeline?.Status !== "ACTIVE") {
23 * yield* Effect.logWarning(`pipeline is ${Pipeline?.Status}`);
24 * }
25 * ```
26 *
27 * @binding
28 */
29 export interface GetPipeline extends Binding.Service<
30 GetPipeline,
31 "AWS.OSIS.GetPipeline",
32 (
33 pipeline: Pipeline,
34 ) => Effect.Effect<() => Effect.Effect<osis.GetPipelineResponse, osis.GetPipelineError>>
35 > {}
36 export const GetPipeline = Binding.Service<GetPipeline>("AWS.OSIS.GetPipeline");