AdsApp.​VideoAudienceBuilder

Builder for VideoAudience objects. For details about video audiences, please see About targeting for video campaigns.

Example usage:

var videoAudienceBuilder = videoAdGroup
  .videoTargeting()
  .newAudienceBuilder();
var videoAudienceOperation = videoAudienceBuilder
  .withAudienceType('USER_INTEREST')   // required
  .withAudienceId(80432)               // required
  .build();                            // create the audience

Methods:

MemberTypeDescription
build AdsApp.VideoAudienceOperation Builds the video audience.
exclude AdsApp.ExcludedVideoAudienceOperation Builds the excluded video audience.
withAudienceId AdsApp.VideoAudienceBuilder Sets the ID of the excluded audience.
withAudienceType AdsApp.VideoAudienceBuilder Sets the type of the audience.

build()

Builds the video audience. Returns a VideoAudienceOperation that corresponds to the creation of the VideoAudience.

Return values:

TypeDescription
AdsApp.VideoAudienceOperation The VideoAudienceOperation.

exclude()

Builds the excluded video audience. Returns an ExcludedVideoAudienceOperation that corresponds to the creation of the ExcludedVideoAudience.

Custom affinities cannot be excluded.

Return values:

TypeDescription
AdsApp.ExcludedVideoAudienceOperation The ExcludedVideoAudienceOperation.

withAudienceId(audienceId)

Sets the ID of the excluded audience. This field is required. For user interests, affinity categories and corresponding IDs can be found on API documentation on affinity categories, and in-market categories and corresponding IDs can be found on API documentation on in-market categories. User List IDs (List IDs) are available on the details page of a User List (found under the Audiences section of the Shared Library).

Arguments:

NameTypeDescription
audienceId String The ID of the excluded audience.

Return values:

TypeDescription
AdsApp.VideoAudienceBuilder An audience builder with the specified audience ID.

withAudienceType(audienceType)

Sets the type of the audience. Possible values: USER_INTEREST, USER_LIST or CUSTOM_AFFINITY. This field is required.

Arguments:

NameTypeDescription
audienceType String The type of the excluded audience.

Return values:

TypeDescription
AdsApp.VideoAudienceBuilder An VideoAudienceBuilder with the specified audience type.