本页还没有译文
本页 48 段还没译成Português (BR),下面显示的是英文原文。WorkflowDefinition
还没翻译译自英文(tanstack.com)本页 48 段都还没译
Interface: WorkflowDefinition<TInput, TOutput, TState>
Defined in: packages/workflow-core/src/types.ts:415
Type Parameters
TInput
TInput = unknown
TOutput
TOutput = unknown
TState
TState = Record<string, unknown>
Properties
__kind
__kind: "workflow";Defined in: packages/workflow-core/src/types.ts:420
defaultStepRetry?
optional defaultStepRetry: StepRetryOptions;Defined in: packages/workflow-core/src/types.ts:434
description?
optional description: string;Defined in: packages/workflow-core/src/types.ts:422
handler()
handler: (ctx) => Promise<TOutput>;Defined in: packages/workflow-core/src/types.ts:436
Parameters
ctx
any
Returns
Promise<TOutput>
id
id: string;Defined in: packages/workflow-core/src/types.ts:421
initialize()?
optional initialize: (args) => Partial<TState>;Defined in: packages/workflow-core/src/types.ts:433
Parameters
args
input
TInput
Returns
Partial<TState>
inputSchema?
optional inputSchema: SchemaInput;Defined in: packages/workflow-core/src/types.ts:430
middlewares
middlewares: readonly AnyMiddleware[];Defined in: packages/workflow-core/src/types.ts:435
outputSchema?
optional outputSchema: SchemaInput;Defined in: packages/workflow-core/src/types.ts:431
previousVersions?
optional previousVersions: readonly WorkflowDefinition<any, any, any>[];Defined in: packages/workflow-core/src/types.ts:429
Older versions of this workflow that may still have in-flight
runs. The engine routes a run's resume call to the version whose
identifier matches the run's persisted workflowVersion.
stateSchema?
optional stateSchema: SchemaInput;Defined in: packages/workflow-core/src/types.ts:432
version?
optional version: string;Defined in: packages/workflow-core/src/types.ts:425
Caller-supplied version identifier. Used with previousVersions
and selectWorkflowVersion for cross-version routing.