# Google Cloud Discovery Engine V1 Client - Class SearchLinkPromotion (1.11.1)

1.11.1 (latest) 1.11.0 1.10.1 1.9.1 1.8.0 1.7.0 1.6.1 1.5.1 1.4.0 1.3.3 1.2.0 1.1.0 1.0.0 0.11.3 0.8.0 0.7.1 0.6.0 0.5.0 0.4.0 0.3.0 0.2.0 0.1.1 Reference documentation and code samples for the Google Cloud Discovery Engine V1 Client class SearchLinkPromotion.

Promotion proto includes uri and other helping information to display the
promotion.

Generated from protobuf message `google.cloud.discoveryengine.v1.SearchLinkPromotion`

## Namespace

Google \\ Cloud \\ DiscoveryEngine \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ title` | `string` Required. The title of the promotion. Maximum length: 160 characters. |
| `↳ uri` | `string` Optional. The URL for the page the user wants to promote. Must be set for site search. For other verticals, this is optional. |
| `↳ document` | `string` Optional. The [Document](https://docs.cloud.google.com/php/docs/reference/cloud-discoveryengine/latest/V1.Document) the user wants to promote. For site search, leave unset and only populate uri. Can be set along with uri. |
| `↳ image_uri` | `string` Optional. The promotion thumbnail image url. |
| `↳ description` | `string` Optional. The Promotion description. Maximum length: 200 characters. |
| `↳ enabled` | `bool` Optional. The enabled promotion will be returned for any serving configs associated with the parent of the control this promotion is attached to. This flag is used for basic site search only. |

### getTitle

Required. The title of the promotion.

Maximum length: 160 characters.

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

### setTitle

Required. The title of the promotion.

Maximum length: 160 characters.

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

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

### getUri

Optional. The URL for the page the user wants to promote. Must be set for
site search. For other verticals, this is optional.

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

### setUri

Optional. The URL for the page the user wants to promote. Must be set for
site search. For other verticals, this is optional.

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

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

### getDocument

Optional. The [Document](https://docs.cloud.google.com/php/docs/reference/cloud-discoveryengine/latest/V1.Document) the user
wants to promote. For site search, leave unset and only populate uri. Can
be set along with uri.

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

### setDocument

Optional. The [Document](https://docs.cloud.google.com/php/docs/reference/cloud-discoveryengine/latest/V1.Document) the user
wants to promote. For site search, leave unset and only populate uri. Can
be set along with uri.

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

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

### getImageUri

Optional. The promotion thumbnail image url.

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

### setImageUri

Optional. The promotion thumbnail image url.

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

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

### getDescription

Optional. The Promotion description.

Maximum length: 200 characters.

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

### setDescription

Optional. The Promotion description.

Maximum length: 200 characters.

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

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

### getEnabled

Optional. The enabled promotion will be returned for any serving configs
associated with the parent of the control this promotion is attached to.

This flag is used for basic site search only.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setEnabled

Optional. The enabled promotion will be returned for any serving configs
associated with the parent of the control this promotion is attached to.

This flag is used for basic site search only.

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

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