Type alias FunctionToolsExecutedEvent

FunctionToolsExecutedEvent: {
    createdAt: number;
    functionCallOutputs: FunctionCallOutput[];
    functionCalls: FunctionCall[];
    hasAgentHandoff: boolean;
    hasToolReply: boolean;
    type: "function_tools_executed";
    cancelAgentHandoff(): void;
    cancelToolReply(): void;
}

Type declaration

  • createdAt: number
  • functionCallOutputs: FunctionCallOutput[]
  • functionCalls: FunctionCall[]

    Function calls and outputs are parallel arrays: the output at a given index belongs to the call at the same index, and its callId matches the paired function call's callId.

  • Readonly hasAgentHandoff: boolean

    Whether a tool in this batch hands off to another agent that will start.

  • Readonly hasToolReply: boolean

    Whether any output in this batch asks the model to reply.

  • type: "function_tools_executed"
  • cancelAgentHandoff:function
    • Keep the current agent: the handoff returned by a tool in this batch does not start.

      Returns void

  • cancelToolReply:function
    • Ask the model not to reply to this batch. Each output is still delivered, since a realtime model holds the call open until it is answered.

      Returns void