agentLoop property

AgentSdkAgentLoop? agentLoop
final

Claude Code's own agent loop for every request, or null for none (plain completions and the request's own tools).

With a loop, the tool calls Claude Code makes are recorded in the trails and left out of the run's stream: they are the far end's to run, and a caller reading LlmToolCalls as calls to make must not see them.

Implementation

final AgentSdkAgentLoop? agentLoop;