This service provides operations for retrieving and approving SuggestedAdUnit objects.
Publishers may create ad tags that lack a corresponding ad unit defined in DFP, in order to gather information about potential ads without needing to create dummy ad units and make them available for targeting in line items. Any undefined ad unit to receive more than ten serving requests in the past week is treated as a 'suggested ad unit'. These can be queried by the client and selectively approved. Approval causes a new ad unit to be created based on the suggested ad unit. Unapproved suggested ad units cease to exist whenever their corresponding ad tag has been served fewer than ten times in the past seven days.
This service is only available to Premium publishers. Before use, suggested ad units must be enabled for the client's network. This can be done in the UI: in the Inventory tab, click "Network settings" in the left-hand panel, then enable the checkbox "Get suggestions for new ad units." If suggested ad units are not enabled, then getSuggestedAdUnitsByStatement will always return an empty page.
- Production WSDL
-
https://ads.google.com/apis/ads/publisher/v202411/SuggestedAdUnitService?wsdl
- Namespace
-
https://www.google.com/apis/ads/publisher/v202411
- Operations
- Errors
-
- ApiVersionError
- AuthenticationError
- CollectionSizeError
- CommonError
- EntityLimitReachedError
- FeatureError
- InternalApiError
- InventoryUnitSizesError
- LabelEntityAssociationError
- NotNullError
- ParseError
- PermissionError
- PublisherQueryLanguageContextError
- PublisherQueryLanguageSyntaxError
- QuotaError
- RequiredCollectionError
- RequiredError
- ServerError
- StatementError
- StringFormatError
- StringLengthError
- TypeError
- UniqueError
getSuggestedAdUnitsByStatement
Gets a SuggestedAdUnitPage of SuggestedAdUnit objects that satisfy the filter query. There is a system-enforced limit of 1000 on the number of suggested ad units that are suggested at any one time.
PQL Property | Object Property |
---|---|
id
|
SuggestedAdUnit.id |
numRequests
|
SuggestedAdUnit.numRequests |
Note: After API version 201311, the
id
field will only be
numerical.
Parameters
Field | Type | Description |
---|---|---|
filterStatement
|
|
Response
Field | Type | Description |
---|---|---|
rval
|
|
performSuggestedAdUnitAction
Performs actions on SuggestedAdUnit objects that match the given Statement.query. The following fields are supported for filtering:
PQL Property | Object Property |
---|---|
id
|
SuggestedAdUnit.id |
numRequests
|
SuggestedAdUnit.numRequests |
Parameters
Field | Type | Description |
---|---|---|
suggestedAdUnitAction
|
|
|
filterStatement
|
|
Response
Field | Type | Description |
---|---|---|
rval
|
|
Errors
Error | Reasons |
---|---|
ApiVersionError
|
Errors related to the usage of API versions.
Enumerations
|
AuthenticationError
|
An error for an exception that occurred when authenticating.
Enumerations
|
CollectionSizeError
|
Error for the size of the collection being too large
Enumerations
|
CommonError
|
A place for common errors that can be used across services.
Enumerations
|
EntityLimitReachedError
|
An error that occurs when creating an entity if the limit on the number of allowed entities for
a network has already been reached.
Enumerations
|
FeatureError
|
Errors related to feature management. If you attempt using a feature that is not available to
the current network you'll receive a FeatureError with the missing feature as the trigger.
Enumerations
|
InternalApiError
|
Indicates that a server-side error has occured. InternalApiError s
are generally not the result of an invalid request or message sent by the
client.
Enumerations
|
InventoryUnitSizesError
|
An error specifically for InventoryUnitSizes.
Enumerations
|
LabelEntityAssociationError
|
Errors specific to creating label entity associations.
Enumerations
|
NotNullError
|
Caused by supplying a null value for an attribute that cannot be null.
Enumerations
|
ParseError
|
Lists errors related to parsing.
Enumerations
|
PermissionError
|
Errors related to incorrect permission.
Enumerations
|
PublisherQueryLanguageContextError
|
An error that occurs while executing a PQL query contained in
a Statement object.
Enumerations
|
PublisherQueryLanguageSyntaxError
|
An error that occurs while parsing a PQL query contained in a
Statement object.
Enumerations
|
QuotaError
|
Describes a client-side error on which a user is attempting
to perform an action to which they have no quota remaining.
Enumerations
|
RequiredCollectionError
|
A list of all errors to be used for validating sizes of collections.
Enumerations
|
RequiredError
|
Errors due to missing required field.
Enumerations
|
ServerError
|
Errors related to the server.
Enumerations
|
StatementError
|
An error that occurs while parsing Statement objects.
Enumerations
|
StringFormatError
|
A list of error code for reporting invalid content of input strings.
Enumerations
|
StringLengthError
|
Errors for Strings which do not meet given length constraints.
Enumerations
|
TypeError
|
An error for a field which is an invalid type. |
UniqueError
|
An error for a field which must satisfy a uniqueness constraint |