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

main
ts 45 lines 1.34 KB
Raw
1 import type * as datapipelines from "@distilled.cloud/gcp/datapipelines_v1";
2 import * as Binding from "alchemy/Binding";
3 import type { RuntimeContext } from "alchemy/RuntimeContext";
4 import type * as Effect from "effect/Effect";
5 import type { Pipeline } from "./Pipeline.ts";
6
7 export interface RunPipelineRequest extends Omit<
8 datapipelines.RunProjectsLocationsPipelinesRequest,
9 "name"
10 > {}
11
12 /**
13 * Runtime binding for Data Pipelines `pipelines.run`.
14 *
15 * Creates a job for the bound pipeline immediately. Use this when the
16 * internal scheduler is not configured. Bind in a Function/Action init
17 * phase and provide {@link RunPipelineHttp}.
18 *
19 * ### Running Pipelines
20 * **Example:** Run the bound pipeline now
21 * ```typescript
22 * const runPipeline = yield* GCP.DataPipelines.RunPipeline(batch);
23 * const response = yield* runPipeline();
24 * ```
25 *
26 * @binding
27 * @category DataPipelines
28 */
29 export interface RunPipeline extends Binding.Service<
30 RunPipeline,
31 "GCP.DataPipelines.RunPipeline",
32 (
33 pipeline: Pipeline,
34 ) => Effect.Effect<
35 (
36 request?: RunPipelineRequest,
37 ) => Effect.Effect<
38 datapipelines.GoogleCloudDatapipelinesV1RunPipelineResponse,
39 datapipelines.RunProjectsLocationsPipelinesError,
40 RuntimeContext
41 >
42 >
43 > {}
44
45 export const RunPipeline = Binding.Service<RunPipeline>("GCP.DataPipelines.RunPipeline");