# REST Resource: adPlays

- [Resource: AdPlay](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/adPlays#AdPlay)
  - [JSON representation](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/adPlays#AdPlay.SCHEMA_REPRESENTATION)
- [Methods](https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/adPlays#METHODS_SUMMARY)

## Resource: AdPlay

A single ad play.

| JSON representation |
|---|
| ``` { "name": string, "line": string, "adUnit": string, "creative": string, "startTime": string, "endTime": string, "recordTime": string, "impressions": number } ``` |

| Fields ||
|---|---|
| `name` | `string` Output only. The resource name of the ad play in the format: `adPlays/{id}`. |
| `line` | `string` Required. The line this ad play belongs to. The order will be inferred from the line. Format: `orders/123/line/321`. |
| `adUnit` | `string` Required. The ad unit this ad play was served on. Format: `adUnits/123`. |
| `creative` | `string` Required. The creative this ad play served. Format: `creativeAssets/123`. |
| `startTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Required. Time the ad started to play (inclusive). Should be in the past and within the last 3 days. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `endTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Required. Time the ad play ended (exclusive). Should be in the past and after start time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `recordTime` | ``string (`https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Timestamp` format)`` Optional. Time this ad play was recorded. Should be in the past and after end time. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: `"2014-10-02T15:01:23Z"` and `"2014-10-02T15:01:23.045123456Z"`. |
| `impressions` | `number` Required. Total number of impressions. |

| ## Methods ||
|---|---|
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/adPlays/create` | Creates an ad play. |
| ### `https://developers.google.com/display-video/out-of-home-seller/reference/rest/v1beta1/adPlays/createWithExternalIds` | Creates an ad play with external ids. |