AI-generated Key Takeaways
-
This page documents the
VideoYouTubeVideoBuilder
, used for creating or excluding YouTube videos for targeting in video ad groups. -
The builder provides methods to set the YouTube video ID (
withVideoId
) and to build theVideoYouTubeVideo
orExcludedVideoYouTubeVideo
object (build
orexclude
). -
Using the
build
method creates aVideoYouTubeVideoOperation
for targeting specific YouTube videos. -
Using the
exclude
method creates anExcludedVideoYouTubeVideoOperation
for excluding specific YouTube videos.
Example usage:
var videoYouTubeVideoBuilder = videoAdGroup .videoTargeting() .newYouTubeVideoBuilder(); var videoYouTubeVideoOperation = videoYouTubeVideoBuilder .withVideoId('_YUugB4IUl4') // required .build(); // create the YouTube video
Methods:
Member | Type | Description |
---|---|---|
build() | AdsApp.VideoYouTubeVideoOperation |
Builds the video YouTube video. |
exclude() | AdsApp.ExcludedVideoYouTubeVideoOperation |
Builds the excluded video YouTube video. |
withVideoId(videoId) | AdsApp.VideoYouTubeVideoBuilder |
Sets the YouTube video ID. |
build()
Builds the video YouTube video. Returns a
VideoYouTubeVideoOperation that corresponds to the creation of the VideoYouTubeVideo. Return values:
Type | Description |
---|---|
AdsApp.VideoYouTubeVideoOperation |
The VideoYouTubeVideoOperation. |
exclude()
Builds the excluded video YouTube video. Returns an
ExcludedVideoYouTubeVideoOperation that corresponds to the creation of the ExcludedVideoYouTubeVideo. Return values:
Type | Description |
---|---|
AdsApp.ExcludedVideoYouTubeVideoOperation |
The ExcludedVideoYouTubeVideoOperation. |
withVideoId(videoId)
Sets the YouTube video ID. This field is required. Arguments:
Name | Type | Description |
---|---|---|
videoId | String |
The YouTube video ID. |
Return values:
Type | Description |
---|---|
AdsApp.VideoYouTubeVideoBuilder |
A VideoYouTubeVideoBuilder with the specified video ID. |