The best way to control Claude Code, Codex and more from any computer or phone

main
ts 41 lines 1.37 KB
Raw
1 import type * as transcribe from "@distilled.cloud/aws/transcribe";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4
5 /**
6 * Runtime binding for `transcribe:GetTranscriptionJob` — read the status and
7 * result of a batch transcription job started with
8 * {@link StartTranscriptionJob}.
9 *
10 * Account-scoped (no resource to manage): the binding takes no arguments and
11 * grants the function `transcribe:GetTranscriptionJob` (the action has no
12 * resource-level IAM). Poll `TranscriptionJob.TranscriptionJobStatus` until
13 * it reaches `COMPLETED` or `FAILED`.
14 *
15 * ### Polling a Transcription Job
16 * **Example:** Poll a Job to Completion
17 * ```typescript
18 * // init
19 * const getJob = yield* AWS.Transcribe.GetTranscriptionJob();
20 *
21 * // runtime
22 * const { TranscriptionJob } = yield* getJob({
23 * TranscriptionJobName: "my-job",
24 * });
25 * const status = TranscriptionJob?.TranscriptionJobStatus;
26 * ```
27 *
28 * @binding
29 */
30 export interface GetTranscriptionJob extends Binding.Service<
31 GetTranscriptionJob,
32 "AWS.Transcribe.GetTranscriptionJob",
33 () => Effect.Effect<
34 (
35 request: transcribe.GetTranscriptionJobRequest,
36 ) => Effect.Effect<transcribe.GetTranscriptionJobResponse, transcribe.GetTranscriptionJobError>
37 >
38 > {}
39 export const GetTranscriptionJob = Binding.Service<GetTranscriptionJob>(
40 "AWS.Transcribe.GetTranscriptionJob",
41 );