REST Resource: accounts.adclients.adunits

Resource: AdUnit

Representation of an ad unit. An ad unit represents a saved ad unit with a specific set of ad settings that have been customized within an account.

JSON representation
{
  "name": string,
  "reportingDimensionId": string,
  "displayName": string,
  "state": enum (State),
  "contentAdsSettings": {
    object (ContentAdsSettings)
  }
}
Fields
name

string

Output only. Resource name of the ad unit. Format: accounts/{account}/adclients/{adclient}/adunits/{adunit}

reportingDimensionId

string

Output only. Unique ID of the ad unit as used in the AD_UNIT_ID reporting dimension.

displayName

string

Required. Display name of the ad unit, as provided when the ad unit was created.

state

enum (State)

Required. State of the ad unit.

contentAdsSettings

object (ContentAdsSettings)

Required. Settings specific to content ads (AFC).

State

State of an ad unit.

Enums
STATE_UNSPECIFIED State unspecified.
ACTIVE Ad unit has been activated by the user.
ARCHIVED Ad unit has been archived by the user. Note that archived ad units are only removed from the default view in the UI. Archived ad units can still serve ads.

ContentAdsSettings

Settings specific to content ads (AFC).

JSON representation
{
  "size": string,
  "type": enum (Type)
}
Fields
size

string

Required. Size of the ad unit. e.g. "728x90", "1x3" (for responsive ad units).

type

enum (Type)

Required. Type of the ad unit.

Type

Content ads settings types supported by the api.

Enums
TYPE_UNSPECIFIED Unspecified ad unit type.
DISPLAY Display ad unit.
FEED In-feed ad unit.
ARTICLE In-article ad unit.
MATCHED_CONTENT Matched content unit.

Methods

create

Creates an ad unit.

get

Gets an ad unit from a specified account and ad client.

getAdcode

Gets the ad unit code for a given ad unit.

list

Lists all ad units under a specified account and ad client.

listLinkedCustomChannels

Lists all the custom channels available for an ad unit.

patch

Updates an ad unit.