v1

latestOpenAPI 3.0.0Creative Commons Attribution 3.02026-07-13177414729.5 KB
advertisers

Creates a new association between the identified resource and a YouTube asset. Returns the newly-created association. Warning: This method is only available to an informed subset of users.

post/v4/advertisers/{+advertiserId}/lineItems/{+lineItemId}/youtubeAssetTypes/{+youtubeAssetType}/youtubeAssetAssociations

Path parameters

advertiserIdstring required

Required. The ID of the advertiser that the linked entity belongs to.

lineItemIdstring required

The ID of a line item.

youtubeAssetType'YOUTUBE_ASSET_TYPE_UNSPECIFIED' | 'YOUTUBE_ASSET_TYPE_LOCATION' | 'YOUTUBE_ASSET_TYPE_AFFILIATE_LOCATION' | 'YOUTUBE_ASSET_TYPE_SITELINK' required

Required. The type of YouTube asset associated with the resource.

Query parameters

linkedEntity.adGroupIdstring

The ID of an ad group.

Request body

namestring

Identifier. The resource name of the association. For line item-level associations: The name pattern is advertisers/{advertiser_id}/lineItems/{line_item_id}/youtubeAssetTypes/{youtube_asset_type}/youtubeAssetAssociations/{youtube_asset_association_id}. For ad group-level associations: The name pattern is advertisers/{advertiser_id}/adGroups/{ad_group_id}/youtubeAssetTypes/{youtube_asset_type}/youtubeAssetAssociations/{youtube_asset_association_id}. For YOUTUBE_ASSET_TYPE_LOCATION and YOUTUBE_ASSET_TYPE_AFFILIATE_LOCATION associations: youtube_asset_association_id is the ID of the asset set linked, or 0 if the location_matching_type or affiliate_location_matching_type is DISABLED. For YOUTUBE_ASSET_TYPE_SITELINK associations: youtube_asset_association_id is be the ID of the sitelink asset linked.

youtubeAssetType'YOUTUBE_ASSET_TYPE_UNSPECIFIED' | 'YOUTUBE_ASSET_TYPE_LOCATION' | 'YOUTUBE_ASSET_TYPE_AFFILIATE_LOCATION' | 'YOUTUBE_ASSET_TYPE_SITELINK'

Required. The type of YouTube asset associated with the resource.

Response

Successful response