You can update your selectors with a new
withConditionclause to separate Video action campaigns from other video campaign types in your code.
To get campaigns with the video action type:
AdsApp.videoCampaigns() .withCondition("AdvertisingChannelSubType = VIDEO_ACTION") .get();Or to get video campaigns of other types, which are unaffected by this change:
AdsApp.videoCampaigns() .withCondition("AdvertisingChannelSubType != VIDEO_ACTION") .get();Once you've identified that you're acting on a Video action campaign, create a new type of ad group that can house responsive video ads, and then construct a new type of ad at ad creation time. For other types of video campaigns, this new ad type isn’t available.
For creating the ad group, if you were using:
videoCampaign.newVideoAdGroupBuilder().withAdGroupType("VIDEO_TRUE_VIEW_IN_STREAM")Then update that code to:
videoCampaign.newVideoAdGroupBuilder().withAdGroupType("VIDEO_RESPONSIVE")For creating the ads themselves, if you were using:
adGroup.newVideoAd().inStreamAdBuilder()Then update that code to:
adGroup.newVideoAd().responsiveVideoAdBuilder()Check out the reference documentation for the new responsiveVideoAdBuilder for details on its fields and methods.
If you have any questions, please leave a post on our forum so that we can help.