Skip to main content
This reference covers 0.14.0, building on the first executable-DSL milestone. The tutorial includes complete compiling examples.

Definition

Parallel branches and fan-out bodies return values to their enclosing join; they do not author independent success terminals. Choices inside them still support explicitly non-success paths. Empty continuing choice arms retain incoming data. Incomplete arms, unreachable work and ambiguous bindings refuse compilation.

Typed data

Step<I,O> declares input and output through a concrete class signature. Raw implementations and erased lambdas cannot provide these contracts. An unambiguous compatible whole value binds directly; otherwise a record input can combine legally visible values one level deep. The first Step’s declared input is the submitted root value, including a whole input record. Type arguments such as List<FileReview> remain part of the contract. Record component names do not select Step names. See Parameterization.

Registration and runtime

StepRegistry holds application-supplied objects. ExecutionCompatibility declares build/settings identity and observes codec/JDK compatibility; it does not archive implementation code. ExecutionPolicy separately bounds physical Step concurrency, attempts, depth and logical invocation count. DurableWorkflows.open(...) owns a local JDBC store. start(...) durably admits an idempotent submission; resume(...) drives or recovers the saved run. result(...) exposes its successful final value. The application supplies compatible definitions and dependencies after recovery. See Durability.

Fluent completion

Available since 0.14.0. This method is not available on the Sequence stage in 0.13.0.
0.14.0 adds build() to Workflows.Sequence for a final child that always fails or cancels. It adds no implicit terminal and does not permit dangling ordinary paths or unreachable successors. The final child’s explicit terminal closes the parent path; build() adds no implicit successful completion.

MCP servers for a Claude step

ClaudeStep (workflow-flows, a Step<String, String>) runs a Claude agentic loop. ClaudeStep.withMcp(McpConfig) adds an MCP server for that loop; McpConfig.of(name, serverConfig) takes a name and a Jackson-serializable server description, such as a Map with command and args:
The default client runs the claude CLI as a subprocess and writes the configured servers, keyed by name, to a temporary file passed with --mcp-config. A custom ClaudeSyncClient receives the configurations as an argument. The example is from the ClaudeStep Javadoc. This applies only to ClaudeStep: AgentClientStep passes no MCP configuration, so Agent Workflow has no portable MCP path through Agent Client. Available since 0.10.0, including 0.14.0.