onToolCallStarting
suspend fun onToolCallStarting(eventId: String, executionInfo: AgentExecutionInfo, runId: String, toolCallId: String?, toolName: String, toolDescription: String?, toolArgs: JsonObject, context: AIAgentContext)(source)
Notifies all registered tool handlers when a tool is called.
Parameters
eventId
The unique identifier for the current event.
executionInfo
The execution information for the tool call event
runId
The unique identifier for the current run.
toolCallId
The unique identifier for the current tool call.
toolName
The tool name that is being called
toolDescription
The description of the tool that is being called.
toolArgs
The arguments provided to the tool
context
The AI agent context in which the tool call is being executed.