# Google Cloud Dialogflow V2 Client - Class ToolCallResult (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 ToolCallResult.

The result of calling a tool's action.

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

## 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_toolset` | `string` Optional. CES toolset name for this call. Format: `projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/toolsets/ToolsetID>`. |
| `↳ ces_tool` | `string` Optional. CES tool name for this call. Format: `projects/<ProjectID>/locations/<LocationID>/apps/<AppID>/tools/<ToolID>`. |
| `↳ ces_app` | `string` Optional. CES app name for this call. Format: `projects/<ProjectID>/locations/<LocationID>/apps/<AppID>`. |
| `↳ action` | `string` Optional. The name of the tool's action associated with this call. |
| `↳ error` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.ToolCallResult.Error` The tool call's error. |
| `↳ raw_content` | `string` Only populated if the response content is not utf-8 encoded. (by definition byte fields are base64 encoded). |
| `↳ content` | `string` Only populated if the response content is utf-8 encoded. |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` Output only. Create time of the tool call result. |
| `↳ answer_record` | `string` Optional. The answer record associated with this tool call result. |

### 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` |   |

### 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` |   |

### 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` |   |

### 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` |   |

### 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` |   |

### getError

The tool call's error.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.ToolCallResult.Error|null` |   |

### hasError

### setError

The tool call's error.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow/latest/V2.ToolCallResult.Error` |

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

### getRawContent

Only populated if the response content is not utf-8 encoded.

(by definition byte fields are base64 encoded).

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

### hasRawContent

### setRawContent

Only populated if the response content is not utf-8 encoded.

(by definition byte fields are base64 encoded).

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

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

### getContent

Only populated if the response content is utf-8 encoded.

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

### hasContent

### setContent

Only populated if the response content is utf-8 encoded.

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

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

### getCreateTime

Output only. Create time of the tool call result.

| **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 result.

| **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 result.

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

### setAnswerRecord

Optional. The answer record associated with this tool call result.

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

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

### getSource

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

### getResult

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