# Recommender V1 Client - Class MarkInsightAcceptedRequest (2.2.0)

2.2.0 (latest) 2.1.3 2.0.5 1.11.5 1.10.0 1.9.1 1.8.2 1.7.8 Reference documentation and code samples for the Recommender V1 Client class MarkInsightAcceptedRequest.

Request for the `MarkInsightAccepted` method.

Generated from protobuf message `google.cloud.recommender.v1.MarkInsightAcceptedRequest`

## Namespace

Google \\ Cloud \\ Recommender \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Required. Name of the insight. |
| `↳ state_metadata` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Optional. State properties user wish to include with this state. Full replace of the current state_metadata. |
| `↳ etag` | `string` Required. Fingerprint of the Insight. Provides optimistic locking. |

### getName

Required. Name of the insight.

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

### setName

Required. Name of the insight.

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

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

### getStateMetadata

Optional. State properties user wish to include with this state. Full
replace of the current state_metadata.

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

### setStateMetadata

Optional. State properties user wish to include with this state. Full
replace of the current state_metadata.

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

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

### getEtag

Required. Fingerprint of the Insight. Provides optimistic locking.

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

### setEtag

Required. Fingerprint of the Insight. Provides optimistic locking.

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

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

### static::build

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `string` Required. Name of the insight. Please see RecommenderClient::insightName() for help formatting this field. |
| `stateMetadata` | `array` Optional. State properties user wish to include with this state. Full replace of the current state_metadata. |
| `etag` | `string` Required. Fingerprint of the Insight. Provides optimistic locking. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-recommender/latest/V1.MarkInsightAcceptedRequest` |   |