Skip to main content

Interface: ToolCallSegment

Defined in: packages/core/src/stream-segments/types.ts:37

Tool call segment (covers full lifecycle)

Extends

Properties

agentId?

optional agentId?: string

Defined in: packages/core/src/stream-segments/types.ts:20

Agent that produced this segment (populated in group chat contexts)

Inherited from

BaseSegment.agentId


agentName?

optional agentName?: string

Defined in: packages/core/src/stream-segments/types.ts:22

Display name of the agent

Inherited from

BaseSegment.agentName


args?

optional args?: unknown

Defined in: packages/core/src/stream-segments/types.ts:44

Parsed arguments passed to the tool


avatarEmoji?

optional avatarEmoji?: string

Defined in: packages/core/src/stream-segments/types.ts:24

Avatar emoji for display

Inherited from

BaseSegment.avatarEmoji


childSegments?

optional childSegments?: StreamSegment[]

Defined in: packages/core/src/stream-segments/types.ts:56

Child segments for recursive tool calls (spawn_agent, pipelines, etc.)


error?

optional error?: string

Defined in: packages/core/src/stream-segments/types.ts:52

Error message if the tool call failed


id

id: string

Defined in: packages/core/src/stream-segments/types.ts:16

Unique identifier for React keys

Inherited from

BaseSegment.id


name

name: string

Defined in: packages/core/src/stream-segments/types.ts:42

Tool function name (e.g. 'spawn_agent', 'search')


rawArgs?

optional rawArgs?: string

Defined in: packages/core/src/stream-segments/types.ts:46

Raw JSON arguments as streamed (unparsed)


result?

optional result?: unknown

Defined in: packages/core/src/stream-segments/types.ts:50

Return value from the tool execution


status

status: "completed" | "running" | "failed"

Defined in: packages/core/src/stream-segments/types.ts:54

Status for display


streamingOutput?

optional streamingOutput?: string

Defined in: packages/core/src/stream-segments/types.ts:48

Live streamed output chunks before final result


timestamp

timestamp: number

Defined in: packages/core/src/stream-segments/types.ts:18

Timestamp for ordering

Inherited from

BaseSegment.timestamp


toolCallId

toolCallId: string

Defined in: packages/core/src/stream-segments/types.ts:40

Provider-assigned identifier for this tool call


type

type: "tool_call"

Defined in: packages/core/src/stream-segments/types.ts:38