# Google Cloud Dialogflow V2 Client - Class ToolCall (2.4.0)

2.4.0 (latest) 2.3.1 2.2.1 2.1.2 2.0.1 1.17.2 1.16.0 1.15.1 1.14.0 1.13.0 1.12.3 1.11.0 1.10.2 1.9.0 1.8.0 1.7.2 1.6.0 1.5.0 1.4.0 1.3.2 1.2.0 1.1.1 1.0.1 Reference documentation and code samples for the Google Cloud Dialogflow V2 Client class ToolCall.

Represents a call of a specific tool's action with the specified inputs.

Generated from protobuf message `google.cloud.dialogflow.v2.ToolCall`

## Namespace

Google \\ Cloud \\ Dialogflow \\ V2

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ tool` | `string` Optional. The [tool](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.Tool) associated with this call. Format: `projects/<ProjectID>/locations/<LocationID>/tools/<ToolID>`. |
| `↳ ces_tool` | `string` Optional. CES tool name for this call. Format: `projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/tools/<ToolID>`. |
| `↳ ces_toolset` | `string` Optional. CES toolset name for this call. Format: `projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/toolsets/ToolsetID>`. |
| `↳ ces_app` | `string` Optional. CES app name for this call. Format: `projects/<ProjectID>/locations/<LocationID>/apps/<AppID>`. |
| `↳ tool_display_name` | `string` Optional. A human readable short name of the tool, to be shown on the UI. |
| `↳ tool_display_details` | `string` Optional. A human readable description of the tool. |
| `↳ action` | `string` Optional. The name of the tool's action associated with this call. |
| `↳ input_parameters` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Struct` Optional. The action's input parameters. |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. Create time of the tool call. |
| `↳ answer_record` | `string` Optional. The answer record associated with this tool call. |
| `↳ state` | `int` Output only. State of the tool call. |

### getTool

Optional. The [tool](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.Tool) associated with
this call. Format:
`projects/<ProjectID>/locations/<LocationID>/tools/<ToolID>`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasTool

### setTool

Optional. The [tool](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.Tool) associated with
this call. Format:
`projects/<ProjectID>/locations/<LocationID>/tools/<ToolID>`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCesTool

Optional. CES tool name for this call.

Format:
`projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/tools/<ToolID>`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasCesTool

### setCesTool

Optional. CES tool name for this call.

Format:
`projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/tools/<ToolID>`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCesToolset

Optional. CES toolset name for this call.

Format:
`projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/toolsets/ToolsetID>`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasCesToolset

### setCesToolset

Optional. CES toolset name for this call.

Format:
`projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/toolsets/ToolsetID>`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCesApp

Optional. CES app name for this call.

Format:
`projects/<ProjectID>/locations/<LocationID>/apps/<AppID>`.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### hasCesApp

### setCesApp

Optional. CES app name for this call.

Format:
`projects/<ProjectID>/locations/<LocationID>/apps/<AppID>`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getToolDisplayName

Optional. A human readable short name of the tool, to be shown on the UI.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setToolDisplayName

Optional. A human readable short name of the tool, to be shown on the UI.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getToolDisplayDetails

Optional. A human readable description of the tool.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setToolDisplayDetails

Optional. A human readable description of the tool.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAction

Optional. The name of the tool's action associated with this call.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setAction

Optional. The name of the tool's action associated with this call.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getInputParameters

Optional. The action's input parameters.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Struct|null` |   |

### hasInputParameters

### clearInputParameters

### setInputParameters

Optional. The action's input parameters.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Struct` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCreateTime

Output only. Create time of the tool call.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp|null` |   |

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. Create time of the tool call.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getAnswerRecord

Optional. The answer record associated with this tool call.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setAnswerRecord

Optional. The answer record associated with this tool call.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getState

Output only. State of the tool call.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.ToolCall.State). |

### setState

Output only. State of the tool call.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.ToolCall.State). |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSource

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |