Skip to content

js-bao-wss-client


js-bao-wss-client / WorkflowStatusResult

Interface: WorkflowStatusResult<O> ​

Workflow status response.

The optional generic O types output. It defaults to any, so every existing bare reference to WorkflowStatusResult still compiles and the runtime is unchanged (the generic is erased).

Type Parameters ​

O ​

O = any

Properties ​

error? ​

optional error?: WorkflowRunErrorWire | null

Why the run failed, exactly as the server sent it.

An OBJECT for every failed durable run, null on a read that has not failed, and a string on the older form. Branch on failure instead — it says the same thing whichever form arrived.


failure? ​

optional failure?: WorkflowRunError

The same error, normalized: message always, name when the wire carried one, and any remaining keys under details. Additive, and undefined when the run did not fail or the field was not one the client could read.


output? ​

optional output?: O


run? ​

optional run?: WorkflowRun


skipReason? ​

optional skipReason?: "LOCK_CONTENTION"

Why the run did not run, when status === "skipped".


slice? ​

optional slice?: WorkflowStatusSlice

The task slice's record, for a durable function run. Additive and present only when the run has one (a DSL run and a request invocation have none) and the client could read the block the server sent. refreshCount is how many times the slice's token was refreshed through the gateway instead of yielding to renew its budget.


status ​

status: WorkflowStatusValue

Documentation validated against js-bao-wss-client 3.4.0 · js-bao 0.11.0 · primitive-admin 1.0.62 · primitive-app 3.1.0 — 2026-09-30