"pending" - The subagent has been invoked but hasn't started processing yet.
This is the initial state when a tool call is detected but before any
streaming events are received from the subgraph.
"running" - The subagent is actively executing and streaming updates.
The subagent transitions to this state when the first update event is
received from its namespace.
"complete" - The subagent has finished execution successfully.
A tool message with the result has been received, and the result
property contains the final output.
"error" - The subagent encountered an error during execution.
The error property on the SubagentStream contains error details.
The execution status of a subagent.
"pending"- The subagent has been invoked but hasn't started processing yet. This is the initial state when a tool call is detected but before any streaming events are received from the subgraph."running"- The subagent is actively executing and streaming updates. The subagent transitions to this state when the first update event is received from its namespace."complete"- The subagent has finished execution successfully. A tool message with the result has been received, and theresultproperty contains the final output."error"- The subagent encountered an error during execution. Theerrorproperty on the SubagentStream contains error details.