Skip to content

toolCalls

toolCalls(run): ToolCall[]

Returns every tool call observed in a normalized run or session.

Tool results are joined from matching tool_result transcript events when the transcript contains a result for the call.

HarnessRun

ToolCall[]

const names = toolCalls(result).map((call) => call.name);
expect(names).toEqual(["lookupInvoice", "createRefund"]);

toolCalls(session): ToolCall[]

Returns every tool call observed in a normalized run or session.

Tool results are joined from matching tool_result transcript events when the transcript contains a result for the call.

NormalizedSession

ToolCall[]

const names = toolCalls(result).map((call) => call.name);
expect(names).toEqual(["lookupInvoice", "createRefund"]);