Skip to main content

StepOutcome

@forge/monorepo


@forge/monorepo / backend/src / StepOutcome

Type Alias: StepOutcome

StepOutcome = { costMinorUnits?: number; kind: "ok"; value?: unknown; } | { costMinorUnits?: number; error: string; kind: "failed"; } | { interactionId: string; kind: "parked"; } | { kind: "parked-on-run"; member?: string; runId: string; } | { kind: "resumed"; value?: unknown; }

Defined in: backend/src/flows/interpreter.ts:72

What the host reports back. advance is called again with it.

Union Members

Type Literal

{ costMinorUnits?: number; kind: "ok"; value?: unknown; }


Type Literal

{ costMinorUnits?: number; error: string; kind: "failed"; }


Type Literal

{ interactionId: string; kind: "parked"; }

A checkpoint was raised and is now parked. Carries what to resume on.


Type Literal

{ kind: "parked-on-run"; member?: string; runId: string; }

An agent step became a child run, which is now queued — #202.

Distinct from parked because what resumes it is different: a person answers a parked step, and a run finishing resumes this one. Collapsing them would mean the runner could not tell which of the two it was waiting for, and the poll-on-resume path needs to know there is a run to look at.


Type Literal

{ kind: "resumed"; value?: unknown; }

A human answered, or a signal arrived.