Skip to content

Rulvar API reference


Rulvar API reference / @rulvar/rulvar / Workflow

Interface: Workflow<A, R>

Defined in: packages/core/dist/index.d.ts

Closure-form workflow value; in-process only.

Type Parameters

Type ParameterDefault type
Aunknown
Runknown

Properties

PropertyModifierTypeDescriptionDefined in
argsSchema?readonlySchemaSpec<A>-packages/core/dist/index.d.ts
bodyreadonly(ctx, args) => Promise<R>-packages/core/dist/index.d.ts
effort?readonlyEffort-packages/core/dist/index.d.ts
errorPolicyreadonlyErrorPolicy-packages/core/dist/index.d.ts
kindreadonly"workflow"-packages/core/dist/index.d.ts
model?readonlyModelSpecWorkflow defaults: the third layer of the resolution chain, under the call override and the agent profile and over the engine defaults. A workflow that declares nothing contributes no layer and resolves exactly as it did before. The layer follows the CALL TREE, not the file: a child spawned through ctx.workflow contributes ITS OWN defaults inside its scope, so nesting a cheap workflow under an expensive one does the obvious thing.packages/core/dist/index.d.ts
namereadonlystring-packages/core/dist/index.d.ts
routing?readonlyPartial<Record<InvocationRole, ModelSpec>>-packages/core/dist/index.d.ts