import type { SmithersWorkflow } from "@smthrs/components/SmithersWorkflow"; import type { RunOptions } from "@smthrs/driver/RunOptions"; import type { RunResult } from "@smthrs/driver/RunResult"; import type { SmithersWorkflowOptions } from "@smthrs/scheduler/SmithersWorkflowOptions"; import type { CreateSmithersApi } from "../CreateSmithersApi.ts"; import type { HostNodeJson } from "./HostNodeJson.ts"; import type { SerializedCtx } from "./SerializedCtx.ts"; import type { z } from "zod"; export type ExternalSmithersEngine>> = { readonly api: CreateSmithersApi; workflow(buildFn: (ctx: SerializedCtx) => HostNodeJson, options?: SmithersWorkflowOptions): SmithersWorkflow; /** Runs reject on `failed`; the thrown SmithersError retains its nested `cause` chain. */ run( workflow: SmithersWorkflow, options: Omit, ): Promise; close(): Promise; };