Agents 1.6.9
Edge AI Agents SDK
Loading...
Searching...
No Matches
agents::ToolCall Struct Reference

A single tool call emitted by an LLM. More...

#include <types.h>

Public Member Functions

 ToolCall (std::string id_, std::string name_, JsonObject arguments_)
 Construct a new Tool Call object.
 ToolCall (std::string id_, std::string name_, JsonObject arguments_, std::string signature_)
 Construct a new Tool Call object.

Public Attributes

std::string id
 tool id.
std::string name
 tool name.
JsonObject arguments
 tool arguments.
std::string signature
 Opaque provider-specific token that must round-trip with the tool call when echoed back to the LLM in subsequent turns.

Detailed Description

A single tool call emitted by an LLM.

Note
id is the call identifier returned by the LLM. It must be echoed back in the matching tool-result message's tool_call_id so the model can thread results to calls. Some providers (e.g. Gemini) don't return an id; adapters synthesize one (e.g. "call_<n>") in that case.

Constructor & Destructor Documentation

◆ ToolCall() [1/2]

agents::ToolCall::ToolCall ( std::string id_,
std::string name_,
JsonObject arguments_ )
inline

Construct a new Tool Call object.

Parameters
id_tool id.
name_tool name.
arguments_tool args.

◆ ToolCall() [2/2]

agents::ToolCall::ToolCall ( std::string id_,
std::string name_,
JsonObject arguments_,
std::string signature_ )
inline

Construct a new Tool Call object.

Parameters
id_tool id.
name_tool name.
arguments_tool args.
signature_tool signature.

Member Data Documentation

◆ signature

std::string agents::ToolCall::signature

Opaque provider-specific token that must round-trip with the tool call when echoed back to the LLM in subsequent turns.

Note
Currently only populated by Gemini (thoughtSignature). Other adapters leave it empty and ignore it on serialization.