CompanionAds

Metadata for companion ads.

JSON representation
{
  "displayRequirement": enum (DisplayRequirement),
  "companions": [
    {
      object (Companion)
    }
  ]
}
Fields
displayRequirement

enum (DisplayRequirement)

Indicates how many of the companions should be displayed with the ad.

companions[]

object (Companion)

List of companion ads.

DisplayRequirement

Indicates how many of the companions should be displayed with the ad.

Enums
DISPLAY_REQUIREMENT_UNSPECIFIED Required companions are not specified. The default is ALL.
ALL All companions are required to be displayed.
ANY At least one of companions needs to be displayed.
NONE All companions are optional for display.

Companion

Metadata for a companion.

JSON representation
{
  "apiFramework": string,
  "heightPx": integer,
  "widthPx": integer,
  "assetHeightPx": integer,
  "expandedHeightPx": integer,
  "assetWidthPx": integer,
  "expandedWidthPx": integer,
  "adSlotId": string,
  "events": [
    {
      object (Event)
    }
  ],

  // Union field ad_resource can be only one of the following:
  "iframeAdResource": {
    object (IframeAdResource)
  },
  "staticAdResource": {
    object (StaticAdResource)
  },
  "htmlAdResource": {
    object (HtmlAdResource)
  }
  // End of list of possible types for union field ad_resource.
}
Fields
apiFramework

string

The API necessary to communicate with the creative if available.

heightPx

integer

The pixel height of the placement slot for the intended creative.

widthPx

integer

The pixel width of the placement slot for the intended creative.

assetHeightPx

integer

The pixel height of the creative.

expandedHeightPx

integer

The maximum pixel height of the creative in its expanded state.

assetWidthPx

integer

The pixel width of the creative.

expandedWidthPx

integer

The maximum pixel width of the creative in its expanded state.

adSlotId

string

The ID used to identify the desired placement on a publisher's page. Values to be used should be discussed between publishers and advertisers.

events[]

object (Event)

The list of tracking events for the companion.

Union field ad_resource. Ad resource associated with the companion ad. ad_resource can be only one of the following:
iframeAdResource

object (IframeAdResource)

The IFrame ad resource associated with the companion ad.

staticAdResource

object (StaticAdResource)

The static ad resource associated with the companion ad.

htmlAdResource

object (HtmlAdResource)

The HTML ad resource associated with the companion ad.

IframeAdResource

Metadata for an IFrame ad resource.

JSON representation
{
  "uri": string
}
Fields
uri

string

URI source for an IFrame to display for the ad resource.

StaticAdResource

Metadata for a static ad resource.

JSON representation
{
  "uri": string,
  "creativeType": string
}
Fields
uri

string

URI to the static file for the ad resource.

creativeType

string

Describes the MIME type of the ad resource.

HtmlAdResource

Metadata for an HTML ad resource.

JSON representation
{
  "htmlSource": string
}
Fields
htmlSource

string

The HTML to display for the ad resource.