| 1 | import type * as SVC from "@distilled.cloud/aws/codedeploy"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { DeploymentGroup } from "./DeploymentGroup.ts"; |
| 5 | |
| 6 | /** |
| 7 | * Runtime binding for `codedeploy:GetDeploymentTarget` — reads one |
| 8 | * deployment target (instance, Lambda function, or ECS task set) of a |
| 9 | * deployment, including per-lifecycle-event status. |
| 10 | * ### Observing Deployment Targets |
| 11 | * **Example:** Read a Target's Status |
| 12 | * ```typescript |
| 13 | * const getDeploymentTarget = yield* AWS.CodeDeploy.GetDeploymentTarget(group); |
| 14 | * |
| 15 | * const { deploymentTarget } = yield* getDeploymentTarget({ |
| 16 | * deploymentId, |
| 17 | * targetId, |
| 18 | * }); |
| 19 | * ``` |
| 20 | * |
| 21 | * @binding |
| 22 | */ |
| 23 | export interface GetDeploymentTarget extends Binding.Service< |
| 24 | GetDeploymentTarget, |
| 25 | "AWS.CodeDeploy.GetDeploymentTarget", |
| 26 | <G extends DeploymentGroup>( |
| 27 | group: G, |
| 28 | ) => Effect.Effect< |
| 29 | ( |
| 30 | request: SVC.GetDeploymentTargetInput, |
| 31 | ) => Effect.Effect< |
| 32 | SVC.GetDeploymentTargetOutput, |
| 33 | SVC.GetDeploymentTargetError |
| 34 | > |
| 35 | > |
| 36 | > {} |
| 37 | export const GetDeploymentTarget = Binding.Service<GetDeploymentTarget>( |
| 38 | "AWS.CodeDeploy.GetDeploymentTarget", |
| 39 | ); |