- [JSON representation](https://docs.cloud.google.com/gemini-enterprise-cx/cx-agent-studio/reference/rest/v1beta/ToolCall#SCHEMA_REPRESENTATION)

Request for the client or the agent to execute the specified tool.

| JSON representation |
|---|
| ``` { "id": string, "displayName": string, "args": { object }, "parentToolCallId": string, "agentName": string, "targetApp": 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 (`https://docs.cloud.google.com/gemini-enterprise-cx/cx-agent-studio/reference/rest/v1beta/ToolsetTool`) } // End of mutually exclusive fields. } ``` |

| Fields ||
|---|---|
| `id` | `string` Optional. The unique identifier of the tool call. If populated, the client should return the execution result with the matching ID in `https://docs.cloud.google.com/gemini-enterprise-cx/cx-agent-studio/reference/rest/v1beta/ToolResponse#FIELDS.id`. |
| `displayName` | `string` Output only. Display name of the tool. |
| `args` | ``object (`https://protobuf.dev/reference/protobuf/google.protobuf#struct` format)`` Optional. The input parameters and values for the tool in JSON object format. |
| `parentToolCallId` | `string` 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` | `string` Output only. Human-readable name of the agent that issued this call, e.g. "Contract Architect". Empty when the root agent issued it. |
| `targetApp` | `string` Output only. The app this call targets, derived by the assistant from the call's resource arguments: an app resource name, `PROJECT` for location-scoped tools, or empty for session-local tools. Set only in project-scoped assistant sessions. |
| 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` | `string` Optional. The name of the tool to execute. Format: `projects/{project}/locations/{location}/apps/{app}/tools/{tool}` |
| `toolsetTool` | ``object (`https://docs.cloud.google.com/gemini-enterprise-cx/cx-agent-studio/reference/rest/v1beta/ToolsetTool`)`` Optional. The toolset tool to execute. |
| End of mutually exclusive fields. ||