| 1 | import type * as medicalimaging from "@distilled.cloud/aws/medical-imaging"; |
| 2 | import type * as Effect from "effect/Effect"; |
| 3 | import * as Binding from "../../Binding.ts"; |
| 4 | import type { Datastore } from "./Datastore.ts"; |
| 5 | |
| 6 | /** |
| 7 | * `GetImageSet` request with `datastoreId` injected from the bound data |
| 8 | * store. |
| 9 | */ |
| 10 | export interface GetImageSetRequest extends Omit< |
| 11 | medicalimaging.GetImageSetRequest, |
| 12 | "datastoreId" |
| 13 | > {} |
| 14 | |
| 15 | /** |
| 16 | * Runtime binding for the `GetImageSet` operation (IAM action |
| 17 | * `medical-imaging:GetImageSet`), scoped to one {@link Datastore}. |
| 18 | * |
| 19 | * Reads an image set's properties — state, workflow status, version and |
| 20 | * ARN. Pass `versionId` to read a specific version; omit it for the latest. |
| 21 | * Provide the implementation with |
| 22 | * `Effect.provide(AWS.MedicalImaging.GetImageSetHttp)`. |
| 23 | * |
| 24 | * ### Reading Image Sets |
| 25 | * **Example:** Read Image Set Properties |
| 26 | * ```typescript |
| 27 | * const getImageSet = yield* MedicalImaging.GetImageSet(datastore); |
| 28 | * |
| 29 | * const imageSet = yield* getImageSet({ imageSetId }); |
| 30 | * // imageSet.imageSetState === "ACTIVE", imageSet.versionId, imageSet.imageSetArn |
| 31 | * ``` |
| 32 | * |
| 33 | * @binding |
| 34 | */ |
| 35 | export interface GetImageSet extends Binding.Service< |
| 36 | GetImageSet, |
| 37 | "AWS.MedicalImaging.GetImageSet", |
| 38 | ( |
| 39 | datastore: Datastore, |
| 40 | ) => Effect.Effect< |
| 41 | ( |
| 42 | request: GetImageSetRequest, |
| 43 | ) => Effect.Effect< |
| 44 | medicalimaging.GetImageSetResponse, |
| 45 | medicalimaging.GetImageSetError |
| 46 | > |
| 47 | > |
| 48 | > {} |
| 49 | export const GetImageSet = Binding.Service<GetImageSet>( |
| 50 | "AWS.MedicalImaging.GetImageSet", |
| 51 | ); |