The server knows how to read a calibration and how to attempt approval. The inspector thinks in terms of a task: select a submitted calibration, inspect its content, and certify it if the review succeeds. A Journey connects those operations into a named caller-side description.
The full example contains inspectCalibration. Its actor is inspector. Its input is a reference to a calibration record constrained to the submitted state. Its first step gets the record; its second requests the approve transition. The output preserves the calibration identifier for a caller or subsequent task.
Give inputs enough meaning for a consumer
This input fragment is more informative than an untyped string:
calibrationId:
type: reference
references: "adl.calibration.calibration.CalibrationRecord"
required: true
inState: [submitted]
The address identifies the resource, and inState provides an entry-state assumption. A compiler can use that information to track the transition graph. An interface consumer can use it to build a worklist or picker. Neither consumer should treat the hint as a lock on the selected record; the server checks current state again when the request arrives.
Reference inputs also make dependencies visible. If a Journey refers to another domain, its compilation and execution depend on that model and its availability. Record the source versions used to build the artifact.
Read the compiled artifact
Run the current CLI from the repository root:
build/bin/Release/adl.exe --json journey validate \
docs/books/adl-0.6/handbook/examples/02-calibration.yaml
For this edition, the compiler reports one Journey, two steps, no errors or warnings, and the verdict proved. Its artifact includes the GET path, the approval path, entry and exit states, picker metadata, and worklist metadata. The generated JSON is retained with the book.
The verdict must be read in the compiler’s scope. It is not a promise that every runtime inspector can approve every selected record. Alice holds inspector authority but must be refused on her own submission. Bob must be refused when his training claim is missing. The runtime cases are not contradictions of the artifact; they expose dynamic facts that remain obligations at execution.
This pairing is one of the most useful examples in the book: a statically accepted task can still be correctly denied for a particular caller and record. A client should present that denial as a meaningful outcome, not assume the compiler has eliminated it.
A task description is not a transaction
Reading and approving are separate requests. The record can change, a session can expire, or the network can fail between them. The task runner must handle the response that actually arrives. A Journey describes control flow; it does not automatically turn a sequence of HTTP requests into one database transaction.
Longer tasks can branch, call sub-Journeys, or define failure behavior. Before adding retries, decide whether repeating the operation is safe. Retrying a read differs from retrying a payment or dispatch whose result was lost. Chapter 14 treats that uncertainty as an execution problem rather than a syntactic convenience.
Keep role changes tied to real credentials
A multi-role Journey can describe work performed by different actors. Naming the next actor is not authority to impersonate that actor. The runtime or caller must obtain the appropriate credential through the supported mechanism and keep it out of exposed inputs, logs, and generated descriptions.
The calibration example intentionally uses a single inspector actor. The preceding submission is created by the runtime lab under Alice’s own identity. The lab retrieves the Journey definition but does not execute the generic Journey runner or a browser console; those are separate verification targets.
The current Journeys specification, compiler, and CLI implementation provide the detailed forms and verdict aggregation.
Workshop
Change the approval call to a nonexistent transition in a working copy. Compare its compiler diagnostic with a runtime self-approval refusal from the valid Journey. Explain why one is a model error and the other is an authorization outcome for a concrete execution.