1import type * as imagebuilder from "@distilled.cloud/aws/imagebuilder";
2import type * as Effect from "effect/Effect";
3import * as Binding from "../../Binding.ts";
4import type { ImagePipeline } from "./ImagePipeline.ts";
5
6/**
7 * Runtime binding for `imagebuilder:StartImagePipelineExecution`.
8 *
9 * Manually kicks off a build of the bound {@link ImagePipeline} — the
10 * pipeline's ARN is injected and the idempotency `clientToken` is generated
11 * automatically. Returns the `imageBuildVersionArn` of the image being
12 * created, for use with `GetImage` / `CancelImageCreation`. Provide the
13 * implementation with
14 * `Effect.provide(AWS.ImageBuilder.StartImagePipelineExecutionHttp)`.
15 * ### Running Builds
16 * **Example:** Start a Build of the Bound Pipeline
17 * ```typescript
18 * // init — bind the operation to the pipeline
19 * const startBuild = yield* AWS.ImageBuilder.StartImagePipelineExecution(
20 * pipeline,
21 * );
22 *
23 * // runtime
24 * const { imageBuildVersionArn } = yield* startBuild();
25 * yield* Effect.log(`building ${imageBuildVersionArn}`);
26 * ```
27 *
28 * @binding
29 */
30export interface StartImagePipelineExecution extends Binding.Service<
31 StartImagePipelineExecution,
32 "AWS.ImageBuilder.StartImagePipelineExecution",
33 (
34 pipeline: ImagePipeline,
35 ) => Effect.Effect<
36 (
37 request?: Omit<
38 imagebuilder.StartImagePipelineExecutionRequest,
39 "imagePipelineArn" | "clientToken"
40 >,
41 ) => Effect.Effect<
42 imagebuilder.StartImagePipelineExecutionResponse,
43 imagebuilder.StartImagePipelineExecutionError
44 >
45 >
46> {}
47export const StartImagePipelineExecution =
48 Binding.Service<StartImagePipelineExecution>(
49 "AWS.ImageBuilder.StartImagePipelineExecution",
50 );