0.16.0 (latest) 0.15.1 0.14.1 0.8.0 0.7.0 0.6.2 0.5.0 0.4.1 0.3.1 0.2.0 0.1.3 Reference documentation and code samples for the Google Ads Ad Manager V1 Client class DaiSession.

Representation of an individual Dynamic Ad Insertion (DAI) session watching a
[LiveStream](https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.LiveStream) resource or VOD
[Content](https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.Content) resource. Use the
Stream Activity Monitor (SAM) on the Google Ad Manager UI to look up this
session. For details, see [Locate a DAI session ID or debug
key](https://support.google.com/admanager/answer/7257678).

Generated from protobuf message `google.ads.admanager.v1.DaiSession`

## Namespace

Google \\ Ads \\ AdManager \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Identifier. The resource name of the `DaiSession`. |
| `↳ creation_context` | `https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.CreationContext` Output only. Context data to create the DAI session. |
| `↳ slate` | `https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.Creative` Output only. Slate creative to use in the DAI session for unfilled ad durations. |
| `↳ ad_selections` | `array|Google\Protobuf\Internal\MapField` Output only. The ad requests, ad responses and nested ads in the DAI session. |
| `↳ ad_pods` | `array|Google\Protobuf\Internal\MapField` Output only. All decisioned ad pods for this session, disregarding serving status. Keyed by a unique ID to reference an ad pod from a different submessage. |
| `↳ ad_breaks` | `array|Google\Protobuf\Internal\MapField` Output only. All DAI ad breaks for this session. Contains information such as ad duration, slate duration, and various ad statuses. Keyed by a unique ID to reference an ad break from a different submessage. |
| `↳ findings` | `array<https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.Finding>` Output only. Information about errors or notable discoveries that occurred during a session. |
| `↳ session_duration` | `Google\Protobuf\Duration` Output only. The duration of the DAI session, calculated as the difference between the timestamp of DAI's latest recorded event and the timestamp of the session create request. |

### getName

Identifier. The resource name of the `DaiSession`.

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

### setName

Identifier. The resource name of the `DaiSession`.

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

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

### getCreationContext

Output only. Context data to create the DAI session.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.CreationContext|null` |   |

### hasCreationContext

### clearCreationContext

### setCreationContext

Output only. Context data to create the DAI session.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.CreationContext` |

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

### getSlate

Output only. Slate creative to use in the DAI session for unfilled ad
durations.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.Creative|null` |   |

### hasSlate

### clearSlate

### setSlate

Output only. Slate creative to use in the DAI session for unfilled ad
durations.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.Creative` |

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

### getAdSelections

Output only. The ad requests, ad responses and nested ads in the DAI
session.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Internal\MapField` |   |

### setAdSelections

Output only. The ad requests, ad responses and nested ads in the DAI
session.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|Google\Protobuf\Internal\MapField` |

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

### getAdPods

Output only. All decisioned ad pods for this session, disregarding serving
status. Keyed by a unique ID to reference an ad pod from a different
submessage.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Internal\MapField` |   |

### setAdPods

Output only. All decisioned ad pods for this session, disregarding serving
status. Keyed by a unique ID to reference an ad pod from a different
submessage.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|Google\Protobuf\Internal\MapField` |

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

### getAdBreaks

Output only. All DAI ad breaks for this session. Contains information such
as ad duration, slate duration, and various ad statuses. Keyed by a unique
ID to reference an ad break from a different submessage.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Internal\MapField` |   |

### setAdBreaks

Output only. All DAI ad breaks for this session. Contains information such
as ad duration, slate duration, and various ad statuses. Keyed by a unique
ID to reference an ad break from a different submessage.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|Google\Protobuf\Internal\MapField` |

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

### getFindings

Output only. Information about errors or notable discoveries that occurred
during a session.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\RepeatedField<https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.Finding>` |   |

### setFindings

Output only. Information about errors or notable discoveries that occurred
during a session.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/ad-manager/latest/V1.DaiSession.Finding>` |

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

### getSessionDuration

Output only. The duration of the DAI session, calculated as the difference
between the timestamp of DAI's latest recorded event and the timestamp of
the session create request.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Duration|null` |   |

### hasSessionDuration

### clearSessionDuration

### setSessionDuration

Output only. The duration of the DAI session, calculated as the difference
between the timestamp of DAI's latest recorded event and the timestamp of
the session create request.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `Google\Protobuf\Duration` |

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