| 1 | import type * as SVC from "@distilled.cloud/aws/codebuild"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { Project } from "./Project.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for `codebuild:BatchDeleteBuilds` — deletes builds of |
| 8 | * the bound project by id. Builds that cannot be deleted are returned in |
| 9 | * `buildsNotDeleted` with a reason rather than failing the call. |
| 10 | * ### Deleting Builds |
| 11 | * **Example:** Delete Old Builds |
| 12 | * ```typescript |
| 13 | * const batchDeleteBuilds = yield* AWS.CodeBuild.BatchDeleteBuilds(project); |
| 14 | * |
| 15 | * const { buildsDeleted, buildsNotDeleted } = yield* batchDeleteBuilds({ |
| 16 | * ids: oldBuildIds, |
| 17 | * }); |
| 18 | * ``` |
| 19 | * |
| 20 | * @binding |
| 21 | */ |
| 22 | export interface BatchDeleteBuilds extends Binding.Service< |
| 23 | BatchDeleteBuilds, |
| 24 | "AWS.CodeBuild.BatchDeleteBuilds", |
| 25 | <P extends Project>( |
| 26 | project: P, |
| 27 | ) => Effect.Effect< |
| 28 | ( |
| 29 | request: SVC.BatchDeleteBuildsInput, |
| 30 | ) => Effect.Effect<SVC.BatchDeleteBuildsOutput, SVC.BatchDeleteBuildsError> |
| 31 | > |
| 32 | > {} |
| 33 | export const BatchDeleteBuilds = Binding.Service<BatchDeleteBuilds>( |
| 34 | "AWS.CodeBuild.BatchDeleteBuilds", |
| 35 | ); |