/** * Server-side layers for workflow proxy APIs. * * `layerHttpApi` connects the HTTP API group created by `WorkflowProxy` to the * supplied workflows. `layerRpcHandlers` does the same for the generated RPC * definitions. Both layers route execute, discard, and resume requests to the * matching workflow operation, while the `WorkflowEngine` and workflow handler * services stay on the server side. * * @stability unstable * @since 4.0.0 */ import type { NonEmptyReadonlyArray } from "../Array.ts"; import type * as HttpApi from "../http-api/HttpApi.ts"; import type * as HttpApiGroup from "../http-api/HttpApiGroup.ts"; import * as Layer from "../Layer.ts"; import type * as Rpc from "../rpc/Rpc.ts"; import type * as Workflow from "./Workflow.ts"; import type { WorkflowEngine } from "./WorkflowEngine.ts"; /** * Creates handlers for a workflow HTTP API group, wiring execute, discard, and * resume endpoints to the supplied workflows. * * @stability unstable * @category layers * @since 4.0.0 */ export declare const layerHttpApi: , const Workflows extends NonEmptyReadonlyArray>(api: HttpApi.HttpApi, identifier: Identifier, workflows: Workflows) => Layer.Layer, never, WorkflowEngine | Workflow.RequirementsHandler>; /** * Creates RPC handlers for the supplied workflows, wiring execute, discard, * and resume RPCs to workflow operations. * * @stability unstable * @category layers * @since 4.0.0 */ export declare const layerRpcHandlers: , const Prefix extends string = "">(workflows: Workflows, options?: { readonly prefix?: Prefix; }) => Layer.Layer, never, WorkflowEngine | Workflow.RequirementsHandler>; /** * Union of RPC handler services required to serve the generated workflow * execute, discard, and resume RPCs. * * @stability unstable * @category services * @since 4.0.0 */ export type RpcHandlers = Workflows extends Workflow.Workflow ? Rpc.Handler<`${Prefix}${_Name}`> | Rpc.Handler<`${Prefix}${_Name}Discard`> | Rpc.Handler<`${Prefix}${_Name}Resume`> : never; //# sourceMappingURL=WorkflowProxyServer.d.ts.map