# Google Ads Marketing Platform Admin V1alpha Client - Class AnalyticsAccountLink (0.4.2)

0.4.2 (latest) 0.4.1 0.3.1 0.2.1 0.1.4

> [!WARNING]
> **Beta**
>
>
> This library is covered by the [Pre-GA Offerings Terms](https://docs.cloud.google.com/terms/service-terms#1)
> of the Terms of Service. Pre-GA libraries might have limited support,
> and changes to pre-GA libraries might not be compatible with other pre-GA versions.
> For more information, see the
> [launch stage descriptions](https://docs.cloud.google.com/products#product-launch-stages).

Reference documentation and code samples for the Google Ads Marketing Platform Admin V1alpha Client class AnalyticsAccountLink.

A resource message representing the link between a Google Analytics account
and a Google Marketing Platform organization.

Generated from protobuf message `google.marketingplatform.admin.v1alpha.AnalyticsAccountLink`

## Namespace

Google \\ Ads \\ MarketingPlatform \\ Admin \\ V1alpha

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Identifier. Resource name of this AnalyticsAccountLink. Note the resource ID is the same as the ID of the Analtyics account. Format: organizations/{org_id}/analyticsAccountLinks/{analytics_account_link_id} Example: "organizations/xyz/analyticsAccountLinks/1234" |
| `↳ analytics_account` | `string` Required. Immutable. The resource name of the AnalyticsAdmin API account. The account ID will be used as the ID of this AnalyticsAccountLink resource, which will become the final component of the resource name. Format: analyticsadmin.googleapis.com/accounts/{account_id} |
| `↳ display_name` | `string` Output only. The human-readable name for the Analytics account. |
| `↳ link_verification_state` | `int` Output only. The verification state of the link between the Analytics account and the parent organization. |

### getName

Identifier. Resource name of this AnalyticsAccountLink. Note the resource
ID is the same as the ID of the Analtyics account.

Format:
organizations/{org_id}/analyticsAccountLinks/{analytics_account_link_id}
Example: "organizations/xyz/analyticsAccountLinks/1234"

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

### setName

Identifier. Resource name of this AnalyticsAccountLink. Note the resource
ID is the same as the ID of the Analtyics account.

Format:
organizations/{org_id}/analyticsAccountLinks/{analytics_account_link_id}
Example: "organizations/xyz/analyticsAccountLinks/1234"

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

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

### getAnalyticsAccount

Required. Immutable. The resource name of the AnalyticsAdmin API account.

The account ID will be used as the ID of this AnalyticsAccountLink
resource, which will become the final component of the resource name.
Format: analyticsadmin.googleapis.com/accounts/{account_id}

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

### setAnalyticsAccount

Required. Immutable. The resource name of the AnalyticsAdmin API account.

The account ID will be used as the ID of this AnalyticsAccountLink
resource, which will become the final component of the resource name.
Format: analyticsadmin.googleapis.com/accounts/{account_id}

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

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

### getDisplayName

Output only. The human-readable name for the Analytics account.

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

### setDisplayName

Output only. The human-readable name for the Analytics account.

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

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

### getLinkVerificationState

Output only. The verification state of the link between the Analytics
account and the parent organization.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [LinkVerificationState](https://docs.cloud.google.com/php/docs/reference/marketingplatform-admin/latest/V1alpha.LinkVerificationState). |

### setLinkVerificationState

Output only. The verification state of the link between the Analytics
account and the parent organization.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [LinkVerificationState](https://docs.cloud.google.com/php/docs/reference/marketingplatform-admin/latest/V1alpha.LinkVerificationState). |

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