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

main
ts 39 lines 1.28 KB
Raw
1 import type * as entityresolution from "@distilled.cloud/aws/entityresolution";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { MatchingWorkflow } from "./MatchingWorkflow.ts";
5
6 /**
7 * Runtime binding for `entityresolution:GetMatchingJob`.
8 *
9 * Reads the status, metrics, and errors of a matching job run of the bound
10 * workflow. Provide the implementation with
11 * `Effect.provide(AWS.EntityResolution.GetMatchingJobHttp)`.
12 * ### Running Matching Jobs
13 * **Example:** Poll a Job's Status
14 * ```typescript
15 * // init — bind the operation to the workflow
16 * const getMatchingJob = yield* AWS.EntityResolution.GetMatchingJob(workflow);
17 *
18 * // runtime
19 * const job = yield* getMatchingJob({ jobId });
20 * console.log(job.status, job.metrics?.matchIDs);
21 * ```
22 *
23 * @binding
24 */
25 export interface GetMatchingJob extends Binding.Service<
26 GetMatchingJob,
27 "AWS.EntityResolution.GetMatchingJob",
28 (
29 workflow: MatchingWorkflow,
30 ) => Effect.Effect<
31 (
32 request: Omit<entityresolution.GetMatchingJobInput, "workflowName">,
33 ) => Effect.Effect<entityresolution.GetMatchingJobOutput, entityresolution.GetMatchingJobError>
34 >
35 > {}
36
37 export const GetMatchingJob = Binding.Service<GetMatchingJob>(
38 "AWS.EntityResolution.GetMatchingJob",
39 );