A wrapper around the user defined fn handler function.
fn
Callers pass values accepted by inputSchema (z.input). The wrapper parses input, invokes fn, parses output, and returns z.infer<outputSchema>.
inputSchema
z.input
z.infer<outputSchema>
The second argument is a WorkflowInvocationOptions object, allowing workflows configuration overwrite.
The workflow input before inputSchema parse.
Additional options for the invocation.
The workflow output after outputSchema parse.
outputSchema
A wrapper around the user defined
fnhandler function.Callers pass values accepted by
inputSchema(z.input). The wrapper parses input, invokesfn, parses output, and returnsz.infer<outputSchema>.The second argument is a WorkflowInvocationOptions object, allowing workflows configuration overwrite.