#[non_exhaustive]pub struct Step {Show 18 fields
pub id: Uuid,
pub run_id: Uuid,
pub name: String,
pub kind: StepKind,
pub position: u32,
pub status: FsmState<StepStatus>,
pub input: Option<Value>,
pub output: Option<Value>,
pub error: Option<String>,
pub duration_ms: u64,
pub cost_usd: Decimal,
pub input_tokens: Option<u64>,
pub output_tokens: Option<u64>,
pub created_at: DateTime<Utc>,
pub updated_at: DateTime<Utc>,
pub started_at: Option<DateTime<Utc>>,
pub completed_at: Option<DateTime<Utc>>,
pub debug_messages: Option<Value>,
}Expand description
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: UuidUnique identifier (UUIDv7).
run_id: UuidThe run this step belongs to.
name: StringHuman-readable step name (e.g. “build”, “test”, “review”).
kind: StepKindThe type of operation.
position: u32Execution wave within the run (0-based).
In linear flows, this strictly increases (0, 1, 2, …).
In DAGs with parallel execution, steps at the same wave share
the same position and execute concurrently. Use
step_dependencies to determine the actual execution order.
status: FsmState<StepStatus>Current FSM status — embeds state + state_machine_id for SQL-side transitions.
input: Option<Value>Serialized operation configuration.
output: Option<Value>Serialized operation output.
error: Option<String>Error message if the step failed.
duration_ms: u64Wall-clock execution duration in milliseconds.
cost_usd: DecimalCost in USD (agent steps only).
input_tokens: Option<u64>Input token count (agent steps only).
output_tokens: Option<u64>Output token count (agent steps only).
created_at: DateTime<Utc>When the step was created.
updated_at: DateTime<Utc>When the step record was last updated.
started_at: Option<DateTime<Utc>>When step execution started.
completed_at: Option<DateTime<Utc>>When step execution finished.
debug_messages: Option<Value>Debug messages (verbose conversation trace), stored as JSON.