| 1 | import type * as auditmanager from "@distilled.cloud/aws/auditmanager"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { Assessment } from "./Assessment.ts"; |
| 5 | |
| 6 | /** `BatchCreateDelegationByAssessment` request with `assessmentId` injected from the bound {@link Assessment}. */ |
| 7 | export interface BatchCreateDelegationByAssessmentRequest extends Omit< |
| 8 | auditmanager.BatchCreateDelegationByAssessmentRequest, |
| 9 | "assessmentId" |
| 10 | > {} |
| 11 | |
| 12 | /** |
| 13 | * Runtime binding for `auditmanager:BatchCreateDelegationByAssessment`. |
| 14 | * |
| 15 | * Creates a batch of delegations — handing control sets of the bound |
| 16 | * assessment to reviewers. Provide the |
| 17 | * implementation with `Effect.provide(AWS.AuditManager.BatchCreateDelegationByAssessmentHttp)`. |
| 18 | * ### Delegations |
| 19 | * **Example:** Delegate Control Sets for Review |
| 20 | * ```typescript |
| 21 | * const batchCreateDelegationByAssessment = yield* AWS.AuditManager.BatchCreateDelegationByAssessment(assessment); |
| 22 | * const result = yield* batchCreateDelegationByAssessment({ |
| 23 | * createDelegationRequests: [{ |
| 24 | * roleArn: reviewerRoleArn, |
| 25 | * roleType: "RESOURCE_OWNER", |
| 26 | * controlSetId, |
| 27 | * }], |
| 28 | * }); |
| 29 | * ``` |
| 30 | * |
| 31 | * @binding |
| 32 | */ |
| 33 | export interface BatchCreateDelegationByAssessment extends Binding.Service< |
| 34 | BatchCreateDelegationByAssessment, |
| 35 | "AWS.AuditManager.BatchCreateDelegationByAssessment", |
| 36 | ( |
| 37 | assessment: Assessment, |
| 38 | ) => Effect.Effect< |
| 39 | ( |
| 40 | request: BatchCreateDelegationByAssessmentRequest, |
| 41 | ) => Effect.Effect< |
| 42 | auditmanager.BatchCreateDelegationByAssessmentResponse, |
| 43 | auditmanager.BatchCreateDelegationByAssessmentError |
| 44 | > |
| 45 | > |
| 46 | > {} |
| 47 | |
| 48 | export const BatchCreateDelegationByAssessment = |
| 49 | Binding.Service<BatchCreateDelegationByAssessment>( |
| 50 | "AWS.AuditManager.BatchCreateDelegationByAssessment", |
| 51 | ); |