RequiredSizeError.NOT_ALLOWED

787 views
Skip to first unread message

Dan LaRiviere

unread,
Jan 25, 2011, 11:34:14 AM1/25/11
to google-doubleclick...@googlegroups.com
I created an AdUnit with a default size of 500x350.

I then added a ImageCreative with the size of 530 x 290.

All this works fine. The problem comes when I try to create the LineItemCreativeAssociation. I am getting the error:
[RequiredSizeError.NOT_ALLOWED @ sizes; trigger:'530x290']

Since my creative size doesn't match the AdUnit size, I am setting the LineItemCreativeAssociation.Sizes property per the DFP documentation:

"Overrides the value set for Creative.size, which allows the creative to be served to ad units that would otherwise not be compatible for its actual size. This value is optional."

What do I need to do to get it to accept the new size?

Here is the code:
=======================================
 var lica = new LineItemCreativeAssociation
{
creativeId = (long) banner.Banner.DfpBannerId,
lineItemId = (long) banner.AdOrderItem.DfpOrderItemId,
manualCreativeRotationWeight = banner.Weight,
status = banner.Active ? LineItemCreativeAssociationStatus.ACTIVE : LineItemCreativeAssociationStatus.INACTIVE
};

var size = new Size
{
width = (int)banner.Banner.Width,
height = (int)banner.Banner.Height,
isAspectRatio = false
};
lica.sizes = new Size[] { size };

licaService.createLineItemCreativeAssociation(lica);



DFP API Advisor

unread,
Jan 25, 2011, 5:57:12 PM1/25/11
to Google's DoubleClick for Publishers API Forum
Hi Dan,

Can you post the SOAP request XML (please remove the auth token) so I
can see all of the IDs involved here?

Also, is this a small business network, a premium one, or the sandbox?

Thanks,
Adam Rogal, DFP API Team

Dan LaRiviere

unread,
Jan 25, 2011, 6:03:21 PM1/25/11
to google-doubleclick...@googlegroups.com
This is a DFP for Small Business account.

Here is the XML - auth token.

-----------------BEGIN API CALL---------------------

Request
-------

POST /apis/ads/publisher/v201010/LineItemCreativeAssociationService
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; MS Web Services Client Protocol 2.0.50727.4952)
Content-Type: text/xml; charset=utf-8
SOAPAction: ""
Host: www.google.com
Content-Length: 1182
TimeStamp: Tue, 25 Jan 2011 15:59:22 GMT

<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Header><RequestHeader xmlns="https://www.google.com/apis/ads/publisher/v201010"><authToken>asdf</authToken><networkCode>10485668</networkCode><applicationName>DfpApi-DotNet-1.0.0|TriFind.com</applicationName></RequestHeader></soap:Header><soap:Body><createLineItemCreativeAssociation xmlns="https://www.google.com/apis/ads/publisher/v201010"><lineItemCreativeAssociation><lineItemId>2311108</lineItemId><creativeId>5760426388</creativeId><manualCreativeRotationWeight>1</manualCreativeRotationWeight><sizes><width>470</width><height>353</height><isAspectRatio>false</isAspectRatio></sizes><status>ACTIVE</status></lineItemCreativeAssociation></createLineItemCreativeAssociation></soap:Body></soap:Envelope>

Response
--------

X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
Transfer-Encoding: chunked
Cache-Control: private, max-age=0
Content-Type: text/xml; charset=UTF-8
Date: Tue, 25 Jan 2011 22:59:55 GMT
Expires: Tue, 25 Jan 2011 22:59:55 GMT
Server: GSE
TimeStamp: Tue, 25 Jan 2011 15:59:22 GMT

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Header><ResponseHeader xmlns="https://www.google.com/apis/ads/publisher/v201010"><requestId>7208279ffcf3f34e3d6072370bff905a</requestId><responseTime>490</responseTime></ResponseHeader></soap:Header><soap:Body><soap:Fault><faultcode>soap:Server</faultcode><faultstring>[RequiredSizeError.NOT_ALLOWED @ sizes; trigger:'470x353']</faultstring><detail><ApiExceptionFault xmlns="https://www.google.com/apis/ads/publisher/v201010"><message xmlns="https://www.google.com/apis/ads/publisher/v201010">[RequiredSizeError.NOT_ALLOWED @ sizes; trigger:'470x353']</message><ApplicationException.Type xmlns="https://www.google.com/apis/ads/publisher/v201010">ApiException</ApplicationException.Type><errors xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="RequiredSizeError" xmlns="https://www.google.com/apis/ads/publisher/v201010"><fieldPath xmlns="https://www.google.com/apis/ads/publisher/v201010">sizes</fieldPath><trigger xmlns="https://www.google.com/apis/ads/publisher/v201010">470x353</trigger><errorString xmlns="https://www.google.com/apis/ads/publisher/v201010">RequiredSizeError.NOT_ALLOWED</errorString><ApiError.Type xmlns="https://www.google.com/apis/ads/publisher/v201010">RequiredSizeError</ApiError.Type><reason xmlns="https://www.google.com/apis/ads/publisher/v201010">NOT_ALLOWED</reason></errors></ApiExceptionFault></detail></soap:Fault></soap:Body></soap:Envelope>
-----------------END API CALL-----------------------

host=www.google.com,url=/apis/ads/publisher/v201010/LineItemCreativeAssociationService,method=createLineItemCreativeAssociation,requestId=7208279ffcf3f34e3d6072370bff905a,responseTime=490
[RequiredSizeError.NOT_ALLOWED @ sizes; trigger:'470x353']
-----------------BEGIN API CALL---------------------


DFP API Advisor

unread,
Jan 25, 2011, 6:24:24 PM1/25/11
to Google's DoubleClick for Publishers API Forum
hi,

The lineItem only has sizes 500x350. The override needs to match one
of the sizes that the line item can support. Overriding the LICA size
is only important to fit a creative into another valid size of the
line item.

Thanks,
Adam Rogal, DFP API Team

On Jan 25, 6:03 pm, Dan LaRiviere <theriver...@gmail.com> wrote:
> This is a DFP for Small Business account.
>
> Here is the XML - auth token.
>
> -----------------BEGIN API CALL---------------------
>
> Request
> -------
>
> POST /apis/ads/publisher/v201010/LineItemCreativeAssociationService
> User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; MS Web Services Client
> Protocol 2.0.50727.4952)
> Content-Type: text/xml; charset=utf-8
> SOAPAction: ""
> Host:www.google.com
> Content-Length: 1182
> TimeStamp: Tue, 25 Jan 2011 15:59:22 GMT
>
> <?xml version="1.0" encoding="utf-8"?><soap:Envelope
> xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Header><RequestHeader
> xmlns="https://www.google.com/apis/ads/publisher/v201010"><authToken>asdf</authToken><networkCode>10485668</networkCode><applicatio nName>DfpApi-DotNet-1.0.0|TriFind.com</applicationName></RequestHeader></so ap:Header><soap:Body><createLineItemCreativeAssociation
> xmlns="https://www.google.com/apis/ads/publisher/v201010"><lineItemCreativeAssociation><lineItemId>2311108</lineItemId><creativeId> 5760426388</creativeId><manualCreativeRotationWeight>1</manualCreativeRotat ionWeight><sizes><width>470</width><height>353</height><isAspectRatio>false </isAspectRatio></sizes><status>ACTIVE</status></lineItemCreativeAssociatio n></createLineItemCreativeAssociation></soap:Body></soap:Envelope>
>
> Response
> --------
>
> X-Content-Type-Options: nosniff
> X-Frame-Options: SAMEORIGIN
> X-XSS-Protection: 1; mode=block
> Transfer-Encoding: chunked
> Cache-Control: private, max-age=0
> Content-Type: text/xml; charset=UTF-8
> Date: Tue, 25 Jan 2011 22:59:55 GMT
> Expires: Tue, 25 Jan 2011 22:59:55 GMT
> Server: GSE
> TimeStamp: Tue, 25 Jan 2011 15:59:22 GMT
>
> <soap:Envelope
> xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Header><ResponseHeader
> xmlns="https://www.google.com/apis/ads/publisher/v201010"><requestId>7208279ffcf3f34e3d6072370bff905a</requestId><responseTime>490< /responseTime></ResponseHeader></soap:Header><soap:Body><soap:Fault><faultc ode>soap:Server</faultcode><faultstring>[RequiredSizeError.NOT_ALLOWED
> @ sizes; trigger:'470x353']</faultstring><detail><ApiExceptionFault
> xmlns="https://www.google.com/apis/ads/publisher/v201010"><message
> xmlns="https://www.google.com/apis/ads/publisher/v201010">[RequiredSizeError.NOT_ALLOWED
> @ sizes; trigger:'470x353']</message><ApplicationException.Type
> xmlns="https://www.google.com/apis/ads/publisher/v201010">ApiException</ApplicationException.Type><errors
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:type="RequiredSizeError"
> xmlns="https://www.google.com/apis/ads/publisher/v201010"><fieldPath
> xmlns="https://www.google.com/apis/ads/publisher/v201010">sizes</fieldPath><trigger
> xmlns="https://www.google.com/apis/ads/publisher/v201010">470x353</trigger><errorString
> xmlns="https://www.google.com/apis/ads/publisher/v201010">RequiredSizeError.NOT_ALLOWED</errorString><ApiError.Type
> xmlns="https://www.google.com/apis/ads/publisher/v201010">RequiredSizeError</ApiError.Type><reason
> xmlns="https://www.google.com/apis/ads/publisher/v201010">NOT_ALLOWED</reason></errors></ApiExceptionFault></detail></soap:Fault></ soap:Body></soap:Envelope>
> -----------------END API CALL-----------------------
>
> host=www.google.com,url=/apis/ads/publisher/v201010/LineItemCreativeAssoci...
Reply all
Reply to author
Forward
0 new messages