# Google Cloud Dialogflow Cx V3 Client - Class AnswerFeedback (0.11.1)

0.11.1 (latest) 0.11.0 0.10.2 0.9.2 0.8.1 0.7.2 0.6.0 0.5.2 0.4.1 0.3.4 0.2.1 0.1.1 Reference documentation and code samples for the Google Cloud Dialogflow Cx V3 Client class AnswerFeedback.

Stores information about feedback provided by users about a response.

Generated from protobuf message `google.cloud.dialogflow.cx.v3.AnswerFeedback`

## Namespace

Google \\ Cloud \\ Dialogflow \\ Cx \\ V3

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ rating` | `int` Optional. Rating from user for the specific Dialogflow response. |
| `↳ rating_reason` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AnswerFeedback.RatingReason` Optional. In case of thumbs down rating provided, users can optionally provide context about the rating. |
| `↳ custom_rating` | `string` Optional. Custom rating from the user about the provided answer, with maximum length of 1024 characters. For example, client could use a customized JSON object to indicate the rating. |

### getRating

Optional. Rating from user for the specific Dialogflow response.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [Rating](https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AnswerFeedback.Rating). |

### setRating

Optional. Rating from user for the specific Dialogflow response.

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

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

### getRatingReason

Optional. In case of thumbs down rating provided, users can optionally
provide context about the rating.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AnswerFeedback.RatingReason|null` |   |

### hasRatingReason

### clearRatingReason

### setRatingReason

Optional. In case of thumbs down rating provided, users can optionally
provide context about the rating.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-dialogflow-cx/latest/V3.AnswerFeedback.RatingReason` |

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

### getCustomRating

Optional. Custom rating from the user about the provided answer, with
maximum length of 1024 characters. For example, client could use a
customized JSON object to indicate the rating.

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

### setCustomRating

Optional. Custom rating from the user about the provided answer, with
maximum length of 1024 characters. For example, client could use a
customized JSON object to indicate the rating.

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

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