A message within a conversation.
| JSON representation |
|---|
{
"role": string,
"chunks": [
{
object ( |
| Fields | |
|---|---|
role |
Optional. The role within the conversation, e.g., user, agent. |
chunks[] |
Optional. Content of the message as a series of chunks. |
eventTime |
Optional. Timestamp when the message was sent or received. Should not be used if the message is part of an Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
Chunk
A chunk of content within a message.
| JSON representation |
|---|
{ // The following is a list of mutually exclusive fields. At most one of the // fields will be set in a response: "text": string, "transcript": string, "blob": { object ( |
| Fields | |
|---|---|
| Chunk data. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
text |
Optional. Text data. |
transcript |
Optional. Transcript associated with the audio. |
blob |
Optional. Blob data. |
payload |
Optional. Custom payload data. |
image |
Optional. Image data. |
toolCall |
Optional. Tool execution request. |
toolResponse |
Optional. Tool execution response. |
agentTransfer |
Optional. Agent transfer event. |
updatedVariables |
A struct represents variables that were updated in the conversation, keyed by variable names. |
defaultVariables |
A struct represents default variables at the start of the conversation, keyed by variable names. |
| End of mutually exclusive fields. | |
Blob
Represents a blob input or output in the conversation.
| JSON representation |
|---|
{ "mimeType": string, "data": string } |
| Fields | |
|---|---|
mimeType |
Required. The IANA standard MIME type of the source data. |
data |
Required. Raw bytes of the blob. A base64-encoded string. |
Image
Represents an image input or output in the conversation.
| JSON representation |
|---|
{ "mimeType": string, "data": string, "altText": string } |
| Fields | |
|---|---|
mimeType |
Required. The IANA standard MIME type of the source data. Supported image types includes: * image/png * image/jpeg * image/webp |
data |
Required. Raw bytes of the image. A base64-encoded string. |
altText |
Optional. The alternative text for the image. |
ToolCall
Request for the client or the agent to execute the specified tool.
| JSON representation |
|---|
{
"id": string,
"displayName": string,
"args": {
object
},
"parentToolCallId": string,
"agentName": string,
// The following is a list of mutually exclusive fields. At most one of the
// fields will be set in a response:
"tool": string,
"toolsetTool": {
object ( |
| Fields | |
|---|---|
id |
Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in |
displayName |
Output only. Display name of the tool. |
args |
Optional. The input parameters and values for the tool in JSON object format. |
parentToolCallId |
Output only. The id of the tool call that caused this one, when it was issued by a sub-agent working on behalf of a parent call. Empty for top-level calls. Lets a client group a sub-agent's work under the call that started it instead of rendering every step as a sibling. |
agentName |
Output only. Human-readable name of the agent that issued this call, e.g. "Contract Architect". Empty when the root agent issued it. |
| The identifier of the tool to execute. It could be either a persisted tool or a tool from a toolset. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
tool |
Optional. The name of the tool to execute. Format: |
toolsetTool |
Optional. The toolset tool to execute. |
| End of mutually exclusive fields. | |
ToolsetTool
A tool that is created from a toolset.
| JSON representation |
|---|
{ "toolset": string, "toolId": string } |
| Fields | |
|---|---|
toolset |
Required. The resource name of the Toolset from which this tool is derived. Format: |
toolId |
Optional. The tool ID to filter the tools to retrieve the schema for. |
ToolResponse
The execution result of a specific tool from the client or the agent.
| JSON representation |
|---|
{
"id": string,
"displayName": string,
"response": {
object
},
"parentToolCallId": string,
"agentName": string,
// The following is a list of mutually exclusive fields. At most one of the
// fields will be set in a response:
"tool": string,
"toolsetTool": {
object ( |
| Fields | |
|---|---|
id |
Optional. The matching ID of the |
displayName |
Output only. Display name of the tool. |
response |
Required. The tool execution result in JSON object format. Use "output" key to specify tool response and "error" key to specify error details (if any). If "output" and "error" keys are not specified, then whole "response" is treated as tool execution result. |
parentToolCallId |
Output only. The id of the tool call that caused this one, when it was issued by a sub-agent working on behalf of a parent call. Empty for top-level calls. Lets a client group a sub-agent's work under the call that started it instead of rendering every step as a sibling. |
agentName |
Output only. Human-readable name of the agent that issued this call, e.g. "Contract Architect". Empty when the root agent issued it. |
| The identifier of the tool that got executed. It could be either a persisted tool or a tool from a toolset. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response: | |
tool |
Optional. The name of the tool to execute. Format: |
toolsetTool |
Optional. The toolset tool that got executed. |
| End of mutually exclusive fields. | |
AgentTransfer
Represents an event indicating the transfer of a conversation to a different agent.
| JSON representation |
|---|
{ "targetAgent": string, "displayName": string } |
| Fields | |
|---|---|
targetAgent |
Required. The agent to which the conversation is being transferred. The agent will handle the conversation from this point forward. Format: |
displayName |
Output only. Display name of the agent. |